diff options
| author | Madhav Bhatt <madhav.bhatt@amd.com> | 2024-09-24 04:50:48 -0700 |
|---|---|---|
| committer | Mark Hatle <mark.hatle@amd.com> | 2024-09-24 13:33:43 -0500 |
| commit | 7a9a7ab4633a5abff185a5a27c652ac3452018be (patch) | |
| tree | 2b2273f6dd99bbd7da7779e4e4b74d1ad146dec8 /meta-xilinx-standalone-sdt | |
| parent | 88651af8a97753c09696d1cefc25cc3d80fc32ae (diff) | |
| download | meta-xilinx-7a9a7ab4633a5abff185a5a27c652ac3452018be.tar.gz | |
meta-xilinx-standalone-sdt: recipes-libraries: xilpm: Allow user to set xilpm library parameters
Add handling block so that consumer of xilpm can set library options
using some custom flags.
Signed-off-by: Madhav Bhatt <madhav.bhatt@amd.com>
Signed-off-by: Mark Hatle <mark.hatle@amd.com>
Diffstat (limited to 'meta-xilinx-standalone-sdt')
| -rw-r--r-- | meta-xilinx-standalone-sdt/recipes-libraries/xilpm_2024.2.bb | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/meta-xilinx-standalone-sdt/recipes-libraries/xilpm_2024.2.bb b/meta-xilinx-standalone-sdt/recipes-libraries/xilpm_2024.2.bb index 69b505c8..ee6faa13 100644 --- a/meta-xilinx-standalone-sdt/recipes-libraries/xilpm_2024.2.bb +++ b/meta-xilinx-standalone-sdt/recipes-libraries/xilpm_2024.2.bb | |||
| @@ -5,11 +5,34 @@ ESW_COMPONENT_NAME = "libxilpm.a" | |||
| 5 | 5 | ||
| 6 | DEPENDS += "libxil ${@'xilplmi cframe' if d.getVar('ESW_MACHINE') == 'psv_pmc_0' else ''}" | 6 | DEPENDS += "libxil ${@'xilplmi cframe' if d.getVar('ESW_MACHINE') == 'psv_pmc_0' else ''}" |
| 7 | 7 | ||
| 8 | def lopper_args(d): | ||
| 9 | lopper_cmd_append = "" | ||
| 10 | flags = [ | ||
| 11 | "APU_AS_OVERLAY_CONFIG_MASTER", | ||
| 12 | "APU_AS_POWER_MANAGEMENT_MASTER", | ||
| 13 | "APU_AS_RESET_MANAGEMENT_MASTER", | ||
| 14 | "RPU0_AS_OVERLAY_CONFIG_MASTER", | ||
| 15 | "RPU0_AS_POWER_MANAGEMENT_MASTER", | ||
| 16 | "RPU0_AS_RESET_MANAGEMENT_MASTER", | ||
| 17 | "RPU1_AS_OVERLAY_CONFIG_MASTER", | ||
| 18 | "RPU1_AS_POWER_MANAGEMENT_MASTER", | ||
| 19 | "RPU1_AS_RESET_MANAGEMENT_MASTER" | ||
| 20 | ] | ||
| 21 | |||
| 22 | for flag in flags: | ||
| 23 | value = d.getVar("XILPM_" + flag) | ||
| 24 | if value: | ||
| 25 | lopper_cmd_append += "XILPM_" + flag.lower() + ":" + value.lower() + " " | ||
| 26 | |||
| 27 | return lopper_cmd_append | ||
| 28 | |||
| 29 | LOPPER_CMD_APPEND = "${@lopper_args(d)}" | ||
| 30 | |||
| 8 | do_configure:prepend:zynqmp() { | 31 | do_configure:prepend:zynqmp() { |
| 9 | # This script should also not rely on relative paths and such | 32 | # This script should also not rely on relative paths and such |
| 10 | ( | 33 | ( |
| 11 | cd ${S} | 34 | cd ${S} |
| 12 | lopper -f --enhanced --werror ${DTS_FILE} -- generate_config_object pm_cfg_obj.c ${ESW_MACHINE} | 35 | lopper -f --enhanced --werror ${DTS_FILE} -- generate_config_object pm_cfg_obj.c ${ESW_MACHINE} ${LOPPER_CMD_APPEND} |
| 13 | install -m 0755 pm_cfg_obj.c ${S}/${ESW_COMPONENT_SRC}/zynqmp/client/common/ | 36 | install -m 0755 pm_cfg_obj.c ${S}/${ESW_COMPONENT_SRC}/zynqmp/client/common/ |
| 14 | ) | 37 | ) |
| 15 | } | 38 | } |
