amd_x86: Clear SMI/SCI event mask early during suspend
amd_x86: Clear SMI/SCI event mask early during suspend

Clear the SMI/SCI event mask at the earliest indication that the host is
suspending. The earliest indication is the host sleep event. This avoids
the case where the EC asserts an event while the host has already
started suspending which can cause a premature wake.

BUG=b:213423172
BRANCH=guybrush
TEST=suspend_stress_test while also attempting to trigger an SCI event
Do not observe any premature wakes after 100+ cycles

Change-Id: I83a842c64d33703595c4e9a5b110d038035cf72e
Signed-off-by: Rob Barnes <3ced0940a2329ce70499686f01d3d60685ec66ed@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3580114
Reviewed-by: Diana Z <cb2016afc7183e5356c690dc63b4ba817470501a@chromium.org>

coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec