Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

firmware: Add coreboot device tree binding documentation

This patch adds documentation describing a device tree binding for the
coreboot firmware. It is meant to be dynamically added during boot and
contains address definitions for the coreboot table (a list of
variable-sized descriptors providing information about various compile-
and run-time generated firmware parameters) and the CBMEM area (the
structure containing most run-time resident memory regions set up by
coreboot).

These definitions allow kernel drivers to easily access data contained
in and pointed to by these regions (such as coreboot's in-memory log).
(An example implementation can be seen in the following patch)

Signed-off-by: Julius Werner <jwerner@chromium.org>
Signed-off-by: Thierry Escande <thierry.escande@collabora.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Julius Werner and committed by
Greg Kroah-Hartman
88cfb1ee d384d6f4

+33
+33
Documentation/devicetree/bindings/firmware/coreboot.txt
··· 1 + COREBOOT firmware information 2 + 3 + The device tree node to communicate the location of coreboot's memory-resident 4 + bookkeeping structures to the kernel. Since coreboot itself cannot boot a 5 + device-tree-based kernel (yet), this node needs to be inserted by a 6 + second-stage bootloader (a coreboot "payload"). 7 + 8 + Required properties: 9 + - compatible: Should be "coreboot" 10 + - reg: Address and length of the following two memory regions, in order: 11 + 1.) The coreboot table. This is a list of variable-sized descriptors 12 + that contain various compile- and run-time generated firmware 13 + parameters. It is identified by the magic string "LBIO" in its first 14 + four bytes. 15 + See coreboot's src/commonlib/include/commonlib/coreboot_tables.h for 16 + details. 17 + 2.) The CBMEM area. This is a downward-growing memory region used by 18 + coreboot to dynamically allocate data structures that remain resident. 19 + It may or may not include the coreboot table as one of its members. It 20 + is identified by a root node descriptor with the magic number 21 + 0xc0389481 that resides in the topmost 8 bytes of the area. 22 + See coreboot's src/include/imd.h for details. 23 + 24 + Example: 25 + firmware { 26 + ranges; 27 + 28 + coreboot { 29 + compatible = "coreboot"; 30 + reg = <0xfdfea000 0x264>, 31 + <0xfdfea000 0x16000>; 32 + } 33 + };