summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorPratik Prajapati <pratikkumar.v.prajapati@intel.com>2016-11-30 17:29:10 -0800
committerAaron Durbin <adurbin@chromium.org>2016-12-10 03:16:55 +0100
commit2a7708a9f8e543cd03d55716f21ea3318920ac03 (patch)
tree5cb361c5c906ae737c72cff27dae01779236c5d1 /src/include
parentb6e9021b162ebe73d67a4d75c3e304fb2727860d (diff)
downloadcoreboot-2a7708a9f8e543cd03d55716f21ea3318920ac03.tar.xz
cbfs: Add API to locate a file from specific region
This patch adds an API to find file by name from any specific region of fmap. Change-Id: Iabe785a6434937be6a57c7009882a0d68f6c8ad4 Signed-off-by: Pratik Prajapati <pratikkumar.v.prajapati@intel.com> Reviewed-on: https://review.coreboot.org/17664 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Diffstat (limited to 'src/include')
-rw-r--r--src/include/cbfs.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/include/cbfs.h b/src/include/cbfs.h
index 8538b3d119..1350671af2 100644
--- a/src/include/cbfs.h
+++ b/src/include/cbfs.h
@@ -34,6 +34,9 @@ int cbfs_boot_locate(struct cbfsf *fh, const char *name, uint32_t *type);
* leaking mappings are a no-op. Returns NULL on error, else returns
* the mapping and sets the size of the file. */
void *cbfs_boot_map_with_leak(const char *name, uint32_t type, size_t *size);
+/* Locate file in a specific region of fmap. Return 0 on success. < 0 on error*/
+int cbfs_locate_file_in_region(struct cbfsf *fh, const char *region_name,
+ const char *name, uint32_t *type);
/* Load a struct file from CBFS into a buffer. Returns amount of loaded
* bytes on success or 0 on error. File will get decompressed as necessary.
* Same decompression requirements as cbfs_load_and_decompress(). */