diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2024-03-04 15:27:03 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-03-05 16:38:28 +0300 |
commit | 79d713baf63c8f23cc58b304c40be33d64a12aaf (patch) | |
tree | 12e3fcbe59772419b3e89573bfacb6b5adb2c4f9 /include/linux/serial_core.h | |
parent | 35c822a34b2293aedf475238c395e75858d1e8c8 (diff) | |
download | linux-79d713baf63c8f23cc58b304c40be33d64a12aaf.tar.xz |
serial: core: Add UPIO_UNKNOWN constant for unknown port type
In some APIs we would like to assign the special value to iotype
and compare against it in another places. Introduce UPIO_UNKNOWN
for this purpose.
Note, we can't use 0, because it's a valid value for IO port access.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20240304123035.758700-3-andriy.shevchenko@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/serial_core.h')
-rw-r--r-- | include/linux/serial_core.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/serial_core.h b/include/linux/serial_core.h index f9d7f0a625fd..3b64c9a26945 100644 --- a/include/linux/serial_core.h +++ b/include/linux/serial_core.h @@ -470,6 +470,7 @@ struct uart_port { unsigned char iotype; /* io access style */ +#define UPIO_UNKNOWN ((unsigned char)~0U) /* UCHAR_MAX */ #define UPIO_PORT (SERIAL_IO_PORT) /* 8b I/O port access */ #define UPIO_HUB6 (SERIAL_IO_HUB6) /* Hub6 ISA card */ #define UPIO_MEM (SERIAL_IO_MEM) /* driver-specific */ |