Age | Commit message (Collapse) | Author |
|
Added some comments, and moved function return values to the same line as the
function name.
TEST=Compiled for x86-alex.
BUG=chrome-os-partner:5702
Change-Id: I101ab927f72653a912ec82df5e665a0baf223c92
Signed-off-by: Gabe Black <gabeblack@google.com>
Reviewed-on: http://gerrit.chromium.org/gerrit/6726
Reviewed-by: Stefan Reinauer <reinauer@google.com>
|
|
If u-boot needs something out of CBFS very early before the heap is
configured, it won't be able to use the normal CBFS support which caches some
information in memory it allocates from the heap. This change adds a new
cbfs_file_find_uncached function which searchs a CBFS instance without touching
the heap. It also refactors the implementation of u-boot's CBFS support to
avoid code duplication, and allows some functions to be used without CBFS being
initialized which sets up the cache on the heap.
BUG=chrome-os-partner:5432
TEST=Built x86-alex, verified that the CBFS commands still work, and with
later changes verified that the device tree could be loaded from CBFS before
the heap is initialized.
Signed-off-by: Gabe Black <gabeblack@google.com>
Change-Id: Ia57a5c553a0cd524073c05ca964501ccf6c5e025
Reviewed-on: http://gerrit.chromium.org/gerrit/5858
Tested-by: Gabe Black <gabeblack@chromium.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
|
|
This change refactors the implementation of the CBFS driver so that it can be
used effectively both from the command line and programmatically from within
u-boot.
BUG=chrome-os-partner:4993
TEST=Built and booted on Alex. Verified that the CBFS commands still behaved
correctly.
Change-Id: I97720828e282261f69479979d7d0c2c7d193c53f
Signed-off-by: Gabe Black <gabeblack@google.com>
Reviewed-on: http://gerrit.chromium.org/gerrit/4916
Reviewed-by: Gabe Black <gabeblack@chromium.org>
Tested-by: Gabe Black <gabeblack@chromium.org>
|
|
This change adds CBFS support and some commands to use it to u-boot. These
commands are:
cbfsinit - Initialize CBFS support and pull all metadata into RAM. The end of
the ROM is an optional parameter which defaults to the standard 0xffffffff and
can be used to support multiple CBFSes in a system. The last one set up with
cbfsinit is the one that will be used.
cbfsinfo - Print information from the CBFS header.
cbfsls - Print out the size, type, and name of all the files in the current
CBFS. Recognized types are translated into symbolic names.
cbfsload - Load a file from CBFS into memory. Like the similar command for fat
filesystems, you can optionally provide a maximum size.
Support for CBFS is compiled in when the CONFIG_CMD_CBFS option is specified.
BUG=chrome-os-partner:3910
TEST=Built and booted on an Alex. Initialized with and without specifying the
end of the ROM, and with a bad end of ROM. Ran the commands before CBFS was
initialized. Ran cbfsinfo and saw reasonable output. Ran cbfsls and saw output
that matched what was printed when the CBFS was put together by the coreboot
ebuild. Used cbfsload to load a test text file into memory and verified that it
was the correct size and had the correct contents. Ran with a max size and saw
the file was truncated in memory.
Change-Id: I64d06d49633cef3cffac1d571519eae38c7d267f
Signed-off-by: Gabe Black <gabeblack@google.com>
Reviewed-on: http://gerrit.chromium.org/gerrit/4167
Reviewed-by: Gabe Black <gabeblack@chromium.org>
Tested-by: Gabe Black <gabeblack@chromium.org>
|