From: John Linn Date: Tue, 1 Jul 2008 17:52:41 +0000 (-0700) Subject: powerpc/legacy_serial: Bail if reg-offset/shift properties are present X-Git-Tag: v2.6.26-rc9~83^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1e6d1f260611387a7b4e6eae4d1dd6f62e53714d;p=platform%2Fkernel%2Flinux-stable.git powerpc/legacy_serial: Bail if reg-offset/shift properties are present The legacy serial driver does not work with an 8250 type UART that is described in the device tree with the reg-offset and reg-shift properties. This change makes legacy_serial ignore these devices. Signed-off-by: John Linn Signed-off-by: Grant Likely --- diff --git a/arch/powerpc/kernel/legacy_serial.c b/arch/powerpc/kernel/legacy_serial.c index 61dd174..cf37f5c 100644 --- a/arch/powerpc/kernel/legacy_serial.c +++ b/arch/powerpc/kernel/legacy_serial.c @@ -136,6 +136,11 @@ static int __init add_legacy_soc_port(struct device_node *np, if (of_get_property(np, "clock-frequency", NULL) == NULL) return -1; + /* if reg-shift or offset, don't try to use it */ + if ((of_get_property(np, "reg-shift", NULL) != NULL) || + (of_get_property(np, "reg-offset", NULL) != NULL)) + return -1; + /* if rtas uses this device, don't try to use it as well */ if (of_get_property(np, "used-by-rtas", NULL) != NULL) return -1;