Commit 48543bd8 authored by Kent Gibson's avatar Kent Gibson Committed by Bartosz Golaszewski
Browse files

gpiolib: fix unwatch ioctl()



Fix the field having a bit cleared by the unwatch ioctl().

Fixes: 51c1064e ("gpiolib: add new ioctl() for monitoring changes in line info")
Signed-off-by: default avatarKent Gibson <warthog618@gmail.com>
Signed-off-by: default avatarBartosz Golaszewski <bgolaszewski@baylibre.com>
parent df2cd589
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1276,7 +1276,7 @@ static long gpio_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
		if (IS_ERR(desc))
			return PTR_ERR(desc);

		clear_bit(desc_to_gpio(desc), &desc->flags);
		clear_bit(desc_to_gpio(desc), priv->watched_lines);
		return 0;
	}
	return -EINVAL;