[coreboot-gerrit] Change in coreboot[master]: util/sconfig: Re-factor sconfig to not assume chip as device

Furquan Shaikh (Code Review) gerrit at coreboot.org
Thu May 31 02:12:40 CEST 2018


Hello build bot (Jenkins), 

I'd like you to reexamine a change. Please visit

    https://review.coreboot.org/26720

to look at the new patch set (#3).

Change subject: util/sconfig: Re-factor sconfig to not assume chip as device
......................................................................

util/sconfig: Re-factor sconfig to not assume chip as device

This change adds a new structure "struct chip" to identify elements of
type chip rather than re-using the structure for device. Until now
chip was treated as a device while generating the parse tree and then
device tree postprocessing skipped over all the chip entries in
children and sibling pointers of device nodes.

With this change, the device tree will only contain struct device in
the parsed tree. It helps by avoiding unnecessary pointers to chip
structure as children or next_sibling and then skipping those elements
in post processing. Every device can then hold a pointer to its chip.

When generating static.c, chip structure is emitted before device
structure to ensure that the device structure has chip within its
scope. Externally, the only visible change in static.c should be the
order in which chip/device elements are emitted i.e. previously all
chips under a particular device were emitted to static.c and then the
devices using those chips. Now, a chip is emitted just before device
that is using it.

BUG=b:80081934
TEST=Verified that abuild is successful for all boards. Also, verified
that static.c generated for eve, kahlee, scarlet, asrock imb_a180 is
unchanged from before in node definitions.

Change-Id: I255092f527c8eecb144385eb681df20e54caf8f5
Signed-off-by: Furquan Shaikh <furquan at google.com>
---
M util/sconfig/main.c
M util/sconfig/sconfig.h
M util/sconfig/sconfig.tab.c_shipped
M util/sconfig/sconfig.tab.h_shipped
M util/sconfig/sconfig.y
5 files changed, 183 insertions(+), 111 deletions(-)


  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/20/26720/3
-- 
To view, visit https://review.coreboot.org/26720
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I255092f527c8eecb144385eb681df20e54caf8f5
Gerrit-Change-Number: 26720
Gerrit-PatchSet: 3
Gerrit-Owner: Furquan Shaikh <furquan at google.com>
Gerrit-Reviewer: Furquan Shaikh <furquan at google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply at coreboot.org>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20180531/c9f0435d/attachment.html>


More information about the coreboot-gerrit mailing list