Skip to content

Commit

Permalink
drivers/flash: stm32: DT_INST_0_SOC_NV_FLASH_LABEL is not dev name
Browse files Browse the repository at this point in the history
Don't use DT_INST_0_SOC_NV_FLASH_LABEL as device name.
Use DT_FLASH_DEV_NAME instead

Fixes zephyrproject-rtos#23678

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
  • Loading branch information
erwango authored and hakehuang committed Apr 30, 2020
1 parent 41b883d commit fcbc902
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/flash/flash_stm32.c
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,6 @@ static int stm32_flash_init(struct device *dev)
return flash_stm32_write_protection(dev, false);
}

DEVICE_AND_API_INIT(stm32_flash, DT_INST_0_SOC_NV_FLASH_LABEL,
DEVICE_AND_API_INIT(stm32_flash, DT_FLASH_DEV_NAME,
stm32_flash_init, &flash_data, NULL, POST_KERNEL,
CONFIG_KERNEL_INIT_PRIORITY_DEVICE, &flash_stm32_api);

0 comments on commit fcbc902

Please sign in to comment.