@@ -73,9 +73,10 @@ UpdateSlotUsage(
)
{
EFI_STATUS Status;
- serdes_param_t sSerdesParam;
+ serdes_param_t SerdesParamA;
+ serdes_param_t SerdesParamB;
- Status = OemGetSerdesParam (&sSerdesParam);
+ Status = OemGetSerdesParam (&SerdesParamA, &SerdesParamB, 0);
if(EFI_ERROR(Status))
{
DEBUG((EFI_D_ERROR, "[%a]:[%dL] OemGetSerdesParam failed %r\n", __FUNCTION__, __LINE__, Status));
@@ -85,7 +86,7 @@ UpdateSlotUsage(
//
// PCIE0
//
- if (((UINTN)InputData == (UINTN)&MiscSystemSlotDesignationPcie0Data) && sSerdesParam.hilink1_mode == EM_HILINK1_PCIE0_8LANE)
+ if (((UINTN)InputData == (UINTN)&MiscSystemSlotDesignationPcie0Data) && SerdesParamA.hilink1_mode == EM_HILINK1_PCIE0_8LANE)
{
InputData->CurrentUsage = SlotUsageAvailable;
}
@@ -95,7 +96,7 @@ UpdateSlotUsage(
//
if ((UINTN)InputData == (UINTN)&MiscSystemSlotDesignationPcie1Data)
{
- if (sSerdesParam.hilink0_mode == EM_HILINK0_PCIE1_4LANE_PCIE2_4LANE)
+ if (SerdesParamA.hilink0_mode == EM_HILINK0_PCIE1_4LANE_PCIE2_4LANE)
{
InputData->SlotDataBusWidth = SlotDataBusWidth4X;
}
@@ -106,12 +107,12 @@ UpdateSlotUsage(
//
if ((UINTN)InputData == (UINTN)&MiscSystemSlotDesignationPcie2Data)
{
- if (sSerdesParam.hilink0_mode == EM_HILINK0_PCIE1_4LANE_PCIE2_4LANE)
+ if (SerdesParamA.hilink0_mode == EM_HILINK0_PCIE1_4LANE_PCIE2_4LANE)
{
InputData->SlotDataBusWidth = SlotDataBusWidth4X;
InputData->CurrentUsage = SlotUsageAvailable;
}
- else if (sSerdesParam.hilink2_mode == EM_HILINK2_PCIE2_8LANE)
+ else if (SerdesParamA.hilink2_mode == EM_HILINK2_PCIE2_8LANE)
{
InputData->CurrentUsage = SlotUsageAvailable;
}
@@ -120,7 +121,7 @@ UpdateSlotUsage(
//
// PCIE3
//
- if (((UINTN)InputData == (UINTN)&MiscSystemSlotDesignationPcie3Data) && sSerdesParam.hilink5_mode == EM_HILINK5_PCIE3_4LANE)
+ if (((UINTN)InputData == (UINTN)&MiscSystemSlotDesignationPcie3Data) && SerdesParamA.hilink5_mode == EM_HILINK5_PCIE3_4LANE)
{
InputData->CurrentUsage = SlotUsageAvailable;
}
@@ -82,7 +82,7 @@ typedef struct {
UINT32 DsCfg;
} SERDES_POLARITY_INVERT;
-EFI_STATUS OemGetSerdesParam (serdes_param_t *Param);
+EFI_STATUS OemGetSerdesParam (serdes_param_t *ParamA, serdes_param_t *ParamB, UINT32 SocketId);
extern SERDES_POLARITY_INVERT gSerdesPolarityTxDesc[];
extern SERDES_POLARITY_INVERT gSerdesPolarityRxDesc[];
UINT32 GetEthType(UINT8 EthChannel);
@@ -76,7 +76,7 @@ typedef struct {
} SERDES_POLARITY_INVERT;
-EFI_STATUS OemGetSerdesParam (serdes_param_t *Param);
+EFI_STATUS OemGetSerdesParam (serdes_param_t *ParamA, serdes_param_t *ParamB, UINT32 SocketId);
extern SERDES_POLARITY_INVERT gSerdesPolarityTxDesc[];
extern SERDES_POLARITY_INVERT gSerdesPolarityRxDesc[];
UINT32 GetEthType(UINT8 EthChannel);
@@ -59,15 +59,15 @@ serdes_param_t gSerdesParam = {
.hilink5_mode = EM_HILINK5_SAS1_4LANE,
};
-EFI_STATUS OemGetSerdesParam (serdes_param_t *Param)
+EFI_STATUS OemGetSerdesParam (serdes_param_t *ParamA, serdes_param_t *ParamB, UINT32 SocketId)
{
- if (NULL == Param)
+ if (ParamA == NULL)
{
- DEBUG((EFI_D_ERROR, "[%a]:[%dL] Param == NULL!\n", __FUNCTION__, __LINE__));
+ DEBUG((EFI_D_ERROR, "[%a]:[%dL] ParamA == NULL!\n", __FUNCTION__, __LINE__));
return EFI_INVALID_PARAMETER;
}
- (VOID) CopyMem(Param, &gSerdesParam, sizeof(*Param));
+ (VOID) CopyMem(ParamA, &gSerdesParam, sizeof(*ParamA));
return EFI_SUCCESS;
}
@@ -75,15 +75,15 @@ serdes_param_t gSerdesParam1 = {
.use_ssc = 0,
};
-EFI_STATUS OemGetSerdesParam (serdes_param_t *Param)
+EFI_STATUS OemGetSerdesParam (serdes_param_t *ParamA, serdes_param_t *ParamB, UINT32 SocketId)
{
- if (NULL == Param)
+ if (ParamA == NULL)
{
DEBUG((EFI_D_ERROR, "[%a]:[%dL] Param == NULL!\n", __FUNCTION__, __LINE__));
return EFI_INVALID_PARAMETER;
}
- (VOID) CopyMem(Param, &gSerdesParam, sizeof(*Param));
+ (VOID) CopyMem(ParamA, &gSerdesParam, sizeof(*ParamA));
return EFI_SUCCESS;
}