mirror of
https://xff.cz/git/u-boot/
synced 2025-11-01 10:56:02 +01:00
dm: core: Add a new sequence number for devices
At present each device has two sequence numbers, with 'req_seq' being set up at bind time and 'seq' at probe time. The idea is that devices can 'request' a sequence number and then the conflicts are resolved when the device is probed. This makes things complicated in a few cases, since we don't really know what the sequence number will end up being. We want to honour the bind-time requests if at all possible, but in fact the only source of these at present is the devicetree aliases. Since we have the devicetree available at bind time, we may as well just use it, in the hope that the required processing will turn out to be useful later (i.e. the device actually gets used). Add a new 'sqq' member, the bind-time sequence number. It operates in parallel to the old values for now. All devices get a valid sqq value, i.e. it is never -1. Drop an #ifdef while we are here. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -311,22 +311,24 @@ int dm_init_and_scan(bool pre_reloc_only)
|
||||
ret = dm_scan_plat(pre_reloc_only);
|
||||
if (ret) {
|
||||
debug("dm_scan_plat() failed: %d\n", ret);
|
||||
return ret;
|
||||
goto fail;
|
||||
}
|
||||
|
||||
if (CONFIG_IS_ENABLED(OF_CONTROL) && !CONFIG_IS_ENABLED(OF_PLATDATA)) {
|
||||
ret = dm_extended_scan(pre_reloc_only);
|
||||
if (ret) {
|
||||
debug("dm_extended_scan() failed: %d\n", ret);
|
||||
return ret;
|
||||
goto fail;
|
||||
}
|
||||
}
|
||||
|
||||
ret = dm_scan_other(pre_reloc_only);
|
||||
if (ret)
|
||||
return ret;
|
||||
goto fail;
|
||||
|
||||
return 0;
|
||||
fail:
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_ACPIGEN
|
||||
|
||||
Reference in New Issue
Block a user