src/dpdk/drivers/net/bnx2x/bnx2x.c
static inline struct eth_spe *bnx2x_sp_get_next(struct bnx2x_softc *sc)
{
	struct eth_spe *next_spe = sc->spq_prod_bd;

	if (sc->spq_prod_bd == sc->spq_last_bd) {
		/* wrap back to the first eth_spq */
		sc->spq_prod_bd = sc->spq;
		sc->spq_prod_idx = 0;
	} else {
		sc->spq_prod_bd++;
		sc->spq_prod_idx++;
	}

	return next_spe;
}
/* must be called under the spq lock */
must be called under the spq lock
must be called under the spq lock
static inline struct eth_spe *bnx2x_sp_get_next(struct bnx2x_softc *sc)
{
	struct eth_spe *next_spe = sc->spq_prod_bd;
	if (sc->spq_prod_bd == sc->spq_last_bd) {
		sc->spq_prod_bd = sc->spq;
		sc->spq_prod_idx = 0;
	} else {
		sc->spq_prod_bd++;
		sc->spq_prod_idx++;
	}
	return next_spe;
}
static inline struct eth_spe * bnx2x_sp_get_next ( struct bnx2x_softc * sc ) { struct eth_spe * next_spe = sc -> spq_prod_bd ; if ( sc -> spq_prod_bd == sc -> spq_last_bd ) { sc -> spq_prod_bd = sc -> spq ; sc -> spq_prod_idx = 0 ; } else { sc -> spq_prod_bd ++ ; sc -> spq_prod_idx ++ ; } return next_spe ; }
must be called under the spq lock
must be called under the spq lock
/* wrap back to the first eth_spq */