]> git.baikalelectronics.ru Git - kernel.git/commit
NFC: pn544: use flags argument of devm_gpiod_get to set direction
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Tue, 19 May 2015 07:22:56 +0000 (09:22 +0200)
committerSamuel Ortiz <sameo@linux.intel.com>
Mon, 8 Jun 2015 22:34:19 +0000 (00:34 +0200)
commit05680ec860b8b28d1186ee56a707f6649a7342da
tree25e554acdb674a980351cfd7346ad2905834193b
parent057511bb93c9f5d1191e5b41cadaa159adf678a4
NFC: pn544: use flags argument of devm_gpiod_get to set direction

Since 5767dae43dee (gpio: add flags argument to gpiod_get*()
functions) which appeared in v3.17-rc1, the gpiod_get* functions
take an additional parameter that allows to specify direction and
initial value for output.

Use this to simplify the driver. Furthermore this is one caller less
that stops us making the flags argument to gpiod_get*() mandatory.

While touching this also do some minor coding style fixes.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
drivers/nfc/pn544/i2c.c