dahdi-linux icon indicating copy to clipboard operation
dahdi-linux copied to clipboard

In Rocky Linux 8.8 or 9.2 got compilation failures related with netif_napi_add function

Open rodolfojcj opened this issue 1 year ago • 2 comments

When using either the DAHDI linux complete 3.2.0 tar.gz file or the master branch sources, trying to compile on Rocky Linux 8.9 or 9.2 fails with error messages like these:

linux/drivers/dahdi/wctc4xxp/base.c: In function ‘wctc4xxp_net_register’:
linux/drivers/dahdi/wctc4xxp/base.c:665:9: error: too many arguments to function ‘netif_napi_add’
665 |         netif_napi_add(netdev, &wc->napi, &wctc4xxp_poll, 64);
    |         ^~~~~~~~~~~~~~
In file included from ./include/net/inet_sock.h:19,
                 from ./include/linux/udp.h:16,
                 from /linux/drivers/dahdi/wctc4xxp/base.c:38: 
./include/linux/netdevice.h:2519:1: note: declared here
2519 | netif_napi_add(struct net_device *dev, struct napi_struct *napi,
     | ^~~~~~~~~~~~~~

rodolfojcj avatar Sep 25 '23 00:09 rodolfojcj

The attached file dahdi-linux-issue-38-fix-24sept2023.zip has a possible fix to this issue.

I tested it with:

  • Ubuntu 23.04, kernel 6.2.0-20-generic
  • Ubuntu 22.10, kernel 5.19.0-43-generic
  • Ubuntu 22.04, kernel 5.15.0-73-generic
  • Ubuntu 20.04, kernel 5.4.0-150-generic
  • Ubuntu 18.04, kernel 4.15.0-212-generic
  • Ubuntu 16.04, kernel 4.4.0-210-generic
  • Debian 12, kernel 6.1.0-10-amd64
  • Debian 11, kernel 5.10.0-23-amd64
  • Debian 10, kernel 4.19.0-24-amd64
  • CentOS 7.9.2009 3.10.0-1160.95.1.el7.x86_64
  • Rocky Linux 9.2, kernel 5.14.0-284.25.1.el9_2.x86_64
  • Rocky Linux 8.8, kernel 4.18.0-477.21.1.el8_8.x86_64

In all those cases the compilation is successful.

Thanks in advance for any developer of this project that may review and possibly apply this fix for the master branch.

rodolfojcj avatar Sep 25 '23 01:09 rodolfojcj

As with another issue, this appears to be addressed by https://github.com/asterisk/dahdi-linux/commit/08fda500eda8893fddb269e07e3b1eaafd0a684b, though with slightly differing version numbers.

InterLinked1 avatar Sep 18 '24 21:09 InterLinked1