]> git.ipfire.org Git - thirdparty/linux.git/commit
serial: qcom-geni: Avoid probing debug console UART without console support
authorAniket Randive <aniket.randive@oss.qualcomm.com>
Mon, 4 May 2026 10:10:45 +0000 (15:40 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 11 May 2026 15:21:12 +0000 (17:21 +0200)
commit16e95bfb79b5d9d01dc7651d98caf3c2ace331cd
treec34ed47015ce2581718b88dd8735183cd20f5456
parentebd57bda9df6234d93e05dfe2fd250c6535ca3bb
serial: qcom-geni: Avoid probing debug console UART without console support

When CONFIG_SERIAL_QCOM_GENI_CONSOLE is disabled, the driver still
advertises the debug UART compatible strings ("qcom,geni-debug-uart"
and "qcom,sa8255p-geni-debug-uart") in its of_match table. This lets the
driver match and probe console UART DT nodes even though console
support is not built. As a result, the console port is never registered
with the UART core and uart_add_one_port() fails with -EINVAL.

Fix this by only including the debug UART compatible entries in the
match table when CONFIG_SERIAL_QCOM_GENI_CONSOLE is enabled, preventing
the driver from probing console UART nodes when console support is
absent.

Reviewed-by: Praveen Talari <praveen.talari@oss.qualcomm.com>
Signed-off-by: Aniket Randive <aniket.randive@oss.qualcomm.com>
Link: https://patch.msgid.link/20260504101045.1084672-1-aniket.randive@oss.qualcomm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/qcom_geni_serial.c