Patch Set 2:

Patch Set 2:

Patch Set 2:

(21 comments)

This CL should be broken down into multiple smaller CLs:

1. Adding probed property to sconfig to support probed devices
2. Adding power resource device to device tree
3. Adding power resource driver for ACPI
4. Adding helper function for enabling power in bootblock
5. Moving all mainboards using power resource to the newly added device
6. Get rid of power resource properties from I2C generic and SPI devices.
7. Get rid of probed property

If power is enabled in bootblock, and probing is done in ramstage, when is the appropriate time to deassert reset?

So you think it would be appropriate to assert enable GPIOs first, then sleep() until the max() of the enable times has elapsed, and then deassert resets?

Yes. grepping for enable_delay_ms in coreboot and ignoring the values of 1:

git grep "\"enable_delay_ms\"" | grep -v "1"
src/mainboard/google/octopus/variants/bobba/overridetree.cb: register "enable_delay_ms" = "50"
src/mainboard/google/octopus/variants/phaser/overridetree.cb: register "enable_delay_ms" = "50"
src/mainboard/google/poppy/variants/baseboard/devicetree.cb: register "enable_delay_ms" = "250"
src/mainboard/google/poppy/variants/nami/devicetree.cb: register "enable_delay_ms" = "5"
src/mainboard/google/reef/variants/coral/devicetree.cb: register "enable_delay_ms" = "50"
src/mainboard/google/reef/variants/snappy/devicetree.cb: register "enable_delay_ms" = "5"
src/mainboard/google/reef/variants/snappy/devicetree.cb: register "enable_delay_ms" = "50"
src/mainboard/google/sarien/variants/sarien/devicetree.cb: register "enable_delay_ms" = "5"

Looking closely at each of these, I think most of them are incorrect configurations. Same device is being used on other mainboards with enable delay of 1. I understand it is difficult to predict what a device in future would require for enable delay, but sprinkling the logic in more places seems to make it just more complicated than necessary. Thoughts?

View Change

To view, visit change 32188. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I253a11e24a086792e151c3e47335586d43c3fce0
Gerrit-Change-Number: 32188
Gerrit-PatchSet: 2
Gerrit-Owner: Tim Wawrzynczak <twawrzynczak@chromium.org>
Gerrit-Reviewer: Furquan Shaikh <furquan@google.com>
Gerrit-Reviewer: Martin Roth <martinroth@google.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi@google.com>
Gerrit-Reviewer: Paul Fagerburg <pfagerburg@chromium.org>
Gerrit-Reviewer: Shelley Chen <shchen@google.com>
Gerrit-Reviewer: Tim Wawrzynczak <twawrzynczak@chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org>
Gerrit-CC: Paul Menzel <paulepanter@users.sourceforge.net>
Gerrit-Comment-Date: Wed, 24 Apr 2019 04:38:53 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment