src/dpdk/drivers/net/bnx2x/bnx2x.c
static int bnx2x_pretend_func(struct bnx2x_softc *sc, uint16_t pretend_func_val)
{
	uint32_t pretend_reg;

	if (CHIP_IS_E1H(sc) && (pretend_func_val > E1H_FUNC_MAX))
		return -1;

	/* get my own pretend register */
	pretend_reg = bnx2x_get_pretend_reg(sc);
	REG_WR(sc, pretend_reg, pretend_func_val);
	REG_RD(sc, pretend_reg);
	return 0;
}
/*
 * Called only on E1H or E2.
 * When pretending to be PF, the pretend value is the function number 0..7.
 * When pretending to be VF, the pretend val is the PF-num:VF-valid:ABS-VFID
 * combination.
 */
Called only on E1H or E2.
When pretending to be PF, the pretend value is the function number 0..7.
When pretending to be VF, the pretend val is the PF-num:VF-valid:ABS-VFID
combination.
Called only on E1H or E2 . When pretending to be PF the pretend value is the function number 0 .. 7 . When pretending to be VF the pretend val is the PF - num : VF - valid : ABS - VFID combination .
static int bnx2x_pretend_func(struct bnx2x_softc *sc, uint16_t pretend_func_val)
{
	uint32_t pretend_reg;
	if (CHIP_IS_E1H(sc) && (pretend_func_val > E1H_FUNC_MAX))
		return -1;
	pretend_reg = bnx2x_get_pretend_reg(sc);
	REG_WR(sc, pretend_reg, pretend_func_val);
	REG_RD(sc, pretend_reg);
	return 0;
}
static int bnx2x_pretend_func ( struct bnx2x_softc * sc , uint16_t pretend_func_val ) { uint32_t pretend_reg ; if ( CHIP_IS_E1H ( sc ) && ( pretend_func_val > E1H_FUNC_MAX ) ) return -1 ; pretend_reg = bnx2x_get_pretend_reg ( sc ) ; REG_WR ( sc , pretend_reg , pretend_func_val ) ; REG_RD ( sc , pretend_reg ) ; return 0 ; }
Called only on E1H or E2.
Called only on E1H or E2 .
/* get my own pretend register */