]> git.ipfire.org Git - thirdparty/linux.git/commit
serial: 8250: longson: Fix NULL vs IS_ERR() bug in probe
authorDan Carpenter <dan.carpenter@linaro.org>
Sat, 29 Nov 2025 14:51:23 +0000 (17:51 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Dec 2025 14:11:00 +0000 (15:11 +0100)
commit5edb7338d6117bb0ce17ead7973c67390da42258
tree9f2e27385dc1f96cb49780450878a9d1e8302208
parent24ec03cc55126b7b3adf102f4b3d9f716532b329
serial: 8250: longson: Fix NULL vs IS_ERR() bug in probe

The devm_platform_get_and_ioremap_resource() function never returns
NULL, it returns error pointers.  Fix the error checking to match.

Fixes: 25e95d763176 ("serial: 8250: Add Loongson uart driver support")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Link: https://patch.msgid.link/aSsIa3KdAlXh5uQC@stanley.mountain
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_loongson.c