diff options
author | Alan Cox <alan@linux.intel.com> | 2012-11-20 11:33:14 -0500 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2012-11-20 11:35:57 -0500 |
commit | e3bbe8755c9c947d80f88c8a2a81073dbc01bd1f (patch) | |
tree | 5056ee0fbca7e8c573a63b65aac4f2a465fd4977 /drivers/hid | |
parent | d339f61d14692517e9ba5a977fc266769d6c5c28 (diff) |
HID: sensor-hub: Remove pointless NULL check
report cannot be NULL, fortunately as we use it before we check !
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid')
-rw-r--r-- | drivers/hid/hid-sensor-hub.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/hid/hid-sensor-hub.c b/drivers/hid/hid-sensor-hub.c index d9d73e9163eb..4ff24977544d 100644 --- a/drivers/hid/hid-sensor-hub.c +++ b/drivers/hid/hid-sensor-hub.c | |||
@@ -437,9 +437,6 @@ static int sensor_hub_raw_event(struct hid_device *hdev, | |||
437 | ptr = raw_data; | 437 | ptr = raw_data; |
438 | ptr++; /*Skip report id*/ | 438 | ptr++; /*Skip report id*/ |
439 | 439 | ||
440 | if (!report) | ||
441 | goto err_report; | ||
442 | |||
443 | spin_lock_irqsave(&pdata->lock, flags); | 440 | spin_lock_irqsave(&pdata->lock, flags); |
444 | 441 | ||
445 | for (i = 0; i < report->maxfield; ++i) { | 442 | for (i = 0; i < report->maxfield; ++i) { |
@@ -485,7 +482,6 @@ static int sensor_hub_raw_event(struct hid_device *hdev, | |||
485 | callback->pdev); | 482 | callback->pdev); |
486 | spin_unlock_irqrestore(&pdata->lock, flags); | 483 | spin_unlock_irqrestore(&pdata->lock, flags); |
487 | 484 | ||
488 | err_report: | ||
489 | return 1; | 485 | return 1; |
490 | } | 486 | } |
491 | 487 | ||