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>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 28 Oct 2014 08:10:24 +0100
From:	Matthias Klein <matthias.klein@...ux.com>
To:	Stephen Warren <swarren@...dotorg.org>,
	linux-rpi-kernel@...ts.infradead.org, linus.walleij@...aro.org
CC:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] pinctrl: bcm2835: Start GPIO numeration at zero


Am 28.10.2014 um 01:00 schrieb Stephen Warren:
> On 10/27/2014 05:05 PM, Matthias Klein wrote:
>
>> - To be in sync with the GPIO numbers in the datasheet / documentation
>
> I assume that's only relevant because of the second point; the GPIO 
> IDs in DT files already match the datasheet.
>
>> - For userland applications which rely on these GPIO numbers
>
> This isn't a scalable solution for that; this "fix" can only work for 
> a single GPIO controller in any one system. It'd be better for all 
> usage to search for the correct GPIO controller in sysfs, find the 
> base address of that, and then add on the controller-relative GPIO ID. 
> That way, the same approach is taken irrespective of which GPIO 
> controller is in use, and there are no special cases.
>
> Perhaps this could be simplified (removing the need to adding 
> base+offset to get the Linux ID) if the GPIO core exported a 
> per-controller directory in sysfs for GPIO manipulation (the files in 
> which used controller-relative numbering), rather than having a single 
> directory using Linux-internal global GPIO numbering; something like 
> /sys/class/gpio/gpio@...00000/export which uses ID 0..N vs. 
> /sys/class/gpio/export which uses IDs X..X+N where X is arbitary.
Would you accept a patch which implements the "gpio-base" property into 
the device tree for pinctrl-bcm2835?

--
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