mirror of
https://github.com/torvalds/linux.git
synced 2026-10-17 06:20:02 +02:00
serial: 8250_keba: Use dev_err_probe()
Simplify the probe() code by using dev_err_probe(). Suggested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Gerhard Engleder <eg@keba.com> Link: https://patch.msgid.link/20251216193726.55449-4-gerhard@engleder-embedded.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
ee086a69c3
commit
e5484745c4
|
|
@ -252,10 +252,9 @@ static int kuart_probe(struct auxiliary_device *auxdev,
|
|||
}
|
||||
|
||||
retval = serial8250_register_8250_port(&uart);
|
||||
if (retval < 0) {
|
||||
dev_err(&auxdev->dev, "UART registration failed!\n");
|
||||
return retval;
|
||||
}
|
||||
if (retval < 0)
|
||||
return dev_err_probe(&auxdev->dev, retval,
|
||||
"UART registration failed!\n");
|
||||
kuart->line = retval;
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user