[PATCH v25 0/5] Provide basic driver to control Arm R5 co-processor found on Xilinx ZynqMP

Ben Levinsky ben.levinsky at xilinx.com
Sun Jan 10 21:02:45 EST 2021


R5 is included in Xilinx Zynq UltraScale MPSoC so by adding this
remotproc driver, we can boot the R5 sub-system in two different
configurations -
	* Split
	* Lockstep

The Xilinx R5 Remoteproc Driver boots the R5's via calls to the Xilinx
Platform Management Unit that handles the R5 configuration, memory access
and R5 lifecycle management. The interface to this manager is done in this
driver via zynqmp_pm_* function calls.

v25:
- reword error message for rpu configuration
- change char name[15] to 16 chars to have null terminated string
  in parse_mem_regions()
- reword comments in tcm_mem_alloc
- grammar in device tree bindings
- call xilinx platform cleanup in parse_tcm_banks() case of failure
- check value of mbox_send_message in all calls within this driver
- update include/linux/firmware/xlnx-zynqmp.h style to match for enum
  pm_node_id
- indentation in zynqmp_r5_remoteproc driver
- update style of constructing carveouts to match convention in ST
  remoteproc drivers. No longer iterate through memory-region property
  using of_count_phandle_with_args. Instead use of_phandle_iterator
- use rproc_of_resm_mem_entry_init for vdev0buffer carveout as per feedback
- rework loop in zynqmp_r5_pm_request_sram as per feedback
- fix comment and linebreak in tcm_mem_alloc description
- add comments and remove extraneous devm_ioremap_wc call in tcm_mem_alloc
- in parse_tcm_banks remove check for bank not being available
- rework order of locals and remove else in zynqmp_r5_rproc_kick
- document and update logic for zynqmp_r5_parse_fw
- add dev_dbg output in event_notified_idr_cb if
  rproc_vq_interrupt(rproc, id) == IRQ_NONE
- add comment for handle_event_notified mbox_send_message function call
- add comment for zynqmp_r5_mb_rx_cb
- update zynqmp_r5_setup_mbox to match convention of mbox setup in ST
  remoteproc drivers
- change return in zynqmp_r5_setup_mbox to use PTR_ERR
- add zynqmp_r5_cleanup_mbox
- in zynqmp_r5_probe, reteurn zynqmp_r5_rproc instead of taking in as arg.
- in zynqmp_r5_probe use return of PTR_ERR and use zynqmp_r5_cleanup_mbox
- in zynqmp_r5_remoteproc_probe update use return value of zynqmp_r5_probe as
  either zynqmp_r5_rproc* or PTR_ERR
- update loop that cleans up cluster and mboxes in zynqmp_r5_remoteproc_probe
- update loop that cleans up cluster and mboxes in zynqmp_r5_remoteproc_remove

Previous version:
https://patchwork.kernel.org/project/linux-remoteproc/list/?series=393387


Ben Levinsky (5):
  firmware: xilinx: Add ZynqMP firmware ioctl enums for RPU
    configuration.
  firmware: xilinx: Add shutdown/wakeup APIs
  firmware: xilinx: Add RPU configuration APIs
  dt-bindings: remoteproc: Add documentation for ZynqMP R5 rproc
    bindings
  remoteproc: Add initial zynqmp R5 remoteproc driver

 .../xilinx,zynqmp-r5-remoteproc.yaml          | 223 +++++
 drivers/firmware/xilinx/zynqmp.c              |  96 ++
 drivers/remoteproc/Kconfig                    |   8 +
 drivers/remoteproc/Makefile                   |   1 +
 drivers/remoteproc/zynqmp_r5_remoteproc.c     | 897 ++++++++++++++++++
 include/linux/firmware/xlnx-zynqmp.h          |  66 +-
 6 files changed, 1290 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/devicetree/bindings/remoteproc/xilinx,zynqmp-r5-remoteproc.yaml
 create mode 100644 drivers/remoteproc/zynqmp_r5_remoteproc.c

-- 
2.17.1




More information about the linux-arm-kernel mailing list