numam-dpdk/kernel
Ferruh Yigit 18cb8293e3 kni: fix build for igb_ndo_bridge_setlink in Linux 5.0
Build error seen with Linux kernel 5.0 and
when CONFIG_RTE_KNI_KMOD_ETHTOOL is enabled.

build error:
.../build/build/kernel/linux/kni/igb_main.c:2348:24:
  error: initialization of
  ‘int (*)(struct net_device *, struct nlmsghdr *, u16,
  	struct netlink_ext_ack *)’
  {aka ‘int (*)(struct net_device *, struct nlmsghdr *,
  	short unsigned int,  struct netlink_ext_ack *)’}
  from incompatible pointer type
  ‘int (*)(struct net_device *, struct nlmsghdr *, u16)’
  {aka ‘int (*)(struct net_device *, struct nlmsghdr *,
  	short unsigned int)’}
  [-Werror=incompatible-pointer-types]
  .ndo_bridge_setlink = igb_ndo_bridge_setlink,
                        ^~~~~~~~~~~~~~~~~~~~~~
.../build/build/kernel/linux/kni/igb_main.c:2348:24:
  note: (near initialization for ‘igb_netdev_ops.ndo_bridge_setlink’)

igb_ndo_bridge_setlink() is changed in Linux kernel version 5.0
and now requires a new parameter, 'struct netlink_ext_ack *extack'.
Fixed by adding a new parameter with a kernel version check.

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
2019-01-23 22:34:41 +01:00
..
freebsd build: clean up building kernel modules using meson 2018-04-17 16:09:43 +02:00
linux kni: fix build for igb_ndo_bridge_setlink in Linux 5.0 2019-01-23 22:34:41 +01:00
Makefile move kernel modules directories 2018-03-21 23:04:21 +01:00
meson.build build: clean up building kernel modules using meson 2018-04-17 16:09:43 +02:00