diff options
author | Amit Pundir <amit.pundir@linaro.org> | 2019-11-27 23:06:38 +0530 |
---|---|---|
committer | Amit Pundir <amit.pundir@linaro.org> | 2019-11-27 23:11:41 +0530 |
commit | 9fe5e6019c5adde33178e55d1b28300d65522827 (patch) | |
tree | d944af81a967fbb829639ff7ab243c90717d8e5d | |
parent | 4c88555ac266663f2243529a1481ed8a15fe139d (diff) |
QcomModulePkg: BootLib: set DTB best match explicitly
GetSocDtb() match and load the best DTB in dtb.img.
This match is done based on non-upstream DT properties
i.e. qcom,{msm-id/board-id/pmic-id}, which are not
supported on db845c.
Since we do not support multiple DTBs in dtb.img anyway,
we set the current (and only available dtb in dtb.img)
as the best match explicitly.
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
-rw-r--r-- | QcomModulePkg/Library/BootLib/LocateDeviceTree.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/QcomModulePkg/Library/BootLib/LocateDeviceTree.c b/QcomModulePkg/Library/BootLib/LocateDeviceTree.c index 43efc78d5d..13701e81ba 100644 --- a/QcomModulePkg/Library/BootLib/LocateDeviceTree.c +++ b/QcomModulePkg/Library/BootLib/LocateDeviceTree.c @@ -946,6 +946,14 @@ GetSocDtb (VOID *Kernel, UINT32 KernelSize, UINT32 DtbOffset, VOID *DtbLoadAddr) break; CurDtbInfo.Dtb = Dtb; + /* + * HACK: set Current (and only dtb in our case) as the Best match explicitly. + * Default behaviour is to iterate thru the list of dtbs in dtb.img and pick + * the best match based on DTMATCH_PARAMS (qcom,{msm-id/board-id/pmic-id} in + * dts). msm-id/board-id/pmic-id are non-upstream dt properties which we do + * not support on db845c. + */ + BestDtbInfo.Dtb = Dtb; if (ReadDtbFindMatch (&CurDtbInfo, &BestDtbInfo, SOC_MATCH)) { DtbIdx = DtbCount; } |