linux-mips
[Top] [All Lists]

Re: [PATCH 1/2] ar7: fix build failures when CONFIG_SERIAL_8250 is not e

To: Ralf Baechle <ralf@linux-mips.org>
Subject: Re: [PATCH 1/2] ar7: fix build failures when CONFIG_SERIAL_8250 is not enabled
From: Florian Fainelli <florian@openwrt.org>
Date: Fri, 24 Jul 2009 13:24:15 +0200
Cc: linux-mips@linux-mips.org
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:message-id; bh=z3EtnKpG7gyPdclqulLOHkWB9uFHOdfoXf+H1mOx4hc=; b=B/X7CQ3DsIuUmcvOOseW1T6LDpD8IpXxF5VDyyu1aSW+69vZB6MDxTGLxy1Q5+z9Xc XKXYhOP+Kw4wbuftnb3gPlp1c2WrDNtX3qg/thJ5lQQJy+RbKv4zXK0cuu3lW7H2BFNr /mQuvMcPGui3Kbmm8DGQGuzcsxy2PKqwcn0Vc=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding :content-disposition:message-id; b=Qx6L9gpuuC8VmWBwE3pt/rmT0vBAet0fTQDDU90/32yAB2SUOxtwEGvn3hAh6sESti rWLDlXLDI3o68k8MG2LeOVf8qU6YkNLEl1M63jVxtInuq7VbEDVZ4pRTqlqV/oZmeTpX vbYMjv/40dRCCr62WtbSZvtFuk6fUh4EV2bUQ=
In-reply-to: <20090721150811.GA18826@linux-mips.org>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <200907211237.39264.florian@openwrt.org> <20090721150811.GA18826@linux-mips.org>
Sender: linux-mips-bounce@linux-mips.org
User-agent: KMail/1.9.9
Le Tuesday 21 July 2009 17:08:12 Ralf Baechle, vous avez écrit :
> On Tue, Jul 21, 2009 at 12:37:37PM +0200, Florian Fainelli wrote:
> > This patch fixes the following build failure when CONFIG_SERIAL_8250
> > is not enabled in the kernel configuration:
> > arch/mips/ar7/built-in.o: In function `ar7_register_devices':
> > platform.c:(.init.text+0x61c): undefined reference to
> > `early_serial_setup' platform.c:(.init.text+0x61c): relocation truncated
> > to fit: R_MIPS_26 against `early_serial_setup'
> > platform.c:(.init.text+0x68c): undefined reference to
> > `early_serial_setup' platform.c:(.init.text+0x68c): relocation truncated
> > to fit: R_MIPS_26 against `early_serial_setup'
>
> This patch rejects.

The one I sent previously applies to -queue, the one below applies to -master. 
Thanks !
--
From: Florian Fainelli <florian@openwrt.org>
Subject: [PATCH] ar7: fix build failures when CONFIG_SERIAL_8250 is not enabled

This patch fixes the following build failure when CONFIG_SERIAL_8250
is not enabled in the kernel configuration:
arch/mips/ar7/built-in.o: In function `ar7_register_devices':
platform.c:(.init.text+0x61c): undefined reference to `early_serial_setup'
platform.c:(.init.text+0x61c): relocation truncated to fit: R_MIPS_26 against 
`early_serial_setup'
platform.c:(.init.text+0x68c): undefined reference to `early_serial_setup'
platform.c:(.init.text+0x68c): relocation truncated to fit: R_MIPS_26 against 
`early_serial_setup'

Signed-off-by: Florian Fainelli <florian@openwrt.org>
---
diff --git a/arch/mips/ar7/platform.c b/arch/mips/ar7/platform.c
index c4d71fb..8ef8266 100644
--- a/arch/mips/ar7/platform.c
+++ b/arch/mips/ar7/platform.c
@@ -480,6 +480,7 @@ static void __init detect_leds(void)
 static int __init ar7_register_devices(void)
 {
        int res;
+#ifdef CONFIG_SERIAL_8250
        static struct uart_port uart_port[2];
 
        memset(uart_port, 0, sizeof(struct uart_port) * 2);
@@ -511,7 +512,7 @@ static int __init ar7_register_devices(void)
                if (res)
                        return res;
        }
-
+#endif /* CONFIG_SERIAL_8250 */
        res = platform_device_register(&physmap_flash);
        if (res)
                return res;

<Prev in Thread] Current Thread [Next in Thread>