summaryrefslogtreecommitdiff
path: root/drivers/hid/hid-cmedia.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/hid/hid-cmedia.c')
-rw-r--r--drivers/hid/hid-cmedia.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hid/hid-cmedia.c b/drivers/hid/hid-cmedia.c
index 6bc50df9b3e1..7b3dd4197875 100644
--- a/drivers/hid/hid-cmedia.c
+++ b/drivers/hid/hid-cmedia.c
@@ -99,7 +99,7 @@ static int cmhid_raw_event(struct hid_device *hid, struct hid_report *report,
{
struct cmhid *cm = hid_get_drvdata(hid);
- if (len != CM6533_JD_RAWEV_LEN)
+ if (len != CM6533_JD_RAWEV_LEN || !(hid->claimed & HID_CLAIMED_INPUT))
goto out;
if (memcmp(data+CM6533_JD_SFX_OFFSET, ji_sfx, sizeof(ji_sfx)))
goto out;