drivers: serial: Refactor drivers to use shared init priority Kconfig
Refactors all of the serial drivers to use a shared driver class initialization priority configuration, CONFIG_SERIAL_INIT_PRIORITY, to allow configuring serial drivers separately from other devices. This is similar to other driver classes like I2C and SPI. The default is set to CONFIG_KERNEL_INIT_PRIORITY_DEVICE to preserve the existing default initialization priority for most drivers. The one exception is uart_lpc11u6x.c which previously used CONFIG_KERNEL_INIT_PRIORITY_OBJECTS. This change was motivated by an issue on the frdm_k64f board where the serial driver was incorrectly initialized before the clock control driver. Signed-off-by: Maureen Helm <maureen.helm@intel.com>
This commit is contained in:
parent
6d2b91461b
commit
ad1450510a
44 changed files with 62 additions and 56 deletions
|
@ -443,7 +443,7 @@ DEVICE_DT_INST_DEFINE(0,
|
|||
NULL,
|
||||
&pl011_data_port_0,
|
||||
&pl011_cfg_port_0, PRE_KERNEL_1,
|
||||
CONFIG_KERNEL_INIT_PRIORITY_DEVICE,
|
||||
CONFIG_SERIAL_INIT_PRIORITY,
|
||||
&pl011_driver_api);
|
||||
|
||||
#ifdef CONFIG_UART_INTERRUPT_DRIVEN
|
||||
|
@ -506,7 +506,7 @@ DEVICE_DT_INST_DEFINE(1,
|
|||
NULL,
|
||||
&pl011_data_port_1,
|
||||
&pl011_cfg_port_1, PRE_KERNEL_1,
|
||||
CONFIG_KERNEL_INIT_PRIORITY_DEVICE,
|
||||
CONFIG_SERIAL_INIT_PRIORITY,
|
||||
&pl011_driver_api);
|
||||
|
||||
#ifdef CONFIG_UART_INTERRUPT_DRIVEN
|
||||
|
@ -571,7 +571,7 @@ DEVICE_DT_INST_DEFINE(0,
|
|||
NULL,
|
||||
&pl011_data_sbsa,
|
||||
&pl011_cfg_sbsa, PRE_KERNEL_1,
|
||||
CONFIG_KERNEL_INIT_PRIORITY_DEVICE,
|
||||
CONFIG_SERIAL_INIT_PRIORITY,
|
||||
&pl011_driver_api);
|
||||
|
||||
#ifdef CONFIG_UART_INTERRUPT_DRIVEN
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue