Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/cxgbe/crypto/t4_crypto.c
Show First 20 Lines • Show All 2,147 Lines • ▼ Show 20 Lines | ccr_init_port(struct ccr_softc *sc, int port) | |||||||||
sc->ports[port].txq = &sc->adapter->sge.ctrlq[port]; | sc->ports[port].txq = &sc->adapter->sge.ctrlq[port]; | |||||||||
sc->ports[port].rxq = &sc->adapter->sge.rxq[pi->vi->first_rxq]; | sc->ports[port].rxq = &sc->adapter->sge.rxq[pi->vi->first_rxq]; | |||||||||
sc->ports[port].rx_channel_id = pi->rx_c_chan; | sc->ports[port].rx_channel_id = pi->rx_c_chan; | |||||||||
sc->ports[port].tx_channel_id = pi->tx_chan; | sc->ports[port].tx_channel_id = pi->tx_chan; | |||||||||
sc->ports[port].stats_queued = counter_u64_alloc(M_WAITOK); | sc->ports[port].stats_queued = counter_u64_alloc(M_WAITOK); | |||||||||
sc->ports[port].stats_completed = counter_u64_alloc(M_WAITOK); | sc->ports[port].stats_completed = counter_u64_alloc(M_WAITOK); | |||||||||
_Static_assert(sizeof(sc->port_mask) * NBBY >= MAX_NPORTS - 1, | _Static_assert(sizeof(sc->port_mask) * NBBY >= MAX_NPORTS - 1, | |||||||||
"Too many ports to fit in port_mask"); | "Too many ports to fit in port_mask"); | |||||||||
/* | ||||||||||
* Completions for crypto requests on port 1 can sometimes | ||||||||||
* return a stale cookie value due to a firmware bug. Disable | ||||||||||
* requests on port 1 by default on affected firmware. | ||||||||||
*/ | ||||||||||
if (sc->adapter->params.fw_vers >= FW_VERSION32(1, 25, 4, 0) || | ||||||||||
npUnsubmitted Done Inline Actions
np: | ||||||||||
port == 0) | ||||||||||
sc->port_mask |= 1u << port; | sc->port_mask |= 1u << port; | |||||||||
} | } | |||||||||
Done Inline ActionsComment needs to be updated. np: Comment needs to be updated. | ||||||||||
static int | static int | |||||||||
ccr_attach(device_t dev) | ccr_attach(device_t dev) | |||||||||
{ | { | |||||||||
struct ccr_softc *sc; | struct ccr_softc *sc; | |||||||||
int32_t cid; | int32_t cid; | |||||||||
int i; | int i; | |||||||||
▲ Show 20 Lines • Show All 806 Lines • Show Last 20 Lines |