security/vboot: Remove vboot_named_region_device(_rw)
Remove vboot_named_region_device(_rw) and use fmap_locate_area_as_rdev(_rw) directly. BRANCH=none BUG=none TEST=emerge-kukui coreboot Change-Id: I244ac4e01ae5b80285162b3baffc0b30aa057bfb Signed-off-by: Yu-Ping Wu <yupingso@chromium.org> Reviewed-on: https://review.coreboot.org/c/coreboot/+/36922 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Aaron Durbin <adurbin@chromium.org>
This commit is contained in:
@ -19,6 +19,7 @@
|
||||
#include <cbmem.h>
|
||||
#include <console/console.h>
|
||||
#include <console/vtxprintf.h>
|
||||
#include <fmap.h>
|
||||
#include <string.h>
|
||||
#include <timestamp.h>
|
||||
#include <vb2_api.h>
|
||||
@ -78,7 +79,7 @@ vb2_error_t vb2ex_read_resource(struct vb2_context *ctx,
|
||||
return VB2_ERROR_EX_READ_RESOURCE_INDEX;
|
||||
}
|
||||
|
||||
if (vboot_named_region_device(name, &rdev))
|
||||
if (fmap_locate_area_as_rdev(name, &rdev))
|
||||
return VB2_ERROR_EX_READ_RESOURCE_SIZE;
|
||||
|
||||
if (rdev_readat(&rdev, buf, offset, size) != size)
|
||||
@ -265,7 +266,7 @@ static int locate_firmware(struct vb2_context *ctx,
|
||||
else
|
||||
name = "FW_MAIN_B";
|
||||
|
||||
return vboot_named_region_device(name, fw_main);
|
||||
return fmap_locate_area_as_rdev(name, fw_main);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user