blob: 7df168325a16c2bac4b1440faead12dc8c78b3d5 [file] [log] [blame]
Brad Bishopf3fd2882019-06-21 08:06:37 -04001def riscv_get_extra_oemake_image(d):
2 sbi_payload = d.getVar('RISCV_SBI_PAYLOAD')
3 deploy_dir = d.getVar('DEPLOY_DIR_IMAGE')
4
5 if sbi_payload is None:
6 return ""
7
8 if d.getVar('RISCV_SBI_PAYLOAD'):
9 return "FW_PAYLOAD_PATH=" + deploy_dir + "/" + sbi_payload
10
11 return ""
12
13def riscv_get_extra_oemake_fdt(d):
14 sbi_fdt_payload = d.getVar('RISCV_SBI_FDT')
15 deploy_dir = d.getVar('DEPLOY_DIR_IMAGE')
16
17 if sbi_fdt_payload is None:
18 return ""
19
20 if d.getVar('RISCV_SBI_PAYLOAD'):
21 # This is internal to openSBI, not a full path
22 return "FW_PAYLOAD_FDT=" + sbi_fdt_payload
23
24 return ""
25
26def riscv_get_do_compile_depends(d):
27 sbi_payload = d.getVar('RISCV_SBI_PAYLOAD')
28
29 if sbi_payload is None:
30 return ""
31
32 if 'linux' in sbi_payload or 'Image' in sbi_payload:
33 return "virtual/kernel:do_deploy"
34 if 'u-boot' in sbi_payload:
35 return "virtual/bootloader:do_deploy"
36
37 return ""