summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authormsaitoh <msaitoh@NetBSD.org>2017-10-13 08:17:44 +0000
committermsaitoh <msaitoh@NetBSD.org>2017-10-13 08:17:44 +0000
commit573a4f7340e148ec830dea35bc7c8257f8945e42 (patch)
tree1590ab69a7b1df03c8163c5a3f88481cba283734 /sys/dev
parente9f3e4cec0ac91c84aa37f245009409a76e8c14b (diff)
Show 2.5GBASE-T and 5GBASE-T correctly on ixv(4). Tested on a virtual function
on X550 T1.
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/pci/ixgbe/ixgbe_common.c4
-rw-r--r--sys/dev/pci/ixgbe/ixgbe_vf.c4
-rw-r--r--sys/dev/pci/ixgbe/ixv.c8
3 files changed, 11 insertions, 5 deletions
diff --git a/sys/dev/pci/ixgbe/ixgbe_common.c b/sys/dev/pci/ixgbe/ixgbe_common.c
index b3358b05a66..0c40a25fff8 100644
--- a/sys/dev/pci/ixgbe/ixgbe_common.c
+++ b/sys/dev/pci/ixgbe/ixgbe_common.c
@@ -1,4 +1,4 @@
-/* $NetBSD: ixgbe_common.c,v 1.14 2017/08/30 08:49:18 msaitoh Exp $ */
+/* $NetBSD: ixgbe_common.c,v 1.15 2017/10/13 08:17:44 msaitoh Exp $ */
/******************************************************************************
@@ -4248,7 +4248,7 @@ s32 ixgbe_check_mac_link_generic(struct ixgbe_hw *hw, ixgbe_link_speed *speed,
break;
case IXGBE_LINKS_SPEED_100_82599:
*speed = IXGBE_LINK_SPEED_100_FULL;
- if (hw->mac.type == ixgbe_mac_X550) {
+ if (hw->mac.type >= ixgbe_mac_X550) {
if (links_reg & IXGBE_LINKS_SPEED_NON_STD)
*speed = IXGBE_LINK_SPEED_5GB_FULL;
}
diff --git a/sys/dev/pci/ixgbe/ixgbe_vf.c b/sys/dev/pci/ixgbe/ixgbe_vf.c
index 00f6d71d845..a5e15a3eebd 100644
--- a/sys/dev/pci/ixgbe/ixgbe_vf.c
+++ b/sys/dev/pci/ixgbe/ixgbe_vf.c
@@ -1,4 +1,4 @@
-/* $NetBSD: ixgbe_vf.c,v 1.13 2017/08/30 08:49:18 msaitoh Exp $ */
+/* $NetBSD: ixgbe_vf.c,v 1.14 2017/10/13 08:17:44 msaitoh Exp $ */
/******************************************************************************
@@ -630,7 +630,7 @@ s32 ixgbe_check_mac_link_vf(struct ixgbe_hw *hw, ixgbe_link_speed *speed,
break;
case IXGBE_LINKS_SPEED_100_82599:
*speed = IXGBE_LINK_SPEED_100_FULL;
- if (hw->mac.type == ixgbe_mac_X550) {
+ if (hw->mac.type >= ixgbe_mac_X550) {
if (links_reg & IXGBE_LINKS_SPEED_NON_STD)
*speed = IXGBE_LINK_SPEED_5GB_FULL;
}
diff --git a/sys/dev/pci/ixgbe/ixv.c b/sys/dev/pci/ixgbe/ixv.c
index 02a93e28927..a5e2f0e5d9a 100644
--- a/sys/dev/pci/ixgbe/ixv.c
+++ b/sys/dev/pci/ixgbe/ixv.c
@@ -1,4 +1,4 @@
-/*$NetBSD: ixv.c,v 1.70 2017/10/13 04:52:40 msaitoh Exp $*/
+/*$NetBSD: ixv.c,v 1.71 2017/10/13 08:17:44 msaitoh Exp $*/
/******************************************************************************
@@ -955,6 +955,12 @@ ixv_media_status(struct ifnet *ifp, struct ifmediareq *ifmr)
case IXGBE_LINK_SPEED_10GB_FULL:
ifmr->ifm_active |= IFM_10G_T | IFM_FDX;
break;
+ case IXGBE_LINK_SPEED_5GB_FULL:
+ ifmr->ifm_active |= IFM_5000_T | IFM_FDX;
+ break;
+ case IXGBE_LINK_SPEED_2_5GB_FULL:
+ ifmr->ifm_active |= IFM_2500_T | IFM_FDX;
+ break;
case IXGBE_LINK_SPEED_1GB_FULL:
ifmr->ifm_active |= IFM_1000_T | IFM_FDX;
break;