New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 709119 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner:
Last visit > 30 days ago
Closed: Jun 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

gru (and children): power cycle pp1800_lid at warm reboot

Project Member Reported by diand...@chromium.org, Apr 6 2017

Issue description

In general, it's considered bad form to do this:

1. Have a device "Master" that is i2c master
2. Have it connected via i2c to another device "Slave"
3. Reset "Master" without resetting "Slave".

---

Why is this bad?  If we don't do this then we need to add "unwedge" code to the kernel somewhere.  That's possible, but slightly less than ideal.

For some history about wedged i2c busses, you can see:

  https://chromium-review.googlesource.com/c/32168/

...but in general the i2c bus is stateful.  If the master gets reset but the slave doesn't then we need to do something to get them back in sync.  In the worst case we'll reset the master right as the slave was driving the lines in which case the bus will be fully wedged until we unwedge things.

---

So why talk about i2c and wedging here?  The rt5514 codec is connected to the rk3399 AP.  ...but it's powered by a rail (pp1800_lid) that is turned on any time we're not in S5.  That means we can potentially get wedged.

The easiest fix for this is to just power cycle this rail when the EC sees that the AP wants a warm reset.  This seems like a totally sane thing to do anyway.


NOTE: on some gru children (like Bob) things are even worse because of the way that PP1800_AUDIO powers up.  On these boards a reboot can cause a phantom glitch on the rt5514 and wedge things up even more often.  See b/36666089
 
There's quite a list of i2c busses that this would apply for:

i2c0, backlight, depends on the device
i2c1, microphone, pulse GPIO_PP1800_LID_EN_L to reset slaves
i2c3, touchscreen, pp3300_touchscreen (via pp3300_s0_en_l, which i don't think can be pulsed off during warm reset)
i2c5, trackpad, pp3300_trackpad
i2c7, nfc, pp*00_nfc connected through 0ohm resistors to PP*00_S0 rails
i2c8, headphone jack codec, there is no rail that can be pulsed to reset the codec because it's powered from an S5 rail? (anti pop i assume)

Some we can turn off, some we can't.
Owner: rspangler@chromium.org
Status: Assigned (was: Untriaged)
Status: WontFix (was: Assigned)
All those devices launched, so I don't think we're fixing them now.

Sign in to add a comment