Marshall Dawson uploaded patch set #2 to this change.

View Change

NOT_FOR_MERGE soc/amd/stoneridge: Add DRAM check for s3

Allocate cbmem space to store DRAM check data during S3. Verify the
the data is unchanged during the resume. Due to where the save and
verify steps are placed, the test cannot capture 100% of potential
memory corruption causes in coreboot.

The ranges to verify are determined by the coreboot tables that are
constructed at the end of POST. If a failure occurs within RAM available
to the OS, the test reports "ERROR" to force suspend_stress_test to
stop. Otherwise, the mismatch is reported as "FYI", e.g. in memory
owned by coreboot.

The granularity of blocks to check within each range is configurable,
and defaults to 1MB. The size of data stored for each block is 32 bits.
Both parameters may be changed if desired.

CAUTION: This test must not be deployed in a shipping system. It
disables TSEG, and its protections, in order to allow the
performance to be at an acceptable level.
TODO: Add the capability of checking DRAM above 4GB.

TEST=Suspend and resume grunt. Verify mismatch with induced error.
BUG=b:118157730

Change-Id: I375dd7ea9a3ab8992f1616126bcbd9724e4fc9a0
Signed-off-by: Marshall Dawson <marshalldawson3rd@gmail.com>
---
M src/soc/amd/common/block/pi/amd_resume_final.c
M src/soc/amd/stoneyridge/Kconfig
M src/soc/amd/stoneyridge/Makefile.inc
M src/soc/amd/stoneyridge/finalize.c
M src/soc/amd/stoneyridge/include/soc/iomap.h
A src/soc/amd/stoneyridge/include/soc/s3test_util.h
A src/soc/amd/stoneyridge/s3test_util.c
M src/soc/amd/stoneyridge/smihandler.c
8 files changed, 431 insertions(+), 1 deletion(-)

git pull ssh://review.coreboot.org:29418/coreboot refs/changes/06/29406/2

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

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I375dd7ea9a3ab8992f1616126bcbd9724e4fc9a0
Gerrit-Change-Number: 29406
Gerrit-PatchSet: 2
Gerrit-Owner: Marshall Dawson <marshalldawson3rd@gmail.com>
Gerrit-CC: build bot (Jenkins) <no-reply@coreboot.org>