From patchwork Sat Nov 17 16:00:44 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Lunn X-Patchwork-Id: 1759651 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id 6221BDFFEC for ; Sat, 17 Nov 2012 16:03:59 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TZkq0-0008Dd-P5; Sat, 17 Nov 2012 16:01:44 +0000 Received: from londo.lunn.ch ([2001:1620:f9f:1000::1]) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TZkpf-0008Ac-AB for linux-arm-kernel@lists.infradead.org; Sat, 17 Nov 2012 16:01:24 +0000 Received: from lunn by londo.lunn.ch with local (Exim 3.36 #1 (Debian)) id 1TZkpS-0003fn-00; Sat, 17 Nov 2012 17:01:10 +0100 From: Andrew Lunn To: Jason Cooper Subject: [PATCH v2 02/14] ARM: Kirkwood: Make use of mvebu pincltl and gpio drivers Date: Sat, 17 Nov 2012 17:00:44 +0100 Message-Id: <1353168058-14043-3-git-send-email-andrew@lunn.ch> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1353168058-14043-1-git-send-email-andrew@lunn.ch> References: <1353168058-14043-1-git-send-email-andrew@lunn.ch> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20121117_110123_623559_37F0EBF7 X-CRM114-Status: GOOD ( 11.35 ) X-Spam-Score: -2.6 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.6 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record -0.7 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Andrew Lunn , linux ARM X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Select the generic mvebu kirkwood pincltr driver and generic mvebu gpio driver. This requires minor changes to the DT, and the calls to configure plat-orion gpio driver are removed. Signed-off-by: Andrew Lunn Tested-by: Michael Walle Tested-by: Simon Baatz Tested-by: Jamie Lentin Tested-by: Joshua Coombs --- arch/arm/Kconfig | 2 ++ arch/arm/boot/dts/kirkwood.dtsi | 10 ++++++++-- arch/arm/plat-orion/irq.c | 6 +----- 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index ade7e92..bf1df2b 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -547,6 +547,8 @@ config ARCH_KIRKWOOD select CPU_FEROCEON select GENERIC_CLOCKEVENTS select PCI + select PINCTRL + select PINCTRL_KIRKWOOD select PLAT_ORION_LEGACY help Support for the following Marvell Kirkwood series SoCs: diff --git a/arch/arm/boot/dts/kirkwood.dtsi b/arch/arm/boot/dts/kirkwood.dtsi index 4e5b815..6f4a97a 100644 --- a/arch/arm/boot/dts/kirkwood.dtsi +++ b/arch/arm/boot/dts/kirkwood.dtsi @@ -4,6 +4,10 @@ compatible = "marvell,kirkwood"; interrupt-parent = <&intc>; + aliases { + gpio0 = &gpio0; + gpio1 = &gpio1; + }; intc: interrupt-controller { compatible = "marvell,orion-intc", "marvell,intc"; interrupt-controller; @@ -24,7 +28,8 @@ #gpio-cells = <2>; gpio-controller; reg = <0x10100 0x40>; - ngpio = <32>; + ngpios = <32>; + interrupt-controller; interrupts = <35>, <36>, <37>, <38>; }; @@ -33,7 +38,8 @@ #gpio-cells = <2>; gpio-controller; reg = <0x10140 0x40>; - ngpio = <18>; + ngpios = <18>; + interrupt-controller; interrupts = <39>, <40>, <41>; }; diff --git a/arch/arm/plat-orion/irq.c b/arch/arm/plat-orion/irq.c index 1867944..8db0b98 100644 --- a/arch/arm/plat-orion/irq.c +++ b/arch/arm/plat-orion/irq.c @@ -41,7 +41,7 @@ void __init orion_irq_init(unsigned int irq_start, void __iomem *maskaddr) static int __init orion_add_irq_domain(struct device_node *np, struct device_node *interrupt_parent) { - int i = 0, irq_gpio; + int i = 0; void __iomem *base; do { @@ -54,10 +54,6 @@ static int __init orion_add_irq_domain(struct device_node *np, irq_domain_add_legacy(np, i * 32, 0, 0, &irq_domain_simple_ops, NULL); - - irq_gpio = i * 32; - orion_gpio_of_init(irq_gpio); - return 0; }