diff options
author | Johan Hovold <jhovold@gmail.com> | 2013-03-12 15:21:34 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-12 19:20:45 -0400 |
commit | 2d798a3f20ae992b0b69a2b68c04ada397c32ed4 (patch) | |
tree | a8eb78bbbcbf2f2ff7cb1b4f1d07979ad2aaee56 | |
parent | f6161aa153581da4a3867a2d1a7caf4be19b6ec9 (diff) |
ARM: w1-gpio: fix erroneous gpio requests
Fix regression introduced by commit d2323cf773 ("onewire: w1-gpio: add
ext_pullup_enable pin in platform data") which added a gpio entry to the
platform data, but did not add the required initialisers to the board
files using it. Consequently, the driver would request gpio 0 at probe,
which could break other uses of the corresponding pin.
On AT91 requesting gpio 0 changes the pin muxing for PIOA0, which, for
instance, breaks SPI0 on at91sam9g20.
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | arch/arm/mach-at91/board-foxg20.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-at91/board-stamp9g20.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-ixp4xx/vulcan-setup.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-pxa/raumfeld.c | 1 |
4 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm/mach-at91/board-foxg20.c b/arch/arm/mach-at91/board-foxg20.c index 2ea7059b840b..c20a870ea9c9 100644 --- a/arch/arm/mach-at91/board-foxg20.c +++ b/arch/arm/mach-at91/board-foxg20.c | |||
@@ -176,6 +176,7 @@ static struct w1_gpio_platform_data w1_gpio_pdata = { | |||
176 | /* If you choose to use a pin other than PB16 it needs to be 3.3V */ | 176 | /* If you choose to use a pin other than PB16 it needs to be 3.3V */ |
177 | .pin = AT91_PIN_PB16, | 177 | .pin = AT91_PIN_PB16, |
178 | .is_open_drain = 1, | 178 | .is_open_drain = 1, |
179 | .ext_pullup_enable_pin = -EINVAL, | ||
179 | }; | 180 | }; |
180 | 181 | ||
181 | static struct platform_device w1_device = { | 182 | static struct platform_device w1_device = { |
diff --git a/arch/arm/mach-at91/board-stamp9g20.c b/arch/arm/mach-at91/board-stamp9g20.c index a033b8df9fb2..869cbecf00b7 100644 --- a/arch/arm/mach-at91/board-stamp9g20.c +++ b/arch/arm/mach-at91/board-stamp9g20.c | |||
@@ -188,6 +188,7 @@ static struct spi_board_info portuxg20_spi_devices[] = { | |||
188 | static struct w1_gpio_platform_data w1_gpio_pdata = { | 188 | static struct w1_gpio_platform_data w1_gpio_pdata = { |
189 | .pin = AT91_PIN_PA29, | 189 | .pin = AT91_PIN_PA29, |
190 | .is_open_drain = 1, | 190 | .is_open_drain = 1, |
191 | .ext_pullup_enable_pin = -EINVAL, | ||
191 | }; | 192 | }; |
192 | 193 | ||
193 | static struct platform_device w1_device = { | 194 | static struct platform_device w1_device = { |
diff --git a/arch/arm/mach-ixp4xx/vulcan-setup.c b/arch/arm/mach-ixp4xx/vulcan-setup.c index d42730a1d4ab..d599e354ca57 100644 --- a/arch/arm/mach-ixp4xx/vulcan-setup.c +++ b/arch/arm/mach-ixp4xx/vulcan-setup.c | |||
@@ -163,6 +163,7 @@ static struct platform_device vulcan_max6369 = { | |||
163 | 163 | ||
164 | static struct w1_gpio_platform_data vulcan_w1_gpio_pdata = { | 164 | static struct w1_gpio_platform_data vulcan_w1_gpio_pdata = { |
165 | .pin = 14, | 165 | .pin = 14, |
166 | .ext_pullup_enable_pin = -EINVAL, | ||
166 | }; | 167 | }; |
167 | 168 | ||
168 | static struct platform_device vulcan_w1_gpio = { | 169 | static struct platform_device vulcan_w1_gpio = { |
diff --git a/arch/arm/mach-pxa/raumfeld.c b/arch/arm/mach-pxa/raumfeld.c index af41888acbd6..969b0ba7fa70 100644 --- a/arch/arm/mach-pxa/raumfeld.c +++ b/arch/arm/mach-pxa/raumfeld.c | |||
@@ -505,6 +505,7 @@ static struct w1_gpio_platform_data w1_gpio_platform_data = { | |||
505 | .pin = GPIO_ONE_WIRE, | 505 | .pin = GPIO_ONE_WIRE, |
506 | .is_open_drain = 0, | 506 | .is_open_drain = 0, |
507 | .enable_external_pullup = w1_enable_external_pullup, | 507 | .enable_external_pullup = w1_enable_external_pullup, |
508 | .ext_pullup_enable_pin = -EINVAL, | ||
508 | }; | 509 | }; |
509 | 510 | ||
510 | struct platform_device raumfeld_w1_gpio_device = { | 511 | struct platform_device raumfeld_w1_gpio_device = { |