diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2013-07-14 23:03:13 -0400 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2013-08-14 00:58:21 -0400 |
commit | e0f5fa99a378d6910d234f3c8998aebfe2f54745 (patch) | |
tree | 4818750ef6773042ff2898b73aff6de57788499f /arch/powerpc/kernel/legacy_serial.c | |
parent | 309257484cc1a592e8ac5fbdd8cd661be2b80bf8 (diff) |
powerpc: Check "status" property before adding legacy ISA serial ports
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel/legacy_serial.c')
-rw-r--r-- | arch/powerpc/kernel/legacy_serial.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/arch/powerpc/kernel/legacy_serial.c b/arch/powerpc/kernel/legacy_serial.c index 9a4d9fe9ff1c..c9c469f3c5c3 100644 --- a/arch/powerpc/kernel/legacy_serial.c +++ b/arch/powerpc/kernel/legacy_serial.c | |||
@@ -386,9 +386,11 @@ void __init find_legacy_serial_ports(void) | |||
386 | struct device_node *isa = of_get_parent(np); | 386 | struct device_node *isa = of_get_parent(np); |
387 | if (isa && (!strcmp(isa->name, "isa") || | 387 | if (isa && (!strcmp(isa->name, "isa") || |
388 | !strcmp(isa->name, "lpc"))) { | 388 | !strcmp(isa->name, "lpc"))) { |
389 | index = add_legacy_isa_port(np, isa); | 389 | if (of_device_is_available(np)) { |
390 | if (index >= 0 && np == stdout) | 390 | index = add_legacy_isa_port(np, isa); |
391 | legacy_serial_console = index; | 391 | if (index >= 0 && np == stdout) |
392 | legacy_serial_console = index; | ||
393 | } | ||
392 | } | 394 | } |
393 | of_node_put(isa); | 395 | of_node_put(isa); |
394 | } | 396 | } |