Subject: [PATCH 1/8] net: 8021q: remove unneeded MODULE_VERSION() usage

Remove MODULE_VERSION(), as it isn't needed at all: the only version
making sense is the kernel version.

Signed-off-by: Enrico Weigelt, metux IT consult <[email protected]>
---
net/8021q/vlan.c | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c
index d4bcfd8f95bf..ded7bf7229cf 100644
--- a/net/8021q/vlan.c
+++ b/net/8021q/vlan.c
@@ -36,15 +36,10 @@
#include "vlan.h"
#include "vlanproc.h"

-#define DRV_VERSION "1.8"
-
/* Global VLAN variables */

unsigned int vlan_net_id __read_mostly;

-const char vlan_fullname[] = "802.1Q VLAN Support";
-const char vlan_version[] = DRV_VERSION;
-
/* End of global variables definitions. */

static int vlan_group_prealloc_vid(struct vlan_group *vg,
@@ -683,7 +678,7 @@ static int __init vlan_proto_init(void)
{
int err;

- pr_info("%s v%s\n", vlan_fullname, vlan_version);
+ pr_info("802.1Q VLAN Support\n");

err = register_pernet_subsys(&vlan_net_ops);
if (err < 0)
@@ -739,4 +734,3 @@ module_init(vlan_proto_init);
module_exit(vlan_cleanup_module);

MODULE_LICENSE("GPL");
-MODULE_VERSION(DRV_VERSION);
--
2.11.0


Subject: [PATCH 8/8] net: tipc: remove unneeded MODULE_VERSION() usage

Remove MODULE_VERSION(), as it isn't needed at all: the only version
making sense is the kernel version.

Signed-off-by: Enrico Weigelt, metux IT consult <[email protected]>
---
net/tipc/core.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/net/tipc/core.c b/net/tipc/core.c
index 4f6dc74adf45..98dbc18a0dd8 100644
--- a/net/tipc/core.c
+++ b/net/tipc/core.c
@@ -221,4 +221,3 @@ module_exit(tipc_exit);

MODULE_DESCRIPTION("TIPC: Transparent Inter Process Communication");
MODULE_LICENSE("Dual BSD/GPL");
-MODULE_VERSION(TIPC_MOD_VER);
--
2.11.0

Subject: [PATCH 5/8] net: bluetooth: remove unneeded MODULE_VERSION() usage

Remove MODULE_VERSION(), as it isn't needed at all: the only version
making sense is the kernel version.

Signed-off-by: Enrico Weigelt, metux IT consult <[email protected]>
---
net/bluetooth/6lowpan.c | 3 ---
net/bluetooth/af_bluetooth.c | 1 -
net/bluetooth/bnep/core.c | 1 -
net/bluetooth/cmtp/core.c | 1 -
net/bluetooth/hidp/core.c | 1 -
net/bluetooth/rfcomm/core.c | 1 -
6 files changed, 8 deletions(-)

diff --git a/net/bluetooth/6lowpan.c b/net/bluetooth/6lowpan.c
index 4febc82a7c76..76fabc65b8a9 100644
--- a/net/bluetooth/6lowpan.c
+++ b/net/bluetooth/6lowpan.c
@@ -21,8 +21,6 @@

#include <net/6lowpan.h> /* for the compression support */

-#define VERSION "0.1"
-
static struct dentry *lowpan_enable_debugfs;
static struct dentry *lowpan_control_debugfs;

@@ -1303,5 +1301,4 @@ module_exit(bt_6lowpan_exit);

MODULE_AUTHOR("Jukka Rissanen <[email protected]>");
MODULE_DESCRIPTION("Bluetooth 6LoWPAN");
-MODULE_VERSION(VERSION);
MODULE_LICENSE("GPL");
diff --git a/net/bluetooth/af_bluetooth.c b/net/bluetooth/af_bluetooth.c
index 3fd124927d4d..1a6972fac1f7 100644
--- a/net/bluetooth/af_bluetooth.c
+++ b/net/bluetooth/af_bluetooth.c
@@ -798,6 +798,5 @@ module_exit(bt_exit);

MODULE_AUTHOR("Marcel Holtmann <[email protected]>");
MODULE_DESCRIPTION("Bluetooth Core ver " VERSION);
-MODULE_VERSION(VERSION);
MODULE_LICENSE("GPL");
MODULE_ALIAS_NETPROTO(PF_BLUETOOTH);
diff --git a/net/bluetooth/bnep/core.c b/net/bluetooth/bnep/core.c
index 43c284158f63..96f0eb60deb0 100644
--- a/net/bluetooth/bnep/core.c
+++ b/net/bluetooth/bnep/core.c
@@ -764,6 +764,5 @@ MODULE_PARM_DESC(compress_dst, "Compress destination headers");

MODULE_AUTHOR("Marcel Holtmann <[email protected]>");
MODULE_DESCRIPTION("Bluetooth BNEP ver " VERSION);
-MODULE_VERSION(VERSION);
MODULE_LICENSE("GPL");
MODULE_ALIAS("bt-proto-4");
diff --git a/net/bluetooth/cmtp/core.c b/net/bluetooth/cmtp/core.c
index 07cfa3249f83..9a6306d7f738 100644
--- a/net/bluetooth/cmtp/core.c
+++ b/net/bluetooth/cmtp/core.c
@@ -511,6 +511,5 @@ module_exit(cmtp_exit);

MODULE_AUTHOR("Marcel Holtmann <[email protected]>");
MODULE_DESCRIPTION("Bluetooth CMTP ver " VERSION);
-MODULE_VERSION(VERSION);
MODULE_LICENSE("GPL");
MODULE_ALIAS("bt-proto-5");
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c
index bef84b95e2c4..a225ae5f1849 100644
--- a/net/bluetooth/hidp/core.c
+++ b/net/bluetooth/hidp/core.c
@@ -1475,6 +1475,5 @@ module_exit(hidp_exit);
MODULE_AUTHOR("Marcel Holtmann <[email protected]>");
MODULE_AUTHOR("David Herrmann <[email protected]>");
MODULE_DESCRIPTION("Bluetooth HIDP ver " VERSION);
-MODULE_VERSION(VERSION);
MODULE_LICENSE("GPL");
MODULE_ALIAS("bt-proto-6");
diff --git a/net/bluetooth/rfcomm/core.c b/net/bluetooth/rfcomm/core.c
index 3a9e9d9670be..e621fbb451b3 100644
--- a/net/bluetooth/rfcomm/core.c
+++ b/net/bluetooth/rfcomm/core.c
@@ -2245,6 +2245,5 @@ MODULE_PARM_DESC(l2cap_ertm, "Use L2CAP ERTM mode for connection");

MODULE_AUTHOR("Marcel Holtmann <[email protected]>");
MODULE_DESCRIPTION("Bluetooth RFCOMM ver " VERSION);
-MODULE_VERSION(VERSION);
MODULE_LICENSE("GPL");
MODULE_ALIAS("bt-proto-3");
--
2.11.0

Subject: [PATCH 2/8] net: 8021q: use netdev_info()/netdev_warn()

Use netdev_info() / netdev_warn() instead of pr_info() / pr_warn()
for more consistent log output.

Signed-off-by: Enrico Weigelt, metux IT consult <[email protected]>
---
net/8021q/vlan.c | 4 ++--
net/8021q/vlan_core.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c
index ded7bf7229cf..7f18c8406ff8 100644
--- a/net/8021q/vlan.c
+++ b/net/8021q/vlan.c
@@ -123,7 +123,7 @@ int vlan_check_real_dev(struct net_device *real_dev,
const char *name = real_dev->name;

if (real_dev->features & NETIF_F_VLAN_CHALLENGED) {
- pr_info("VLANs not supported on %s\n", name);
+ netdev_info(real_dev, "VLANs not supported on %s\n", name);
NL_SET_ERR_MSG_MOD(extack, "VLANs not supported on device");
return -EOPNOTSUPP;
}
@@ -376,7 +376,7 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event,

if ((event == NETDEV_UP) &&
(dev->features & NETIF_F_HW_VLAN_CTAG_FILTER)) {
- pr_info("adding VLAN 0 to HW filter on device %s\n",
+ netdev_info(dev, "adding VLAN 0 to HW filter on device %s\n",
dev->name);
vlan_vid_add(dev, htons(ETH_P_8021Q), 0);
}
diff --git a/net/8021q/vlan_core.c b/net/8021q/vlan_core.c
index a313165e7a67..bc32b33e0da8 100644
--- a/net/8021q/vlan_core.c
+++ b/net/8021q/vlan_core.c
@@ -360,7 +360,7 @@ static void __vlan_vid_del(struct vlan_info *vlan_info,

err = vlan_kill_rx_filter_info(dev, proto, vid);
if (err)
- pr_warn("failed to kill vid %04x/%d for device %s\n",
+ netdev_warn(dev, "failed to kill vid %04x/%d for device %s\n",
proto, vid, dev->name);

list_del(&vid_info->list);
--
2.11.0

Subject: [PATCH 7/8] net: vmw_vsock: remove unneeded MODULE_VERSION() usage

Remove MODULE_VERSION(), as it isn't needed at all: the only version
making sense is the kernel version.

Signed-off-by: Enrico Weigelt, metux IT consult <[email protected]>
---
net/vmw_vsock/af_vsock.c | 1 -
net/vmw_vsock/hyperv_transport.c | 1 -
net/vmw_vsock/vmci_transport.c | 1 -
3 files changed, 3 deletions(-)

diff --git a/net/vmw_vsock/af_vsock.c b/net/vmw_vsock/af_vsock.c
index 74db4cd637a7..7e0cd3220d42 100644
--- a/net/vmw_vsock/af_vsock.c
+++ b/net/vmw_vsock/af_vsock.c
@@ -2203,5 +2203,4 @@ module_exit(vsock_exit);

MODULE_AUTHOR("VMware, Inc.");
MODULE_DESCRIPTION("VMware Virtual Socket Family");
-MODULE_VERSION("1.0.2.0-k");
MODULE_LICENSE("GPL v2");
diff --git a/net/vmw_vsock/hyperv_transport.c b/net/vmw_vsock/hyperv_transport.c
index b3bdae74c243..f6cb66b62479 100644
--- a/net/vmw_vsock/hyperv_transport.c
+++ b/net/vmw_vsock/hyperv_transport.c
@@ -985,6 +985,5 @@ module_init(hvs_init);
module_exit(hvs_exit);

MODULE_DESCRIPTION("Hyper-V Sockets");
-MODULE_VERSION("1.0.0");
MODULE_LICENSE("GPL");
MODULE_ALIAS_NETPROTO(PF_VSOCK);
diff --git a/net/vmw_vsock/vmci_transport.c b/net/vmw_vsock/vmci_transport.c
index 644d32e43d23..f2f689b7ca9a 100644
--- a/net/vmw_vsock/vmci_transport.c
+++ b/net/vmw_vsock/vmci_transport.c
@@ -2140,7 +2140,6 @@ module_exit(vmci_transport_exit);

MODULE_AUTHOR("VMware, Inc.");
MODULE_DESCRIPTION("VMCI transport for Virtual Sockets");
-MODULE_VERSION("1.0.5.0-k");
MODULE_LICENSE("GPL v2");
MODULE_ALIAS("vmware_vsock");
MODULE_ALIAS_NETPROTO(PF_VSOCK);
--
2.11.0

2020-01-05 02:42:13

by kernel test robot

[permalink] [raw]
Subject: Re: [PATCH 1/8] net: 8021q: remove unneeded MODULE_VERSION() usage

Hi "Enrico,

I love your patch! Yet something to improve:

[auto build test ERROR on net/master]
[also build test ERROR on net-next/master v5.5-rc4 next-20191220]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url: https://github.com/0day-ci/linux/commits/Enrico-Weigelt-metux-IT-consult/net-8021q-remove-unneeded-MODULE_VERSION-usage/20200105-075730
base: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git b54ef37b1ce892fdf6b632d566246d2f2f539910
config: alpha-defconfig (attached as .config)
compiler: alpha-linux-gcc (GCC) 7.5.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.5.0 make.cross ARCH=alpha

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <[email protected]>

All errors (new ones prefixed by >>):

>> ERROR: "vlan_fullname" [net/8021q/8021q.ko] undefined!
>> ERROR: "vlan_version" [net/8021q/8021q.ko] undefined!

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/hyperkitty/list/[email protected] Intel Corporation


Attachments:
(No filename) (1.41 kB)
.config.gz (13.01 kB)
Download all attachments

2020-01-05 05:58:10

by kernel test robot

[permalink] [raw]
Subject: Re: [PATCH 1/8] net: 8021q: remove unneeded MODULE_VERSION() usage

Hi "Enrico,

I love your patch! Yet something to improve:

[auto build test ERROR on net/master]
[also build test ERROR on net-next/master v5.5-rc4 next-20191220]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url: https://github.com/0day-ci/linux/commits/Enrico-Weigelt-metux-IT-consult/net-8021q-remove-unneeded-MODULE_VERSION-usage/20200105-075730
base: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git b54ef37b1ce892fdf6b632d566246d2f2f539910
config: x86_64-randconfig-e001-20200105 (attached as .config)
compiler: gcc-7 (Debian 7.5.0-3) 7.5.0
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <[email protected]>

All errors (new ones prefixed by >>):

ld: net/8021q/vlan_dev.o: in function `vlan_ethtool_get_drvinfo':
vlan_dev.c:(.text+0x10a): undefined reference to `vlan_fullname'
>> ld: vlan_dev.c:(.text+0x11f): undefined reference to `vlan_version'

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/hyperkitty/list/[email protected] Intel Corporation


Attachments:
(No filename) (1.35 kB)
.config.gz (39.72 kB)
Download all attachments

2020-01-05 09:35:46

by Marcel Holtmann

[permalink] [raw]
Subject: Re: [PATCH 5/8] net: bluetooth: remove unneeded MODULE_VERSION() usage

Hi Enrico,

> Remove MODULE_VERSION(), as it isn't needed at all: the only version
> making sense is the kernel version.

I prefer to keep the MODULE_VERSION info since it provides this information via modinfo.

Unless there is a kernel wide consent to remove MODULE_VERSION altogether, the Bluetooth subsystem is keeping it.

Regards

Marcel