blob: d853aaafbc185d2a6d2d6431ba1f6bb6e5e67369 [file] [log] [blame]
Masahiro Yamada9fadbc82014-09-22 19:59:05 +09001#
2# Device Tree Control
3#
Masahiro Yamada9fadbc82014-09-22 19:59:05 +09004
5config SUPPORT_OF_CONTROL
6 bool
7
Tom Rini61d0fac2017-09-23 13:00:57 -04008config DTC
9 bool
10
Masahiro Yamada87247af2017-10-17 13:42:44 +090011config PYLIBFDT
12 bool
13
14config DTOC
15 bool
16 select PYLIBFDT
17
18config BINMAN
19 bool
20 select DTOC
21
Bin Mengd72582f2021-05-10 20:23:37 +080022config BINMAN_STANDALONE_FDT
23 bool
24 depends on BINMAN
25 default y if OF_BOARD || OF_PRIOR_STAGE
26 help
27 This option tells U-Boot build system that a standalone device tree
28 source is explicitly required when using binman to package U-Boot.
29
30 This is not necessary in a common scenario where a device tree source
31 that contains the binman node is provided in the arch/<arch>/dts
32 directory for a specific board. Such device tree sources are built for
33 OF_SEPARATE or OF_EMBED. However for a scenario like the board device
34 tree blob is not provided in the U-Boot build tree, but fed to U-Boot
35 in the runtime, e.g.: in the OF_PRIOR_STAGE case that it is passed by
36 a prior stage bootloader. For such scenario, a standalone device tree
37 blob containing binman node to describe how to package U-Boot should
38 be provided explicitly.
39
Masahiro Yamada9fadbc82014-09-22 19:59:05 +090040menu "Device Tree Control"
Masahiro Yamada9fadbc82014-09-22 19:59:05 +090041 depends on SUPPORT_OF_CONTROL
42
43config OF_CONTROL
44 bool "Run-time configuration via Device Tree"
Tom Rini61d0fac2017-09-23 13:00:57 -040045 select DTC
Sean Anderson08c854a2019-12-17 21:40:09 -050046 select OF_LIBFDT if !OF_PLATDATA
Masahiro Yamada9fadbc82014-09-22 19:59:05 +090047 help
48 This feature provides for run-time configuration of U-Boot
49 via a flattened device tree.
50
Simon Glass7c4ba162021-08-07 07:24:02 -060051config OF_REAL
52 def_bool y
53 help
54 Indicates that a real devicetree is available which can be accessed
55 at runtime. This means that dev_read_...() functions can be used to
56 read data from the devicetree for each device. This is true if
57 OF_CONTROL is enabled in U-Boot proper.
58
mario.six@gdsys.cc7e9b9d62017-02-22 16:07:22 +010059config OF_BOARD_FIXUP
60 bool "Board-specific manipulation of Device Tree"
61 help
62 In certain circumstances it is necessary to be able to modify
63 U-Boot's device tree (e.g. to delete device from it). This option
64 make the Device Tree writeable and provides a board-specific
65 "board_fix_fdt" callback (called during pre-relocation time), which
66 enables the board initialization to modifiy the Device Tree. The
67 modified copy is subsequently used by U-Boot after relocation.
68
Masahiro Yamada1e35f392015-08-12 07:31:54 +090069config SPL_OF_CONTROL
70 bool "Enable run-time configuration via Device Tree in SPL"
71 depends on SPL && OF_CONTROL
Sean Anderson08c854a2019-12-17 21:40:09 -050072 select SPL_OF_LIBFDT if !SPL_OF_PLATDATA
Simon Glass7c4ba162021-08-07 07:24:02 -060073 select SPL_OF_REAL if !SPL_OF_PLATDATA
Simon Glass400d0402015-02-27 22:06:38 -070074 help
75 Some boards use device tree in U-Boot but only have 4KB of SRAM
Walter Lozano7b3d2582019-10-22 11:50:19 -030076 which is not enough to support device tree. Disable this option to
Simon Glass400d0402015-02-27 22:06:38 -070077 allow such boards to be supported by U-Boot SPL.
78
Philipp Tomsich2341dc62017-06-29 11:11:21 +020079config TPL_OF_CONTROL
80 bool "Enable run-time configuration via Device Tree in TPL"
81 depends on TPL && OF_CONTROL
Sean Anderson08c854a2019-12-17 21:40:09 -050082 select TPL_OF_LIBFDT if !TPL_OF_PLATDATA
Simon Glass7c4ba162021-08-07 07:24:02 -060083 select TPL_OF_REAL if !TPL_OF_PLATDATA
Philipp Tomsich2341dc62017-06-29 11:11:21 +020084 help
85 Some boards use device tree in U-Boot but only have 4KB of SRAM
86 which is not enough to support device tree. Enable this option to
87 allow such boards to be supported by U-Boot TPL.
88
Simon Glassa6eedb82017-05-18 20:08:53 -060089config OF_LIVE
90 bool "Enable use of a live tree"
Bin Meng85f737b2021-02-03 21:20:03 +080091 depends on DM && OF_CONTROL
Simon Glassa6eedb82017-05-18 20:08:53 -060092 help
93 Normally U-Boot uses a flat device tree which saves space and
94 avoids the need to unpack the tree before use. However a flat
Michal Simek97a0e492018-08-17 10:16:36 +020095 tree does not support modification from within U-Boot since it
Simon Glassa6eedb82017-05-18 20:08:53 -060096 can invalidate driver-model device tree offsets. This option
97 enables a live tree which is available after relocation,
98 and can be adjusted as needed.
99
Masahiro Yamada9fadbc82014-09-22 19:59:05 +0900100choice
101 prompt "Provider of DTB for DT control"
102 depends on OF_CONTROL
103
104config OF_SEPARATE
105 bool "Separate DTB for DT control"
106 depends on !SANDBOX
107 help
108 If this option is enabled, the device tree will be built and
109 placed as a separate u-boot.dtb file alongside the U-Boot image.
110
111config OF_EMBED
112 bool "Embedded DTB for DT control"
113 help
114 If this option is enabled, the device tree will be picked up and
Simon Glassd9b64ea2015-08-31 18:47:52 -0600115 built into the U-Boot image. This is suitable for local debugging
116 and development only and is not recommended for production devices.
117 Boards in the mainline U-Boot tree should not use it.
Masahiro Yamada9fadbc82014-09-22 19:59:05 +0900118
Alex Deymo5b661ec2017-04-02 01:25:20 -0700119config OF_BOARD
120 bool "Provided by the board at runtime"
121 depends on !SANDBOX
122 help
123 If this option is enabled, the device tree will be provided by
124 the board at runtime if the board supports it, instead of being
125 bundled with the image.
126
Masahiro Yamada9fadbc82014-09-22 19:59:05 +0900127config OF_HOSTFILE
128 bool "Host filed DTB for DT control"
129 depends on SANDBOX
130 help
131 If this option is enabled, DTB will be read from a file on startup.
132 This is only useful for Sandbox. Use the -d flag to U-Boot to
133 specify the file to read.
134
Thomas Fitzsimmons919646d2018-06-08 17:59:45 -0400135config OF_PRIOR_STAGE
136 bool "Prior stage bootloader DTB for DT control"
137 help
138 If this option is enabled, the device tree used for DT
139 control will be read from a device tree binary, at a memory
140 location passed to U-Boot by the prior stage bootloader.
141
Masahiro Yamada9fadbc82014-09-22 19:59:05 +0900142endchoice
143
Masahiro Yamada8c65b9d2014-09-22 19:59:06 +0900144config DEFAULT_DEVICE_TREE
145 string "Default Device Tree for DT control"
Simon Glass644f5bc2016-02-22 22:55:44 -0700146 depends on OF_CONTROL
Masahiro Yamada8c65b9d2014-09-22 19:59:06 +0900147 help
148 This option specifies the default Device Tree used for DT control.
Robert P. J. Dayeb61df52014-10-21 16:44:32 -0400149 It can be overridden from the command line:
Masahiro Yamada8c65b9d2014-09-22 19:59:06 +0900150 $ make DEVICE_TREE=<device-tree-name>
151
Simon Glass963817b2016-02-22 22:55:57 -0700152config OF_LIST
153 string "List of device tree files to include for DT control"
Jean-Jacques Hiblot2037fa42017-09-15 12:57:24 +0200154 depends on SPL_LOAD_FIT || MULTI_DTB_FIT
Michal Simek9b2e95a2016-05-04 15:14:11 +0200155 default DEFAULT_DEVICE_TREE
Simon Glass963817b2016-02-22 22:55:57 -0700156 help
157 This option specifies a list of device tree files to use for DT
Cooper Jr., Franklin06c7b622017-06-16 17:25:09 -0500158 control. These will be packaged into a FIT. At run-time, U-boot
159 or SPL will select the correct DT to use by examining the
160 hardware (e.g. reading a board ID value). This is a list of
161 device tree files (without the directory or .dtb suffix)
162 separated by <space>.
Simon Glass963817b2016-02-22 22:55:57 -0700163
Jean-Jacques Hiblot985cec32019-10-22 16:39:21 +0200164config OF_OVERLAY_LIST
165 string "List of device tree overlays to include for DT control"
166 depends on SPL_LOAD_FIT_APPLY_OVERLAY
167 help
168 This option specifies a list of device tree overlays to use for DT
169 control. This option can then be used by a FIT generator to include
170 the overlays in the FIT image.
171
Marek Vasutaeaa29d2019-03-08 16:06:55 +0100172choice
Baruch Siach45508fc2019-10-07 15:05:47 +0300173 prompt "OF LIST compression"
Marek Vasutaeaa29d2019-03-08 16:06:55 +0100174 depends on MULTI_DTB_FIT
175 default MULTI_DTB_FIT_NO_COMPRESSION
176
177config MULTI_DTB_FIT_LZO
178 bool "LZO"
179 depends on SYS_MALLOC_F
180 select LZO
181 help
182 Compress the FIT image containing the DTBs available for the SPL
183 using LZO compression. (requires lzop on host).
184
185config MULTI_DTB_FIT_GZIP
186 bool "GZIP"
187 depends on SYS_MALLOC_F
188 select GZIP
189 help
190 Compress the FIT image containing the DTBs available for the SPL
191 using GZIP compression. (requires gzip on host)
192
193config MULTI_DTB_FIT_NO_COMPRESSION
194 bool "No compression"
195 help
196 Do not compress the FIT image containing the DTBs available for the SPL.
197 Use this options only if LZO is not available and the DTBs are very small.
198endchoice
199
200choice
201 prompt "Location of uncompressed DTBs"
202 depends on (MULTI_DTB_FIT_GZIP || MULTI_DTB_FIT_LZO)
203 default MULTI_DTB_FIT_DYN_ALLOC if SYS_MALLOC_F
204
205config MULTI_DTB_FIT_DYN_ALLOC
206 bool "Dynamically allocate the memory"
207 depends on SYS_MALLOC_F
208
209config MULTI_DTB_FIT_USER_DEFINED_AREA
210 bool "User-defined location"
211endchoice
212
213config MULTI_DTB_FIT_UNCOMPRESS_SZ
214 hex "Size of memory reserved to uncompress the DTBs"
215 depends on (MULTI_DTB_FIT_GZIP || MULTI_DTB_FIT_LZO)
216 default 0x8000
217 help
218 This is the size of this area where the DTBs are uncompressed.
219 If this area is dynamically allocated, make sure that
220 SYS_MALLOC_F_LEN is big enough to contain it.
221
222config MULTI_DTB_FIT_USER_DEF_ADDR
223 hex "Address of memory where dtbs are uncompressed"
224 depends on MULTI_DTB_FIT_USER_DEFINED_AREA
225 help
226 the FIT image containing the DTBs is uncompressed in an area defined
227 at compilation time. This is the address of this area. It must be
228 aligned on 2-byte boundary.
Jean-Jacques Hiblot2037fa42017-09-15 12:57:24 +0200229
230config DTB_RESELECT
231 bool "Support swapping dtbs at a later point in boot"
232 depends on MULTI_DTB_FIT
233 help
234 It is possible during initial boot you may need to use a generic
235 dtb until you can fully determine the board your running on. This
236 config allows boards to implement a function at a later point
237 during boot to switch to the "correct" dtb.
238
239config MULTI_DTB_FIT
240 bool "Support embedding several DTBs in a FIT image for u-boot"
241 help
242 This option provides hooks to allow U-boot to parse an
243 appended FIT image and enable board specific code to then select
244 the correct DTB to be used. Use this if you need to support
245 multiple DTBs but don't use the SPL.
246
Jean-Jacques Hiblota2fee162017-09-15 12:57:32 +0200247
248config SPL_MULTI_DTB_FIT
Simon Glass7c4ba162021-08-07 07:24:02 -0600249 depends on SPL_LOAD_FIT && SPL_OF_REAL
Jean-Jacques Hiblota2fee162017-09-15 12:57:32 +0200250 bool "Support embedding several DTBs in a FIT image for the SPL"
251 help
252 This option provides the SPL with the ability to select its own
253 DTB at runtime from an appended FIT image containing several DTBs.
254 This allows using the same SPL binary on multiple platforms.
255 The primary purpose is to handle different versions of
256 the same platform without tweaking the platform code if the
257 differences can be expressed in the DTBs (common examples are: bus
258 capabilities, pad configurations).
259
260config SPL_OF_LIST
261 string "List of device tree files to include for DT control in SPL"
262 depends on SPL_MULTI_DTB_FIT
263 default OF_LIST
264 help
265 This option specifies a list of device tree files to use for DT
266 control in the SPL. These will be packaged into a FIT. At run-time,
267 the SPL will select the correct DT to use by examining the
268 hardware (e.g. reading a board ID value). This is a list of
269 device tree files (without the directory or .dtb suffix)
270 separated by <space>.
271
272choice
273 prompt "SPL OF LIST compression"
274 depends on SPL_MULTI_DTB_FIT
275 default SPL_MULTI_DTB_FIT_LZO
276
277config SPL_MULTI_DTB_FIT_LZO
278 bool "LZO"
279 depends on SYS_MALLOC_F
280 select SPL_LZO
281 help
282 Compress the FIT image containing the DTBs available for the SPL
283 using LZO compression. (requires lzop on host).
284
285config SPL_MULTI_DTB_FIT_GZIP
286 bool "GZIP"
287 depends on SYS_MALLOC_F
288 select SPL_GZIP
289 help
290 Compress the FIT image containing the DTBs available for the SPL
291 using GZIP compression. (requires gzip on host)
292
293config SPL_MULTI_DTB_FIT_NO_COMPRESSION
294 bool "No compression"
295 help
296 Do not compress the FIT image containing the DTBs available for the SPL.
297 Use this options only if LZO is not available and the DTBs are very small.
298endchoice
299
300choice
Michal Simekc7df3a22018-07-23 08:38:56 +0200301 prompt "Location of uncompressed DTBs"
Jean-Jacques Hiblota2fee162017-09-15 12:57:32 +0200302 depends on (SPL_MULTI_DTB_FIT_GZIP || SPL_MULTI_DTB_FIT_LZO)
303 default SPL_MULTI_DTB_FIT_DYN_ALLOC if SYS_MALLOC_F
304
305config SPL_MULTI_DTB_FIT_DYN_ALLOC
306 bool "Dynamically allocate the memory"
307 depends on SYS_MALLOC_F
308
309config SPL_MULTI_DTB_FIT_USER_DEFINED_AREA
310 bool "User-defined location"
311endchoice
312
313config SPL_MULTI_DTB_FIT_UNCOMPRESS_SZ
314 hex "Size of memory reserved to uncompress the DTBs"
315 depends on (SPL_MULTI_DTB_FIT_GZIP || SPL_MULTI_DTB_FIT_LZO)
316 default 0x8000
317 help
318 This is the size of this area where the DTBs are uncompressed.
319 If this area is dynamically allocated, make sure that
320 SPL_SYS_MALLOC_F_LEN is big enough to contain it.
321
322config SPL_MULTI_DTB_FIT_USER_DEF_ADDR
323 hex "Address of memory where dtbs are uncompressed"
324 depends on SPL_MULTI_DTB_FIT_USER_DEFINED_AREA
325 help
326 the FIT image containing the DTBs is uncompressed in an area defined
327 at compilation time. This is the address of this area. It must be
328 aligned on 2-byte boundary.
329
Simon Glass89caf332015-06-23 15:38:29 -0600330config OF_SPL_REMOVE_PROPS
331 string "List of device tree properties to drop for SPL"
Masahiro Yamadaddb9aa972015-08-28 20:28:42 +0900332 depends on SPL_OF_CONTROL
Michal Simekde218072019-02-22 10:50:23 +0100333 default "interrupt-parent interrupts" if SPL_PINCTRL && SPL_CLK
334 default "clocks clock-names interrupt-parent interrupts" if SPL_PINCTRL
335 default "pinctrl-0 pinctrl-names interrupt-parent interrupts" if SPL_CLK
336 default "pinctrl-0 pinctrl-names clocks clock-names interrupt-parent interrupts"
Simon Glass89caf332015-06-23 15:38:29 -0600337 help
338 Since SPL normally runs in a reduced memory space, the device tree
339 is cut down to only what is needed to load and start U-Boot. Only
340 nodes marked with the property "u-boot,dm-pre-reloc" will be
341 included. In addition, some properties are not used by U-Boot and
342 can be discarded. This option defines the list of properties to
343 discard.
344
Anatolij Gustschin08568342020-01-12 15:57:42 +0100345config OF_DTB_PROPS_REMOVE
346 bool "Enable removal of device tree properties"
347 depends on OF_CONTROL
348 help
349 Some boards have restricted amount of storage for U-Boot image.
350 If the generated binary doesn't fit into available image storage,
351 the built-in device tree could probably be cut down by removing
352 some not required device tree properties to reduce the image size.
353 Enable this option and define the properties to be removed in the
354 CONFIG_OF_REMOVE_PROPS list. Do not enable this option if you must
355 pass the built-in DTB directly to the kernel!
356
357config OF_REMOVE_PROPS
358 string "List of device tree properties to drop"
359 depends on OF_DTB_PROPS_REMOVE
360 default "interrupt-parent interrupts" if PINCTRL
361 help
362 Some properties are not used by U-Boot and can be discarded.
363 This option defines the list of properties to discard.
364
Simon Glass7bc65f32016-07-04 11:58:06 -0600365config SPL_OF_PLATDATA
366 bool "Generate platform data for use in SPL"
367 depends on SPL_OF_CONTROL
Masahiro Yamada87247af2017-10-17 13:42:44 +0900368 select DTOC
Simon Glass8beeb282021-03-15 17:25:36 +1300369 select SPL_OF_PLATDATA_DRIVER_RT if !SPL_OF_PLATDATA_INST
Simon Glass7bc65f32016-07-04 11:58:06 -0600370 help
371 For very constrained SPL environments the overhead of decoding
372 device tree nodes and converting their contents into platform data
373 is too large. This overhead includes libfdt code as well as the
374 device tree contents itself. The latter is fairly compact, but the
375 former can add 3KB or more to a Thumb 2 Image.
376
377 This option enables generation of platform data from the device
Simon Glass1d8364a2020-12-28 20:34:54 -0700378 tree as C code. This code creates devices using U_BOOT_DRVINFO()
Simon Glass7bc65f32016-07-04 11:58:06 -0600379 declarations. The benefit is that it allows driver code to access
380 the platform data directly in C structures, avoidin the libfdt
381 overhead.
382
383 This option works by generating C structure declarations for each
Simon Glass1d8364a2020-12-28 20:34:54 -0700384 compatible string, then adding platform data and U_BOOT_DRVINFO
Simon Goldschmidt49ce8ca2019-01-16 20:40:18 +0100385 declarations for each node. See of-plat.txt for more information.
Simon Glass7bc65f32016-07-04 11:58:06 -0600386
Simon Glass7c4ba162021-08-07 07:24:02 -0600387config SPL_OF_REAL
388 bool
389 help
390 Indicates that a real devicetree is available which can be accessed
391 at runtime. This means that dev_read_...() functions can be used to
392 read data from the devicetree for each device. This is true if
393 SPL_OF_CONTROL is enabled and not SPL_OF_PLATDATA
394
Simon Glass240d5f62021-02-03 06:01:13 -0700395if SPL_OF_PLATDATA
396
Simon Glass36b15e22020-10-03 11:31:35 -0600397config SPL_OF_PLATDATA_PARENT
398 bool "Support parent information in devices"
Simon Glass36b15e22020-10-03 11:31:35 -0600399 default y
400 help
401 Generally it is useful to be able to access the parent of a device
402 with of-platdata. To save space this can be disabled, but in that
403 case dev_get_parent() will always return NULL;
404
Simon Glass240d5f62021-02-03 06:01:13 -0700405config SPL_OF_PLATDATA_INST
406 bool "Declare devices at build time"
407 help
408 Declare devices as udevice instances so that they do not need to be
409 bound when U-Boot starts. This can save time and code space.
410
Simon Glass47fd4a22021-03-15 17:25:15 +1300411config SPL_OF_PLATDATA_NO_BIND
412 bool "Don't allow run-time binding of devices"
413 depends on SPL_OF_PLATDATA_INST
414 default y
415 help
416 This removes the ability to bind devices at run time, thus saving
417 some code space in U-Boot. This can be disabled if binding is needed,
418 at the code of some code size increase.
419
Simon Glass5b21b342021-03-15 17:25:35 +1300420config SPL_OF_PLATDATA_RT
421 bool "Use a separate struct for device runtime data"
422 depends on SPL_OF_PLATDATA_INST
423 default y
424 help
425 For systems running SPL from read-only memory it is convenient to
426 separate out the runtime information, so that the devices don't need
427 to be copied before being used. This moves the read-write parts of
428 struct udevice (at present just the flags) into a separate struct,
429 which is allocated at runtime.
430
Simon Glass8beeb282021-03-15 17:25:36 +1300431config SPL_OF_PLATDATA_DRIVER_RT
432 bool
433 help
434 Use a separate struct for driver runtime data.
435
436 This enables the driver_rt information, used with of-platdata when
437 of-platdata-inst is not used. It allows finding devices by their
438 driver data.
439
Simon Glass240d5f62021-02-03 06:01:13 -0700440endif
441
Simon Glass7c4ba162021-08-07 07:24:02 -0600442config TPL_OF_REAL
443 bool
444 help
445 Indicates that a real devicetree is available which can be accessed
446 at runtime. This means that dev_read_...() functions can be used to
447 read data from the devicetree for each device. This is true if
448 TPL_OF_CONTROL is enabled and not TPL_OF_PLATDATA
449
Philipp Tomsich2341dc62017-06-29 11:11:21 +0200450config TPL_OF_PLATDATA
451 bool "Generate platform data for use in TPL"
452 depends on TPL_OF_CONTROL
Masahiro Yamada87247af2017-10-17 13:42:44 +0900453 select DTOC
Simon Glass8beeb282021-03-15 17:25:36 +1300454 select TPL_OF_PLATDATA_DRIVER_RT if !TPL_OF_PLATDATA_INST
Philipp Tomsich2341dc62017-06-29 11:11:21 +0200455 help
456 For very constrained SPL environments the overhead of decoding
457 device tree nodes and converting their contents into platform data
458 is too large. This overhead includes libfdt code as well as the
459 device tree contents itself. The latter is fairly compact, but the
460 former can add 3KB or more to a Thumb 2 Image.
461
462 This option enables generation of platform data from the device
Simon Glass1d8364a2020-12-28 20:34:54 -0700463 tree as C code. This code creates devices using U_BOOT_DRVINFO()
Philipp Tomsich2341dc62017-06-29 11:11:21 +0200464 declarations. The benefit is that it allows driver code to access
465 the platform data directly in C structures, avoidin the libfdt
466 overhead.
467
468 This option works by generating C structure declarations for each
Simon Glass1d8364a2020-12-28 20:34:54 -0700469 compatible string, then adding platform data and U_BOOT_DRVINFO
Simon Goldschmidt49ce8ca2019-01-16 20:40:18 +0100470 declarations for each node. See of-plat.txt for more information.
Philipp Tomsich2341dc62017-06-29 11:11:21 +0200471
Simon Glass240d5f62021-02-03 06:01:13 -0700472if TPL_OF_PLATDATA
473
Simon Glass36b15e22020-10-03 11:31:35 -0600474config TPL_OF_PLATDATA_PARENT
475 bool "Support parent information in devices"
Simon Glass36b15e22020-10-03 11:31:35 -0600476 default y
477 help
478 Generally it is useful to be able to access the parent of a device
479 with of-platdata. To save space this can be disabled, but in that
480 case dev_get_parent() will always return NULL;
481
Simon Glass240d5f62021-02-03 06:01:13 -0700482config TPL_OF_PLATDATA_INST
483 bool "Declare devices at build time"
484
485 help
486 Declare devices as udevice instances so that they do not need to be
487 bound when U-Boot starts. This can save time and code space.
488
Simon Glass47fd4a22021-03-15 17:25:15 +1300489config TPL_OF_PLATDATA_NO_BIND
490 bool "Don't allow run-time binding of devices"
491 depends on TPL_OF_PLATDATA_INST
492 default y
493 help
494 This removes the ability to bind devices at run time, thus saving
495 some code space in U-Boot. This can be disabled if binding is needed,
496 at the code of some code size increase.
497
Simon Glass5b21b342021-03-15 17:25:35 +1300498config TPL_OF_PLATDATA_RT
499 bool "Use a separate struct for device runtime data"
500 depends on TPL_OF_PLATDATA_INST
501 default y
502 help
503 For systems running TPL from read-only memory it is convenient to
504 separate out the runtime information, so that the devices don't need
505 to be copied before being used. This moves the read-write parts of
506 struct udevice (at present just the flags) into a separate struct,
507 which is allocated at runtime.
508
Simon Glass8beeb282021-03-15 17:25:36 +1300509config TPL_OF_PLATDATA_DRIVER_RT
510 bool
511 help
512 Use a separate struct for driver runtime data.
513
514 This enables the driver_rt information, used with of-platdata when
515 of-platdata-inst is not used. It allows finding devices by their
516 driver data.
517
Simon Glass240d5f62021-02-03 06:01:13 -0700518endif
519
Masahiro Yamada9fadbc82014-09-22 19:59:05 +0900520endmenu