Thread (15 messages) 15 messages, 8 authors, 2017-08-31

linux-next regression caused by "gpiolib: request the gpio before querying its direction"

From: Thomas Petazzoni <hidden>
Date: 2017-08-30 14:33:09
Also in: linux-gpio

Possibly related (same subject, not in this thread)

Hello,

On Wed, 30 Aug 2017 09:22:55 -0500, Timur Tabi wrote:
No, that's it.  The question is, what exactly should the 'request' 
function do?  Should it be modifying the hardware to satisfy the 
request?  When I wrote my patch, I assumed that it wouldn't.  I thought 
that request simply answered the question, "can I touch this GPIO"?
No, it also muxes the pin in GPIO, and you can see the "reference"
implementation pinctrl-single also does it.

Let's see what Linus W. has to say about the semantic of the "request"
operation.

But if we change the semantic of "request" to no longer mux the hardware
as GPIO, then you will also have regressions, because there are plenty
of GPIOs that are requested, but not explicitly muxed as GPIOs in the
DT, precisely because today requesting a GPIO is sufficient to have it
re-muxed as GPIO at the pinctrl level.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help