All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/4] mfd: aat2870-core: Use gpio_request_one
@ 2011-12-01  1:47 Axel Lin
  2011-12-01  1:49 ` [PATCH 2/4] mfd: dm355evm_msp: " Axel Lin
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Axel Lin @ 2011-12-01  1:47 UTC (permalink / raw)
  To: linux-kernel; +Cc: Jin Park, Samuel Ortiz

Use gpio_request_one() instead of multiple gpiolib calls.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
 drivers/mfd/aat2870-core.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mfd/aat2870-core.c b/drivers/mfd/aat2870-core.c
index 02c4201..7620617 100644
--- a/drivers/mfd/aat2870-core.c
+++ b/drivers/mfd/aat2870-core.c
@@ -407,13 +407,13 @@ static int aat2870_i2c_probe(struct i2c_client *client,
 		aat2870->init(aat2870);
 
 	if (aat2870->en_pin >= 0) {
-		ret = gpio_request(aat2870->en_pin, "aat2870-en");
+		ret = gpio_request_one(aat2870->en_pin, GPIOF_OUT_INIT_HIGH,
+				       "aat2870-en");
 		if (ret < 0) {
 			dev_err(&client->dev,
 				"Failed to request GPIO %d\n", aat2870->en_pin);
 			goto out_kfree;
 		}
-		gpio_direction_output(aat2870->en_pin, 1);
 	}
 
 	aat2870_enable(aat2870);
-- 
1.7.5.4




^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2011-12-19 11:08 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-01  1:47 [PATCH 1/4] mfd: aat2870-core: Use gpio_request_one Axel Lin
2011-12-01  1:49 ` [PATCH 2/4] mfd: dm355evm_msp: " Axel Lin
2011-12-01  1:53 ` [PATCH 3/4] mfd: omap-usb-host: " Axel Lin
2011-12-01  8:02   ` Igor Grinberg
2011-12-01  1:55 ` [PATCH 4/4] mfd: twl6040-core: " Axel Lin
2011-12-01  8:02   ` Igor Grinberg
2011-12-01  8:18     ` Axel Lin
2011-12-01  9:10       ` Igor Grinberg
2011-12-01  8:38 ` [PATCH 1/4] mfd: aat2870-core: " Jinyoung Park
2011-12-19 11:13 ` Samuel Ortiz

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.