summaryrefslogtreecommitdiff
path: root/arch/arm/mach-zynqmp/mp.c
AgeCommit message (Collapse)AuthorFilesLines
2023-07-21arm64: zynqmp: Switch to amd.com emailsMichal Simek1-1/+1
Update my and DPs email address to match current setup. Signed-off-by: Michal Simek <michal.simek@amd.com> Link: https://lore.kernel.org/r/aba5b19b9c5a95608829e86ad5cc4671c940f1bb.1688992543.git.michal.simek@amd.com
2023-07-21xilinx: Consolidate zynqmp_mmio_read/write in zynqmp_firmware.hMichal Simek1-0/+1
zynqmp_mmio_read/write() are firmware provided hooks that's why use only zynqmp_firmware.h for function declaration. Signed-off-by: Michal Simek <michal.simek@amd.com> Link: https://lore.kernel.org/r/e7489556f9e447c737a578c169d7e1e43586a273.1687524706.git.michal.simek@amd.com
2023-06-12arm64: zynqmp: Fix lockstep mode cpu release functionalityVenkatesh Yadav Abbarapu1-0/+4
For lockstep mode, cpu_release function is expecting to execute on R5 core 0, if there is attempt to pass other than R5 core 0, through an error saying "Lockstep mode should run on R5 core 0 only". Signed-off-by: Venkatesh Yadav Abbarapu <venkatesh.abbarapu@amd.com> Link: https://lore.kernel.org/r/20230608032152.980-3-venkatesh.abbarapu@amd.com Signed-off-by: Michal Simek <michal.simek@amd.com>
2023-05-15arm64: zynqmp: Fix issue of apps executing from R5 core 1Ashok Reddy Soma1-10/+16
In current implementation, applications can execute only on R5 core 0. The boot address for R5 core 1 is not supplied. Pass TCM address for R5 core 1 based on the argument to fix the issue. Remove incomplete comment. Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@amd.com> Signed-off-by: Michal Simek <michal.simek@amd.com> Link: https://lore.kernel.org/r/da865717d26648ab7a84345ca8749712efdddee5.1680699999.git.michal.simek@amd.com
2023-05-15arch: arm: zynqmp: mp.c: tcminit halt both cores in split modeNeal Frager1-0/+2
The "zynqmp tcminit split" command should halt both cores and not just RPU1 when configuring the TCM memory for split mode. Signed-off-by: Neal Frager <neal.frager@amd.com> Link: https://lore.kernel.org/r/20230323082506.31576-1-neal.frager@amd.com Signed-off-by: Michal Simek <michal.simek@amd.com>
2022-12-05arm64: zynqmp: dynamically mark r5 cores as usedLukas Funke1-0/+26
When Linux boot takes over control of the pmu (by signaling PM_INIT_FINALIZE via ipi), pmu will switch off 'unused' rpu cores. The Xilinx zynqmp fsbl prevents switching off those cores by marking rpu cores as 'used' when loading code partitions to those cores. The current u-boot SPL is missing this behaviour, which results in halting rpu cores during Linux boot. This commit mimics the xilinx zynqmp fsbl behavior by marking r5 cores as used when they are released during boot. Signed-off-by: Lukas Funke <lukas.funke@weidmueller.com> Signed-off-by: Lukas Funke <lukas.funke-oss@weidmueller.com> Link: https://lore.kernel.org/r/20221028121547.26464-2-lukas.funke-oss@weidmueller.com Signed-off-by: Michal Simek <michal.simek@amd.com>
2022-10-07arm64: zynqmp: Fix compiler warnings in mp.cVenkatesh Yadav Abbarapu1-3/+3
make W=1 generates the following warning in cpu_disable, cpu_status and cpu_release functions. arch/arm/mach-zynqmp/mp.c:166:16: warning: comparison of unsigned expression in '>= 0' is always true [-Wtype-limits] 166 | if (nr >= ZYNQMP_CORE_APU0 && nr <= ZYNQMP_CORE_APU3) { | ^~ Signed-off-by: Venkatesh Yadav Abbarapu <venkatesh.abbarapu@amd.com> Link: https://lore.kernel.org/r/20221004053454.25470-1-venkatesh.abbarapu@amd.com Signed-off-by: Michal Simek <michal.simek@amd.com>
2022-05-18arm64: zynqmp: Fix split mode reset functionalityNeal Frager1-6/+25
This patch fixes two issues in the set_r5_reset function. 1. When in split mode, the lpd_amba_rst bit should only be set when both r5 cpu cores are in reset. Otherwise, if one r5 core is still running, setting the lpd_amba_rst bit will cause an error for the running core. The set_r5_reset function has been modified to check if the other r5 core is still running before setting the lpd_amba_rst bit. 2. The cpu_disable function was always assuming that the r5 cores are in split mode when resetting either core 4 or 5. This is incorrect for lockstep functionality. This patch adds a function check_r5_mode to handle the cpu_disable function correctly for the r5 cores by checking the mode and handling the reset appropriately. Signed-off-by: Neal Frager <neal.frager@amd.com> Signed-off-by: Michal Simek <michal.simek@amd.com> Link: https://lore.kernel.org/r/d99cbd7f2394ac055ef27457298f554ff0747ba7.1651648344.git.michal.simek@amd.com
2021-08-02global: Convert simple_strtoul() with hex to hextoul()Simon Glass1-1/+1
It is a pain to have to specify the value 16 in each call. Add a new hextoul() function and update the code to use it. Add a proper comment to simple_strtoul() while we are here. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-06-23arm64: zynqmp: Fix application loading on R5 core1Ashok Reddy Soma1-31/+39
From U-Boot, loading application on RPU core 0 is fine but loading on core 1 is not handled properly. Lock-step mode needs both the R5 cores to be initialized and it is working fine. Whereas in SPLIT mode individual R5 cores needs to be initialized as they need to execute differenet applications. Handle both these lock-step and split modes by propagating mode and RPU core number(4 for RPU0 and 5 for RPU1) for various functions and by adding conditions in those functions. Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2020-05-19common: Drop linux/delay.h from common headerSimon Glass1-0/+1
Move this uncommon header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-05-19common: Drop log.h from common headerSimon Glass1-0/+1
Move this header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-05-19command: Remove the cmd_tbl_t typedefSimon Glass1-1/+1
We should not use typedefs in U-Boot. They cannot be used as forward declarations which means that header files must include the full header to access them. Drop the typedef and rename the struct to remove the _s suffix which is now not useful. This requires quite a few header-file additions. Signed-off-by: Simon Glass <sjg@chromium.org>
2019-12-03common: Move older CPU functions to their own headerSimon Glass1-0/+1
These should be moved to driver model, but in the meantime, move them out of the common header to help reduce its size. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-01-24arm64: zynqmp: Move SoC sources to mach-zynqmpMichal Simek1-0/+297
Similar changes was done for Zynq in past and this patch just follow this pattern to separate cpu code from SoC code. Move arch/arm/cpu/armv8/zynqmp/* -> arch/arm/mach-zynqmp/* And also fix references to these files. Based on "ARM: zynq: move SoC sources to mach-zynq" (sha1: 0107f2403669f764ab726d0d404e35bb9447bbcc) Signed-off-by: Michal Simek <michal.simek@xilinx.com>