From f8a7fc6cda8705d8c1628af1ce9a91894ab9597d Mon Sep 17 00:00:00 2001 From: Jiri Kosina Date: Thu, 6 Dec 2012 10:59:28 +0100 Subject: [PATCH] --- yaml --- r: 343072 b: refs/heads/master c: 9afd09a1db93cc9084846c2b9bc0d1194743e5dc h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/hid/i2c-hid/i2c-hid.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 1145660d5d64..bf368056b18d 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: e5b50fe7bea43d0658773c89ba410ecc56867ee6 +refs/heads/master: 9afd09a1db93cc9084846c2b9bc0d1194743e5dc diff --git a/trunk/drivers/hid/i2c-hid/i2c-hid.c b/trunk/drivers/hid/i2c-hid/i2c-hid.c index ce01d5916184..6e1774c3a3f9 100644 --- a/trunk/drivers/hid/i2c-hid/i2c-hid.c +++ b/trunk/drivers/hid/i2c-hid/i2c-hid.c @@ -520,7 +520,7 @@ static int i2c_hid_get_raw_report(struct hid_device *hid, ret_count = ihid->inbuf[0] | (ihid->inbuf[1] << 8); - if (!ret_count) + if (ret_count <= 2) return 0; ret_count = min(ret_count, ask_count);