sconfig: Use get_chip_instance() to set base_chip_instance

Now that multiple device trees are supported (chipset, base,
override), base_chip_instance parameter for override device needs to
be set to the base chip instance of the corresponding device in
base/primary tree. This can be achieved by using `get_chip_instance()`
instead of using base_dev->chip_instance in `update_device()`.

TEST=Verified that coreboot.rom generated using timeless shows no
change for all boards.

Change-Id: I42e3f4b83c55f3479b95dbbd7a3721558c32b1c8
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/50868
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
This commit is contained in:
Furquan Shaikh 2021-02-17 19:07:18 -08:00 committed by Patrick Georgi
parent 80b2f23584
commit 9d1bf811fe
1 changed files with 1 additions and 1 deletions

View File

@ -1674,7 +1674,7 @@ static void update_device(struct device *base_dev, struct device *override_dev)
* Update base_chip_instance member in chip instance of override tree to forward it to
* the chip instance in base tree.
*/
override_dev->chip_instance->base_chip_instance = base_dev->chip_instance;
override_dev->chip_instance->base_chip_instance = get_chip_instance(base_dev);
/*
* Now that the device properties are all copied over, look at each bus