diff options
| author | Tom Rini <[email protected]> | 2026-03-23 13:53:04 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2026-04-07 11:32:46 -0600 |
| commit | 25d55485dbced189f8d0400fb0da58b19e196662 (patch) | |
| tree | d1dec4ef926b02fc1cd853ce4a86df333d89cc22 /drivers/serial | |
| parent | ff031c34210f3c573dbb84196dadf0c4f2017aca (diff) | |
serial: ns16550: Fix an "unused" warning with SERIAL_PRESENT=n and OF_REAL=y
The definition of our ID table is guarded with OF_REAL however the
U_BOOT_DRIVER that would in turn use the table is guarded with
SERIAL_PRESENT. To avoid a potential warning we must also guard the
ID table with SERIAL_PRESENT.
Signed-off-by: Tom Rini <[email protected]>
Diffstat (limited to 'drivers/serial')
| -rw-r--r-- | drivers/serial/ns16550.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/serial/ns16550.c b/drivers/serial/ns16550.c index 2f24f47badf..10271f46aa6 100644 --- a/drivers/serial/ns16550.c +++ b/drivers/serial/ns16550.c @@ -586,6 +586,7 @@ const struct dm_serial_ops ns16550_serial_ops = { .getinfo = ns16550_serial_getinfo, }; +#if CONFIG_IS_ENABLED(SERIAL_PRESENT) #if CONFIG_IS_ENABLED(OF_REAL) /* * Please consider existing compatible strings before adding a new @@ -603,8 +604,6 @@ static const struct udevice_id ns16550_serial_ids[] = { }; #endif /* OF_REAL */ -#if CONFIG_IS_ENABLED(SERIAL_PRESENT) - /* TODO([email protected]): Integrate this into a macro like CONFIG_IS_ENABLED */ #if !defined(CONFIG_TPL_BUILD) || defined(CONFIG_TPL_DM_SERIAL) U_BOOT_DRIVER(ns16550_serial) = { |
