diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpio/altera_pio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpio/altera_pio.c b/drivers/gpio/altera_pio.c index 59e30979f0..324f9c29a8 100644 --- a/drivers/gpio/altera_pio.c +++ b/drivers/gpio/altera_pio.c @@ -56,7 +56,7 @@ static int altera_pio_get_value(struct udevice *dev, unsigned pin) struct altera_pio_platdata *plat = dev_get_platdata(dev); struct altera_pio_regs *const regs = plat->regs; - return readl(®s->data) & (1 << pin); + return !!(readl(®s->data) & (1 << pin)); } |