aboutsummaryrefslogtreecommitdiff
path: root/drivers/input
diff options
context:
space:
mode:
authorXi Wang <xi.wang@gmail.com>2011-12-11 23:40:56 -0800
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2011-12-12 00:01:02 -0800
commit3a7f8fb1d8c9b6a066b0452cea47c85547c97723 (patch)
treea19b49539c47ce77f84a85e6abb685a7198acdce /drivers/input
parent0d0e3064a88cc8d6bd3a9b43c5ae069ca838fc6e (diff)
Input: cma3000_d0x - fix signedness bug in cma3000_thread_irq()
The error check (intr_status < 0) didn't work because intr_status is a u8. Change its type to signed int. Signed-off-by: Xi Wang <xi.wang@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/misc/cma3000_d0x.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/input/misc/cma3000_d0x.c b/drivers/input/misc/cma3000_d0x.c
index 1633b634226..09f8f202558 100644
--- a/drivers/input/misc/cma3000_d0x.c
+++ b/drivers/input/misc/cma3000_d0x.c
@@ -114,8 +114,8 @@ static void decode_mg(struct cma3000_accl_data *data, int *datax,
static irqreturn_t cma3000_thread_irq(int irq, void *dev_id)
{
struct cma3000_accl_data *data = dev_id;
- int datax, datay, dataz;
- u8 ctrl, mode, range, intr_status;
+ int datax, datay, dataz, intr_status;
+ u8 ctrl, mode, range;
intr_status = CMA3000_READ(data, CMA3000_INTSTATUS, "interrupt status");
if (intr_status < 0)