linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Jiri Kosina <jkosina@suse.cz>
Cc: linux-input@vger.kernel.org,
	Benjamin Tissoires <benjamin.tissoires@redhat.com>
Subject: Re: [PATCH] i2c-hid: explicitly cast parametrs to follow specifiers
Date: Tue, 06 Aug 2013 14:43:56 +0300	[thread overview]
Message-ID: <1375789436.403.16.camel@smile> (raw)
In-Reply-To: <1372163081-11394-1-git-send-email-andriy.shevchenko@linux.intel.com>

On Tue, 2013-06-25 at 15:24 +0300, Andy Shevchenko wrote: 
> The vendor and product parameters are defined as __u32, but used as short int.
> Let's do an explicit casting for them.

Jiri, Benjamin, any comment on this?

> 
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
>  drivers/hid/i2c-hid/i2c-hid.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/hid/i2c-hid/i2c-hid.c b/drivers/hid/i2c-hid/i2c-hid.c
> index 879b0ed..d595f2a 100644
> --- a/drivers/hid/i2c-hid/i2c-hid.c
> +++ b/drivers/hid/i2c-hid/i2c-hid.c
> @@ -1009,7 +1009,7 @@ static int i2c_hid_probe(struct i2c_client *client,
>  	hid->product = le16_to_cpu(ihid->hdesc.wProductID);
>  
>  	snprintf(hid->name, sizeof(hid->name), "%s %04hX:%04hX",
> -		 client->name, hid->vendor, hid->product);
> +		 client->name, (short int)hid->vendor, (short int)hid->product);
>  
>  	ret = hid_add_device(hid);
>  	if (ret) {

-- 
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy

  reply	other threads:[~2013-08-06 11:44 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-25 12:24 [PATCH] i2c-hid: explicitly cast parametrs to follow specifiers Andy Shevchenko
2013-08-06 11:43 ` Andy Shevchenko [this message]
2013-09-04 11:17 ` Jiri Kosina
2013-09-04 11:51   ` Andy Shevchenko

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=1375789436.403.16.camel@smile \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=benjamin.tissoires@redhat.com \
    --cc=jkosina@suse.cz \
    --cc=linux-input@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).