Compiling mlnx-en drivers manually

I’m trying to compile mlnx-en-4.6 and 4.7 for Linux kernel 4.19 and am having an issue getting dereferencing pointer to incomplete type ‘const struct tc_action_ops’.

The relevant failure is below.

CC [M] /home/ryan/git/x86-dolby-transcoder/MLNX_EN_SRC-4.6-1.0.1.1/SOURCES/mlnx-en-4.6/drivers/net/ethernet/mellanox/mlx5/core/en_tc.o

In file included from /home/ryan/git/x86-dolby-transcoder/MLNX_EN_SRC-4.6-1.0.1.1/SOURCES/mlnx-en-4.6/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c:52:0:

/home/ryan/git/x86-dolby-transcoder/MLNX_EN_SRC-4.6-1.0.1.1/SOURCES/mlnx-en-4.6/include/net/tc_act/tc_mirred.h: In function ‘to_mirred_compat’:

/home/ryan/git/x86-dolby-transcoder/MLNX_EN_SRC-4.6-1.0.1.1/SOURCES/mlnx-en-4.6/include/net/tc_act/tc_mirred.h:47:24: error: dereferencing pointer to incomplete type ‘const struct tc_action_ops’

if (!a->ops || !a->ops->dump || !is_tcf_mirred_compat(a))

^~

Any ideas how to fix this?

I can compile mlnx-en-4.6 against kernel 4.14 OK but my team wants the newer kernel and newer 4.7 driver.

Thanks,

Ryan Wilkins

Hi Ryan,

Please review the supported OS/Kernel version for MLNX_EN 4.7.3

https://docs.mellanox.com/display/MLNXENv473290/General+Support+in+MLNX_EN#GeneralSupportinMLNX_EN-SupportedNon-LinuxVirtualMachines

Thanks,

Samer

Hi, I ran into this same issue building the same version on an AARCH64 platform with ubuntu 18.04. I found that this setup is not supported in the link here.

I setup OFED 5.0.-2, the link here states that Aarch64/Ubuntu 18.04 is supported, however this link lists a 3rd column. I am using a kernel version of 4.19. I get the same exact compilation failure os the original post. Regardless of the kernel mismatch, should I not at least get past this step, and hit kernel mismatch errors later on?

Thanks

Hi, guys. I have the same issue on OFED 5.1 (which needed for mellanox 6lx card) on 4.19 kernel.

Do you have any suggestion, how to patch sources or fix it?