README.entries 43 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256
  1. Binman Entry Documentation
  2. ===========================
  3. This file describes the entry types supported by binman. These entry types can
  4. be placed in an image one by one to build up a final firmware image. It is
  5. fairly easy to create new entry types. Just add a new file to the 'etype'
  6. directory. You can use the existing entries as examples.
  7. Note that some entries are subclasses of others, using and extending their
  8. features to produce new behaviours.
  9. Entry: atf-bl31: Entry containing an ARM Trusted Firmware (ATF) BL31 blob
  10. -------------------------------------------------------------------------
  11. Properties / Entry arguments:
  12. - atf-bl31-path: Filename of file to read into entry. This is typically
  13. called bl31.bin or bl31.elf
  14. This entry holds the run-time firmware, typically started by U-Boot SPL.
  15. See the U-Boot README for your architecture or board for how to use it. See
  16. https://github.com/ARM-software/arm-trusted-firmware for more information
  17. about ATF.
  18. Entry: blob: Entry containing an arbitrary binary blob
  19. ------------------------------------------------------
  20. Note: This should not be used by itself. It is normally used as a parent
  21. class by other entry types.
  22. Properties / Entry arguments:
  23. - filename: Filename of file to read into entry
  24. - compress: Compression algorithm to use:
  25. none: No compression
  26. lz4: Use lz4 compression (via 'lz4' command-line utility)
  27. This entry reads data from a file and places it in the entry. The
  28. default filename is often specified specified by the subclass. See for
  29. example the 'u_boot' entry which provides the filename 'u-boot.bin'.
  30. If compression is enabled, an extra 'uncomp-size' property is written to
  31. the node (if enabled with -u) which provides the uncompressed size of the
  32. data.
  33. Entry: blob-dtb: A blob that holds a device tree
  34. ------------------------------------------------
  35. This is a blob containing a device tree. The contents of the blob are
  36. obtained from the list of available device-tree files, managed by the
  37. 'state' module.
  38. Entry: blob-ext: Entry containing an externally built binary blob
  39. -----------------------------------------------------------------
  40. Note: This should not be used by itself. It is normally used as a parent
  41. class by other entry types.
  42. If the file providing this blob is missing, binman can optionally ignore it
  43. and produce a broken image with a warning.
  44. See 'blob' for Properties / Entry arguments.
  45. Entry: blob-named-by-arg: A blob entry which gets its filename property from its subclass
  46. -----------------------------------------------------------------------------------------
  47. Properties / Entry arguments:
  48. - <xxx>-path: Filename containing the contents of this entry (optional,
  49. defaults to None)
  50. where <xxx> is the blob_fname argument to the constructor.
  51. This entry cannot be used directly. Instead, it is used as a parent class
  52. for another entry, which defined blob_fname. This parameter is used to
  53. set the entry-arg or property containing the filename. The entry-arg or
  54. property is in turn used to set the actual filename.
  55. See cros_ec_rw for an example of this.
  56. Entry: cbfs: Entry containing a Coreboot Filesystem (CBFS)
  57. ----------------------------------------------------------
  58. A CBFS provides a way to group files into a group. It has a simple directory
  59. structure and allows the position of individual files to be set, since it is
  60. designed to support execute-in-place in an x86 SPI-flash device. Where XIP
  61. is not used, it supports compression and storing ELF files.
  62. CBFS is used by coreboot as its way of orgnanising SPI-flash contents.
  63. The contents of the CBFS are defined by subnodes of the cbfs entry, e.g.:
  64. cbfs {
  65. size = <0x100000>;
  66. u-boot {
  67. cbfs-type = "raw";
  68. };
  69. u-boot-dtb {
  70. cbfs-type = "raw";
  71. };
  72. };
  73. This creates a CBFS 1MB in size two files in it: u-boot.bin and u-boot.dtb.
  74. Note that the size is required since binman does not support calculating it.
  75. The contents of each entry is just what binman would normally provide if it
  76. were not a CBFS node. A blob type can be used to import arbitrary files as
  77. with the second subnode below:
  78. cbfs {
  79. size = <0x100000>;
  80. u-boot {
  81. cbfs-name = "BOOT";
  82. cbfs-type = "raw";
  83. };
  84. dtb {
  85. type = "blob";
  86. filename = "u-boot.dtb";
  87. cbfs-type = "raw";
  88. cbfs-compress = "lz4";
  89. cbfs-offset = <0x100000>;
  90. };
  91. };
  92. This creates a CBFS 1MB in size with u-boot.bin (named "BOOT") and
  93. u-boot.dtb (named "dtb") and compressed with the lz4 algorithm.
  94. Properties supported in the top-level CBFS node:
  95. cbfs-arch:
  96. Defaults to "x86", but you can specify the architecture if needed.
  97. Properties supported in the CBFS entry subnodes:
  98. cbfs-name:
  99. This is the name of the file created in CBFS. It defaults to the entry
  100. name (which is the node name), but you can override it with this
  101. property.
  102. cbfs-type:
  103. This is the CBFS file type. The following are supported:
  104. raw:
  105. This is a 'raw' file, although compression is supported. It can be
  106. used to store any file in CBFS.
  107. stage:
  108. This is an ELF file that has been loaded (i.e. mapped to memory), so
  109. appears in the CBFS as a flat binary. The input file must be an ELF
  110. image, for example this puts "u-boot" (the ELF image) into a 'stage'
  111. entry:
  112. cbfs {
  113. size = <0x100000>;
  114. u-boot-elf {
  115. cbfs-name = "BOOT";
  116. cbfs-type = "stage";
  117. };
  118. };
  119. You can use your own ELF file with something like:
  120. cbfs {
  121. size = <0x100000>;
  122. something {
  123. type = "blob";
  124. filename = "cbfs-stage.elf";
  125. cbfs-type = "stage";
  126. };
  127. };
  128. As mentioned, the file is converted to a flat binary, so it is
  129. equivalent to adding "u-boot.bin", for example, but with the load and
  130. start addresses specified by the ELF. At present there is no option
  131. to add a flat binary with a load/start address, similar to the
  132. 'add-flat-binary' option in cbfstool.
  133. cbfs-offset:
  134. This is the offset of the file's data within the CBFS. It is used to
  135. specify where the file should be placed in cases where a fixed position
  136. is needed. Typical uses are for code which is not relocatable and must
  137. execute in-place from a particular address. This works because SPI flash
  138. is generally mapped into memory on x86 devices. The file header is
  139. placed before this offset so that the data start lines up exactly with
  140. the chosen offset. If this property is not provided, then the file is
  141. placed in the next available spot.
  142. The current implementation supports only a subset of CBFS features. It does
  143. not support other file types (e.g. payload), adding multiple files (like the
  144. 'files' entry with a pattern supported by binman), putting files at a
  145. particular offset in the CBFS and a few other things.
  146. Of course binman can create images containing multiple CBFSs, simply by
  147. defining these in the binman config:
  148. binman {
  149. size = <0x800000>;
  150. cbfs {
  151. offset = <0x100000>;
  152. size = <0x100000>;
  153. u-boot {
  154. cbfs-type = "raw";
  155. };
  156. u-boot-dtb {
  157. cbfs-type = "raw";
  158. };
  159. };
  160. cbfs2 {
  161. offset = <0x700000>;
  162. size = <0x100000>;
  163. u-boot {
  164. cbfs-type = "raw";
  165. };
  166. u-boot-dtb {
  167. cbfs-type = "raw";
  168. };
  169. image {
  170. type = "blob";
  171. filename = "image.jpg";
  172. };
  173. };
  174. };
  175. This creates an 8MB image with two CBFSs, one at offset 1MB, one at 7MB,
  176. both of size 1MB.
  177. Entry: cros-ec-rw: A blob entry which contains a Chromium OS read-write EC image
  178. --------------------------------------------------------------------------------
  179. Properties / Entry arguments:
  180. - cros-ec-rw-path: Filename containing the EC image
  181. This entry holds a Chromium OS EC (embedded controller) image, for use in
  182. updating the EC on startup via software sync.
  183. Entry: fdtmap: An entry which contains an FDT map
  184. -------------------------------------------------
  185. Properties / Entry arguments:
  186. None
  187. An FDT map is just a header followed by an FDT containing a list of all the
  188. entries in the image. The root node corresponds to the image node in the
  189. original FDT, and an image-name property indicates the image name in that
  190. original tree.
  191. The header is the string _FDTMAP_ followed by 8 unused bytes.
  192. When used, this entry will be populated with an FDT map which reflects the
  193. entries in the current image. Hierarchy is preserved, and all offsets and
  194. sizes are included.
  195. Note that the -u option must be provided to ensure that binman updates the
  196. FDT with the position of each entry.
  197. Example output for a simple image with U-Boot and an FDT map:
  198. / {
  199. image-name = "binman";
  200. size = <0x00000112>;
  201. image-pos = <0x00000000>;
  202. offset = <0x00000000>;
  203. u-boot {
  204. size = <0x00000004>;
  205. image-pos = <0x00000000>;
  206. offset = <0x00000000>;
  207. };
  208. fdtmap {
  209. size = <0x0000010e>;
  210. image-pos = <0x00000004>;
  211. offset = <0x00000004>;
  212. };
  213. };
  214. If allow-repack is used then 'orig-offset' and 'orig-size' properties are
  215. added as necessary. See the binman README.
  216. Entry: files: Entry containing a set of files
  217. ---------------------------------------------
  218. Properties / Entry arguments:
  219. - pattern: Filename pattern to match the files to include
  220. - compress: Compression algorithm to use:
  221. none: No compression
  222. lz4: Use lz4 compression (via 'lz4' command-line utility)
  223. This entry reads a number of files and places each in a separate sub-entry
  224. within this entry. To access these you need to enable device-tree updates
  225. at run-time so you can obtain the file positions.
  226. Entry: fill: An entry which is filled to a particular byte value
  227. ----------------------------------------------------------------
  228. Properties / Entry arguments:
  229. - fill-byte: Byte to use to fill the entry
  230. Note that the size property must be set since otherwise this entry does not
  231. know how large it should be.
  232. You can often achieve the same effect using the pad-byte property of the
  233. overall image, in that the space between entries will then be padded with
  234. that byte. But this entry is sometimes useful for explicitly setting the
  235. byte value of a region.
  236. Entry: fit: Entry containing a FIT
  237. ----------------------------------
  238. This calls mkimage to create a FIT (U-Boot Flat Image Tree) based on the
  239. input provided.
  240. Nodes for the FIT should be written out in the binman configuration just as
  241. they would be in a file passed to mkimage.
  242. For example, this creates an image containing a FIT with U-Boot SPL:
  243. binman {
  244. fit {
  245. description = "Test FIT";
  246. fit,fdt-list = "of-list";
  247. images {
  248. kernel@1 {
  249. description = "SPL";
  250. os = "u-boot";
  251. type = "rkspi";
  252. arch = "arm";
  253. compression = "none";
  254. load = <0>;
  255. entry = <0>;
  256. u-boot-spl {
  257. };
  258. };
  259. };
  260. };
  261. };
  262. U-Boot supports creating fdt and config nodes automatically. To do this,
  263. pass an of-list property (e.g. -a of-list=file1 file2). This tells binman
  264. that you want to generates nodes for two files: file1.dtb and file2.dtb
  265. The fit,fdt-list property (see above) indicates that of-list should be used.
  266. If the property is missing you will get an error.
  267. Then add a 'generator node', a node with a name starting with '@':
  268. images {
  269. @fdt-SEQ {
  270. description = "fdt-NAME";
  271. type = "flat_dt";
  272. compression = "none";
  273. };
  274. };
  275. This tells binman to create nodes fdt-1 and fdt-2 for each of your two
  276. files. All the properties you specify will be included in the node. This
  277. node acts like a template to generate the nodes. The generator node itself
  278. does not appear in the output - it is replaced with what binman generates.
  279. You can create config nodes in a similar way:
  280. configurations {
  281. default = "@config-DEFAULT-SEQ";
  282. @config-SEQ {
  283. description = "NAME";
  284. firmware = "uboot";
  285. loadables = "atf";
  286. fdt = "fdt-SEQ";
  287. };
  288. };
  289. This tells binman to create nodes config-1 and config-2, i.e. a config for
  290. each of your two files.
  291. Available substitutions for '@' nodes are:
  292. SEQ Sequence number of the generated fdt (1, 2, ...)
  293. NAME Name of the dtb as provided (i.e. without adding '.dtb')
  294. Note that if no devicetree files are provided (with '-a of-list' as above)
  295. then no nodes will be generated.
  296. The 'default' property, if present, will be automatically set to the name
  297. if of configuration whose devicetree matches the 'default-dt' entry
  298. argument, e.g. with '-a default-dt=sun50i-a64-pine64-lts'.
  299. Properties (in the 'fit' node itself):
  300. fit,external-offset: Indicates that the contents of the FIT are external
  301. and provides the external offset. This is passsed to mkimage via
  302. the -E and -p flags.
  303. Entry: fmap: An entry which contains an Fmap section
  304. ----------------------------------------------------
  305. Properties / Entry arguments:
  306. None
  307. FMAP is a simple format used by flashrom, an open-source utility for
  308. reading and writing the SPI flash, typically on x86 CPUs. The format
  309. provides flashrom with a list of areas, so it knows what it in the flash.
  310. It can then read or write just a single area, instead of the whole flash.
  311. The format is defined by the flashrom project, in the file lib/fmap.h -
  312. see www.flashrom.org/Flashrom for more information.
  313. When used, this entry will be populated with an FMAP which reflects the
  314. entries in the current image. Note that any hierarchy is squashed, since
  315. FMAP does not support this. Also, CBFS entries appear as a single entry -
  316. the sub-entries are ignored.
  317. Entry: gbb: An entry which contains a Chromium OS Google Binary Block
  318. ---------------------------------------------------------------------
  319. Properties / Entry arguments:
  320. - hardware-id: Hardware ID to use for this build (a string)
  321. - keydir: Directory containing the public keys to use
  322. - bmpblk: Filename containing images used by recovery
  323. Chromium OS uses a GBB to store various pieces of information, in particular
  324. the root and recovery keys that are used to verify the boot process. Some
  325. more details are here:
  326. https://www.chromium.org/chromium-os/firmware-porting-guide/2-concepts
  327. but note that the page dates from 2013 so is quite out of date. See
  328. README.chromium for how to obtain the required keys and tools.
  329. Entry: image-header: An entry which contains a pointer to the FDT map
  330. ---------------------------------------------------------------------
  331. Properties / Entry arguments:
  332. location: Location of header ("start" or "end" of image). This is
  333. optional. If omitted then the entry must have an offset property.
  334. This adds an 8-byte entry to the start or end of the image, pointing to the
  335. location of the FDT map. The format is a magic number followed by an offset
  336. from the start or end of the image, in twos-compliment format.
  337. This entry must be in the top-level part of the image.
  338. NOTE: If the location is at the start/end, you will probably need to specify
  339. sort-by-offset for the image, unless you actually put the image header
  340. first/last in the entry list.
  341. Entry: intel-cmc: Entry containing an Intel Chipset Micro Code (CMC) file
  342. -------------------------------------------------------------------------
  343. Properties / Entry arguments:
  344. - filename: Filename of file to read into entry
  345. This file contains microcode for some devices in a special format. An
  346. example filename is 'Microcode/C0_22211.BIN'.
  347. See README.x86 for information about x86 binary blobs.
  348. Entry: intel-descriptor: Intel flash descriptor block (4KB)
  349. -----------------------------------------------------------
  350. Properties / Entry arguments:
  351. filename: Filename of file containing the descriptor. This is typically
  352. a 4KB binary file, sometimes called 'descriptor.bin'
  353. This entry is placed at the start of flash and provides information about
  354. the SPI flash regions. In particular it provides the base address and
  355. size of the ME (Management Engine) region, allowing us to place the ME
  356. binary in the right place.
  357. With this entry in your image, the position of the 'intel-me' entry will be
  358. fixed in the image, which avoids you needed to specify an offset for that
  359. region. This is useful, because it is not possible to change the position
  360. of the ME region without updating the descriptor.
  361. See README.x86 for information about x86 binary blobs.
  362. Entry: intel-fit: Intel Firmware Image Table (FIT)
  363. --------------------------------------------------
  364. This entry contains a dummy FIT as required by recent Intel CPUs. The FIT
  365. contains information about the firmware and microcode available in the
  366. image.
  367. At present binman only supports a basic FIT with no microcode.
  368. Entry: intel-fit-ptr: Intel Firmware Image Table (FIT) pointer
  369. --------------------------------------------------------------
  370. This entry contains a pointer to the FIT. It is required to be at address
  371. 0xffffffc0 in the image.
  372. Entry: intel-fsp: Entry containing an Intel Firmware Support Package (FSP) file
  373. -------------------------------------------------------------------------------
  374. Properties / Entry arguments:
  375. - filename: Filename of file to read into entry
  376. This file contains binary blobs which are used on some devices to make the
  377. platform work. U-Boot executes this code since it is not possible to set up
  378. the hardware using U-Boot open-source code. Documentation is typically not
  379. available in sufficient detail to allow this.
  380. An example filename is 'FSP/QUEENSBAY_FSP_GOLD_001_20-DECEMBER-2013.fd'
  381. See README.x86 for information about x86 binary blobs.
  382. Entry: intel-fsp-m: Entry containing Intel Firmware Support Package (FSP) memory init
  383. -------------------------------------------------------------------------------------
  384. Properties / Entry arguments:
  385. - filename: Filename of file to read into entry
  386. This file contains a binary blob which is used on some devices to set up
  387. SDRAM. U-Boot executes this code in SPL so that it can make full use of
  388. memory. Documentation is typically not available in sufficient detail to
  389. allow U-Boot do this this itself..
  390. An example filename is 'fsp_m.bin'
  391. See README.x86 for information about x86 binary blobs.
  392. Entry: intel-fsp-s: Entry containing Intel Firmware Support Package (FSP) silicon init
  393. --------------------------------------------------------------------------------------
  394. Properties / Entry arguments:
  395. - filename: Filename of file to read into entry
  396. This file contains a binary blob which is used on some devices to set up
  397. the silicon. U-Boot executes this code in U-Boot proper after SDRAM is
  398. running, so that it can make full use of memory. Documentation is typically
  399. not available in sufficient detail to allow U-Boot do this this itself.
  400. An example filename is 'fsp_s.bin'
  401. See README.x86 for information about x86 binary blobs.
  402. Entry: intel-fsp-t: Entry containing Intel Firmware Support Package (FSP) temp ram init
  403. ---------------------------------------------------------------------------------------
  404. Properties / Entry arguments:
  405. - filename: Filename of file to read into entry
  406. This file contains a binary blob which is used on some devices to set up
  407. temporary memory (Cache-as-RAM or CAR). U-Boot executes this code in TPL so
  408. that it has access to memory for its stack and initial storage.
  409. An example filename is 'fsp_t.bin'
  410. See README.x86 for information about x86 binary blobs.
  411. Entry: intel-ifwi: Entry containing an Intel Integrated Firmware Image (IFWI) file
  412. ----------------------------------------------------------------------------------
  413. Properties / Entry arguments:
  414. - filename: Filename of file to read into entry. This is either the
  415. IFWI file itself, or a file that can be converted into one using a
  416. tool
  417. - convert-fit: If present this indicates that the ifwitool should be
  418. used to convert the provided file into a IFWI.
  419. This file contains code and data used by the SoC that is required to make
  420. it work. It includes U-Boot TPL, microcode, things related to the CSE
  421. (Converged Security Engine, the microcontroller that loads all the firmware)
  422. and other items beyond the wit of man.
  423. A typical filename is 'ifwi.bin' for an IFWI file, or 'fitimage.bin' for a
  424. file that will be converted to an IFWI.
  425. The position of this entry is generally set by the intel-descriptor entry.
  426. The contents of the IFWI are specified by the subnodes of the IFWI node.
  427. Each subnode describes an entry which is placed into the IFWFI with a given
  428. sub-partition (and optional entry name).
  429. Properties for subnodes:
  430. ifwi-subpart - sub-parition to put this entry into, e.g. "IBBP"
  431. ifwi-entry - entry name t use, e.g. "IBBL"
  432. ifwi-replace - if present, indicates that the item should be replaced
  433. in the IFWI. Otherwise it is added.
  434. See README.x86 for information about x86 binary blobs.
  435. Entry: intel-me: Entry containing an Intel Management Engine (ME) file
  436. ----------------------------------------------------------------------
  437. Properties / Entry arguments:
  438. - filename: Filename of file to read into entry
  439. This file contains code used by the SoC that is required to make it work.
  440. The Management Engine is like a background task that runs things that are
  441. not clearly documented, but may include keyboard, display and network
  442. access. For platform that use ME it is not possible to disable it. U-Boot
  443. does not directly execute code in the ME binary.
  444. A typical filename is 'me.bin'.
  445. The position of this entry is generally set by the intel-descriptor entry.
  446. See README.x86 for information about x86 binary blobs.
  447. Entry: intel-mrc: Entry containing an Intel Memory Reference Code (MRC) file
  448. ----------------------------------------------------------------------------
  449. Properties / Entry arguments:
  450. - filename: Filename of file to read into entry
  451. This file contains code for setting up the SDRAM on some Intel systems. This
  452. is executed by U-Boot when needed early during startup. A typical filename
  453. is 'mrc.bin'.
  454. See README.x86 for information about x86 binary blobs.
  455. Entry: intel-refcode: Entry containing an Intel Reference Code file
  456. -------------------------------------------------------------------
  457. Properties / Entry arguments:
  458. - filename: Filename of file to read into entry
  459. This file contains code for setting up the platform on some Intel systems.
  460. This is executed by U-Boot when needed early during startup. A typical
  461. filename is 'refcode.bin'.
  462. See README.x86 for information about x86 binary blobs.
  463. Entry: intel-vbt: Entry containing an Intel Video BIOS Table (VBT) file
  464. -----------------------------------------------------------------------
  465. Properties / Entry arguments:
  466. - filename: Filename of file to read into entry
  467. This file contains code that sets up the integrated graphics subsystem on
  468. some Intel SoCs. U-Boot executes this when the display is started up.
  469. See README.x86 for information about Intel binary blobs.
  470. Entry: intel-vga: Entry containing an Intel Video Graphics Adaptor (VGA) file
  471. -----------------------------------------------------------------------------
  472. Properties / Entry arguments:
  473. - filename: Filename of file to read into entry
  474. This file contains code that sets up the integrated graphics subsystem on
  475. some Intel SoCs. U-Boot executes this when the display is started up.
  476. This is similar to the VBT file but in a different format.
  477. See README.x86 for information about Intel binary blobs.
  478. Entry: mkimage: Entry containing a binary produced by mkimage
  479. -------------------------------------------------------------
  480. Properties / Entry arguments:
  481. - datafile: Filename for -d argument
  482. - args: Other arguments to pass
  483. The data passed to mkimage is collected from subnodes of the mkimage node,
  484. e.g.:
  485. mkimage {
  486. args = "-n test -T imximage";
  487. u-boot-spl {
  488. };
  489. };
  490. This calls mkimage to create an imximage with u-boot-spl.bin as the input
  491. file. The output from mkimage then becomes part of the image produced by
  492. binman.
  493. Entry: powerpc-mpc85xx-bootpg-resetvec: PowerPC mpc85xx bootpg + resetvec code for U-Boot
  494. -----------------------------------------------------------------------------------------
  495. Properties / Entry arguments:
  496. - filename: Filename of u-boot-br.bin (default 'u-boot-br.bin')
  497. This entry is valid for PowerPC mpc85xx cpus. This entry holds
  498. 'bootpg + resetvec' code for PowerPC mpc85xx CPUs which needs to be
  499. placed at offset 'RESET_VECTOR_ADDRESS - 0xffc'.
  500. Entry: section: Entry that contains other entries
  501. -------------------------------------------------
  502. Properties / Entry arguments: (see binman README for more information)
  503. pad-byte: Pad byte to use when padding
  504. sort-by-offset: True if entries should be sorted by offset, False if
  505. they must be in-order in the device tree description
  506. end-at-4gb: Used to build an x86 ROM which ends at 4GB (2^32)
  507. skip-at-start: Number of bytes before the first entry starts. These
  508. effectively adjust the starting offset of entries. For example,
  509. if this is 16, then the first entry would start at 16. An entry
  510. with offset = 20 would in fact be written at offset 4 in the image
  511. file, since the first 16 bytes are skipped when writing.
  512. name-prefix: Adds a prefix to the name of every entry in the section
  513. when writing out the map
  514. Properties:
  515. allow_missing: True if this section permits external blobs to be
  516. missing their contents. The second will produce an image but of
  517. course it will not work.
  518. Since a section is also an entry, it inherits all the properies of entries
  519. too.
  520. A section is an entry which can contain other entries, thus allowing
  521. hierarchical images to be created. See 'Sections and hierarchical images'
  522. in the binman README for more information.
  523. Entry: text: An entry which contains text
  524. -----------------------------------------
  525. The text can be provided either in the node itself or by a command-line
  526. argument. There is a level of indirection to allow multiple text strings
  527. and sharing of text.
  528. Properties / Entry arguments:
  529. text-label: The value of this string indicates the property / entry-arg
  530. that contains the string to place in the entry
  531. <xxx> (actual name is the value of text-label): contains the string to
  532. place in the entry.
  533. <text>: The text to place in the entry (overrides the above mechanism).
  534. This is useful when the text is constant.
  535. Example node:
  536. text {
  537. size = <50>;
  538. text-label = "message";
  539. };
  540. You can then use:
  541. binman -amessage="this is my message"
  542. and binman will insert that string into the entry.
  543. It is also possible to put the string directly in the node:
  544. text {
  545. size = <8>;
  546. text-label = "message";
  547. message = "a message directly in the node"
  548. };
  549. or just:
  550. text {
  551. size = <8>;
  552. text = "some text directly in the node"
  553. };
  554. The text is not itself nul-terminated. This can be achieved, if required,
  555. by setting the size of the entry to something larger than the text.
  556. Entry: u-boot: U-Boot flat binary
  557. ---------------------------------
  558. Properties / Entry arguments:
  559. - filename: Filename of u-boot.bin (default 'u-boot.bin')
  560. This is the U-Boot binary, containing relocation information to allow it
  561. to relocate itself at runtime. The binary typically includes a device tree
  562. blob at the end of it. Use u_boot_nodtb if you want to package the device
  563. tree separately.
  564. U-Boot can access binman symbols at runtime. See:
  565. 'Access to binman entry offsets at run time (fdt)'
  566. in the binman README for more information.
  567. Entry: u-boot-dtb: U-Boot device tree
  568. -------------------------------------
  569. Properties / Entry arguments:
  570. - filename: Filename of u-boot.dtb (default 'u-boot.dtb')
  571. This is the U-Boot device tree, containing configuration information for
  572. U-Boot. U-Boot needs this to know what devices are present and which drivers
  573. to activate.
  574. Note: This is mostly an internal entry type, used by others. This allows
  575. binman to know which entries contain a device tree.
  576. Entry: u-boot-dtb-with-ucode: A U-Boot device tree file, with the microcode removed
  577. -----------------------------------------------------------------------------------
  578. Properties / Entry arguments:
  579. - filename: Filename of u-boot.dtb (default 'u-boot.dtb')
  580. See Entry_u_boot_ucode for full details of the three entries involved in
  581. this process. This entry provides the U-Boot device-tree file, which
  582. contains the microcode. If the microcode is not being collated into one
  583. place then the offset and size of the microcode is recorded by this entry,
  584. for use by u_boot_with_ucode_ptr. If it is being collated, then this
  585. entry deletes the microcode from the device tree (to save space) and makes
  586. it available to u_boot_ucode.
  587. Entry: u-boot-elf: U-Boot ELF image
  588. -----------------------------------
  589. Properties / Entry arguments:
  590. - filename: Filename of u-boot (default 'u-boot')
  591. This is the U-Boot ELF image. It does not include a device tree but can be
  592. relocated to any address for execution.
  593. Entry: u-boot-img: U-Boot legacy image
  594. --------------------------------------
  595. Properties / Entry arguments:
  596. - filename: Filename of u-boot.img (default 'u-boot.img')
  597. This is the U-Boot binary as a packaged image, in legacy format. It has a
  598. header which allows it to be loaded at the correct address for execution.
  599. You should use FIT (Flat Image Tree) instead of the legacy image for new
  600. applications.
  601. Entry: u-boot-nodtb: U-Boot flat binary without device tree appended
  602. --------------------------------------------------------------------
  603. Properties / Entry arguments:
  604. - filename: Filename of u-boot.bin (default 'u-boot-nodtb.bin')
  605. This is the U-Boot binary, containing relocation information to allow it
  606. to relocate itself at runtime. It does not include a device tree blob at
  607. the end of it so normally cannot work without it. You can add a u_boot_dtb
  608. entry after this one, or use a u_boot entry instead (which contains both
  609. U-Boot and the device tree).
  610. Entry: u-boot-spl: U-Boot SPL binary
  611. ------------------------------------
  612. Properties / Entry arguments:
  613. - filename: Filename of u-boot-spl.bin (default 'spl/u-boot-spl.bin')
  614. This is the U-Boot SPL (Secondary Program Loader) binary. This is a small
  615. binary which loads before U-Boot proper, typically into on-chip SRAM. It is
  616. responsible for locating, loading and jumping to U-Boot. Note that SPL is
  617. not relocatable so must be loaded to the correct address in SRAM, or written
  618. to run from the correct address if direct flash execution is possible (e.g.
  619. on x86 devices).
  620. SPL can access binman symbols at runtime. See:
  621. 'Access to binman entry offsets at run time (symbols)'
  622. in the binman README for more information.
  623. The ELF file 'spl/u-boot-spl' must also be available for this to work, since
  624. binman uses that to look up symbols to write into the SPL binary.
  625. Entry: u-boot-spl-bss-pad: U-Boot SPL binary padded with a BSS region
  626. ---------------------------------------------------------------------
  627. Properties / Entry arguments:
  628. None
  629. This is similar to u_boot_spl except that padding is added after the SPL
  630. binary to cover the BSS (Block Started by Symbol) region. This region holds
  631. the various used by SPL. It is set to 0 by SPL when it starts up. If you
  632. want to append data to the SPL image (such as a device tree file), you must
  633. pad out the BSS region to avoid the data overlapping with U-Boot variables.
  634. This entry is useful in that case. It automatically pads out the entry size
  635. to cover both the code, data and BSS.
  636. The ELF file 'spl/u-boot-spl' must also be available for this to work, since
  637. binman uses that to look up the BSS address.
  638. Entry: u-boot-spl-dtb: U-Boot SPL device tree
  639. ---------------------------------------------
  640. Properties / Entry arguments:
  641. - filename: Filename of u-boot.dtb (default 'spl/u-boot-spl.dtb')
  642. This is the SPL device tree, containing configuration information for
  643. SPL. SPL needs this to know what devices are present and which drivers
  644. to activate.
  645. Entry: u-boot-spl-elf: U-Boot SPL ELF image
  646. -------------------------------------------
  647. Properties / Entry arguments:
  648. - filename: Filename of SPL u-boot (default 'spl/u-boot-spl')
  649. This is the U-Boot SPL ELF image. It does not include a device tree but can
  650. be relocated to any address for execution.
  651. Entry: u-boot-spl-nodtb: SPL binary without device tree appended
  652. ----------------------------------------------------------------
  653. Properties / Entry arguments:
  654. - filename: Filename of spl/u-boot-spl-nodtb.bin (default
  655. 'spl/u-boot-spl-nodtb.bin')
  656. This is the U-Boot SPL binary, It does not include a device tree blob at
  657. the end of it so may not be able to work without it, assuming SPL needs
  658. a device tree to operation on your platform. You can add a u_boot_spl_dtb
  659. entry after this one, or use a u_boot_spl entry instead (which contains
  660. both SPL and the device tree).
  661. Entry: u-boot-spl-with-ucode-ptr: U-Boot SPL with embedded microcode pointer
  662. ----------------------------------------------------------------------------
  663. This is used when SPL must set up the microcode for U-Boot.
  664. See Entry_u_boot_ucode for full details of the entries involved in this
  665. process.
  666. Entry: u-boot-tpl: U-Boot TPL binary
  667. ------------------------------------
  668. Properties / Entry arguments:
  669. - filename: Filename of u-boot-tpl.bin (default 'tpl/u-boot-tpl.bin')
  670. This is the U-Boot TPL (Tertiary Program Loader) binary. This is a small
  671. binary which loads before SPL, typically into on-chip SRAM. It is
  672. responsible for locating, loading and jumping to SPL, the next-stage
  673. loader. Note that SPL is not relocatable so must be loaded to the correct
  674. address in SRAM, or written to run from the correct address if direct
  675. flash execution is possible (e.g. on x86 devices).
  676. SPL can access binman symbols at runtime. See:
  677. 'Access to binman entry offsets at run time (symbols)'
  678. in the binman README for more information.
  679. The ELF file 'tpl/u-boot-tpl' must also be available for this to work, since
  680. binman uses that to look up symbols to write into the TPL binary.
  681. Entry: u-boot-tpl-dtb: U-Boot TPL device tree
  682. ---------------------------------------------
  683. Properties / Entry arguments:
  684. - filename: Filename of u-boot.dtb (default 'tpl/u-boot-tpl.dtb')
  685. This is the TPL device tree, containing configuration information for
  686. TPL. TPL needs this to know what devices are present and which drivers
  687. to activate.
  688. Entry: u-boot-tpl-dtb-with-ucode: U-Boot TPL with embedded microcode pointer
  689. ----------------------------------------------------------------------------
  690. This is used when TPL must set up the microcode for U-Boot.
  691. See Entry_u_boot_ucode for full details of the entries involved in this
  692. process.
  693. Entry: u-boot-tpl-elf: U-Boot TPL ELF image
  694. -------------------------------------------
  695. Properties / Entry arguments:
  696. - filename: Filename of TPL u-boot (default 'tpl/u-boot-tpl')
  697. This is the U-Boot TPL ELF image. It does not include a device tree but can
  698. be relocated to any address for execution.
  699. Entry: u-boot-tpl-with-ucode-ptr: U-Boot TPL with embedded microcode pointer
  700. ----------------------------------------------------------------------------
  701. See Entry_u_boot_ucode for full details of the entries involved in this
  702. process.
  703. Entry: u-boot-ucode: U-Boot microcode block
  704. -------------------------------------------
  705. Properties / Entry arguments:
  706. None
  707. The contents of this entry are filled in automatically by other entries
  708. which must also be in the image.
  709. U-Boot on x86 needs a single block of microcode. This is collected from
  710. the various microcode update nodes in the device tree. It is also unable
  711. to read the microcode from the device tree on platforms that use FSP
  712. (Firmware Support Package) binaries, because the API requires that the
  713. microcode is supplied before there is any SRAM available to use (i.e.
  714. the FSP sets up the SRAM / cache-as-RAM but does so in the call that
  715. requires the microcode!). To keep things simple, all x86 platforms handle
  716. microcode the same way in U-Boot (even non-FSP platforms). This is that
  717. a table is placed at _dt_ucode_base_size containing the base address and
  718. size of the microcode. This is either passed to the FSP (for FSP
  719. platforms), or used to set up the microcode (for non-FSP platforms).
  720. This all happens in the build system since it is the only way to get
  721. the microcode into a single blob and accessible without SRAM.
  722. There are two cases to handle. If there is only one microcode blob in
  723. the device tree, then the ucode pointer it set to point to that. This
  724. entry (u-boot-ucode) is empty. If there is more than one update, then
  725. this entry holds the concatenation of all updates, and the device tree
  726. entry (u-boot-dtb-with-ucode) is updated to remove the microcode. This
  727. last step ensures that that the microcode appears in one contiguous
  728. block in the image and is not unnecessarily duplicated in the device
  729. tree. It is referred to as 'collation' here.
  730. Entry types that have a part to play in handling microcode:
  731. Entry_u_boot_with_ucode_ptr:
  732. Contains u-boot-nodtb.bin (i.e. U-Boot without the device tree).
  733. It updates it with the address and size of the microcode so that
  734. U-Boot can find it early on start-up.
  735. Entry_u_boot_dtb_with_ucode:
  736. Contains u-boot.dtb. It stores the microcode in a
  737. 'self.ucode_data' property, which is then read by this class to
  738. obtain the microcode if needed. If collation is performed, it
  739. removes the microcode from the device tree.
  740. Entry_u_boot_ucode:
  741. This class. If collation is enabled it reads the microcode from
  742. the Entry_u_boot_dtb_with_ucode entry, and uses it as the
  743. contents of this entry.
  744. Entry: u-boot-with-ucode-ptr: U-Boot with embedded microcode pointer
  745. --------------------------------------------------------------------
  746. Properties / Entry arguments:
  747. - filename: Filename of u-boot-nodtb.bin (default 'u-boot-nodtb.bin')
  748. - optional-ucode: boolean property to make microcode optional. If the
  749. u-boot.bin image does not include microcode, no error will
  750. be generated.
  751. See Entry_u_boot_ucode for full details of the three entries involved in
  752. this process. This entry updates U-Boot with the offset and size of the
  753. microcode, to allow early x86 boot code to find it without doing anything
  754. complicated. Otherwise it is the same as the u_boot entry.
  755. Entry: vblock: An entry which contains a Chromium OS verified boot block
  756. ------------------------------------------------------------------------
  757. Properties / Entry arguments:
  758. - content: List of phandles to entries to sign
  759. - keydir: Directory containing the public keys to use
  760. - keyblock: Name of the key file to use (inside keydir)
  761. - signprivate: Name of provide key file to use (inside keydir)
  762. - version: Version number of the vblock (typically 1)
  763. - kernelkey: Name of the kernel key to use (inside keydir)
  764. - preamble-flags: Value of the vboot preamble flags (typically 0)
  765. Output files:
  766. - input.<unique_name> - input file passed to futility
  767. - vblock.<unique_name> - output file generated by futility (which is
  768. used as the entry contents)
  769. Chromium OS signs the read-write firmware and kernel, writing the signature
  770. in this block. This allows U-Boot to verify that the next firmware stage
  771. and kernel are genuine.
  772. Entry: x86-reset16: x86 16-bit reset code for U-Boot
  773. ----------------------------------------------------
  774. Properties / Entry arguments:
  775. - filename: Filename of u-boot-x86-reset16.bin (default
  776. 'u-boot-x86-reset16.bin')
  777. x86 CPUs start up in 16-bit mode, even if they are 32-bit CPUs. This code
  778. must be placed at a particular address. This entry holds that code. It is
  779. typically placed at offset CONFIG_RESET_VEC_LOC. The code is responsible
  780. for jumping to the x86-start16 code, which continues execution.
  781. For 64-bit U-Boot, the 'x86_reset16_spl' entry type is used instead.
  782. Entry: x86-reset16-spl: x86 16-bit reset code for U-Boot
  783. --------------------------------------------------------
  784. Properties / Entry arguments:
  785. - filename: Filename of u-boot-x86-reset16.bin (default
  786. 'u-boot-x86-reset16.bin')
  787. x86 CPUs start up in 16-bit mode, even if they are 32-bit CPUs. This code
  788. must be placed at a particular address. This entry holds that code. It is
  789. typically placed at offset CONFIG_RESET_VEC_LOC. The code is responsible
  790. for jumping to the x86-start16 code, which continues execution.
  791. For 32-bit U-Boot, the 'x86_reset_spl' entry type is used instead.
  792. Entry: x86-reset16-tpl: x86 16-bit reset code for U-Boot
  793. --------------------------------------------------------
  794. Properties / Entry arguments:
  795. - filename: Filename of u-boot-x86-reset16.bin (default
  796. 'u-boot-x86-reset16.bin')
  797. x86 CPUs start up in 16-bit mode, even if they are 32-bit CPUs. This code
  798. must be placed at a particular address. This entry holds that code. It is
  799. typically placed at offset CONFIG_RESET_VEC_LOC. The code is responsible
  800. for jumping to the x86-start16 code, which continues execution.
  801. For 32-bit U-Boot, the 'x86_reset_tpl' entry type is used instead.
  802. Entry: x86-start16: x86 16-bit start-up code for U-Boot
  803. -------------------------------------------------------
  804. Properties / Entry arguments:
  805. - filename: Filename of u-boot-x86-start16.bin (default
  806. 'u-boot-x86-start16.bin')
  807. x86 CPUs start up in 16-bit mode, even if they are 32-bit CPUs. This code
  808. must be placed in the top 64KB of the ROM. The reset code jumps to it. This
  809. entry holds that code. It is typically placed at offset
  810. CONFIG_SYS_X86_START16. The code is responsible for changing to 32-bit mode
  811. and jumping to U-Boot's entry point, which requires 32-bit mode (for 32-bit
  812. U-Boot).
  813. For 64-bit U-Boot, the 'x86_start16_spl' entry type is used instead.
  814. Entry: x86-start16-spl: x86 16-bit start-up code for SPL
  815. --------------------------------------------------------
  816. Properties / Entry arguments:
  817. - filename: Filename of spl/u-boot-x86-start16-spl.bin (default
  818. 'spl/u-boot-x86-start16-spl.bin')
  819. x86 CPUs start up in 16-bit mode, even if they are 32-bit CPUs. This code
  820. must be placed in the top 64KB of the ROM. The reset code jumps to it. This
  821. entry holds that code. It is typically placed at offset
  822. CONFIG_SYS_X86_START16. The code is responsible for changing to 32-bit mode
  823. and jumping to U-Boot's entry point, which requires 32-bit mode (for 32-bit
  824. U-Boot).
  825. For 32-bit U-Boot, the 'x86-start16' entry type is used instead.
  826. Entry: x86-start16-tpl: x86 16-bit start-up code for TPL
  827. --------------------------------------------------------
  828. Properties / Entry arguments:
  829. - filename: Filename of tpl/u-boot-x86-start16-tpl.bin (default
  830. 'tpl/u-boot-x86-start16-tpl.bin')
  831. x86 CPUs start up in 16-bit mode, even if they are 32-bit CPUs. This code
  832. must be placed in the top 64KB of the ROM. The reset code jumps to it. This
  833. entry holds that code. It is typically placed at offset
  834. CONFIG_SYS_X86_START16. The code is responsible for changing to 32-bit mode
  835. and jumping to U-Boot's entry point, which requires 32-bit mode (for 32-bit
  836. U-Boot).
  837. If TPL is not being used, the 'x86-start16-spl or 'x86-start16' entry types
  838. may be used instead.