Skip to content

Commit ad85283

Browse files
henrikbrixandersenMaureenHelm
authored andcommitted
drivers: adc: ad5592: use K_KERNEL_STACK_SIZEOF()
Use K_KERNEL_STACK_SIZEOF() for calculating thread stack size, as this takes K_KERNEL_STACK_RESERVED into account. Fixes: #69133 Signed-off-by: Henrik Brix Andersen <[email protected]>
1 parent 4274d1b commit ad85283

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/adc/adc_ad5592.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ static int adc_ad5592_init(const struct device *dev)
218218
adc_context_init(&data->ctx);
219219

220220
tid = k_thread_create(&data->thread, data->stack,
221-
CONFIG_ADC_AD5592_ACQUISITION_THREAD_STACK_SIZE,
221+
K_KERNEL_STACK_SIZEOF(data->stack),
222222
(k_thread_entry_t)adc_ad5592_acquisition_thread, data, NULL, NULL,
223223
CONFIG_ADC_AD5592_ACQUISITION_THREAD_PRIO, 0, K_NO_WAIT);
224224

0 commit comments

Comments
 (0)