coreboot-kgpe-d16/src/mainboard/google/poppy
Ricardo Ribalda 752fc6026f mb/google/poppy: Fix race condition in acpi camera_pmic
Newer kernels can re-schedule new acpi command calls during a Sleep().

This causes that the following trace fails to detect the cameras:
[   15.764725] drivers/acpi/power.c:358 Power resource [OVFI] turned on start
[   15.772180] drivers/acpi/power.c:358 Power resource [OVTH] turned on start
[   15.834970] drivers/acpi/power.c:362 Power resource [OVFI] turned on start
[   15.852456] drivers/acpi/power.c:415 Power resource [OVFI] turned off start
[   15.955987] drivers/acpi/power.c:420 Power resource [OVFI] turned off end
ERROR!!
[   16.030896] drivers/acpi/power.c:362 Power resource [OVTH] turned on end

Which can be triggered more frequently if the Sleep() commands in OVTH
 _ON Method are increased.

To avoid the race condition, we create a new Power Resource that
handles the common resources of both cameras and make both cameras
depend on that resource. This also simplifies the acpi table by removing
a Mutex.

BRANCH=poppy
BUG=b:171955583
TEST=while true; do if ssh $DUT "dmesg | grep \"failed to find sensor\" "; then  break;  fi; ssh $DUT reboot; sleep 30 ; done
Signed-off-by: Ricardo Ribalda <ribalda@chromium.org>

Change-Id: I25df0225699759c1828b8791c5bdee66529858a7
Reviewed-on: https://review.coreboot.org/c/coreboot/+/48631
Reviewed-by: Furquan Shaikh <furquan@google.com>
Reviewed-by: Rizwan Qureshi <rizwan.qureshi@intel.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-12-16 06:29:20 +00:00
..
acpi
spd mb: remove duplicated Make code for spd.bin generation 2020-09-06 14:57:06 +00:00
variants mb/google/poppy: Fix race condition in acpi camera_pmic 2020-12-16 06:29:20 +00:00
board_info.txt
bootblock.c
chromeos.c mb/google: Drop unneeded empty lines 2020-09-22 17:14:10 +00:00
chromeos.fmd
dsdt.asl {src/mb,util/autoport}: Use macro for DSDT revision 2020-10-13 18:27:04 +00:00
ec.c
gma-mainboard.ads
Kconfig mrc_cache: Move code for triggering memory training into mrc_cache 2020-11-13 22:57:50 +00:00
Kconfig.name mb/google/poppy: Add retail names 2020-06-09 06:26:21 +00:00
mainboard.c
Makefile.inc
ramstage.c
romstage.c cbfs: Simplify load/map API names, remove type arguments 2020-12-02 22:13:17 +00:00
smihandler.c