From patchwork Wed Oct 24 14:53:53 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Lunn X-Patchwork-Id: 1639021 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 A5FA5DF2AB for ; Wed, 24 Oct 2012 14:58: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 1TR2NK-0005bq-RG; Wed, 24 Oct 2012 14:56:08 +0000 Received: from londo.lunn.ch ([80.238.139.98]) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TR2Ls-000556-UN for linux-arm-kernel@lists.infradead.org; Wed, 24 Oct 2012 14:54:38 +0000 Received: from lunn by londo.lunn.ch with local (Exim 3.36 #1 (Debian)) id 1TR2LT-0007xe-00; Wed, 24 Oct 2012 16:54:11 +0200 From: Andrew Lunn To: jm@lentin.co.uk, Sebastian Hesselbarth , Jason Cooper , josh.coombs@gmail.com, gmbnomis@gmail.com, arnaud.patard@rtp-net.org, alanbutty12@gmail.com, michael@walle.cc Subject: [PATCH 8/9] ARM: Kirkwood: Convert lsxl boards to pinctrl. Date: Wed, 24 Oct 2012 16:53:53 +0200 Message-Id: <1351090434-30499-9-git-send-email-andrew@lunn.ch> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1351090434-30499-1-git-send-email-andrew@lunn.ch> References: <1351090434-30499-1-git-send-email-andrew@lunn.ch> X-Spam-Note: CRM114 invocation failed X-Spam-Score: 0.4 (/) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (0.4 points) pts rule name description ---- ---------------------- -------------------------------------------------- 3.0 KHOP_BIG_TO_CC Sent to 10+ recipients instaed of Bcc or a list -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: valentin.longchamp@keymile.com, linux ARM , Andrew Lunn 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 Signed-off-by: Andrew Lunn --- arch/arm/boot/dts/kirkwood-lsxl.dtsi | 67 ++++++++++++++++++++++++++++++++++ arch/arm/mach-kirkwood/board-lsxl.c | 19 ---------- 2 files changed, 67 insertions(+), 19 deletions(-) diff --git a/arch/arm/boot/dts/kirkwood-lsxl.dtsi b/arch/arm/boot/dts/kirkwood-lsxl.dtsi index 8fea375..01d6e3a 100644 --- a/arch/arm/boot/dts/kirkwood-lsxl.dtsi +++ b/arch/arm/boot/dts/kirkwood-lsxl.dtsi @@ -6,6 +6,73 @@ }; ocp@f1000000 { + pinctrl: pinctrl@10000 { + compatible = "marvell,88f6281-pinctrl"; + reg = <0x10000 0x20>; + + pinctrl-0 = < &pmx_power_hdd &pmx_usb_vbus + &pmx_fan_low &pmx_fan_high + &pmx_led_function_red &pmx_led_alarm + &pmx_led_info &pmx_led_power + &pmx_fan_lock &pmx_button_function + &pmx_power_switch &pmx_power_auto_switch + &pmx_led_function_blue >; + pinctrl-names = "default"; + + pmx_power_hdd: pmx-power-hdd { + marvell,pins = "mpp10"; + marvell,function = "gpio"; + }; + pmx_usb_vbus: pmx-usb-vbus { + marvell,pins = "mpp11"; + marvell,function = "gpio"; + }; + pmx_fan_high: pmx-fan-high { + marvell,pins = "mpp18"; + marvell,function = "gpo"; + }; + pmx_fan_low: pmx-fan-low { + marvell,pins = "mpp19"; + marvell,function = "gpo"; + }; + pmx_led_function_blue: pmx-led-function-blue { + marvell,pins = "mpp36"; + marvell,function = "gpio"; + }; + pmx_led_alarm: pmx-led-alarm { + marvell,pins = "mpp37"; + marvell,function = "gpio"; + }; + pmx_led_info: pmx-led-info { + marvell,pins = "mpp38"; + marvell,function = "gpio"; + }; + pmx_led_power: pmx-led-power { + marvell,pins = "mpp39"; + marvell,function = "gpio"; + }; + pmx_fan_lock: pmx-fan-lock { + marvell,pins = "mpp40"; + marvell,function = "gpo"; + }; + pmx_button_function: pmx-button-function { + marvell,pins = "mpp41"; + marvell,function = "gpio"; + }; + pmx_power_switch: pmx-power-switch { + marvell,pins = "mpp42"; + marvell,function = "gpio"; + }; + pmx_power_auto_switch: pmx-power-auto-switch { + marvell,pins = "mpp43"; + marvell,function = "gpio"; + }; + pmx_led_function_red: pmx-led-function_red { + marvell,pins = "mpp43"; + marvell,function = "gpio"; + }; + + }; sata@80000 { status = "okay"; nr-ports = <1>; diff --git a/arch/arm/mach-kirkwood/board-lsxl.c b/arch/arm/mach-kirkwood/board-lsxl.c index 83d8975..868bdb0 100644 --- a/arch/arm/mach-kirkwood/board-lsxl.c +++ b/arch/arm/mach-kirkwood/board-lsxl.c @@ -26,7 +26,6 @@ #include #include #include "common.h" -#include "mpp.h" static struct mv643xx_eth_platform_data lsxl_ge00_data = { .phy_addr = MV643XX_ETH_PHY_ADDR(0), @@ -36,23 +35,6 @@ static struct mv643xx_eth_platform_data lsxl_ge01_data = { .phy_addr = MV643XX_ETH_PHY_ADDR(8), }; -static unsigned int lsxl_mpp_config[] __initdata = { - MPP10_GPO, /* HDD Power Enable */ - MPP11_GPIO, /* USB Vbus Enable */ - MPP18_GPO, /* FAN High Enable# */ - MPP19_GPO, /* FAN Low Enable# */ - MPP36_GPIO, /* Function Blue LED */ - MPP37_GPIO, /* Alarm LED */ - MPP38_GPIO, /* Info LED */ - MPP39_GPIO, /* Power LED */ - MPP40_GPIO, /* Fan Lock */ - MPP41_GPIO, /* Function Button */ - MPP42_GPIO, /* Power Switch */ - MPP43_GPIO, /* Power Auto Switch */ - MPP48_GPIO, /* Function Red LED */ - 0 -}; - #define LSXL_GPIO_FAN_HIGH 18 #define LSXL_GPIO_FAN_LOW 19 #define LSXL_GPIO_FAN_LOCK 40 @@ -119,7 +101,6 @@ void __init lsxl_init(void) /* * Basic setup. Needs to be called early. */ - kirkwood_mpp_conf(lsxl_mpp_config); /* usb and sata power on */ gpio_set_value(LSXL_GPIO_USB_POWER, 1);