From patchwork Mon Jun 17 16:33:51 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Figa X-Patchwork-Id: 2735571 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 5642FC0AB1 for ; Mon, 17 Jun 2013 17:13:09 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id BE2A2202AF for ; Mon, 17 Jun 2013 17:13:07 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C059C202AE for ; Mon, 17 Jun 2013 17:13:06 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UocSm-0002Da-Ns; Mon, 17 Jun 2013 16:39:31 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UocQz-0006Na-Ru; Mon, 17 Jun 2013 16:37:37 +0000 Received: from mailout3.w1.samsung.com ([210.118.77.13]) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UocOt-00061t-M9 for linux-arm-kernel@lists.infradead.org; Mon, 17 Jun 2013 16:35:32 +0000 Received: from eucpsbgm2.samsung.com (unknown [203.254.199.245]) by mailout3.w1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MOJ00MBNQ1N6260@mailout3.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 17 Jun 2013 17:34:42 +0100 (BST) X-AuditID: cbfec7f5-b7f376d000001ec6-2b-51bf3aa206a6 Received: from eusync3.samsung.com ( [203.254.199.213]) by eucpsbgm2.samsung.com (EUCPMTA) with SMTP id 9F.3B.07878.2AA3FB15; Mon, 17 Jun 2013 17:34:42 +0100 (BST) Received: from amdc1227.digital.local ([106.116.147.199]) by eusync3.samsung.com (Oracle Communications Messaging Server 7u4-23.01(7.0.4.23.0) 64bit (built Aug 10 2011)) with ESMTPA id <0MOJ002RHQ1OMHC0@eusync3.samsung.com>; Mon, 17 Jun 2013 17:34:42 +0100 (BST) From: Tomasz Figa To: linux-samsung-soc@vger.kernel.org Subject: [PATCH v2 06/38] ARM: EXYNOS: common: Remove legacy UART initialization code Date: Mon, 17 Jun 2013 18:33:51 +0200 Message-id: <1371486863-12398-7-git-send-email-t.figa@samsung.com> X-Mailer: git-send-email 1.8.2.1 In-reply-to: <1371486863-12398-1-git-send-email-t.figa@samsung.com> References: <1371486863-12398-1-git-send-email-t.figa@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFupgluLIzCtJLcpLzFFi42I5/e/4Vd1FVvsDDTbeFLD4O+kYu0Xvgqts Fmeb3rBbbHp8jdVixvl9TBZrj9xltzh1/TObxeE37awW62e8ZrE4NmMJowOXx+9fkxg97lzb w+axeUm9x5UTTawefVtWMXp83iQXwBbFZZOSmpNZllqkb5fAldF+5wFLwSmJitft5Q2MzSJd jJwcEgImEvcXzWeFsMUkLtxbz9bFyMUhJLCUUeLHmh1sIAkhgT4miSXnw0BsNgE1ic8Nj8Di IgKqEp/bFrCDNDALvGSSuNv4gB0kISwQLrF60kawqSxARXe6LjCB2LwCThK32w8wQ2xTkDi+ fRsjiM0p4CyxuO8WM8QyJ4ndMy+xTmDkXcDIsIpRNLU0uaA4KT3XSK84Mbe4NC9dLzk/dxMj JPS+7mBceszqEKMAB6MSD2+i2P5AIdbEsuLK3EOMEhzMSiK8sRP3BQrxpiRWVqUW5ccXleak Fh9iZOLglGpgdGg1DN6w9biBVrDyxq/xPgeWJj2caaU83+Zw+poWm3uf7qrEr3W/bTzFqvHV xt6mP4c4ayRUdW6e0cjWOrnuu4vw0w6Tezf7PEOCGPObM8tOCtUxiDRcem25YbWV0JHZNces tOZXLZ++yFtnzc52nokVonHurKnVD5cliJY8XfKwJW5Xb7OyEktxRqKhFnNRcSIAEt5ALxsC AAA= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130617_123527_867156_2795FE54 X-CRM114-Status: GOOD ( 13.34 ) X-Spam-Score: -8.0 (--------) Cc: Kukjin Kim , Arnd Bergmann , Tomasz Figa , Kyungmin Park , Thomas Abraham , Sylwester Nawrocki , Olof Johansson , linux-arm-kernel@lists.infradead.org, Marek Szyprowski X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-5.3 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch removes legacy UART initialization code that was used to set up UART platform devices when booting with ATAGS, which is not supported on Exynos any more. Signed-off-by: Tomasz Figa Signed-off-by: Kyungmin Park --- arch/arm/mach-exynos/common.c | 17 ----------------- arch/arm/plat-samsung/init.c | 8 +++++--- 2 files changed, 5 insertions(+), 20 deletions(-) diff --git a/arch/arm/mach-exynos/common.c b/arch/arm/mach-exynos/common.c index 488d9bd..598e4b8 100644 --- a/arch/arm/mach-exynos/common.c +++ b/arch/arm/mach-exynos/common.c @@ -69,7 +69,6 @@ static const char name_exynos5440[] = "EXYNOS5440"; static void exynos4_map_io(void); static void exynos5_map_io(void); static void exynos5440_map_io(void); -static void exynos4_init_uarts(struct s3c2410_uartcfg *cfg, int no); static int exynos_init(void); unsigned long xxti_f = 0, xusbxti_f = 0; @@ -79,21 +78,18 @@ static struct cpu_table cpu_ids[] __initdata = { .idcode = EXYNOS4210_CPU_ID, .idmask = EXYNOS4_CPU_MASK, .map_io = exynos4_map_io, - .init_uarts = exynos4_init_uarts, .init = exynos_init, .name = name_exynos4210, }, { .idcode = EXYNOS4212_CPU_ID, .idmask = EXYNOS4_CPU_MASK, .map_io = exynos4_map_io, - .init_uarts = exynos4_init_uarts, .init = exynos_init, .name = name_exynos4212, }, { .idcode = EXYNOS4412_CPU_ID, .idmask = EXYNOS4_CPU_MASK, .map_io = exynos4_map_io, - .init_uarts = exynos4_init_uarts, .init = exynos_init, .name = name_exynos4412, }, { @@ -602,16 +598,3 @@ static int __init exynos_init(void) return device_register(&exynos4_dev); } - -/* uart registration process */ - -static void __init exynos4_init_uarts(struct s3c2410_uartcfg *cfg, int no) -{ - struct s3c2410_uartcfg *tcfg = cfg; - u32 ucnt; - - for (ucnt = 0; ucnt < no; ucnt++, tcfg++) - tcfg->has_fracval = 1; - - s3c24xx_init_uartdevs("exynos4210-uart", exynos4_uart_resources, cfg, no); -} diff --git a/arch/arm/plat-samsung/init.c b/arch/arm/plat-samsung/init.c index 79d10fc..3e5c461 100644 --- a/arch/arm/plat-samsung/init.c +++ b/arch/arm/plat-samsung/init.c @@ -87,7 +87,7 @@ void __init s3c24xx_init_clocks(int xtal) } /* uart management */ - +#if IS_ENABLED(CONFIG_SAMSUNG_ATAGS) static int nr_uarts __initdata = 0; static struct s3c2410_uartcfg uart_cfgs[CONFIG_SERIAL_SAMSUNG_UARTS]; @@ -134,11 +134,12 @@ void __init s3c24xx_init_uarts(struct s3c2410_uartcfg *cfg, int no) if (cpu == NULL) return; - if (cpu->init_uarts == NULL) { + if (cpu->init_uarts == NULL && IS_ENABLED(CONFIG_SAMSUNG_ATAGS)) { printk(KERN_ERR "s3c24xx_init_uarts: cpu has no uart init\n"); } else (cpu->init_uarts)(cfg, no); } +#endif static int __init s3c_arch_init(void) { @@ -152,8 +153,9 @@ static int __init s3c_arch_init(void) ret = (cpu->init)(); if (ret != 0) return ret; - +#if IS_ENABLED(CONFIG_SAMSUNG_ATAGS) ret = platform_add_devices(s3c24xx_uart_devs, nr_uarts); +#endif return ret; }