mips: Return proper error code from console ->setup() hook
For unifying console ->setup() handling, which is poorly documented, return error code, rather than non-zero arbitrary number. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Petr Mladek <pmladek@suse.com> Acked-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de> Signed-off-by: Petr Mladek <pmladek@suse.com> Link: https://lore.kernel.org/r/20200618164751.56828-2-andriy.shevchenko@linux.intel.com
This commit is contained in:
parent
5c2fb57af0
commit
4fc29e63cc
|
@ -28,7 +28,9 @@ static void prom_console_write(struct console *co, const char *s,
|
|||
|
||||
static int prom_console_setup(struct console *co, char *options)
|
||||
{
|
||||
return !(prom_flags & PROM_FLAG_USE_AS_CONSOLE);
|
||||
if (prom_flags & PROM_FLAG_USE_AS_CONSOLE)
|
||||
return 0;
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
static struct console arc_cons = {
|
||||
|
|
Loading…
Reference in New Issue