ARM: Kirkwood: Add DT support for (eSATA) Sheevaplug
Subsystems (6)
cover ARM: Kirkwood: Add DT support for (eSATA) Sheevaplug
These patches add DT support for the Sheevaplugs by Globalscale Technologies. There exists two versions, one with an eSATA port and one without.
Surprisingly, the conversion was not straight forward. In the eSATA version (board revision 1.3), the CD and WP pins are connected to GPIO lines, but I could not get this to work. Apparently, I am not the only one ([1]). I found that the pins are reversed on my hardware and use different active low/active high settings.
Thus, the first patch adds support for the GPIO active low/high flag in DT to the mvsdio driver.
With that, everything except the Gigabit Ethernet can be described in the DTS. I have split the DTS and the board support files into two patches. This way, we can drop the last patch once we can describe everything in the DTS or we can squash them together if we don't want to wait.
I could only test on an eSATA Sheevaplug. I found patches with different LEDs for the Sheevaplug. Thus, I would highly appreciate if someone with the hardware could give this a spin on a non-eSATA version. Some additional testing of the change detect and write protect behaviour for sdio can't hurt either. I hope that there aren't board revisions with different CD/WP pins out there.
[1] http://lists.infradead.org/pipermail/linux-arm-kernel/2011-August/062567.html
Simon Baatz (3):
mmc: mvsdio: Support inverted CD and WP GPIO lines
ARM: Kirkwood: Add dts files for Sheevaplug and eSATA Sheevaplug
ARM: Kirkwood: Add DT support for Sheevaplug and Sheevaplug eSATA
arch/arm/boot/dts/Makefile | 2 + arch/arm/boot/dts/kirkwood-mplcec4.dts | 2 +- arch/arm/boot/dts/kirkwood-sheevaplug-common.dtsi | 97 +++++++++++++++++++++ arch/arm/boot/dts/kirkwood-sheevaplug-esata.dts | 40 +++++++++ arch/arm/boot/dts/kirkwood-sheevaplug.dts | 43 +++++++++ arch/arm/mach-kirkwood/Kconfig | 7 ++ arch/arm/mach-kirkwood/Makefile | 1 + arch/arm/mach-kirkwood/board-dt.c | 4 + arch/arm/mach-kirkwood/board-sheevaplug.c | 27 ++++++ arch/arm/mach-kirkwood/common.h | 5 ++ drivers/mmc/host/mvsdio.c | 14 ++- 11 files changed, 239 insertions(+), 3 deletions(-) create mode 100644 arch/arm/boot/dts/kirkwood-sheevaplug-common.dtsi create mode 100644 arch/arm/boot/dts/kirkwood-sheevaplug-esata.dts create mode 100644 arch/arm/boot/dts/kirkwood-sheevaplug.dts create mode 100644 arch/arm/mach-kirkwood/board-sheevaplug.c
Signature · 1 line
1.7.9.5
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
The slot-gpio helper functions allow to specify whether card detect and write protect GPIO lines are active high or active low. Since DT allows to specify active low/high for GPIO lines as well, we can simply initialize the flags for slot-gpio using the GPIO flags to support all cases.
We need to adapt the dts files that use CD/WP via GPIO accordingly. Only the dts for "MPL CEC4" is affected by this change.
--- arch/arm/boot/dts/kirkwood-mplcec4.dts | 2 +- drivers/mmc/host/mvsdio.c | 14 ++++++++++++-- 2 files changed, 13 insertions(+), 3 deletions(-)
arch/arm/boot/dts/kirkwood-mplcec4.dts +1 -1
@@ -136,7 +136,7 @@ pinctrl-0 = <&pmx_sdio &pmx_sdio_cd>; pinctrl-names = "default"; status = "okay"; - cd-gpios = <&gpio1 15 0>; + cd-gpios = <&gpio1 15 1>; /* No WP GPIO */ }; };
drivers/mmc/host/mvsdio.c +12 -2
@@ -691,6 +691,7 @@ static int __init mvsd_probe(struct platform_device *pdev)struct resource *r;int ret, irq;int gpio_card_detect, gpio_write_protect; +enum of_gpio_flags gpio_flags;struct pinctrl *pinctrl; r =platform_get_resource (pdev,IORESOURCE_MEM ,0 );
@@ -731,8 +732,17 @@ static int __init mvsd_probe(struct platform_device *pdev) } host->base_clock =clk_get_rate (host->clk) /2 ; - gpio_card_detect =of_get_named_gpio (np,"cd-gpios" ,0 ); - gpio_write_protect =of_get_named_gpio (np,"wp-gpios" ,0 ); + gpio_card_detect =of_get_named_gpio_flags (np,"cd-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_card_detect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW )) + mmc->caps2 |=MMC_CAP2_CD_ACTIVE_HIGH ; + + gpio_write_protect =of_get_named_gpio_flags (np,"wp-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_write_protect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW )) + mmc->caps2 |=MMC_CAP2_RO_ACTIVE_HIGH ; }else {const struct mvsdio_platform_data *mvsd_data; mvsd_data = pdev->dev.platform_data;
Signature · 1 line
1.7.9.5
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
Hi Simon,
Quoted 22 lines · Simon Baatz
drivers/mmc/host/mvsdio.c +5
-2@@ -691,6 +691,7 @@ static int __init mvsd_probe(struct platform_device *pdev)struct resource *r;int ret, irq;int gpio_card_detect, gpio_write_protect; +enum of_gpio_flags gpio_flags;struct pinctrl *pinctrl; r =platform_get_resource (pdev,IORESOURCE_MEM ,0 );@@ -731,8 +732,17 @@ static int __init mvsd_probe(struct platform_device *pdev) } host->base_clock =clk_get_rate (host->clk) /2 ; - gpio_card_detect =of_get_named_gpio (np,"cd-gpios" ,0 ); - gpio_write_protect =of_get_named_gpio (np,"wp-gpios" ,0 ); + gpio_card_detect =of_get_named_gpio_flags (np,"cd-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_card_detect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW ))
drivers/mmc/host/mvsdio.c static int __init mvsd_probe(struct platform_device *pdev) · line 748
Quoted 10 lines
drivers/mmc/host/mvsdio.c +7
-0+ mmc->caps2 |=MMC_CAP2_CD_ACTIVE_HIGH ; + + gpio_write_protect =of_get_named_gpio_flags (np,"wp-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_write_protect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW )) + mmc->caps2 |=MMC_CAP2_RO_ACTIVE_HIGH ; }else {const struct mvsdio_platform_data *mvsd_data; mvsd_data = pdev->dev.platform_data;
The core function mmc_of_parse() (new in 3.9) will do all of this DT parsing for you, and will also take care of the driver's later calls to mmc_gpio_request_{cd,wp}(). Could you try using that function instead, please?
Thanks,
- Chris.
Signature · 2 lines
Chris Ball <[email protected]> <http://printf.net/> One Laptop Per Child
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
Quoted 32 lines · Chris Ball
Hi Simon,
Quoted 29 lines · Simon Baatz
drivers/mmc/host/mvsdio.c +12
-2@@ -691,6 +691,7 @@ static int __init mvsd_probe(struct platform_device *pdev)struct resource *r;int ret, irq;int gpio_card_detect, gpio_write_protect; +enum of_gpio_flags gpio_flags;struct pinctrl *pinctrl; r =platform_get_resource (pdev,IORESOURCE_MEM ,0 );@@ -731,8 +732,17 @@ static int __init mvsd_probe(struct platform_device *pdev) } host->base_clock =clk_get_rate (host->clk) /2 ; - gpio_card_detect =of_get_named_gpio (np,"cd-gpios" ,0 ); - gpio_write_protect =of_get_named_gpio (np,"wp-gpios" ,0 ); + gpio_card_detect =of_get_named_gpio_flags (np,"cd-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_card_detect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW )) + mmc->caps2 |=MMC_CAP2_CD_ACTIVE_HIGH ; + + gpio_write_protect =of_get_named_gpio_flags (np,"wp-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_write_protect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW )) + mmc->caps2 |=MMC_CAP2_RO_ACTIVE_HIGH ;
Quoted 8 lines
drivers/mmc/host/mvsdio.c static int __init mvsd_probe(struct platform_device *pdev) · line 748
Quoted 3 lines
drivers/mmc/host/mvsdio.c +0
-0}else {const struct mvsdio_platform_data *mvsd_data; mvsd_data = pdev->dev.platform_data;The core function
mmc_of_parse()(new in 3.9) will do all of this DT parsing for you, and will also take care of the driver's later calls to mmc_gpio_request_{cd,wp}(). Could you try using that function instead, please?
Hi Chris, Simon
I have a vague recollection that Thomas Petazzoni already did this conversion. Take a look in linux-next, or maybe Jason can point you at a branch.
Andrew
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
Quoted 42 lines · Andrew Lunn
Quoted 32 lines · Chris Ball
Hi Simon,
Quoted 29 lines · Simon Baatz
drivers/mmc/host/mvsdio.c +12
-2@@ -691,6 +691,7 @@ static int __init mvsd_probe(struct platform_device *pdev)struct resource *r;int ret, irq;int gpio_card_detect, gpio_write_protect; +enum of_gpio_flags gpio_flags;struct pinctrl *pinctrl; r =platform_get_resource (pdev,IORESOURCE_MEM ,0 );@@ -731,8 +732,17 @@ static int __init mvsd_probe(struct platform_device *pdev) } host->base_clock =clk_get_rate (host->clk) /2 ; - gpio_card_detect =of_get_named_gpio (np,"cd-gpios" ,0 ); - gpio_write_protect =of_get_named_gpio (np,"wp-gpios" ,0 ); + gpio_card_detect =of_get_named_gpio_flags (np,"cd-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_card_detect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW )) + mmc->caps2 |=MMC_CAP2_CD_ACTIVE_HIGH ; + + gpio_write_protect =of_get_named_gpio_flags (np,"wp-gpios" ,0 , + &gpio_flags); +if (gpio_is_valid (gpio_write_protect) && + !(gpio_flags &OF_GPIO_ACTIVE_LOW )) + mmc->caps2 |=MMC_CAP2_RO_ACTIVE_HIGH ;Quoted 8 lines
drivers/mmc/host/mvsdio.c static int __init mvsd_probe(struct platform_device *pdev) · line 748
Quoted 3 lines
drivers/mmc/host/mvsdio.c +0
-0}else {const struct mvsdio_platform_data *mvsd_data; mvsd_data = pdev->dev.platform_data;The core function
mmc_of_parse()(new in 3.9) will do all of this DT parsing for you, and will also take care of the driver's later calls to mmc_gpio_request_{cd,wp}(). Could you try using that function instead, please?
Quoted 5 lines
Hi Chris, Simon
I have a vague recollection that Thomas Petazzoni already did this conversion. Take a look in linux-next, or maybe Jason can point you at a branch.
Andrew,
Thomas did a board conversion here (slated for v3.11 in /pcie branch):
cd2bde5 arm: kirkwood: convert db-88f6281 to the Device Tree
And Sebastian did some mvsdio WP and CD pin work here:
0d0644eARM: Kirkwood: fix unused mvsdio gpio pins
Nothing else really jumps out though. Where either of these what you were thinking of?
thx,
Jason.
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
Quoted 15 lines
Quoted 10 lines
Quoted 4 lines
The core function
mmc_of_parse()(new in 3.9) will do all of this DT parsing for you, and will also take care of the driver's later calls to mmc_gpio_request_{cd,wp}(). Could you try using that function instead, please?Hi Chris, Simon
I have a vague recollection that Thomas Petazzoni already did this conversion. Take a look in linux-next, or maybe Jason can point you at a branch.
Andrew,
Thomas did a board conversion here (slated for v3.11 in /pcie branch):
Quoted 8 lines
cd2bde5 arm: kirkwood: convert db-88f6281 to the Device Tree
And Sebastian did some mvsdio WP and CD pin work here:
0d0644eARM: Kirkwood: fix unused mvsdio gpio pins
Nothing else really jumps out though. Where either of these what you were thinking of?
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138514.html
and
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138513.html
Andrew
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
Hi,
Quoted 8 lines · Andrew Lunn
Quoted 2 lines
Nothing else really jumps out though. Where either of these what you were thinking of?
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138514.html
and
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138513.html
These patches move mvsdio to slot-gpio, which is a prerequisite for using the shared mmc_of_parse(), but they don't go all the way to using mmc_of_parse().
(Which makes sense; mmc_of_parse() was merged to mmc-next in February, so it wasn't available for this patchset in December.)
Thanks,
- Chris.
Signature · 2 lines
Chris Ball <[email protected]> <http://printf.net/> One Laptop Per Child
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
Dear Chris Ball,
Quoted 8 lines · Chris Ball
Quoted 7 lines · Andrew Lunn
Quoted 2 lines
Nothing else really jumps out though. Where either of these what you were thinking of?
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138514.html
and
Quoted 8 lines
These patches move mvsdio to slot-gpio, which is a prerequisite for using the shared
mmc_of_parse(), but they don't go all the way to usingmmc_of_parse().(Which makes sense;
mmc_of_parse()was merged to mmc-next in February, so it wasn't available for this patchset in December.)
Correct. I used the slot-gpio infrastructure in mvsdio, but I wasn't aware of the new mmc_of_parse() thing, and I don't have any patch that converts mvsdio to use it for the moment.
Best regards,
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
In reply to Chris BallHi Chris, Guennadi,
Quoted 8 lines · Chris Ball
Hi,
Quoted 5 lines · Andrew Lunn
Quoted 2 lines
Nothing else really jumps out though. Where either of these what you were thinking of?
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138514.html
Quoted 7 lines
These patches move mvsdio to slot-gpio, which is a prerequisite for using the shared
mmc_of_parse(), but they don't go all the way to usingmmc_of_parse().
That's nice functionality, I was not aware of that. I will convert this to mmc_of_parse() once I find some time.
One question already: Why does mmc_of_parse() not return errors to the caller? If, for example, a GPIO line was given for CD in the DT, but it could not be obtained, shouldn't the caller at least have the possibility to handle this as an error? (mvsdio currently aborts the probe if it can't get the GPIO line).
- Simon
PATCH 1/3 mmc: mvsdio: Support inverted CD and WP GPIO lines
In reply to Andrew LunnQuoted 21 lines · Andrew Lunn
Quoted 21 lines
Quoted 10 lines
Quoted 4 lines
The core function
mmc_of_parse()(new in 3.9) will do all of this DT parsing for you, and will also take care of the driver's later calls to mmc_gpio_request_{cd,wp}(). Could you try using that function instead, please?Hi Chris, Simon
I have a vague recollection that Thomas Petazzoni already did this conversion. Take a look in linux-next, or maybe Jason can point you at a branch.
Andrew,
Thomas did a board conversion here (slated for v3.11 in /pcie branch):
cd2bde5 arm: kirkwood: convert db-88f6281 to the Device Tree
And Sebastian did some mvsdio WP and CD pin work here:
0d0644eARM: Kirkwood: fix unused mvsdio gpio pins
Quoted 8 lines
Quoted 2 lines
Nothing else really jumps out though. Where either of these what you were thinking of?
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138514.html
and
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-December/138513.html
Ahh, they were with the original submission for mvsdio:
07728b7 mmc: mvsdio: use slot-gpio for card detect gpio 3724482 mmc: mvsdio: use slot-gpio infrastructure for write protect gpio
I thought you were referring to a newer patch.
thx,
Jason.
PATCH 2/3 ARM: Kirkwood: Add dts files for Sheevaplug and eSATA Sheevaplug
In reply to Simon Baatz--- arch/arm/boot/dts/Makefile | 2 + arch/arm/boot/dts/kirkwood-sheevaplug-common.dtsi | 97 +++++++++++++++++++++ arch/arm/boot/dts/kirkwood-sheevaplug-esata.dts | 40 +++++++++ arch/arm/boot/dts/kirkwood-sheevaplug.dts | 43 +++++++++ 4 files changed, 182 insertions(+) create mode 100644 arch/arm/boot/dts/kirkwood-sheevaplug-common.dtsi create mode 100644 arch/arm/boot/dts/kirkwood-sheevaplug-esata.dts create mode 100644 arch/arm/boot/dts/kirkwood-sheevaplug.dts
arch/arm/boot/dts/Makefile +2 -0
@@ -70,6 +70,8 @@ dtb-$(CONFIG_ARCH_KIRKWOOD) += kirkwood-dns320.dtb \ kirkwood-ns2max.dtb \ kirkwood-ns2mini.dtb \ kirkwood-nsa310.dtb \ + kirkwood-sheevaplug.dtb \ + kirkwood-sheevaplug-esata.dtb \ kirkwood-topkick.dtb \ kirkwood-ts219-6281.dtb \ kirkwood-ts219-6282.dtb \
arch/arm/boot/dts/kirkwood-sheevaplug-common.dtsi new file +97 -0
97 lines not on this page · raw message
arch/arm/boot/dts/kirkwood-sheevaplug-esata.dts new file +40 -0
@@ -0,0 +1,40 @@ +/* + * kirkwood-sheevaplug-esata.dts - Device tree file for eSATA Sheevaplug + * + * Copyright (C) 2013 Simon Baatz <[email protected]> + * + * Licensed under GPLv2 + */ + +/dts-v1/; + +/include/ "kirkwood-sheevaplug-common.dtsi" + +/ { + model = "Globalscale Technologies eSATA SheevaPlug"; + compatible = "globalscale,sheevaplug-esata-rev13", "globalscale,sheevaplug-esata", "globalscale,sheevaplug", "marvell,kirkwood-88f6281", "marvell,kirkwood"; + + ocp at f1000000 { + pinctrl: pinctrl at 10000 { + + pinctrl-0 = < &pmx_nand &pmx_uart0 + &pmx_usb_power_enable + &pmx_led_blue>; + pinctrl-names = "default"; + + }; + + sata at 80000 { + status = "okay"; + nr-ports = <2>; + }; + + mvsdio at 90000 { + pinctrl-0 = <&pmx_sdio &pmx_sdio_cd &pmx_sdio_wp>; + pinctrl-names = "default"; + status = "okay"; + cd-gpios = <&gpio1 12 1>; + wp-gpios = <&gpio1 15 0>; + }; + }; +};
arch/arm/boot/dts/kirkwood-sheevaplug.dts new file +43 -0
43 lines not on this page · raw message
Signature · 1 line
1.7.9.5
PATCH 3/3 ARM: Kirkwood: Add DT support for Sheevaplug and Sheevaplug eSATA
In reply to Simon Baatz--- arch/arm/mach-kirkwood/Kconfig | 7 +++++++ arch/arm/mach-kirkwood/Makefile | 1 + arch/arm/mach-kirkwood/board-dt.c | 4 ++++ arch/arm/mach-kirkwood/board-sheevaplug.c | 27 +++++++++++++++++++++++++++ arch/arm/mach-kirkwood/common.h | 5 +++++ 5 files changed, 44 insertions(+) create mode 100644 arch/arm/mach-kirkwood/board-sheevaplug.c
arch/arm/mach-kirkwood/Kconfig +7 -0
@@ -58,6 +58,13 @@ config ARCH_KIRKWOOD_DT Say 'Y' here if you want your kernel to support the Marvell Kirkwood using flattened device tree. +config MACH_SHEEVAPLUG_DT + bool "Marvell (eSATA) SheevaPlug (Flattened Device Tree)" + select ARCH_KIRKWOOD_DT + help + Say 'Y' here if you want your kernel to support the + Marvell (eSATA) SheevaPlug (Flattened Device Tree). + config MACH_GURUPLUG_DT bool "Marvell GuruPlug Reference Board (Flattened Device Tree)" select ARCH_KIRKWOOD_DT
arch/arm/mach-kirkwood/Makefile +1 -0
@@ -22,6 +22,7 @@ obj-$(CONFIG_MACH_T5325) += t5325-setup.o obj-$(CONFIG_ARCH_KIRKWOOD_DT) += board-dt.o obj-$(CONFIG_MACH_DREAMPLUG_DT) += board-dreamplug.o obj-$(CONFIG_MACH_GURUPLUG_DT) += board-guruplug.o +obj-$(CONFIG_MACH_SHEEVAPLUG_DT) += board-sheevaplug.o obj-$(CONFIG_MACH_ICONNECT_DT) += board-iconnect.o obj-$(CONFIG_MACH_DLINK_KIRKWOOD_DT) += board-dnskw.o obj-$(CONFIG_MACH_IB62X0_DT) += board-ib62x0.o
arch/arm/mach-kirkwood/board-dt.c +4 -0
@@ -112,6 +112,9 @@ static void __init kirkwood_dt_init(void)if (of_machine_is_compatible ("globalscale,guruplug" ))guruplug_dt_init (); +if (of_machine_is_compatible ("globalscale,sheevaplug" )) +sheevaplug_dt_init (); +if (of_machine_is_compatible ("dlink,dns-kirkwood" ))dnskw_init ();
@@ -161,6 +164,7 @@ static void __init kirkwood_dt_init(void)static const char *const kirkwood_dt_board_compat[] = {"globalscale,dreamplug" ,"globalscale,guruplug" , +"globalscale,sheevaplug" ,"dlink,dns-320" ,"dlink,dns-325" ,"iom,iconnect" ,
arch/arm/mach-kirkwood/board-sheevaplug.c new file +27 -0
@@ -0,0 +1,27 @@ +/* +* arch/arm/mach-kirkwood/board-sheevaplug.c +* +* Marvell Sheevaplug Reference Board Init for drivers not converted to +* flattened device tree yet. +* +* This file is licensed under the terms of the GNU General Public +* License version 2. This program is licensed "as is" without any +* warranty of any kind, whether express or implied. +*/ + +#include <linux/kernel.h> +#include <linux/init.h> +#include <linux/mv643xx_eth.h> +#include "common.h" + +static struct mv643xx_eth_platform_data sheevaplug_ge00_data = { + .phy_addr =MV643XX_ETH_PHY_ADDR (0 ), +}; + +void __init sheevaplug_dt_init (void ) +{ +/* +* Basic setup. Needs to be called early. +*/ +kirkwood_ge00_init (&sheevaplug_ge00_data); +}
arch/arm/mach-kirkwood/common.h +5 -0
@@ -65,6 +65,11 @@ void guruplug_dt_init(void);#else static inline void guruplug_dt_init (void ) {};#endif +#ifdef CONFIG_MACH_SHEEVAPLUG_DT +void sheevaplug_dt_init (void ); +#else +static inline void sheevaplug_dt_init (void ) {}; +#endif #ifdef CONFIG_MACH_TS219_DT void qnap_dt_ts219_init (void );#else
Signature · 1 line
1.7.9.5
cover ARM: Kirkwood: Add DT support for (eSATA) Sheevaplug
In reply to Simon BaatzQuoted 19 lines · Simon Baatz
These patches add DT support for the Sheevaplugs by Globalscale Technologies. There exists two versions, one with an eSATA port and one without.
Surprisingly, the conversion was not straight forward. In the eSATA version (board revision 1.3), the CD and WP pins are connected to GPIO lines, but I could not get this to work. Apparently, I am not the only one ([1]). I found that the pins are reversed on my hardware and use different active low/active high settings.
Thus, the first patch adds support for the GPIO active low/high flag in DT to the mvsdio driver.
With that, everything except the Gigabit Ethernet can be described in the DTS. I have split the DTS and the board support files into two patches. This way, we can drop the last patch once we can describe everything in the DTS or we can squash them together if we don't want to wait.
Quoted 6 lines
I could only test on an eSATA Sheevaplug. I found patches with different LEDs for the Sheevaplug. Thus, I would highly appreciate if someone with the hardware could give this a spin on a non-eSATA version. Some additional testing of the change detect and write protect behaviour for sdio can't hurt either. I hope that there aren't board revisions with different CD/WP pins out there.
Hi Simon
Patches 2 and 3 look good to me. If you submit a new version with the SDIO issue resolved i can give you a Acked-by:
Thanks
Andrew
cover ARM: Kirkwood: Add DT support for (eSATA) Sheevaplug
In reply to Simon BaatzQuoted 26 lines · Simon Baatz
These patches add DT support for the Sheevaplugs by Globalscale Technologies. There exists two versions, one with an eSATA port and one without.
Surprisingly, the conversion was not straight forward. In the eSATA version (board revision 1.3), the CD and WP pins are connected to GPIO lines, but I could not get this to work. Apparently, I am not the only one ([1]). I found that the pins are reversed on my hardware and use different active low/active high settings.
Thus, the first patch adds support for the GPIO active low/high flag in DT to the mvsdio driver.
With that, everything except the Gigabit Ethernet can be described in the DTS. I have split the DTS and the board support files into two patches. This way, we can drop the last patch once we can describe everything in the DTS or we can squash them together if we don't want to wait.
I could only test on an eSATA Sheevaplug. I found patches with different LEDs for the Sheevaplug. Thus, I would highly appreciate if someone with the hardware could give this a spin on a non-eSATA version. Some additional testing of the change detect and write protect behaviour for sdio can't hurt either. I hope that there aren't board revisions with different CD/WP pins out there.
Quoted 6 lines
[1] http://lists.infradead.org/pipermail/linux-arm-kernel/2011-August/062567.html
Simon Baatz (3):
mmc: mvsdio: Support inverted CD and WP GPIO lines
ARM: Kirkwood: Add dts files for Sheevaplug and eSATA Sheevaplug
ARM: Kirkwood: Add DT support for Sheevaplug and Sheevaplug eSATA
Simon,
Were you able to find any time to work on this?
thx,
Jason.