aboutsummaryrefslogtreecommitdiff
path: root/include/cbfs.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/cbfs.h')
-rw-r--r--include/cbfs.h17
1 files changed, 9 insertions, 8 deletions
diff --git a/include/cbfs.h b/include/cbfs.h
index 962b3e848b..5a248781c3 100644
--- a/include/cbfs.h
+++ b/include/cbfs.h
@@ -161,17 +161,18 @@ int cbfs_init_mem(ulong base, ulong size, struct cbfs_priv **privp);
/***************************************************************************/
/**
- * file_cbfs_find_uncached() - Find a file with a particular name in CBFS
- * without using the heap.
+ * file_cbfs_find_uncached() - Find a file in CBFS given the end of the ROM
*
- * @end_of_rom: Points to the end of the ROM the CBFS should be read
- * from.
- * @name: The name to search for.
+ * Note that @node should be declared by the caller. This design is to avoid
+ * the need for allocation here.
*
- * @return A handle to the file, or NULL on error.
+ * @end_of_rom: Points to the end of the ROM the CBFS should be read from
+ * @name: The name to search for
+ * @node: Returns the contents of the node if found (i.e. copied into *node)
+ * @return 0 on success, -ENOENT if not found, -EFAULT on bad header
*/
-const struct cbfs_cachenode *file_cbfs_find_uncached(ulong end_of_rom,
- const char *name);
+int file_cbfs_find_uncached(ulong end_of_rom, const char *name,
+ struct cbfs_cachenode *node);
/**
* file_cbfs_name() - Get the name of a file in CBFS.