Thread (15 messages) 15 messages, 5 authors, 2021-08-16

Re: [PATCH V2 1/3] firmware: zynqmp: Add MMIO read and write support for PS_MODE pin

From: Michal Simek <hidden>
Date: 2021-08-11 14:07:13
Also in: linux-arm-kernel, linux-gpio, lkml

Hi Arnd,

On 8/11/21 3:46 PM, Arnd Bergmann wrote:
On Wed, Aug 11, 2021 at 3:08 PM Linus Walleij [off-list ref] wrote:
quoted
On Thu, Aug 5, 2021 at 7:42 PM Piyush Mehta [off-list ref] wrote:
quoted
Add Xilinx ZynqMP firmware MMIO APIs support to set and get PS_MODE
pins value and status. These APIs create an interface path between
mode pin controller driver and low-level API to access GPIO pins.

Signed-off-by: Piyush Mehta <redacted>
---
Changes in v2:
- Added Xilinx ZynqMP firmware MMIO API support to set and get pin
  value and status.
I doubt this is "GPIO".
General Purpose? I think not. It seems to be about boot mode.
Agreed.
here is register description.

https://www.xilinx.com/html_docs/registers/ug1087/crl_apb___boot_pin_ctrl.html#
quoted
If you need a userspace ABI, then add sysfs files to this firmware
driver instead of bridging it to the GPIO subsystem.
I don't really want custom user interfaces in firmware drivers either.

What is the high-level description of the 'PS_MODE' here? Is
this perhaps something we already have a user interface for?
The reason why this can't be mapped as memory mapped device is that it
is in IP which has be secure. That's why routing is done via firmware
driver.

Based on
https://www.xilinx.com/support/documentation/user_guides/ug1085-zynq-ultrascale-trm.pdf

page 46

PS_MODE Input/Output Dedicated 4-bit boot mode pins sampled on POR
deassertion

It means ROM just capture boot mode at start that's why they have
special meaning and after it is free to use for whatever purpose you
want which seems to pretty much as generic purpose I/O.

I wrote more comments in reply to Linus already.

Thanks,
Michal
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help