diff options
author | Olof Johansson <olof@lixom.net> | 2013-11-15 18:17:59 -0500 |
---|---|---|
committer | Olof Johansson <olof@lixom.net> | 2013-11-15 18:17:59 -0500 |
commit | 6886059f2ef5d62c73e87a905e84fa4f87d56074 (patch) | |
tree | dfe6e1611d7c50057df52db7b55eafbfb8e33a93 /arch/arm/mach-ixp4xx/nslu2-setup.c | |
parent | ca439c9b983ffa14e9eae6030e3ee80ad039388f (diff) | |
parent | 26273e02a0cf18eb72416559310d3294390a9024 (diff) |
Merge tag 'omap-for-v3.13/fixes-for-merge-window-take2' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes
Few clock fixes, a runtime PM fix, and pinctrl-single fix along
with few other fixes that popped up during the merge window.
* tag 'omap-for-v3.13/fixes-for-merge-window-take2' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
ARM: OMAP2+: Fix build for dra7xx without omap4 and 5
ARM: OMAP2+: omap_device: maintain sane runtime pm status around suspend/resume
doc: devicetree: Add bindings documentation for omap-des driver
ARM: dts: doc: Document missing compatible property for omap-sham driver
ARM: OMAP3: Beagle: fix return value check in beagle_opp_init()
ARM: OMAP: devicetree: fix SPI node compatible property syntax items
pinctrl: single: call pcs_soc->rearm() whenever IRQ mask is changed
ARM: OMAP2+: smsc911x: fix return value check in gpmc_smsc911x_init()
+ sync with newer trunk
Diffstat (limited to 'arch/arm/mach-ixp4xx/nslu2-setup.c')
-rw-r--r-- | arch/arm/mach-ixp4xx/nslu2-setup.c | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/arch/arm/mach-ixp4xx/nslu2-setup.c b/arch/arm/mach-ixp4xx/nslu2-setup.c index 7e55236c26ea..ba5f1cda2a9d 100644 --- a/arch/arm/mach-ixp4xx/nslu2-setup.c +++ b/arch/arm/mach-ixp4xx/nslu2-setup.c | |||
@@ -197,11 +197,8 @@ static void nslu2_power_off(void) | |||
197 | { | 197 | { |
198 | /* This causes the box to drop the power and go dead. */ | 198 | /* This causes the box to drop the power and go dead. */ |
199 | 199 | ||
200 | /* enable the pwr cntl gpio */ | 200 | /* enable the pwr cntl gpio and assert power off */ |
201 | gpio_line_config(NSLU2_PO_GPIO, IXP4XX_GPIO_OUT); | 201 | gpio_direction_output(NSLU2_PO_GPIO, 1); |
202 | |||
203 | /* do the deed */ | ||
204 | gpio_line_set(NSLU2_PO_GPIO, IXP4XX_GPIO_HIGH); | ||
205 | } | 202 | } |
206 | 203 | ||
207 | static irqreturn_t nslu2_power_handler(int irq, void *dev_id) | 204 | static irqreturn_t nslu2_power_handler(int irq, void *dev_id) |
@@ -223,6 +220,16 @@ static irqreturn_t nslu2_reset_handler(int irq, void *dev_id) | |||
223 | return IRQ_HANDLED; | 220 | return IRQ_HANDLED; |
224 | } | 221 | } |
225 | 222 | ||
223 | static int __init nslu2_gpio_init(void) | ||
224 | { | ||
225 | if (!machine_is_nslu2()) | ||
226 | return 0; | ||
227 | |||
228 | /* Request the power off GPIO */ | ||
229 | return gpio_request(NSLU2_PO_GPIO, "power off"); | ||
230 | } | ||
231 | device_initcall(nslu2_gpio_init); | ||
232 | |||
226 | static void __init nslu2_timer_init(void) | 233 | static void __init nslu2_timer_init(void) |
227 | { | 234 | { |
228 | /* The xtal on this machine is non-standard. */ | 235 | /* The xtal on this machine is non-standard. */ |