aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpio/gpiolib.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c
index 3707930e082e..584d2b465f84 100644
--- a/drivers/gpio/gpiolib.c
+++ b/drivers/gpio/gpiolib.c
@@ -2005,15 +2005,15 @@ EXPORT_SYMBOL_GPL(gpiod_is_active_low);
2005 * that the GPIO was actually requested. 2005 * that the GPIO was actually requested.
2006 */ 2006 */
2007 2007
2008static int _gpiod_get_raw_value(const struct gpio_desc *desc) 2008static bool _gpiod_get_raw_value(const struct gpio_desc *desc)
2009{ 2009{
2010 struct gpio_chip *chip; 2010 struct gpio_chip *chip;
2011 int value; 2011 bool value;
2012 int offset; 2012 int offset;
2013 2013
2014 chip = desc->chip; 2014 chip = desc->chip;
2015 offset = gpio_chip_hwgpio(desc); 2015 offset = gpio_chip_hwgpio(desc);
2016 value = chip->get ? chip->get(chip, offset) : 0; 2016 value = chip->get ? chip->get(chip, offset) : false;
2017 trace_gpio_value(desc_to_gpio(desc), 1, value); 2017 trace_gpio_value(desc_to_gpio(desc), 1, value);
2018 return value; 2018 return value;
2019} 2019}
@@ -2069,7 +2069,7 @@ EXPORT_SYMBOL_GPL(gpiod_get_value);
2069 * @desc: gpio descriptor whose state need to be set. 2069 * @desc: gpio descriptor whose state need to be set.
2070 * @value: Non-zero for setting it HIGH otherise it will set to LOW. 2070 * @value: Non-zero for setting it HIGH otherise it will set to LOW.
2071 */ 2071 */
2072static void _gpio_set_open_drain_value(struct gpio_desc *desc, int value) 2072static void _gpio_set_open_drain_value(struct gpio_desc *desc, bool value)
2073{ 2073{
2074 int err = 0; 2074 int err = 0;
2075 struct gpio_chip *chip = desc->chip; 2075 struct gpio_chip *chip = desc->chip;
@@ -2096,7 +2096,7 @@ static void _gpio_set_open_drain_value(struct gpio_desc *desc, int value)
2096 * @desc: gpio descriptor whose state need to be set. 2096 * @desc: gpio descriptor whose state need to be set.
2097 * @value: Non-zero for setting it HIGH otherise it will set to LOW. 2097 * @value: Non-zero for setting it HIGH otherise it will set to LOW.
2098 */ 2098 */
2099static void _gpio_set_open_source_value(struct gpio_desc *desc, int value) 2099static void _gpio_set_open_source_value(struct gpio_desc *desc, bool value)
2100{ 2100{
2101 int err = 0; 2101 int err = 0;
2102 struct gpio_chip *chip = desc->chip; 2102 struct gpio_chip *chip = desc->chip;
@@ -2118,7 +2118,7 @@ static void _gpio_set_open_source_value(struct gpio_desc *desc, int value)
2118 __func__, err); 2118 __func__, err);
2119} 2119}
2120 2120
2121static void _gpiod_set_raw_value(struct gpio_desc *desc, int value) 2121static void _gpiod_set_raw_value(struct gpio_desc *desc, bool value)
2122{ 2122{
2123 struct gpio_chip *chip; 2123 struct gpio_chip *chip;
2124 2124