Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1546506
| Path | csiph.com!eternal-september.org!feeder.eternal-september.org!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> |
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 2/2] HID: intel-ish-hid: format 32-bit integers with %X |
| Date | Thu, 22 Dec 2016 18:20:02 +0100 |
| Message-ID | <sRfc6-3Sa-25@gated-at.bofh.it> (permalink) |
| References | <sR8DE-8bR-21@gated-at.bofh.it> <sR8DE-8bR-19@gated-at.bofh.it> |
| X-Extloop1 | 1 |
| X-Ironport-Av | E=Sophos;i="5.33,389,1477983600"; d="scan'208";a="1075300602" |
| Content-Type | text/plain; charset="UTF-8" |
| X-Mailer | Evolution 3.18.5.2 (3.18.5.2-1.fc23) |
| MIME-Version | 1.0 |
| Content-Transfer-Encoding | 8bit |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 40 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | linux-input@vger.kernel.org, linux-kernel@vger.kernel.org |
| X-Original-Date | Thu, 22 Dec 2016 09:12:16 -0800 |
| X-Original-Message-ID | <1482426736.6264.18.camel@linux.intel.com> |
| X-Original-References | <20161222100910.6179-1-nicolas.iooss_linux@m4x.org> <20161222100910.6179-2-nicolas.iooss_linux@m4x.org> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1546506 |
Show key headers only | View raw
On Thu, 2016-12-22 at 11:09 +0100, Nicolas Iooss wrote: > In ishtp_hid_probe(), use %04X instead of %04hX to format __u32 > values, > in order to silent a format error reported by clang: > > drivers/hid/intel-ish-hid/ishtp-hid.c:212:3: error: format > specifies > type 'unsigned short' but the argument has type '__u32' (aka > 'unsigned int') [-Werror,-Wformat] > hid->vendor, hid->product); > ^~~~~~~~~~~ > drivers/hid/intel-ish-hid/ishtp-hid.c:212:16: error: format > specifies type 'unsigned short' but the argument has type '__u32' > (aka 'unsigned int') [-Werror,-Wformat] > hid->vendor, hid->product); > ^~~~~~~~~~~~ > > Signed-off-by: Nicolas Iooss <nicolas.iooss_linux@m4x.org> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> > --- > drivers/hid/intel-ish-hid/ishtp-hid.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/hid/intel-ish-hid/ishtp-hid.c > b/drivers/hid/intel-ish-hid/ishtp-hid.c > index 277983aa1d90..cd23903ddcf1 100644 > --- a/drivers/hid/intel-ish-hid/ishtp-hid.c > +++ b/drivers/hid/intel-ish-hid/ishtp-hid.c > @@ -208,7 +208,7 @@ int ishtp_hid_probe(unsigned int cur_hid_dev, > hid->version = le16_to_cpu(ISH_HID_VERSION); > hid->vendor = le16_to_cpu(ISH_HID_VENDOR); > hid->product = le16_to_cpu(ISH_HID_PRODUCT); > - snprintf(hid->name, sizeof(hid->name), "%s %04hX:%04hX", > "hid-ishtp", > + snprintf(hid->name, sizeof(hid->name), "%s %04X:%04X", "hid- > ishtp", > hid->vendor, hid->product); > > rv = hid_add_device(hid);
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH 2/2] HID: intel-ish-hid: format 32-bit integers with %X Nicolas Iooss <nicolas.iooss_linux@m4x.org> - 2016-12-22 11:20 +0100 Re: [PATCH 2/2] HID: intel-ish-hid: format 32-bit integers with %X Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> - 2016-12-22 18:20 +0100
csiph-web