VMware Communities
RandyTheMagnifi
Contributor
Contributor

kernel module compile warnings 16.2

Module build on Fedora 35 generates some warnings that might be important, FYI.

 

CPATH=/usr/src/kernels/$(uname -r)/include/linux vmware-modconfig --console --install-all

...
/tmp/modconfig-BvYLna/vmnet-only/driver.c: In function ‘VNetFileOpUnlockedIoctl’:
/tmp/modconfig-BvYLna/vmnet-only/driver.c:966:7: warning: this statement may fall through [-Wimplicit-fallthrough=]
966 | {
| ^
/tmp/modconfig-BvYLna/vmnet-only/driver.c:976:4: note: here
976 | case SIOCGETAPIVERSION:
| ^~~~
/tmp/modconfig-BvYLna/vmnet-only/hub.c:237:24: warning: argument 1 of type ‘uint8[]’ {aka ‘unsigned char[]’} with mismatched bound [-Warray-parameter=]
237 | VNetHub_AllocPvn(uint8 id[]) // IN: the PVN ID to alloc on
| ~~~~~~^~~~
In file included from /tmp/modconfig-BvYLna/vmnet-only/hub.c:43:
/tmp/modconfig-BvYLna/vmnet-only/vnetInt.h:173:34: note: previously declared as ‘uint8[20]’ {aka ‘unsigned char[20]’}
173 | VNetJack *VNetHub_AllocPvn(uint8 id[VNET_PVN_ID_LEN]);
| ~~~~~~^~~~~~~~~~~~~~~~~~~
/tmp/modconfig-BvYLna/vmnet-only/hub.c:261:20: warning: argument 3 of type ‘uint8[]’ {aka ‘unsigned char[]’} with mismatched bound [-Warray-parameter=]
261 | uint8 id[]) // IN: PVN ID to use (NULL if allocPvn == FALSE)
| ~~~~~~^~~~
/tmp/modconfig-BvYLna/vmnet-only/hub.c:68:37: note: previously declared as ‘uint8[20]’ {aka ‘unsigned char[20]’}
68 | uint8 id[VNET_PVN_ID_LEN]);
| ~~~~~~^~~~~~~~~~~~~~~~~~~
...

Reply
0 Kudos
2 Replies
mkubecek
Hot Shot
Hot Shot

These are innocuous. Unfortunately, the VMware host module developers to not care much about warnings so I would be rather surprised if these were the only warnings you got. But to be fair, they finally addressed some of the long existing ones between 16.2.1 and 16.2.3.

Reply
0 Kudos
RandyTheMagnifi
Contributor
Contributor

Ran again today and noticed a few other warnings.

/tmp/modconfig-A2skcx/vmmon-only/common/phystrack.o: warning: objtool: PhysTrack_Free() falls through to next function PhysTrack_Add()
/tmp/modconfig-A2skcx/vmmon-only/common/phystrack.o: warning: objtool: PhysTrack_Add() falls through to next function PhysTrack_Remove()
/tmp/modconfig-A2skcx/vmmon-only/common/phystrack.o: warning: objtool: PhysTrack_Remove() falls through to next function PhysTrack_Test()
/tmp/modconfig-A2skcx/vmmon-only/common/task.o: warning: objtool: .text: unexpected end of section

Reply
0 Kudos