diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/freescale/fman/Peripherals/FM/Pcd/fm_plcr.c | 18 | ||||
-rw-r--r-- | drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_pcd_ext.h | 8 |
2 files changed, 13 insertions, 13 deletions
diff --git a/drivers/net/ethernet/freescale/fman/Peripherals/FM/Pcd/fm_plcr.c b/drivers/net/ethernet/freescale/fman/Peripherals/FM/Pcd/fm_plcr.c index f0f1676..cf17618 100644 --- a/drivers/net/ethernet/freescale/fman/Peripherals/FM/Pcd/fm_plcr.c +++ b/drivers/net/ethernet/freescale/fman/Peripherals/FM/Pcd/fm_plcr.c @@ -239,10 +239,10 @@ static void CalcRates(uint32_t bitFor1Micro, * into "integer" and "fraction" where the logic is - as many bits as possible for integer at * high rate, as many bits as possible for fraction at low rate. */ - if (p_NonPassthroughAlgParam->comittedInfoRate > p_NonPassthroughAlgParam->peakOrAccessiveInfoRate) - GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->comittedInfoRate, tsuInTenthNanos, 0, &integer, &fraction); + if (p_NonPassthroughAlgParam->committedInfoRate > p_NonPassthroughAlgParam->peakOrExcessInfoRate) + GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->committedInfoRate, tsuInTenthNanos, 0, &integer, &fraction); else - GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->peakOrAccessiveInfoRate, tsuInTenthNanos, 0, &integer, &fraction); + GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->peakOrExcessInfoRate, tsuInTenthNanos, 0, &integer, &fraction); /* we shift integer, as in cir/pir it is represented by the MSB 16 bits, and * the LSB bits are for the fraction */ @@ -305,13 +305,13 @@ static void CalcRates(uint32_t bitFor1Micro, * This means that the FM TS register will now be used so that 'fppShift' bits are for * fraction and the rest for integer */ /* now we re-calculate cir and pir_eir with the calculated FP */ - GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->comittedInfoRate, tsuInTenthNanos, fppShift, &integer, &fraction); + GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->committedInfoRate, tsuInTenthNanos, fppShift, &integer, &fraction); *cir = (uint32_t)(integer << 16 | (fraction & 0xFFFF)); - GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->peakOrAccessiveInfoRate, tsuInTenthNanos, fppShift, &integer, &fraction); + GetInfoRateReg(p_NonPassthroughAlgParam->rateMode, p_NonPassthroughAlgParam->peakOrExcessInfoRate, tsuInTenthNanos, fppShift, &integer, &fraction); *pir_eir = (uint32_t)(integer << 16 | (fraction & 0xFFFF)); - *cbs = p_NonPassthroughAlgParam->comittedBurstSize; - *pbs_ebs = p_NonPassthroughAlgParam->peakOrAccessiveBurstSize; + *cbs = p_NonPassthroughAlgParam->committedBurstSize; + *pbs_ebs = p_NonPassthroughAlgParam->peakOrExcessBurstSize; /* convert FP as it should be written to reg. * 0-15 --> 16-31 @@ -402,8 +402,8 @@ static t_Error BuildProfileRegs(t_FmPcd *p_FmPcd, case e_FM_PCD_PLCR_RFC_2698: /* Select algorithm MODE[ALG] = "01" */ pemode |= FM_PCD_PLCR_PEMODE_ALG_RFC2698; - if (p_ProfileParams->nonPassthroughAlgParams.comittedInfoRate > p_ProfileParams->nonPassthroughAlgParams.peakOrAccessiveInfoRate) - RETURN_ERROR(MAJOR, E_INVALID_SELECTION, ("in RFC2698 Peak rate must be equal or larger than comittedInfoRate.")); + if (p_ProfileParams->nonPassthroughAlgParams.committedInfoRate > p_ProfileParams->nonPassthroughAlgParams.peakOrExcessInfoRate) + RETURN_ERROR(MAJOR, E_INVALID_SELECTION, ("in RFC2698 Peak rate must be equal or larger than committedInfoRate.")); goto cont_rfc; case e_FM_PCD_PLCR_RFC_4115: /* Select algorithm MODE[ALG] = "10" */ diff --git a/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_pcd_ext.h b/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_pcd_ext.h index e4519cc..ef37770 100644 --- a/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_pcd_ext.h +++ b/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_pcd_ext.h @@ -2066,10 +2066,10 @@ typedef struct t_FmPcdPlcrByteRateModeParams { typedef struct t_FmPcdPlcrNonPassthroughAlgParams { e_FmPcdPlcrRateMode rateMode; /**< Byte mode or Packet mode */ t_FmPcdPlcrByteRateModeParams byteModeParams; /**< Valid for Byte NULL for Packet */ - uint32_t comittedInfoRate; /**< KBits/Second or Packets/Second */ - uint32_t comittedBurstSize; /**< Bytes/Packets */ - uint32_t peakOrAccessiveInfoRate; /**< KBits/Second or Packets/Second */ - uint32_t peakOrAccessiveBurstSize; /**< Bytes/Packets */ + uint32_t committedInfoRate; /**< KBits/Second or Packets/Second */ + uint32_t committedBurstSize; /**< Bytes/Packets */ + uint32_t peakOrExcessInfoRate; /**< KBits/Second or Packets/Second */ + uint32_t peakOrExcessBurstSize; /**< Bytes/Packets */ } t_FmPcdPlcrNonPassthroughAlgParams; /**************************************************************************//** |