Bruce Griffith (Bruce.Griffith@se-eng.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/3630
-gerrit
commit 21f2123e02e185ece1a3539643baef1fa0a78afc Author: Bruce Griffith Bruce.Griffith@se-eng.com Date: Fri Jun 14 18:30:05 2013 -0600
AMD Trinity: Make the graphics source match ONBOARD_VGA_IS_PRIMARY
AGESA needs to know which VGA source is primary. Use the ONBOARD_VGA_IS_PRIMARY flag to set the AGESA primary video source flag.
Change-Id: Ifbcb63a186cac5a818dc92967b38b9fbae70a7cf Signed-off-by: Bruce Griffith Bruce.Griffith@se-eng.com --- src/mainboard/amd/parmer/agesawrapper.c | 10 +++++++++- src/mainboard/amd/thatcher/agesawrapper.c | 10 +++++++++- src/mainboard/asus/f2a85-m/agesawrapper.c | 10 +++++++++- 3 files changed, 27 insertions(+), 3 deletions(-)
diff --git a/src/mainboard/amd/parmer/agesawrapper.c b/src/mainboard/amd/parmer/agesawrapper.c index c160106..870f174 100644 --- a/src/mainboard/amd/parmer/agesawrapper.c +++ b/src/mainboard/amd/parmer/agesawrapper.c @@ -374,6 +374,14 @@ agesawrapper_amdinitmid ( AGESA_STATUS status; AMD_INTERFACE_PARAMS AmdParamStruct;
+ typedef enum { + INTERNAL_GRAPHICS = 0, + EXTERNAL_GRAPHICS = 1, + } GRAPHICS_SOURCE; + + const GRAPHICS_SOURCE graphics_source = + IS_ENABLED(ONBOARD_VGA_IS_PRIMARY) ? INTERNAL_GRAPHICS : EXTERNAL_GRAPHICS; + /* Enable MMIO on AMD CPU Address Map Controller */ agesawrapper_amdinitcpuio ();
@@ -391,7 +399,7 @@ agesawrapper_amdinitmid (
AmdCreateStruct (&AmdParamStruct);
- ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr)->GnbMidConfiguration.iGpuVgaMode = 0;/* 0 iGpuVgaAdapter, 1 iGpuVgaNonAdapter; */ + ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr)->GnbMidConfiguration.iGpuVgaMode = graphics_source;/* 0 iGpuVgaAdapter, 1 iGpuVgaNonAdapter; */ status = AmdInitMid ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr); if (status != AGESA_SUCCESS) agesawrapper_amdreadeventlog(AmdParamStruct.StdHeader.HeapStatus); AmdReleaseStruct (&AmdParamStruct); diff --git a/src/mainboard/amd/thatcher/agesawrapper.c b/src/mainboard/amd/thatcher/agesawrapper.c index 9480bdc..c1f1ebe 100644 --- a/src/mainboard/amd/thatcher/agesawrapper.c +++ b/src/mainboard/amd/thatcher/agesawrapper.c @@ -372,6 +372,14 @@ agesawrapper_amdinitmid ( AGESA_STATUS status; AMD_INTERFACE_PARAMS AmdParamStruct;
+ typedef enum { + INTERNAL_GRAPHICS = 0, + EXTERNAL_GRAPHICS = 1, + } GRAPHICS_SOURCE; + + const GRAPHICS_SOURCE graphics_source = + IS_ENABLED(ONBOARD_VGA_IS_PRIMARY) ? INTERNAL_GRAPHICS : EXTERNAL_GRAPHICS; + /* Enable MMIO on AMD CPU Address Map Controller */ agesawrapper_amdinitcpuio ();
@@ -389,7 +397,7 @@ agesawrapper_amdinitmid (
AmdCreateStruct (&AmdParamStruct);
- ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr)->GnbMidConfiguration.iGpuVgaMode = 0;/* 0 iGpuVgaAdapter, 1 iGpuVgaNonAdapter; */ + ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr)->GnbMidConfiguration.iGpuVgaMode = graphics_source;/* 0 iGpuVgaAdapter, 1 iGpuVgaNonAdapter; */ status = AmdInitMid ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr); if (status != AGESA_SUCCESS) agesawrapper_amdreadeventlog(AmdParamStruct.StdHeader.HeapStatus); AmdReleaseStruct (&AmdParamStruct); diff --git a/src/mainboard/asus/f2a85-m/agesawrapper.c b/src/mainboard/asus/f2a85-m/agesawrapper.c index 66b8d4f..8e73653 100644 --- a/src/mainboard/asus/f2a85-m/agesawrapper.c +++ b/src/mainboard/asus/f2a85-m/agesawrapper.c @@ -374,6 +374,14 @@ agesawrapper_amdinitmid ( AGESA_STATUS status; AMD_INTERFACE_PARAMS AmdParamStruct;
+ typedef enum { + INTERNAL_GRAPHICS = 0, + EXTERNAL_GRAPHICS = 1, + } GRAPHICS_SOURCE; + + const GRAPHICS_SOURCE graphics_source = + IS_ENABLED(ONBOARD_VGA_IS_PRIMARY) ? INTERNAL_GRAPHICS : EXTERNAL_GRAPHICS; + /* Enable MMIO on AMD CPU Address Map Controller */ agesawrapper_amdinitcpuio ();
@@ -391,7 +399,7 @@ agesawrapper_amdinitmid (
AmdCreateStruct (&AmdParamStruct);
- ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr)->GnbMidConfiguration.iGpuVgaMode = 0;/* 0 iGpuVgaAdapter, 1 iGpuVgaNonAdapter; */ + ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr)->GnbMidConfiguration.iGpuVgaMode = graphics_source;/* 0 iGpuVgaAdapter, 1 iGpuVgaNonAdapter; */ status = AmdInitMid ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr); if (status != AGESA_SUCCESS) agesawrapper_amdreadeventlog(AmdParamStruct.StdHeader.HeapStatus); AmdReleaseStruct (&AmdParamStruct);