Skip to contentSkip to conversation

Patch "vlan: also check phy_driver ts_info for vlan's real device" has been added to the 4.9-stable tree

PATCH [email protected] 1 participant 1 message Apr 11, 2018

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

vlan: also check phy_driver ts_info for vlan's real device

to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
vlan-also-check-phy_driver-ts_info-for-vlan-s-real-device.patch
and it can be found in the queue-4.9 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From foo@baz Wed Apr 11 10:26:56 CEST 2018

From: Hangbin Liu <[email protected]>
Date: Fri, 30 Mar 2018 09:44:00 +0800
Subject: vlan: also check phy_driver ts_info for vlan's real device

From: Hangbin Liu <[email protected]>

[ Upstream commit ec1d8ccb07deaf30fd0508af6755364ac47dc08d ]

Just like function ethtool_get_ts_info(), we should also consider the phy_driver ts_info call back. For example, driver dp83640.

Fixes 37dd9255b2f6 ("vlan: Pass ethtool get_ts_info queries to real device.")
---
 net/8021q/vlan_dev.c |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
net/8021q/vlan_dev.c +5 -1
@@ -29,6 +29,7 @@
 #include <linux/net_tstamp.h>
 #include <linux/etherdevice.h>
 #include <linux/ethtool.h>
+#include <linux/phy.h>
 #include <net/arp.h>
 #include <net/switchdev.h>
 
@@ -658,8 +659,11 @@ static int vlan_ethtool_get_ts_info(stru
 {
 	const struct vlan_dev_priv *vlan = vlan_dev_priv(dev);
 	const struct ethtool_ops *ops = vlan->real_dev->ethtool_ops;
+	struct phy_device *phydev = vlan->real_dev->phydev;
 
-	if (ops->get_ts_info) {
+	if (phydev && phydev->drv && phydev->drv->ts_info) {
+		 return phydev->drv->ts_info(phydev, info);
+	} else if (ops->get_ts_info) {
 		return ops->get_ts_info(vlan->real_dev, info);
 	} else {
 		info->so_timestamping = SOF_TIMESTAMPING_RX_SOFTWARE |

Patches currently in stable-queue which might be from [email protected] are

queue-4.9/vlan-also-check-phy_driver-ts_info-for-vlan-s-real-device.patch queue-4.9/l2tp-fix-missing-print-session-offset-info.patch