lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <CAH+eYFCzL5bmnjDMvT5sH=gcDjnStYWCWWeVq_hMjUk9g=+-9w@mail.gmail.com>
Date:	Fri, 24 Feb 2012 20:12:11 +0530
From:	Rabin Vincent <rabin@....in>
To:	viresh kumar <viresh.linux@...il.com>
Cc:	salvatore.dedominicis@...com, bhavna.yadav@...com,
	rajeev-dlh.kumar@...com, Viresh Kumar <viresh.kumar@...com>,
	pratyush.anand@...com, shiraz.hashim@...com,
	grant.likely@...retlab.ca, deepak.sikri@...com, mirko.gardi@...com,
	vipulkumar.samar@...com, linus.walleij@...ricsson.com,
	armando.visconti@...com, amit.virdi@...com,
	vincenzo.frascino@...com, vipin.kumar@...com,
	linux-kernel@...r.kernel.org, bhupesh.sharma@...com
Subject: Re: [PATCH] gpio/gpio-stmpe: Fix the value returned by _get_value routine

On Fri, Feb 24, 2012 at 19:59, viresh kumar <viresh.linux@...il.com> wrote:
> On Feb 24, 2012 7:46 PM, "Rabin Vincent" <rabin@....in> wrote:
>> On Fri, Feb 24, 2012 at 16:04, Viresh Kumar <viresh.kumar@...com> wrote:
>> > The present _get_value routine returns the contents of the GPIO
>> > Monitor Pin Status Register(GPMR) starting from the bit whose value
>> > is requested to BIT 0.
>> >
>> > For e.g. if we request the value of GPIO 6 in the earlier
>> > implementation the value returned is:
>> >
>> >        BIT6 to BIT0
>> >
>> > whereas it should just return BIT6.
>>
>> The current implementation just returns (ret & mask) where mask
>> would have only BIT6 set, so how can it return "BIT6 to BIT0" ?
>
> Oops! I gave same comment when i saw this patch
> on our internal list and i forgot to fix log while applying.
>
> It actually returns 0b1000000 for example. And we need 1 here.

According to the documentation, gpio_get_value() (i.e. this function)
can return zero or non-zero, not necessarily zero or one.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ