blob: b7c4a2fec0316ea3d5a8e0a53a0bb557e22db8fd [file] [log] [blame]
Masahiro Yamada783e6a72014-09-22 19:59:05 +09001#
2# Device Tree Control
3#
Masahiro Yamada783e6a72014-09-22 19:59:05 +09004
5config SUPPORT_OF_CONTROL
6 bool
7
Masahiro Yamadad6a0c782017-10-17 13:42:44 +09008config PYLIBFDT
9 bool
10
11config DTOC
12 bool
13 select PYLIBFDT
14
15config BINMAN
16 bool
17 select DTOC
18
Bin Meng31eefd42021-05-10 20:23:37 +080019config BINMAN_STANDALONE_FDT
20 bool
21 depends on BINMAN
Ilias Apalodimasd6f8ab32021-10-12 00:00:15 +030022 default y if OF_BOARD
Bin Meng31eefd42021-05-10 20:23:37 +080023 help
24 This option tells U-Boot build system that a standalone device tree
25 source is explicitly required when using binman to package U-Boot.
26
27 This is not necessary in a common scenario where a device tree source
28 that contains the binman node is provided in the arch/<arch>/dts
29 directory for a specific board. Such device tree sources are built for
30 OF_SEPARATE or OF_EMBED. However for a scenario like the board device
31 tree blob is not provided in the U-Boot build tree, but fed to U-Boot
Ilias Apalodimasd6f8ab32021-10-12 00:00:15 +030032 in the runtime, e.g.: in the OF_BOARD case that it is passed by
Bin Meng31eefd42021-05-10 20:23:37 +080033 a prior stage bootloader. For such scenario, a standalone device tree
34 blob containing binman node to describe how to package U-Boot should
35 be provided explicitly.
36
Masahiro Yamada783e6a72014-09-22 19:59:05 +090037menu "Device Tree Control"
Masahiro Yamada783e6a72014-09-22 19:59:05 +090038 depends on SUPPORT_OF_CONTROL
39
40config OF_CONTROL
41 bool "Run-time configuration via Device Tree"
Sean Anderson327bb3b2019-12-17 21:40:09 -050042 select OF_LIBFDT if !OF_PLATDATA
Simon Glass414cc152021-08-07 07:24:03 -060043 select OF_REAL if !OF_PLATDATA
Masahiro Yamada783e6a72014-09-22 19:59:05 +090044 help
45 This feature provides for run-time configuration of U-Boot
46 via a flattened device tree.
47
Simon Glasseaad01a2021-08-07 07:24:02 -060048config OF_REAL
Simon Glass414cc152021-08-07 07:24:03 -060049 bool
Simon Glasseaad01a2021-08-07 07:24:02 -060050 help
51 Indicates that a real devicetree is available which can be accessed
52 at runtime. This means that dev_read_...() functions can be used to
53 read data from the devicetree for each device. This is true if
54 OF_CONTROL is enabled in U-Boot proper.
55
mario.six@gdsys.cc2a792752017-02-22 16:07:22 +010056config OF_BOARD_FIXUP
57 bool "Board-specific manipulation of Device Tree"
58 help
59 In certain circumstances it is necessary to be able to modify
60 U-Boot's device tree (e.g. to delete device from it). This option
61 make the Device Tree writeable and provides a board-specific
62 "board_fix_fdt" callback (called during pre-relocation time), which
63 enables the board initialization to modifiy the Device Tree. The
64 modified copy is subsequently used by U-Boot after relocation.
65
Masahiro Yamadadffb86e2015-08-12 07:31:54 +090066config SPL_OF_CONTROL
67 bool "Enable run-time configuration via Device Tree in SPL"
68 depends on SPL && OF_CONTROL
Sean Anderson327bb3b2019-12-17 21:40:09 -050069 select SPL_OF_LIBFDT if !SPL_OF_PLATDATA
Simon Glasseaad01a2021-08-07 07:24:02 -060070 select SPL_OF_REAL if !SPL_OF_PLATDATA
Simon Glass2860f032015-02-27 22:06:38 -070071 help
72 Some boards use device tree in U-Boot but only have 4KB of SRAM
Walter Lozanoc9acae32019-10-22 11:50:19 -030073 which is not enough to support device tree. Disable this option to
Simon Glass2860f032015-02-27 22:06:38 -070074 allow such boards to be supported by U-Boot SPL.
75
Philipp Tomsichf291ce12017-06-29 11:11:21 +020076config TPL_OF_CONTROL
77 bool "Enable run-time configuration via Device Tree in TPL"
78 depends on TPL && OF_CONTROL
Sean Anderson327bb3b2019-12-17 21:40:09 -050079 select TPL_OF_LIBFDT if !TPL_OF_PLATDATA
Simon Glasseaad01a2021-08-07 07:24:02 -060080 select TPL_OF_REAL if !TPL_OF_PLATDATA
Philipp Tomsichf291ce12017-06-29 11:11:21 +020081 help
82 Some boards use device tree in U-Boot but only have 4KB of SRAM
83 which is not enough to support device tree. Enable this option to
84 allow such boards to be supported by U-Boot TPL.
85
Simon Glass5e060d82017-05-18 20:08:53 -060086config OF_LIVE
87 bool "Enable use of a live tree"
Bin Mengced4c312021-02-03 21:20:03 +080088 depends on DM && OF_CONTROL
Simon Glass5e060d82017-05-18 20:08:53 -060089 help
90 Normally U-Boot uses a flat device tree which saves space and
91 avoids the need to unpack the tree before use. However a flat
Michal Simek4adc6602018-08-17 10:16:36 +020092 tree does not support modification from within U-Boot since it
Simon Glass5e060d82017-05-18 20:08:53 -060093 can invalidate driver-model device tree offsets. This option
94 enables a live tree which is available after relocation,
95 and can be adjusted as needed.
96
Masahiro Yamada783e6a72014-09-22 19:59:05 +090097choice
98 prompt "Provider of DTB for DT control"
99 depends on OF_CONTROL
Ilias Apalodimase7fb7892021-10-26 09:12:33 +0300100 default OF_BOARD if SANDBOX
Masahiro Yamada783e6a72014-09-22 19:59:05 +0900101
102config OF_SEPARATE
103 bool "Separate DTB for DT control"
104 depends on !SANDBOX
105 help
106 If this option is enabled, the device tree will be built and
107 placed as a separate u-boot.dtb file alongside the U-Boot image.
108
109config OF_EMBED
110 bool "Embedded DTB for DT control"
111 help
112 If this option is enabled, the device tree will be picked up and
Simon Glass3d3f60c2015-08-31 18:47:52 -0600113 built into the U-Boot image. This is suitable for local debugging
114 and development only and is not recommended for production devices.
115 Boards in the mainline U-Boot tree should not use it.
Masahiro Yamada783e6a72014-09-22 19:59:05 +0900116
Alex Deymo82f766d2017-04-02 01:25:20 -0700117config OF_BOARD
Ilias Apalodimas2e8d2f82021-10-12 00:00:13 +0300118 bool "Provided by the board (e.g a previous loader) at runtime"
Alex Deymo82f766d2017-04-02 01:25:20 -0700119 help
120 If this option is enabled, the device tree will be provided by
121 the board at runtime if the board supports it, instead of being
122 bundled with the image.
123
Masahiro Yamada783e6a72014-09-22 19:59:05 +0900124endchoice
125
Masahiro Yamadaf1ef2b62014-09-22 19:59:06 +0900126config DEFAULT_DEVICE_TREE
127 string "Default Device Tree for DT control"
Simon Glass70d41092016-02-22 22:55:44 -0700128 depends on OF_CONTROL
Masahiro Yamadaf1ef2b62014-09-22 19:59:06 +0900129 help
130 This option specifies the default Device Tree used for DT control.
Robert P. J. Day5699ea62014-10-21 16:44:32 -0400131 It can be overridden from the command line:
Masahiro Yamadaf1ef2b62014-09-22 19:59:06 +0900132 $ make DEVICE_TREE=<device-tree-name>
133
Simon Glasscdf17242016-02-22 22:55:57 -0700134config OF_LIST
135 string "List of device tree files to include for DT control"
Jean-Jacques Hiblot11955592017-09-15 12:57:24 +0200136 depends on SPL_LOAD_FIT || MULTI_DTB_FIT
Michal Simekc409bd02016-05-04 15:14:11 +0200137 default DEFAULT_DEVICE_TREE
Simon Glasscdf17242016-02-22 22:55:57 -0700138 help
139 This option specifies a list of device tree files to use for DT
Cooper Jr., Franklind9797402017-06-16 17:25:09 -0500140 control. These will be packaged into a FIT. At run-time, U-boot
141 or SPL will select the correct DT to use by examining the
142 hardware (e.g. reading a board ID value). This is a list of
143 device tree files (without the directory or .dtb suffix)
144 separated by <space>.
Simon Glasscdf17242016-02-22 22:55:57 -0700145
Jean-Jacques Hiblot557bc972019-10-22 16:39:21 +0200146config OF_OVERLAY_LIST
147 string "List of device tree overlays to include for DT control"
148 depends on SPL_LOAD_FIT_APPLY_OVERLAY
149 help
150 This option specifies a list of device tree overlays to use for DT
151 control. This option can then be used by a FIT generator to include
152 the overlays in the FIT image.
153
Marek Vasut95f4bbd2019-03-08 16:06:55 +0100154choice
Baruch Siach574e3862019-10-07 15:05:47 +0300155 prompt "OF LIST compression"
Marek Vasut95f4bbd2019-03-08 16:06:55 +0100156 depends on MULTI_DTB_FIT
157 default MULTI_DTB_FIT_NO_COMPRESSION
158
159config MULTI_DTB_FIT_LZO
160 bool "LZO"
161 depends on SYS_MALLOC_F
162 select LZO
163 help
164 Compress the FIT image containing the DTBs available for the SPL
165 using LZO compression. (requires lzop on host).
166
167config MULTI_DTB_FIT_GZIP
168 bool "GZIP"
169 depends on SYS_MALLOC_F
170 select GZIP
171 help
172 Compress the FIT image containing the DTBs available for the SPL
173 using GZIP compression. (requires gzip on host)
174
175config MULTI_DTB_FIT_NO_COMPRESSION
176 bool "No compression"
177 help
178 Do not compress the FIT image containing the DTBs available for the SPL.
179 Use this options only if LZO is not available and the DTBs are very small.
180endchoice
181
182choice
183 prompt "Location of uncompressed DTBs"
184 depends on (MULTI_DTB_FIT_GZIP || MULTI_DTB_FIT_LZO)
185 default MULTI_DTB_FIT_DYN_ALLOC if SYS_MALLOC_F
186
187config MULTI_DTB_FIT_DYN_ALLOC
188 bool "Dynamically allocate the memory"
189 depends on SYS_MALLOC_F
190
191config MULTI_DTB_FIT_USER_DEFINED_AREA
192 bool "User-defined location"
193endchoice
194
195config MULTI_DTB_FIT_UNCOMPRESS_SZ
196 hex "Size of memory reserved to uncompress the DTBs"
197 depends on (MULTI_DTB_FIT_GZIP || MULTI_DTB_FIT_LZO)
198 default 0x8000
199 help
200 This is the size of this area where the DTBs are uncompressed.
201 If this area is dynamically allocated, make sure that
202 SYS_MALLOC_F_LEN is big enough to contain it.
203
204config MULTI_DTB_FIT_USER_DEF_ADDR
205 hex "Address of memory where dtbs are uncompressed"
206 depends on MULTI_DTB_FIT_USER_DEFINED_AREA
207 help
208 the FIT image containing the DTBs is uncompressed in an area defined
209 at compilation time. This is the address of this area. It must be
210 aligned on 2-byte boundary.
Jean-Jacques Hiblot11955592017-09-15 12:57:24 +0200211
212config DTB_RESELECT
213 bool "Support swapping dtbs at a later point in boot"
214 depends on MULTI_DTB_FIT
215 help
216 It is possible during initial boot you may need to use a generic
217 dtb until you can fully determine the board your running on. This
218 config allows boards to implement a function at a later point
219 during boot to switch to the "correct" dtb.
220
221config MULTI_DTB_FIT
222 bool "Support embedding several DTBs in a FIT image for u-boot"
223 help
224 This option provides hooks to allow U-boot to parse an
225 appended FIT image and enable board specific code to then select
226 the correct DTB to be used. Use this if you need to support
227 multiple DTBs but don't use the SPL.
228
Jean-Jacques Hiblot2f57c952017-09-15 12:57:32 +0200229
230config SPL_MULTI_DTB_FIT
Simon Glasseaad01a2021-08-07 07:24:02 -0600231 depends on SPL_LOAD_FIT && SPL_OF_REAL
Jean-Jacques Hiblot2f57c952017-09-15 12:57:32 +0200232 bool "Support embedding several DTBs in a FIT image for the SPL"
233 help
234 This option provides the SPL with the ability to select its own
235 DTB at runtime from an appended FIT image containing several DTBs.
236 This allows using the same SPL binary on multiple platforms.
237 The primary purpose is to handle different versions of
238 the same platform without tweaking the platform code if the
239 differences can be expressed in the DTBs (common examples are: bus
240 capabilities, pad configurations).
241
242config SPL_OF_LIST
243 string "List of device tree files to include for DT control in SPL"
244 depends on SPL_MULTI_DTB_FIT
245 default OF_LIST
246 help
247 This option specifies a list of device tree files to use for DT
248 control in the SPL. These will be packaged into a FIT. At run-time,
249 the SPL will select the correct DT to use by examining the
250 hardware (e.g. reading a board ID value). This is a list of
251 device tree files (without the directory or .dtb suffix)
252 separated by <space>.
253
254choice
255 prompt "SPL OF LIST compression"
256 depends on SPL_MULTI_DTB_FIT
257 default SPL_MULTI_DTB_FIT_LZO
258
259config SPL_MULTI_DTB_FIT_LZO
260 bool "LZO"
261 depends on SYS_MALLOC_F
262 select SPL_LZO
263 help
264 Compress the FIT image containing the DTBs available for the SPL
265 using LZO compression. (requires lzop on host).
266
267config SPL_MULTI_DTB_FIT_GZIP
268 bool "GZIP"
269 depends on SYS_MALLOC_F
270 select SPL_GZIP
271 help
272 Compress the FIT image containing the DTBs available for the SPL
273 using GZIP compression. (requires gzip on host)
274
275config SPL_MULTI_DTB_FIT_NO_COMPRESSION
276 bool "No compression"
277 help
278 Do not compress the FIT image containing the DTBs available for the SPL.
279 Use this options only if LZO is not available and the DTBs are very small.
280endchoice
281
282choice
Michal Simekb8448052018-07-23 08:38:56 +0200283 prompt "Location of uncompressed DTBs"
Jean-Jacques Hiblot2f57c952017-09-15 12:57:32 +0200284 depends on (SPL_MULTI_DTB_FIT_GZIP || SPL_MULTI_DTB_FIT_LZO)
285 default SPL_MULTI_DTB_FIT_DYN_ALLOC if SYS_MALLOC_F
286
287config SPL_MULTI_DTB_FIT_DYN_ALLOC
288 bool "Dynamically allocate the memory"
289 depends on SYS_MALLOC_F
290
291config SPL_MULTI_DTB_FIT_USER_DEFINED_AREA
292 bool "User-defined location"
293endchoice
294
295config SPL_MULTI_DTB_FIT_UNCOMPRESS_SZ
296 hex "Size of memory reserved to uncompress the DTBs"
297 depends on (SPL_MULTI_DTB_FIT_GZIP || SPL_MULTI_DTB_FIT_LZO)
298 default 0x8000
299 help
300 This is the size of this area where the DTBs are uncompressed.
301 If this area is dynamically allocated, make sure that
302 SPL_SYS_MALLOC_F_LEN is big enough to contain it.
303
304config SPL_MULTI_DTB_FIT_USER_DEF_ADDR
305 hex "Address of memory where dtbs are uncompressed"
306 depends on SPL_MULTI_DTB_FIT_USER_DEFINED_AREA
307 help
308 the FIT image containing the DTBs is uncompressed in an area defined
309 at compilation time. This is the address of this area. It must be
310 aligned on 2-byte boundary.
311
Simon Glassfa78e0a2015-06-23 15:38:29 -0600312config OF_SPL_REMOVE_PROPS
313 string "List of device tree properties to drop for SPL"
Masahiro Yamada897705e2015-08-28 20:28:42 +0900314 depends on SPL_OF_CONTROL
Michal Simekf00d89f2019-02-22 10:50:23 +0100315 default "interrupt-parent interrupts" if SPL_PINCTRL && SPL_CLK
316 default "clocks clock-names interrupt-parent interrupts" if SPL_PINCTRL
317 default "pinctrl-0 pinctrl-names interrupt-parent interrupts" if SPL_CLK
318 default "pinctrl-0 pinctrl-names clocks clock-names interrupt-parent interrupts"
Simon Glassfa78e0a2015-06-23 15:38:29 -0600319 help
320 Since SPL normally runs in a reduced memory space, the device tree
321 is cut down to only what is needed to load and start U-Boot. Only
322 nodes marked with the property "u-boot,dm-pre-reloc" will be
323 included. In addition, some properties are not used by U-Boot and
324 can be discarded. This option defines the list of properties to
325 discard.
326
Anatolij Gustschin43b6e382020-01-12 15:57:42 +0100327config OF_DTB_PROPS_REMOVE
328 bool "Enable removal of device tree properties"
329 depends on OF_CONTROL
330 help
331 Some boards have restricted amount of storage for U-Boot image.
332 If the generated binary doesn't fit into available image storage,
333 the built-in device tree could probably be cut down by removing
334 some not required device tree properties to reduce the image size.
335 Enable this option and define the properties to be removed in the
336 CONFIG_OF_REMOVE_PROPS list. Do not enable this option if you must
337 pass the built-in DTB directly to the kernel!
338
339config OF_REMOVE_PROPS
340 string "List of device tree properties to drop"
341 depends on OF_DTB_PROPS_REMOVE
342 default "interrupt-parent interrupts" if PINCTRL
343 help
344 Some properties are not used by U-Boot and can be discarded.
345 This option defines the list of properties to discard.
346
Simon Glass2789ddb2016-07-04 11:58:06 -0600347config SPL_OF_PLATDATA
348 bool "Generate platform data for use in SPL"
349 depends on SPL_OF_CONTROL
Masahiro Yamadad6a0c782017-10-17 13:42:44 +0900350 select DTOC
Simon Glassab933d82021-03-15 17:25:36 +1300351 select SPL_OF_PLATDATA_DRIVER_RT if !SPL_OF_PLATDATA_INST
Simon Glass2789ddb2016-07-04 11:58:06 -0600352 help
353 For very constrained SPL environments the overhead of decoding
354 device tree nodes and converting their contents into platform data
355 is too large. This overhead includes libfdt code as well as the
356 device tree contents itself. The latter is fairly compact, but the
357 former can add 3KB or more to a Thumb 2 Image.
358
359 This option enables generation of platform data from the device
Simon Glass20e442a2020-12-28 20:34:54 -0700360 tree as C code. This code creates devices using U_BOOT_DRVINFO()
Simon Glass2789ddb2016-07-04 11:58:06 -0600361 declarations. The benefit is that it allows driver code to access
362 the platform data directly in C structures, avoidin the libfdt
363 overhead.
364
365 This option works by generating C structure declarations for each
Simon Glass20e442a2020-12-28 20:34:54 -0700366 compatible string, then adding platform data and U_BOOT_DRVINFO
Simon Goldschmidt3600b462019-01-16 20:40:18 +0100367 declarations for each node. See of-plat.txt for more information.
Simon Glass2789ddb2016-07-04 11:58:06 -0600368
Simon Glasseaad01a2021-08-07 07:24:02 -0600369config SPL_OF_REAL
370 bool
371 help
372 Indicates that a real devicetree is available which can be accessed
373 at runtime. This means that dev_read_...() functions can be used to
374 read data from the devicetree for each device. This is true if
375 SPL_OF_CONTROL is enabled and not SPL_OF_PLATDATA
376
Simon Glass5a1b25c2021-02-03 06:01:13 -0700377if SPL_OF_PLATDATA
378
Simon Glasse41651f2020-10-03 11:31:35 -0600379config SPL_OF_PLATDATA_PARENT
380 bool "Support parent information in devices"
Simon Glasse41651f2020-10-03 11:31:35 -0600381 default y
382 help
383 Generally it is useful to be able to access the parent of a device
384 with of-platdata. To save space this can be disabled, but in that
385 case dev_get_parent() will always return NULL;
386
Simon Glass5a1b25c2021-02-03 06:01:13 -0700387config SPL_OF_PLATDATA_INST
388 bool "Declare devices at build time"
389 help
390 Declare devices as udevice instances so that they do not need to be
391 bound when U-Boot starts. This can save time and code space.
392
Simon Glass1ef3af32021-03-15 17:25:15 +1300393config SPL_OF_PLATDATA_NO_BIND
394 bool "Don't allow run-time binding of devices"
395 depends on SPL_OF_PLATDATA_INST
396 default y
397 help
398 This removes the ability to bind devices at run time, thus saving
399 some code space in U-Boot. This can be disabled if binding is needed,
400 at the code of some code size increase.
401
Simon Glass95a58252021-03-15 17:25:35 +1300402config SPL_OF_PLATDATA_RT
403 bool "Use a separate struct for device runtime data"
404 depends on SPL_OF_PLATDATA_INST
405 default y
406 help
407 For systems running SPL from read-only memory it is convenient to
408 separate out the runtime information, so that the devices don't need
409 to be copied before being used. This moves the read-write parts of
410 struct udevice (at present just the flags) into a separate struct,
411 which is allocated at runtime.
412
Simon Glassab933d82021-03-15 17:25:36 +1300413config SPL_OF_PLATDATA_DRIVER_RT
414 bool
415 help
416 Use a separate struct for driver runtime data.
417
418 This enables the driver_rt information, used with of-platdata when
419 of-platdata-inst is not used. It allows finding devices by their
420 driver data.
421
Simon Glass5a1b25c2021-02-03 06:01:13 -0700422endif
423
Simon Glasseaad01a2021-08-07 07:24:02 -0600424config TPL_OF_REAL
425 bool
426 help
427 Indicates that a real devicetree is available which can be accessed
428 at runtime. This means that dev_read_...() functions can be used to
429 read data from the devicetree for each device. This is true if
430 TPL_OF_CONTROL is enabled and not TPL_OF_PLATDATA
431
Philipp Tomsichf291ce12017-06-29 11:11:21 +0200432config TPL_OF_PLATDATA
433 bool "Generate platform data for use in TPL"
434 depends on TPL_OF_CONTROL
Masahiro Yamadad6a0c782017-10-17 13:42:44 +0900435 select DTOC
Simon Glassab933d82021-03-15 17:25:36 +1300436 select TPL_OF_PLATDATA_DRIVER_RT if !TPL_OF_PLATDATA_INST
Philipp Tomsichf291ce12017-06-29 11:11:21 +0200437 help
438 For very constrained SPL environments the overhead of decoding
439 device tree nodes and converting their contents into platform data
440 is too large. This overhead includes libfdt code as well as the
441 device tree contents itself. The latter is fairly compact, but the
442 former can add 3KB or more to a Thumb 2 Image.
443
444 This option enables generation of platform data from the device
Simon Glass20e442a2020-12-28 20:34:54 -0700445 tree as C code. This code creates devices using U_BOOT_DRVINFO()
Philipp Tomsichf291ce12017-06-29 11:11:21 +0200446 declarations. The benefit is that it allows driver code to access
447 the platform data directly in C structures, avoidin the libfdt
448 overhead.
449
450 This option works by generating C structure declarations for each
Simon Glass20e442a2020-12-28 20:34:54 -0700451 compatible string, then adding platform data and U_BOOT_DRVINFO
Simon Goldschmidt3600b462019-01-16 20:40:18 +0100452 declarations for each node. See of-plat.txt for more information.
Philipp Tomsichf291ce12017-06-29 11:11:21 +0200453
Simon Glass5a1b25c2021-02-03 06:01:13 -0700454if TPL_OF_PLATDATA
455
Simon Glasse41651f2020-10-03 11:31:35 -0600456config TPL_OF_PLATDATA_PARENT
457 bool "Support parent information in devices"
Simon Glasse41651f2020-10-03 11:31:35 -0600458 default y
459 help
460 Generally it is useful to be able to access the parent of a device
461 with of-platdata. To save space this can be disabled, but in that
462 case dev_get_parent() will always return NULL;
463
Simon Glass5a1b25c2021-02-03 06:01:13 -0700464config TPL_OF_PLATDATA_INST
465 bool "Declare devices at build time"
466
467 help
468 Declare devices as udevice instances so that they do not need to be
469 bound when U-Boot starts. This can save time and code space.
470
Simon Glass1ef3af32021-03-15 17:25:15 +1300471config TPL_OF_PLATDATA_NO_BIND
472 bool "Don't allow run-time binding of devices"
473 depends on TPL_OF_PLATDATA_INST
474 default y
475 help
476 This removes the ability to bind devices at run time, thus saving
477 some code space in U-Boot. This can be disabled if binding is needed,
478 at the code of some code size increase.
479
Simon Glass95a58252021-03-15 17:25:35 +1300480config TPL_OF_PLATDATA_RT
481 bool "Use a separate struct for device runtime data"
482 depends on TPL_OF_PLATDATA_INST
483 default y
484 help
485 For systems running TPL from read-only memory it is convenient to
486 separate out the runtime information, so that the devices don't need
487 to be copied before being used. This moves the read-write parts of
488 struct udevice (at present just the flags) into a separate struct,
489 which is allocated at runtime.
490
Simon Glassab933d82021-03-15 17:25:36 +1300491config TPL_OF_PLATDATA_DRIVER_RT
492 bool
493 help
494 Use a separate struct for driver runtime data.
495
496 This enables the driver_rt information, used with of-platdata when
497 of-platdata-inst is not used. It allows finding devices by their
498 driver data.
499
Simon Glass5a1b25c2021-02-03 06:01:13 -0700500endif
501
Masahiro Yamada783e6a72014-09-22 19:59:05 +0900502endmenu