[media] gpio-ir-recv: a couple signedness bugs
There are couple places where we check unsigned values for negative. I changed ->gpin_nr to signed because in gpio_ir_recv_probe() we do: if (pdata->gpio_nr < 0) return -EINVAL; I also change gval to a signed int in gpio_ir_recv_irq() because that's the type that gpio_get_value_cansleep() returns and we test for negative returns. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Trilok Soni <tsoni@codeaurora.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:

committed by
Mauro Carvalho Chehab

parent
23bfb5be9f
commit
955b44304a
@@ -14,7 +14,7 @@
|
||||
#define __GPIO_IR_RECV_H__
|
||||
|
||||
struct gpio_ir_recv_platform_data {
|
||||
unsigned int gpio_nr;
|
||||
int gpio_nr;
|
||||
bool active_low;
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user