amd/stoneyridge: Check SMI command address before reading
commit66e62da4c7830598c52cd0291bc8d10f4d0ff9c4
authorMarshall Dawson <marshalldawson3rd@gmail.com>
Wed, 27 Sep 2017 19:32:38 +0000 (27 13:32 -0600)
committerMartin Roth <martinroth@google.com>
Mon, 2 Oct 2017 22:30:02 +0000 (2 22:30 +0000)
tree778c44de3339f837d17110fe1de1620eea1f071b
parenteecb794c96f738d20bf4d5890bbad8b3834c9685
amd/stoneyridge: Check SMI command address before reading

Use the currently programmed address of the SMI command port before
checking the passed command.  This ensures we're reading the right
port in case the port was relocated without our knowledge.

Change-Id: I8a3ca285d3a9afd4a107cd471c202abf03f372ac
Signed-off-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Reviewed-on: https://review.coreboot.org/21744
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
src/soc/amd/stoneyridge/include/soc/smi.h
src/soc/amd/stoneyridge/smi_util.c
src/soc/amd/stoneyridge/smihandler.c