Message ID | 20200126100124.86014-1-leon@kernel.org |
---|---|
State | Superseded |
Delegated to: | David Miller |
Headers | show |
Series | [rdma-next,v2] net/core: Replace driver version to be kernel version | expand |
On Sun, Jan 26, 2020 at 12:01:24PM +0200, Leon Romanovsky wrote: > From: Leon Romanovsky <leonro@mellanox.com> > Sorry, I used wrong target branch in the subject. Thanks
diff --git a/net/ethtool/ioctl.c b/net/ethtool/ioctl.c index 182bffbffa78..a403decacb6d 100644 --- a/net/ethtool/ioctl.c +++ b/net/ethtool/ioctl.c @@ -17,6 +17,7 @@ #include <linux/phy.h> #include <linux/bitops.h> #include <linux/uaccess.h> +#include <linux/vermagic.h> #include <linux/vmalloc.h> #include <linux/sfp.h> #include <linux/slab.h> @@ -666,6 +667,8 @@ static noinline_for_stack int ethtool_get_drvinfo(struct net_device *dev, return -EOPNOTSUPP; } + strlcpy(info.version, UTS_RELEASE, sizeof(info.version)); + /* * this method of obtaining string set info is deprecated; * Use ETHTOOL_GSSET_INFO instead.