u-boot-brain/drivers/core
Simon Glass 8a38abfc43 dm: Use driver_info index instead of pointer
At present we use a 'node' pointer in the of-platadata phandle_n_arg
structs. This is a pointer to the struct driver_info for a particular
device, and we can use it to obtain the struct udevice pointer itself.

Since we don't know the struct udevice pointer until it is allocated in
memory, we have to fix up the phandle_n_arg.node at runtime. This is
annoying since it requires that SPL's data is writable and adds a small
amount of extra (generated) code in the dm_populate_phandle_data()
function.

Now that we can find a driver_info by its index, it is easier to put the
index in the phandle_n_arg structures.

Update dtoc to do this, add a new device_get_by_driver_info_idx() to look
up a device by drive_info index and update the tests to match.

Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29 14:42:18 -06:00
..
acpi.c dm: core: Don't show an ACPI warning if there is no ordering 2020-07-20 09:46:42 +08:00
device-remove.c dm: core: Add a way to skip powering down power domains 2020-04-16 08:07:58 -06:00
device.c dm: Use driver_info index instead of pointer 2020-10-29 14:42:18 -06:00
devres.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
dump.c cmd: dm: Fixed/Added DM driver listing subcommands 2020-07-07 15:37:13 -04:00
fdtaddr.c dm: core: Fix devfdt_get_addr_ptr return value 2020-08-22 07:59:14 -06:00
Kconfig dm: core: Allow dm_warn() to be used in SPL 2020-10-29 14:42:17 -06:00
lists.c dm: Support parent devices with of-platdata 2020-10-29 14:42:18 -06:00
Makefile dm: Avoid using #ifdef for CONFIG_OF_LIVE 2020-10-29 14:42:17 -06:00
of_access.c dm: add cells_count parameter in *_count_phandle_with_args 2020-10-06 09:07:54 -06:00
of_addr.c common: Drop linux/bug.h from common header 2020-05-18 21:19:23 -04:00
of_extra.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
ofnode.c dm: add cells_count parameter in *_count_phandle_with_args 2020-10-06 09:07:54 -06:00
read_extra.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
read.c dm: add cells_count parameter in *_count_phandle_with_args 2020-10-06 09:07:54 -06:00
regmap.c regmap: Add support for regmap fields 2020-09-30 11:55:23 -04:00
root.c dm: core: Convert #ifdef to if() in root.c 2020-10-29 14:42:18 -06:00
simple-bus.c drivers: rename drivers to match compatible string 2020-07-09 18:57:22 -06:00
simple-pm-bus.c dm: Add support for simple-pm-bus 2020-07-01 15:01:21 +08:00
syscon-uclass.c syscon: Drop the logging in syscon_get_by_driver_data() 2020-10-22 09:53:31 -04:00
uclass.c dm: uclass: don't assign aliased seq numbers 2020-06-11 20:52:11 -06:00
util.c dm: core: Allow dm_warn() to be used in SPL 2020-10-29 14:42:17 -06:00