File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -27,21 +27,11 @@ fih_ret boot_uuid_vid_match(const struct flash_area *fap, const struct image_uui
2727{
2828 const struct uuid_map_entry * map = NULL ;
2929 size_t n_uuids = boot_uuid_vid_map_get (& map );
30- int fa_ret ;
31- uintptr_t base ;
3230
3331 assert (fap != NULL );
3432
35- /* The memory map contains absolute addresses - fetch the base address for the area
36- * in question.
37- */
38- fa_ret = flash_device_base (flash_area_get_device_id (fap ), & base );
39- if (fa_ret != 0 ) {
40- FIH_RET (FIH_FAILURE );
41- }
42-
4333 for (size_t i = 0 ; i < n_uuids ; i ++ ) {
44- if ((map [i ].dev == fap -> fa_dev ) && (fap -> fa_off + base == map [i ].off ) &&
34+ if ((map [i ].dev == fap -> fa_dev ) && (fap -> fa_off == map [i ].off ) &&
4535 (fap -> fa_size == map [i ].size )) {
4636 if (boot_uuid_compare (uuid_vid , & map [i ].uuid )) {
4737 FIH_RET (FIH_SUCCESS );
@@ -58,21 +48,11 @@ fih_ret boot_uuid_cid_match(const struct flash_area *fap, const struct image_uui
5848{
5949 const struct uuid_map_entry * map = NULL ;
6050 size_t n_uuids = boot_uuid_cid_map_get (& map );
61- int fa_ret ;
62- uintptr_t base ;
6351
6452 assert (fap != NULL );
6553
66- /* The memory map contains absolute addresses - fetch the base address for the area
67- * in question.
68- */
69- fa_ret = flash_device_base (flash_area_get_device_id (fap ), & base );
70- if (fa_ret != 0 ) {
71- FIH_RET (FIH_FAILURE );
72- }
73-
7454 for (size_t i = 0 ; i < n_uuids ; i ++ ) {
75- if ((map [i ].dev == fap -> fa_dev ) && (fap -> fa_off + base == map [i ].off ) &&
55+ if ((map [i ].dev == fap -> fa_dev ) && (fap -> fa_off == map [i ].off ) &&
7656 (fap -> fa_size == map [i ].size )) {
7757 if (boot_uuid_compare (uuid_cid , & map [i ].uuid )) {
7858 FIH_RET (FIH_SUCCESS );
You can’t perform that action at this time.
0 commit comments