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]
Message-ID: <5357A80B.8030701@linux.intel.com>
Date:	Wed, 23 Apr 2014 14:46:19 +0300
From:	Mathias Nyman <mathias.nyman@...ux.intel.com>
To:	Timur Tabi <timur@...eaurora.org>
CC:	Linus <linus.walleij@...aro.org>,
	Grant Likely <grant.likely@...retlab.ca>,
	lkml <linux-kernel@...r.kernel.org>,
	"Westerberg, Mika" <mika.westerberg@...el.com>,
	"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>
Subject: Re: [PATCH v3 1/1] pinctrl: add Intel BayTrail GPIO/pinctrl support

On 04/17/2014 07:47 PM, Timur Tabi wrote:
> On 04/15/2014 05:01 AM, Mathias Nyman wrote:
>>>
>>> This device will only be used on an ACPI system, right?  And isn't ACPI
>>> supposed to hide all the pinctrl programming from the OS?  I thought
>>> that was the whole point behind ACPI and the reason why ARM64 isn't
>>> going to use device trees.
>>>
>>
>> This was my starting point as well, and the driver was initially
>> submitted as a GPIO driver. But Linus W. suggested pinctrl instead, and
>> as he's the maintainer of both those subsystem I trust his judgment.
>
> Do you think, for an ACPI pinctrl driver, that we will need to specify
> any function groups?  When I look at the ASL that configures GPIOs, I
> see only lines like this:
>
> GpioIo (Exclusive, PullDefault, , , , "\\GIO0") {0x1D, 0x1E}
>
> This tells me that ACPI will never use any of the names that are
> defined.  I see that .get_function_name is called on my ACPI system, but
> I don't see where it is used.
>
> The reason I ask is because I would like to make a "generic" ACPI
> pinctrl/gpio driver that doesn't specify any pin groups.  So if we use
> the same pinctrl/gpio hardware on multiple SOCs, the only thing that the
> driver needs from ACPI is the number of pins.
>

Mika, Rafael (and me) have done some effort already on supporting ACPI 
gpio resources.

ACPI code creates a platfrom device out of the GPIO device defined ACPI 
tables, with all the resources set, and a hook back to the ACPI node.

Helper functions to translate the ACPI GpioIO and GpioInt resources to 
linux gpio numbers can be found in gpio/gpiolib-acpi.c together with 
other ACPI and gpio related helper functions.

see also
Documentation/acpi/enumeration.txt for some GPIO and ACPI related info

-Mathias

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