aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorAndrew Lunn <andrew@lunn.ch>2012-11-17 11:00:53 -0500
committerJason Cooper <jason@lakedaemon.net>2012-11-23 21:58:30 -0500
commit8d72b4a6cf3d1bac5e2d61acb6abaee254426779 (patch)
tree7ae340948d40fb508cc92e5bdc2fedcb97b9e752 /arch
parentd1d0c04b951e8eb650e84925bcbd78c6b331cfc0 (diff)
ARM: Kirkwood: Convert lsxl boards to pinctrl.
Signed-off-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Michael Walle <michael@walle.cc> Signed-off-by: Jason Cooper <jason@lakedaemon.net>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/boot/dts/kirkwood-lsxl.dtsi66
-rw-r--r--arch/arm/mach-kirkwood/board-lsxl.c19
2 files changed, 66 insertions, 19 deletions
diff --git a/arch/arm/boot/dts/kirkwood-lsxl.dtsi b/arch/arm/boot/dts/kirkwood-lsxl.dtsi
index 32d302ed2ed0..37d45c4f88fb 100644
--- a/arch/arm/boot/dts/kirkwood-lsxl.dtsi
+++ b/arch/arm/boot/dts/kirkwood-lsxl.dtsi
@@ -1,4 +1,5 @@
1/include/ "kirkwood.dtsi" 1/include/ "kirkwood.dtsi"
2/include/ "kirkwood-6281.dtsi"
2 3
3/ { 4/ {
4 chosen { 5 chosen {
@@ -6,6 +7,71 @@
6 }; 7 };
7 8
8 ocp@f1000000 { 9 ocp@f1000000 {
10 pinctrl: pinctrl@10000 {
11
12 pinctrl-0 = < &pmx_power_hdd &pmx_usb_vbus
13 &pmx_fan_low &pmx_fan_high
14 &pmx_led_function_red &pmx_led_alarm
15 &pmx_led_info &pmx_led_power
16 &pmx_fan_lock &pmx_button_function
17 &pmx_power_switch &pmx_power_auto_switch
18 &pmx_led_function_blue >;
19 pinctrl-names = "default";
20
21 pmx_power_hdd: pmx-power-hdd {
22 marvell,pins = "mpp10";
23 marvell,function = "gpo";
24 };
25 pmx_usb_vbus: pmx-usb-vbus {
26 marvell,pins = "mpp11";
27 marvell,function = "gpio";
28 };
29 pmx_fan_high: pmx-fan-high {
30 marvell,pins = "mpp18";
31 marvell,function = "gpo";
32 };
33 pmx_fan_low: pmx-fan-low {
34 marvell,pins = "mpp19";
35 marvell,function = "gpo";
36 };
37 pmx_led_function_blue: pmx-led-function-blue {
38 marvell,pins = "mpp36";
39 marvell,function = "gpio";
40 };
41 pmx_led_alarm: pmx-led-alarm {
42 marvell,pins = "mpp37";
43 marvell,function = "gpio";
44 };
45 pmx_led_info: pmx-led-info {
46 marvell,pins = "mpp38";
47 marvell,function = "gpio";
48 };
49 pmx_led_power: pmx-led-power {
50 marvell,pins = "mpp39";
51 marvell,function = "gpio";
52 };
53 pmx_fan_lock: pmx-fan-lock {
54 marvell,pins = "mpp40";
55 marvell,function = "gpio";
56 };
57 pmx_button_function: pmx-button-function {
58 marvell,pins = "mpp41";
59 marvell,function = "gpio";
60 };
61 pmx_power_switch: pmx-power-switch {
62 marvell,pins = "mpp42";
63 marvell,function = "gpio";
64 };
65 pmx_power_auto_switch: pmx-power-auto-switch {
66 marvell,pins = "mpp43";
67 marvell,function = "gpio";
68 };
69 pmx_led_function_red: pmx-led-function_red {
70 marvell,pins = "mpp48";
71 marvell,function = "gpio";
72 };
73
74 };
9 sata@80000 { 75 sata@80000 {
10 status = "okay"; 76 status = "okay";
11 nr-ports = <1>; 77 nr-ports = <1>;
diff --git a/arch/arm/mach-kirkwood/board-lsxl.c b/arch/arm/mach-kirkwood/board-lsxl.c
index f780e2e0c5dc..d60cdab46f4b 100644
--- a/arch/arm/mach-kirkwood/board-lsxl.c
+++ b/arch/arm/mach-kirkwood/board-lsxl.c
@@ -20,7 +20,6 @@
20#include <linux/spi/spi.h> 20#include <linux/spi/spi.h>
21#include <linux/mv643xx_eth.h> 21#include <linux/mv643xx_eth.h>
22#include "common.h" 22#include "common.h"
23#include "mpp.h"
24 23
25static struct mv643xx_eth_platform_data lsxl_ge00_data = { 24static struct mv643xx_eth_platform_data lsxl_ge00_data = {
26 .phy_addr = MV643XX_ETH_PHY_ADDR(0), 25 .phy_addr = MV643XX_ETH_PHY_ADDR(0),
@@ -30,23 +29,6 @@ static struct mv643xx_eth_platform_data lsxl_ge01_data = {
30 .phy_addr = MV643XX_ETH_PHY_ADDR(8), 29 .phy_addr = MV643XX_ETH_PHY_ADDR(8),
31}; 30};
32 31
33static unsigned int lsxl_mpp_config[] __initdata = {
34 MPP10_GPO, /* HDD Power Enable */
35 MPP11_GPIO, /* USB Vbus Enable */
36 MPP18_GPO, /* FAN High Enable# */
37 MPP19_GPO, /* FAN Low Enable# */
38 MPP36_GPIO, /* Function Blue LED */
39 MPP37_GPIO, /* Alarm LED */
40 MPP38_GPIO, /* Info LED */
41 MPP39_GPIO, /* Power LED */
42 MPP40_GPIO, /* Fan Lock */
43 MPP41_GPIO, /* Function Button */
44 MPP42_GPIO, /* Power Switch */
45 MPP43_GPIO, /* Power Auto Switch */
46 MPP48_GPIO, /* Function Red LED */
47 0
48};
49
50/* 32/*
51 * On the LS-XHL/LS-CHLv2, the shutdown process is following: 33 * On the LS-XHL/LS-CHLv2, the shutdown process is following:
52 * - Userland monitors key events until the power switch goes to off position 34 * - Userland monitors key events until the power switch goes to off position
@@ -65,7 +47,6 @@ void __init lsxl_init(void)
65 /* 47 /*
66 * Basic setup. Needs to be called early. 48 * Basic setup. Needs to be called early.
67 */ 49 */
68 kirkwood_mpp_conf(lsxl_mpp_config);
69 50
70 kirkwood_ge00_init(&lsxl_ge00_data); 51 kirkwood_ge00_init(&lsxl_ge00_data);
71 kirkwood_ge01_init(&lsxl_ge01_data); 52 kirkwood_ge01_init(&lsxl_ge01_data);