x86-power-control

Vijay Khemka vijaykhemka at fb.com
Fri Oct 18 09:13:28 AEDT 2019



From: openbmc <openbmc-bounces+vijaykhemka=fb.com at lists.ozlabs.org> on behalf of Oskar Senft <osk at google.com>
Date: Thursday, October 17, 2019 at 6:39 AM
To: Michael Richardson <mcr at sandelman.ca>
Cc: OpenBMC Maillist <openbmc at lists.ozlabs.org>
Subject: Re: x86-power-control

Hi Michael

Why in a target system wouldn't naming it in DTS be the most reliable and
most easily accessible mechanism?  I can see that in development being able to define
things helps, but it is not like the production systems would have wire-wrap
where the GPIO pin might change.

I totally agree. I was actually experimenting on our platform (TYAN S7106) to name GPIO pins in the DTS, but I couldn't figure out how to read those names from userspace.

Here's what I tried in the DTS:

&gpio {
        pin_gpio_d2 {
                gpios = <ASPEED_GPIO(D, 2) GPIO_ACTIVE_HIGH>;
                input;
                line-name = "SYS_PWROK_BUF";
        };
...

Another thing here, I want to be able to map actual name defined in DTS to real name used in
Power-control.

However, from what I can tell line-name is actually only relevant when used together with "gpiohog", which is not what we want.

It is mainly used via libgpiod.

Did you manage to make this work?

Thanks
Oskar.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/openbmc/attachments/20191017/2b6cef69/attachment.htm>


More information about the openbmc mailing list