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.