From 955b44304afca143b82304fe421e990ec607834a Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Sat, 10 Mar 2012 04:58:18 -0300 Subject: [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 Reviewed-by: Trilok Soni Signed-off-by: Mauro Carvalho Chehab --- include/media/gpio-ir-recv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/media/gpio-ir-recv.h b/include/media/gpio-ir-recv.h index 61a7fbb47127..67797bf5d432 100644 --- a/include/media/gpio-ir-recv.h +++ b/include/media/gpio-ir-recv.h @@ -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; }; -- cgit v1.2.3