diff options
author | Mandy Lavi <mandy.lavi@freescale.com> | 2015-07-23 04:09:07 (GMT) |
---|---|---|
committer | Mandy Lavi <mandy.lavi@freescale.com> | 2015-10-14 12:20:29 (GMT) |
commit | b5d989953e6e9ade77493b65694e07b016f8bcaf (patch) | |
tree | 09ea7524fa533a3a7ec290d441477def70951c50 | |
parent | 4c642e7af5e9e605b9fb6b8130216548c7bc180b (diff) | |
download | linux-fsl-qoriq-b5d989953e6e9ade77493b65694e07b016f8bcaf.tar.xz |
fmd: Remove FM_PORT_PcdPrsModifyStartOffset routine - not supported
Signed-off-by: Mandy Lavi <mandy.lavi@freescale.com>
4 files changed, 0 insertions, 132 deletions
diff --git a/drivers/net/ethernet/freescale/fman/Peripherals/FM/Port/fm_port.c b/drivers/net/ethernet/freescale/fman/Peripherals/FM/Port/fm_port.c index 379406e..d706ed3 100644 --- a/drivers/net/ethernet/freescale/fman/Peripherals/FM/Port/fm_port.c +++ b/drivers/net/ethernet/freescale/fman/Peripherals/FM/Port/fm_port.c @@ -5430,72 +5430,6 @@ t_Error FM_PORT_PcdKgUnbindSchemes(t_Handle h_FmPort, return err; } -t_Error FM_PORT_PcdPrsModifyStartOffset(t_Handle h_FmPort, - t_FmPcdPrsStart *p_FmPcdPrsStart) -{ - t_FmPort *p_FmPort = (t_FmPort*)h_FmPort; - volatile uint32_t *p_BmiPrsStartOffset = NULL; - volatile uint32_t *p_BmiNia = NULL; - uint32_t tmpReg; - uint8_t hdrNum; - - SANITY_CHECK_RETURN_ERROR(p_FmPort, E_INVALID_HANDLE); - SANITY_CHECK_RETURN_ERROR(!p_FmPort->p_FmPortDriverParam, E_INVALID_STATE); - SANITY_CHECK_RETURN_ERROR(p_FmPort->pcdEngines & FM_PCD_PRS, - E_INVALID_STATE); - - switch (p_FmPort->portType) - { - case (e_FM_PORT_TYPE_RX_10G): - case (e_FM_PORT_TYPE_RX): - p_BmiPrsStartOffset = - &p_FmPort->p_FmPortBmiRegs->rxPortBmiRegs.fmbm_rpso; - p_BmiNia = &p_FmPort->p_FmPortBmiRegs->rxPortBmiRegs.fmbm_rfne; - tmpReg = GET_UINT32(*p_BmiNia) & BMI_RFNE_FDCS_MASK; - break; - case (e_FM_PORT_TYPE_OH_OFFLINE_PARSING): - p_BmiPrsStartOffset = - &p_FmPort->p_FmPortBmiRegs->ohPortBmiRegs.fmbm_opso; - p_BmiNia = &p_FmPort->p_FmPortBmiRegs->ohPortBmiRegs.fmbm_ofne; - tmpReg = 0; - break; - default: - RETURN_ERROR( MAJOR, E_INVALID_OPERATION, - ("available for Rx and offline parsing ports only")); - } - - /* check that current NIA is BMI to BMI */ - if ((GET_UINT32(*p_BmiNia) & ~BMI_RFNE_FDCS_MASK) - != GET_NIA_BMI_AC_ENQ_FRAME(p_FmPort->h_FmPcd)) - RETURN_ERROR( MAJOR, E_INVALID_OPERATION, - ("may be called only for ports in BMI-to-BMI state.")); - - if (!TRY_LOCK(p_FmPort->h_Spinlock, &p_FmPort->lock)) - { - DBG(TRACE, ("FM Port Try Lock - BUSY")); - return ERROR_CODE(E_BUSY); - } - - /* set the first header */ - hdrNum = GetPrsHdrNum(p_FmPcdPrsStart->firstPrsHdr); - if ((hdrNum == ILLEGAL_HDR_NUM) || (hdrNum == NO_HDR_NUM)) - { - RELEASE_LOCK(p_FmPort->lock); - RETURN_ERROR(MAJOR, E_NOT_SUPPORTED, ("Unsupported header.")); - } - - WRITE_UINT32(*p_BmiNia, - (uint32_t)(NIA_ENG_PRS | (uint32_t)hdrNum | tmpReg)); - - /* set start parsing offset */ - WRITE_UINT32( - *p_BmiPrsStartOffset, - (uint32_t)(p_FmPcdPrsStart->parsingOffset + p_FmPort->internalBufferOffset)); - RELEASE_LOCK(p_FmPort->lock); - - return E_OK; -} - t_Error FM_PORT_AddCongestionGrps(t_Handle h_FmPort, t_FmPortCongestionGrps *p_CongestionGrps) { diff --git a/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_port_ext.h b/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_port_ext.h index dbade61..08a5aa5 100644 --- a/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_port_ext.h +++ b/drivers/net/ethernet/freescale/fman/inc/Peripherals/fm_port_ext.h @@ -2510,23 +2510,6 @@ t_Error FM_PORT_PcdKgBindSchemes (t_Handle h_FmPort, t_FmPcdPortSchemesParams *p t_Error FM_PORT_PcdKgUnbindSchemes (t_Handle h_FmPort, t_FmPcdPortSchemesParams *p_PortScheme); /**************************************************************************//** - @Function FM_PORT_PcdPrsModifyStartOffset - - @Description Runtime change of the parser start offset within the header. - The routine may not be called while port - receives packets using the PCD functionalities, therefore port must be first detached - from the PCD, only than the routine may be called, and than port be attached to PCD again. - @Param[in] h_FmPort A handle to a FM Port module. - @Param[in] p_FmPcdPrsStart A structure of parameters for defining the - start point for the parser. - - @Return E_OK on success; Error code otherwise. - - @Cautions Allowed only following FM_PORT_Init(), FM_PORT_SetPCD() and FM_PORT_DetatchPCD(). -*//***************************************************************************/ -t_Error FM_PORT_PcdPrsModifyStartOffset (t_Handle h_FmPort, t_FmPcdPrsStart *p_FmPcdPrsStart); - -/**************************************************************************//** @Function FM_PORT_GetIPv4OptionsCount @Description TODO diff --git a/drivers/net/ethernet/freescale/fman/src/wrapper/lnxwrp_ioctls_fm.c b/drivers/net/ethernet/freescale/fman/src/wrapper/lnxwrp_ioctls_fm.c index b4ab295..9224703 100644 --- a/drivers/net/ethernet/freescale/fman/src/wrapper/lnxwrp_ioctls_fm.c +++ b/drivers/net/ethernet/freescale/fman/src/wrapper/lnxwrp_ioctls_fm.c @@ -4112,43 +4112,6 @@ t_Error LnxwrpFmPortIOCTL(t_LnxWrpFmPortDev *p_LnxWrpFmPortDev, unsigned int cmd break; } - case FM_PORT_IOC_PCD_PRS_MODIFY_START_OFFSET: - { - ioc_fm_pcd_prs_start_t *param; - - param = (ioc_fm_pcd_prs_start_t *) XX_Malloc(sizeof(ioc_fm_pcd_prs_start_t)); - if (!param) - RETURN_ERROR(MINOR, E_NO_MEMORY, ("IOCTL FM PORT")); - - memset(param, 0, sizeof(ioc_fm_pcd_prs_start_t)); - -#if defined(CONFIG_COMPAT) - if (compat) - { - if (copy_from_user(param, (ioc_fm_pcd_prs_start_t *)compat_ptr(arg), - sizeof(ioc_fm_pcd_prs_start_t))) - { - XX_Free(param); - RETURN_ERROR(MINOR, E_WRITE_FAILED, NO_MSG); - } - } - else -#endif - { - if (copy_from_user(param, (ioc_fm_pcd_prs_start_t *)arg, - sizeof(ioc_fm_pcd_prs_start_t))) - { - XX_Free(param); - RETURN_ERROR(MINOR, E_WRITE_FAILED, NO_MSG); - } - } - - err = FM_PORT_PcdPrsModifyStartOffset(p_LnxWrpFmPortDev->h_Dev, (t_FmPcdPrsStart *)param); - - XX_Free(param); - break; - } - case FM_PORT_IOC_PCD_PLCR_ALLOC_PROFILES: { uint16_t num; diff --git a/include/uapi/linux/fmd/Peripherals/fm_port_ioctls.h b/include/uapi/linux/fmd/Peripherals/fm_port_ioctls.h index 0d5965e..a2f6110 100644 --- a/include/uapi/linux/fmd/Peripherals/fm_port_ioctls.h +++ b/include/uapi/linux/fmd/Peripherals/fm_port_ioctls.h @@ -749,18 +749,6 @@ typedef struct ioc_fm_port_pcd_fqids_params_t { #endif #define FM_PORT_IOC_PCD_KG_UNBIND_SCHEMES _IOW(FM_IOC_TYPE_BASE, FM_PORT_IOC_NUM(31), ioc_fm_pcd_port_schemes_params_t) -/**************************************************************************//** - @Function FM_PORT_PcdPrsModifyStartOffset - - @Description Runtime change of the parser start offset within the header. - - @Param[in] ioc_fm_pcd_prs_start_t A structure of parameters for defining the - start point for the parser. - - @Return 0 on success; error code otherwise. -*//***************************************************************************/ -#define FM_PORT_IOC_PCD_PRS_MODIFY_START_OFFSET _IOW(FM_IOC_TYPE_BASE, FM_PORT_IOC_NUM(32), ioc_fm_pcd_prs_start_t) - typedef struct ioc_fm_port_mac_addr_params_t { uint8_t addr[ENET_NUM_OCTETS_PER_ADDRESS]; } ioc_fm_port_mac_addr_params_t; |