[PATCH 0/3] firmware-zynqmp: add accessors for ggs/pggs

Sascha Hauer sha at pengutronix.de
Thu Sep 14 00:59:04 PDT 2023


On Wed, Sep 13, 2023 at 03:24:53PM +0200, Ahmad Fatoum wrote:
> The ZynqMP features eight 32-bit global storage registers that are
> available for general use. Four of them have their values preserved
> after software reboots and four are cleared on software reboots.
> 
> In Linux they are accessed as:
> 
>   /sys/firmware/zynqmp/ggs[0-4]
>   /sys/firmware/zynqmp/pggs[0-4]
> 
> Allow reading and writing these parameters from barebox board code
> via exported functions and from barebox shell as well via device
> parameters:
> 
>   echo ${firmware:zynqmp-firmware.of.ggs0}
>   firmware:zynqmp-firmware.of.pggs0=4
> 
> Because the name is a bit unwieldy, use the device alias support added
> in this series to make the variables more compact:
> 
>   echo ${zynqmp_fw.ggs0}
>   zynqmp_fw.pggs0=4
> 
> Ahmad Fatoum (3):
>   driver: add support for device aliases
>   firmware-zynqmp: export functions for setting GGS/PGGS
>   firmware-zynqmp: add device parameters for ggs/pggs

Applied, thanks

Sascha

> 
>  arch/arm/mach-zynqmp/firmware-zynqmp.c | 133 +++++++++++++++++++++++++
>  common/complete.c                      |  14 ++-
>  drivers/base/driver.c                  |  46 +++++++++
>  include/driver.h                       |   7 ++
>  include/mach/zynqmp/firmware-zynqmp.h  |  33 +++++-
>  5 files changed, 222 insertions(+), 11 deletions(-)
> 
> -- 
> 2.39.2
> 
> 
> 

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



More information about the barebox mailing list