<div style="line-height:1.7;color:#000000;font-size:14px;font-family:Arial"><div>Dear <span style="font-family: arial; white-space: pre-wrap;">Andrew,</span></div><div><span style="font-family: arial; white-space: pre-wrap;"><br></span></div><div><span style="font-family: arial; white-space: pre-wrap;">Thank you. I got it.</span></div><div><font face="arial"><span style="white-space: pre-wrap;">Pass-through function is only a small and special part of GPIO function. </span></font></div><div><font face="arial"><span style="white-space: pre-wrap;">If the entire pinctrl and </span></font><em id="__mceDel" style="font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 13.3333px;"><em id="__mceDel"><em id="__mceDel"><em id="__mceDel">/sys/class/gpio </em></em></em></em><span style="white-space: pre-wrap; font-family: arial;"> are changed due to this function, I am not sure whether it is appropriate.</span></div><br><div>thanks,</div><div>Byron</div><div style="position:relative;zoom:1"></div><div id="divNeteaseMailCard"></div><br><pre><br>At 2019-11-22 14:32:51, "Andrew Jeffery" <andrew@aj.id.au> wrote:
>On Fri, 22 Nov 2019, at 14:55, www wrote:
>> At 2019-11-22 08:31:05, "Andrew Jeffery" <andrew@aj.id.au> wrote:
>
>*snip* 
>
>> >Getting back to your problem rather than solutions, it's possible to view
>> >this as a deficiency in the GPIO subsystem and Aspeed GPIO driver: If we
>> >could describe that we want the pin muxed for pass-through as part of
>> >the GPIO request then your problem would be partly resolved, save for 
>> >the fact that the exported GPIO would still be read-only. However, that
>> >issue is fully resolved by multiple sequential GPIO requests: export the
>> >GPIO in pass-through mode initially, and then when it comes to changing
>> >the host state, re-export the GPIO in non-pass-through mode so that it is
>> >writable, and then again re-export the GPIO back in pass-through mode
>> >after the host state change has been applied. This is the sequence of
>> >your original solution above, just without the need for additional drivers
>> >with ad-hoc userspace interfaces or introducing bugs into the pinctrl
>> >driver.
>> >What are your thoughts on this?
>> >
>> 
>> I haven't heard of this way. Would you please explain it in detail? Thank you
>
>What details are you after? What I suggested above is not yet possible -
>we'd need to develop some kernel patches to make it work, but they would
>be something we could upstream. pinctrl needs to remain aware of whether
>a pin is in GPIO pass-through mode or not, as it not only affects how that pin
>will behave but how *other* "unrelated" pins might behave as well.
>
>Andrew
</pre></div><br><br><span title="neteasefooter"><p> </p></span>