amd/cimx/sb800: Fix building with clang

These are all set but unused variable problems.

Change-Id: I40aaa1d1cdd90731a23142f1f7a0f67a45915f25
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/63046
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
This commit is contained in:
Arthur Heymans 2022-03-23 21:46:17 +01:00 committed by Felix Held
parent 3ba6f8cdf8
commit 2fe012633a
9 changed files with 7 additions and 39 deletions

View File

@ -101,8 +101,6 @@ SbReset (
IN UINT8 OpFlag
)
{
UINT8 Temp;
Temp = OpFlag;
RWIO (0xcf9, AccWidthUint8, 0x0, 0x06);
}

View File

@ -270,13 +270,11 @@ azaliaInitAfterPciEnum (
UINT8 dbTempVariable;
UINT16 dwTempVariable;
UINT32 ddBAR0;
UINT32 ddTempVariable;
dbEnableAzalia = 0;
dbChannelNum = 0;
dbTempVariable = 0;
dwTempVariable = 0;
ddBAR0 = 0;
ddTempVariable = 0;
if ( pConfig->AzaliaController == 1 ) {
return;
@ -509,4 +507,3 @@ configureAzaliaSetConfigD4Dword (
++tempAzaliaCodecEntryPtr;
}
}

View File

@ -88,9 +88,6 @@ AmdSbDispatcher (
{
AGESA_STATUS Status;
UINT64 tdValue;
tdValue = 0x32314130384253ULL;
Status = AGESA_UNSUPPORTED;
saveConfigPointer (pConfig);

View File

@ -109,8 +109,8 @@ ecInitBeforePciEnum (
IN AMDSBCFG* pConfig
)
{
AMDSBCFG* pTmp; // dummy code
pTmp = pConfig;
/* AMDSBCFG* pTmp; // dummy code */
/* pTmp = pConfig; */
}
/**
@ -125,7 +125,7 @@ ecInitLatePost (
IN AMDSBCFG* pConfig
)
{
AMDSBCFG* pTmp; // dummy code
pTmp = pConfig;
/* AMDSBCFG* pTmp; // dummy code */
/* pTmp = pConfig; */
}
#endif

View File

@ -137,9 +137,7 @@ gecInitLatePost (
IN AMDSBCFG* pConfig
)
{
if ( !pConfig->GecConfig == 0) {
return; //return if GEC controller is disabled.
}
/* if ( !pConfig->GecConfig == 0) { */
/* return; //return if GEC controller is disabled. */
/* } */
}

View File

@ -330,14 +330,11 @@ commonInitEarlyBoot (
UINT32 abValue;
UINT16 dwTempVar;
CPUID_DATA CpuId;
UINT8 cimNativepciesupport;
UINT8 cimIrConfig;
UINT8 Data;
cimNativepciesupport = (UINT8) pConfig->NativePcieSupport;
cimIrConfig = (UINT8) pConfig->IrConfig;
#if SB_CIMx_PARAMETER == 0
cimNativepciesupport = cimNativepciesupportDefault;
cimIrConfig = cimIrConfigDefault;
#endif
@ -518,8 +515,6 @@ commonInitEarlyPost (
UINT8 dbPortStatus;
UINT8 cimSpreadSpectrum;
UINT32 cimSpreadSpectrumType;
AMDSBCFG* pTmp;
pTmp = pConfig;
cimSpreadSpectrum = pConfig->SpreadSpectrum;
cimSpreadSpectrumType = pConfig->BuildParameters.SpreadSpectrumType;
@ -606,13 +601,11 @@ abLinkInitBeforePciEnum (
{
UINT32 cimResetCpuOnSyncFlood;
ABTBLENTRY *pAbTblPtr;
AMDSBCFG* Temp;
cimResetCpuOnSyncFlood = pConfig->ResetCpuOnSyncFlood;
#if SB_CIMx_PARAMETER == 0
cimResetCpuOnSyncFlood = cimResetCpuOnSyncFloodDefault;
#endif
Temp = pConfig;
if ( pConfig->SbPcieOrderRule ) {
pAbTblPtr = (ABTBLENTRY *) FIXUP_PTR (&SbPcieOrderRule[0]);
abcfgTbl (pAbTblPtr);
@ -800,9 +793,7 @@ c3PopupSetting (
IN AMDSBCFG* pConfig
)
{
AMDSBCFG* Temp;
UINT8 dbValue;
Temp = pConfig;
//RPR C-State and VID/FID Change
dbValue = getNumberOfCpuCores ();
if (dbValue > 1) {

View File

@ -218,8 +218,6 @@ sbSmmAcpiOn (
{
// Commented the following code since we need to leave the IRQ1/12 filtering enabled always as per latest
// recommendation in RPR. This is required to fix the keyboard stuck issue when playing games under Windows
AMDSBCFG* pTmp; //lx-dummy for /W4 build
pTmp = pConfig;
// Disable Power Button SMI
RWMEM (ACPI_MMIO_BASE + SMI_BASE + SB_SMI_REGB2, AccWidthUint8, ~(BIT4 + BIT5), 0);
@ -250,5 +248,3 @@ CallBackToOEM (
return Result;
}

View File

@ -141,14 +141,12 @@ sbPowerOnInit (
UINT8 dbCg2WR;
UINT8 dbCg1Pll;
UINT8 cimNbSbGen2;
UINT8 cimSataMode;
UINT8 cimSpiFastReadEnable;
UINT8 cimSpiFastReadSpeed;
UINT8 cimSioHwmPortEnable;
UINT8 SataPortNum;
cimNbSbGen2 = pConfig->NbSbGen2;
cimSataMode = pConfig->SATAMODE.SataModeReg;
// Adding Fast Read Function support
if (pConfig->BuildParameters.SpiFastReadEnable != 0 ) {
cimSpiFastReadEnable = (UINT8) pConfig->BuildParameters.SpiFastReadEnable;

View File

@ -63,8 +63,6 @@ sbSmmService (
IN AMDSBCFG* pConfig
)
{
AMDSBCFG* pTmp; //lx-dummy for /W4 build
pTmp = pConfig;
}
/**
@ -79,8 +77,3 @@ softwareSMIservice (
)
{
}