From: kbuild test robot <lkp@intel.com>
To: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Cc: kbuild-all@01.org, Jiri Kosina <jikos@kernel.org>,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH] HID: lg: fix noderef.cocci warnings
Date: Mon, 21 Nov 2016 20:05:31 +0800 [thread overview]
Message-ID: <20161121120531.GA65643@xian.lkp.intel.com> (raw)
In-Reply-To: <1479725322-30863-3-git-send-email-benjamin.tissoires@redhat.com>
drivers/hid/hid-lg.c:780:47-53: ERROR: application of sizeof to pointer
sizeof when applied to a pointer typed expression gives the size of
the pointer
Generated by: scripts/coccinelle/misc/noderef.cocci
CC: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
---
hid-lg.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
--- a/drivers/hid/hid-lg.c
+++ b/drivers/hid/hid-lg.c
@@ -777,8 +777,10 @@ static int lg_probe(struct hid_device *h
buf[1] = 0xB2;
get_random_bytes(&buf[2], 2);
- ret = hid_hw_raw_request(hdev, buf[0], buf, sizeof(buf),
- HID_FEATURE_REPORT, HID_REQ_SET_REPORT);
+ ret = hid_hw_raw_request(hdev, buf[0], buf,
+ sizeof(*buf),
+ HID_FEATURE_REPORT,
+ HID_REQ_SET_REPORT);
}
kfree(buf);
}
next prev parent reply other threads:[~2016-11-21 12:06 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-21 10:48 [PATCH 0/4] HID: fix few non-DMA capable HID transfers Benjamin Tissoires
2016-11-21 10:48 ` [PATCH 1/4] HID: cp2112: make transfer buffers DMA capable Benjamin Tissoires
2016-11-21 10:48 ` [PATCH 2/4] HID: lg: " Benjamin Tissoires
2016-11-21 12:05 ` kbuild test robot [this message]
2016-11-21 14:17 ` [PATCH] HID: lg: fix noderef.cocci warnings Benjamin Tissoires
2016-11-22 10:44 ` Jiri Kosina
2016-11-23 2:22 ` Fengguang Wu
2016-11-23 7:03 ` Julia Lawall
2016-11-21 12:05 ` [PATCH 2/4] HID: lg: make transfer buffers DMA capable kbuild test robot
2016-11-21 10:48 ` [PATCH 3/4] HID: magicmouse: " Benjamin Tissoires
2016-11-21 10:48 ` [PATCH 4/4] HID: rmi: " Benjamin Tissoires
2016-11-23 16:44 ` [PATCH 0/4] HID: fix few non-DMA capable HID transfers Jiri Kosina
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20161121120531.GA65643@xian.lkp.intel.com \
--to=lkp@intel.com \
--cc=benjamin.tissoires@redhat.com \
--cc=jikos@kernel.org \
--cc=kbuild-all@01.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).