public inbox for kernel-janitors@vger.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@cam.ac.uk>
To: Lars-Peter Clausen <lars@metafoo.de>
Cc: Dan Carpenter <dan.carpenter@oracle.com>,
	Greg Kroah-Hartman <gregkh@suse.de>,
	linux-iio@vger.kernel.org, devel@driverdev.osuosl.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [patch] Staging: iio/dac/ad5064.c: signedness bug in ad5064_read_raw()
Date: Mon, 31 Oct 2011 11:22:52 +0000	[thread overview]
Message-ID: <4EAE850C.8040103@cam.ac.uk> (raw)
In-Reply-To: <4EAD2A97.8090103@metafoo.de>

On 10/30/11 10:44, Lars-Peter Clausen wrote:
> On 10/29/2011 09:20 AM, Dan Carpenter wrote:
>> regulator_get_voltage() returns an int so "scale_uv" should be an
>> int.  Making it unsigned here breaks the error handling.
>>
>> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> 
> uhm, yes...
> 
> Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jonathan Cameron <jic23@cam.ac.uk>
> 
> Thanks.
> 
>>
>> diff --git a/drivers/staging/iio/dac/ad5064.c b/drivers/staging/iio/dac/ad5064.c
>> index 24279f2..3b14526 100644
>> --- a/drivers/staging/iio/dac/ad5064.c
>> +++ b/drivers/staging/iio/dac/ad5064.c
>> @@ -280,8 +280,8 @@ static int ad5064_read_raw(struct iio_dev *indio_dev,
>>  			   long m)
>>  {
>>  	struct ad5064_state *st = iio_priv(indio_dev);
>> -	unsigned long scale_uv;
>>  	unsigned int vref;
>> +	int scale_uv;
>>  
>>  	switch (m) {
>>  	case 0:
> 
> 


      reply	other threads:[~2011-10-31 11:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-29  7:20 [patch] Staging: iio/dac/ad5064.c: signedness bug in Dan Carpenter
2011-10-30 10:44 ` [patch] Staging: iio/dac/ad5064.c: signedness bug in ad5064_read_raw() Lars-Peter Clausen
2011-10-31 11:22   ` Jonathan Cameron [this message]

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=4EAE850C.8040103@cam.ac.uk \
    --to=jic23@cam.ac.uk \
    --cc=dan.carpenter@oracle.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@suse.de \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=lars@metafoo.de \
    --cc=linux-iio@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