Dahdi fatal error: linux/pci-aspm.h: No such file or directory

Hello,

I am trying to compile dahdi on centos8 with kernel 4.18.0-240.10.1.el8_3.x86_64

I got the code from https://github.com/asterisk/dahdi-linux/tree/next (next branch)

but the make command fails with:

In file included from /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/oct612x-user.c:28:
/usr/local/src/dahdi-linux-next/include/dahdi/kernel.h:62:10: fatal error: linux/pci-aspm.h: No such file or directory
 #include <linux/pci-aspm.h>
          ^~~~~~~~~~~~~~~~~~
compilation terminated.

The full output:

[root@ast2 src]# cd dahdi-linux-next/
[root@ast2 dahdi-linux-next]# make
make -C drivers/dahdi/firmware firmware-loaders
make[1]: Entering directory '/usr/local/src/dahdi-linux-next/drivers/dahdi/firmware'
Attempting to download dahdi-fwload-vpmadt032-1.25.0.tar.gz
--2021-01-20 21:42:42--  http://downloads.digium.com/pub/telephony/firmware/releases/dahdi-fwload-vpmadt032-1.25.0.tar.gz
Resolving downloads.digium.com (downloads.digium.com)... 2001:470:e0d4::ee, 76.164.171.238
Connecting to downloads.digium.com (downloads.digium.com)|2001:470:e0d4::ee|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 149360 (146K) [application/x-gzip]
Saving to: ‘dahdi-fwload-vpmadt032-1.25.0.tar.gz’

dahdi-fwload-vpmadt032-1.25.0.tar.g 100%[=================================================================>] 145.86K   250KB/s    in 0.6s    

2021-01-20 21:42:43 (250 KB/s) - ‘dahdi-fwload-vpmadt032-1.25.0.tar.gz’ saved [149360/149360]

make[1]: Leaving directory '/usr/local/src/dahdi-linux-next/drivers/dahdi/firmware'
make -C /lib/modules/4.18.0-240.10.1.el8_3.x86_64/build KBUILD_EXTMOD=/usr/local/src/dahdi-linux-next/drivers/dahdi DAHDI_INCLUDE=/usr/local/src/dahdi-linux-next/include DAHDI_MODULES_EXTRA=" " HOTPLUG_FIRMWARE=yes modules DAHDI_BUILD_ALL=m
make[1]: Entering directory '/usr/src/kernels/4.18.0-240.10.1.el8_3.x86_64'
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_adpcm_chan.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_channel.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_chip_open.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_chip_stats.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_conf_bridge.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_debug.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_events.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_interrupts.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_memory.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_miscellaneous.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_mixer.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_phasing_tsst.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_playout_buf.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_remote_debug.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_tlv.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_tone_detection.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_tsi_cnct.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/octdeviceapi/oct6100api/oct6100_api/oct6100_tsst.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/apilib/bt/octapi_bt0.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/apilib/largmath/octapi_largmath.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/apilib/llman/octapi_llman.o
  CC [M]  /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/oct612x-user.o
In file included from /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/oct612x-user.c:28:
/usr/local/src/dahdi-linux-next/include/dahdi/kernel.h:62:10: fatal error: linux/pci-aspm.h: No such file or directory
 #include <linux/pci-aspm.h>
          ^~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [scripts/Makefile.build:316: /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x/oct612x-user.o] Error 1
make[2]: *** [scripts/Makefile.build:556: /usr/local/src/dahdi-linux-next/drivers/dahdi/oct612x] Error 2
make[1]: *** [Makefile:1544: _module_/usr/local/src/dahdi-linux-next/drivers/dahdi] Error 2
make[1]: Leaving directory '/usr/src/kernels/4.18.0-240.10.1.el8_3.x86_64'
make: *** [Makefile:74: modules] Error 2

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.