diff options
author | jfv <jfv@FreeBSD.org> | 2015-03-10 19:17:40 +0000 |
---|---|---|
committer | jfv <jfv@FreeBSD.org> | 2015-03-10 19:17:40 +0000 |
commit | 1d8f4435d6eb461b9c516e914a6264387e6e27a0 (patch) | |
tree | 60d83576d9f975bb7151f146bff1eddd760395a0 /sys/dev/ixl/ixlvc.c | |
parent | ea04b2d2c90aabdc330d737c54eec918e03e1243 (diff) | |
download | FreeBSD-src-1d8f4435d6eb461b9c516e914a6264387e6e27a0.zip FreeBSD-src-1d8f4435d6eb461b9c516e914a6264387e6e27a0.tar.gz |
This delta introduces SRIOV support, thanks to Ryan Stone of Sandvine for
adding this major feature to the driver. Secondly, this updates the base
driver with new 20G device support, and with the new firmware levels some
changes to link handling and initialization were required.
MFC after: 1 week
Diffstat (limited to 'sys/dev/ixl/ixlvc.c')
-rw-r--r-- | sys/dev/ixl/ixlvc.c | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/sys/dev/ixl/ixlvc.c b/sys/dev/ixl/ixlvc.c index a0142ba..02192f3 100644 --- a/sys/dev/ixl/ixlvc.c +++ b/sys/dev/ixl/ixlvc.c @@ -362,7 +362,7 @@ ixlv_configure_queues(struct ixlv_sc *sc) struct i40e_virtchnl_vsi_queue_config_info *vqci; struct i40e_virtchnl_queue_pair_info *vqpi; - + pairs = vsi->num_queues; len = sizeof(struct i40e_virtchnl_vsi_queue_config_info) + (sizeof(struct i40e_virtchnl_queue_pair_info) * pairs); @@ -788,14 +788,11 @@ ixlv_request_stats(struct ixlv_sc *sc) void ixlv_update_stats_counters(struct ixlv_sc *sc, struct i40e_eth_stats *es) { - struct ixl_vsi *vsi; + struct ixl_vsi *vsi = &sc->vsi; uint64_t tx_discards; - int i; - - vsi = &sc->vsi; tx_discards = es->tx_discards; - for (i = 0; i < sc->vsi.num_queues; i++) + for (int i = 0; i < vsi->num_queues; i++) tx_discards += sc->vsi.queues[i].txr.br->br_drops; /* Update ifnet stats */ @@ -816,7 +813,7 @@ ixlv_update_stats_counters(struct ixlv_sc *sc, struct i40e_eth_stats *es) IXL_SET_NOPROTO(vsi, es->rx_unknown_protocol); IXL_SET_COLLISIONS(vsi, 0); - sc->vsi.eth_stats = *es; + vsi->eth_stats = *es; } /* @@ -845,9 +842,9 @@ ixlv_vc_completion(struct ixlv_sc *sc, vpe->event_data.link_event.link_status, vpe->event_data.link_event.link_speed); #endif - vsi->link_up = + sc->link_up = vpe->event_data.link_event.link_status; - vsi->link_speed = + sc->link_speed = vpe->event_data.link_event.link_speed; ixlv_update_link_status(sc); break; |