From 4bfff886e2c41408cbb273a63c4f326e0b8802a9 Mon Sep 17 00:00:00 2001 From: Thierry Lelegard Date: Sun, 10 Sep 2023 12:49:07 +0200 Subject: [PATCH] Added DtPcieNw driver --- README.md | 2 +- build-dektec-dkms | 6 +++--- config/Makefile.template | 1 + config/dektec-dkms.spec | 3 ++- config/dkms.conf.template | 5 ++++- config/postinst.template | 2 +- 6 files changed, 12 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index b7e5da0..84b464e 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ Windows and Linux systems. ### Version identification Currently, there are different device drivers in the LinuxSDK package named -`Dta`, `DtaNw`, `Dtu`, `DtPcie`. Each driver has a distinct version number. +`Dta`, `DtaNw`, `Dtu`, `DtPcie0`, `DtPcieNw`. Each driver has a distinct version number. It is not possible to provide three different DKMS packages since these drivers interact with each other in the kernel (at least `Dta` and `DtaNw`) and contain common code. It is important that a consistent combination of drivers diff --git a/build-dektec-dkms b/build-dektec-dkms index eb126d8..563f08e 100755 --- a/build-dektec-dkms +++ b/build-dektec-dkms @@ -197,12 +197,12 @@ clean-files() load-drivers() { echo "=== Unload current drivers" - for drv in DtPcie DtaNw Dta Dtu; do + for drv in DtPcieNw DtPcie DtaNw Dta Dtu; do sudo rmmod $drv 2>/dev/null done echo "=== Load new drivers" - for drv in Dtu Dta DtaNw DtPcie; do + for drv in Dtu Dta DtaNw DtPcie DtPcieNw; do sudo modprobe $drv done @@ -308,7 +308,7 @@ fi # Special uninstall operation. if $UNINSTALL; then verbose "removing dkms dektec/$VERSION" - sudo rmmod DtaNw Dta Dtu DtPcie + sudo rmmod DtaNw Dta Dtu DtPcieNw DtPcie sudo dkms remove "dektec/$VERSION" --all sudo rm -rf "$DKMS_INSTALL" /etc/udev/rules.d/51-dta.rules /etc/udev/rules.d/51-dtu.rules /etc/udev/rules.d/51-dtpcie.rules clean-exit 0 diff --git a/config/Makefile.template b/config/Makefile.template index f0ba7ef..b80e22a 100644 --- a/config/Makefile.template +++ b/config/Makefile.template @@ -5,6 +5,7 @@ default: $(MAKE) -C Drivers/DtaNw/Source/Linux $(MAKE) -C Drivers/Dtu/Source/Linux $(MAKE) -C Drivers/DtPcie/Source/Linux + $(MAKE) -C Drivers/DtPcieNw/Source/Linux clean: find . \( -name '.*.o.cmd' -o -name '.*.ko.cmd' -o -name '*.mod.c' -o -name '*.o' -o -name '.*.d' -o -name '*.ko' -o -name '.tmp_versions' -o -name 'modules.order' -o -name 'Module.symvers' \) -print0 | xargs -0 rm -rf diff --git a/config/dektec-dkms.spec b/config/dektec-dkms.spec index 43375bd..f5eabbc 100644 --- a/config/dektec-dkms.spec +++ b/config/dektec-dkms.spec @@ -17,7 +17,8 @@ Requires: elfutils-libelf-devel %description Provide the source code and DKMS setup for the kernel modules of the Dektec device drivers. Each time the kernel is upgraded, the Dektec modules are -automatically recompiled. The provided drivers are Dta, DtaNw, Dtu, DtPcie. +automatically recompiled. The provided drivers are Dta, DtaNw, Dtu, DtPcie, +DtPcieNw. Dektec is a manufacturer of PC add-on cards, USB devices, IP converters and software for the professional digital-television market. Their products are diff --git a/config/dkms.conf.template b/config/dkms.conf.template index 97d3933..8d3e1e0 100644 --- a/config/dkms.conf.template +++ b/config/dkms.conf.template @@ -3,7 +3,6 @@ PACKAGE_VERSION={{VERSION}} MAKE="'make' KERNELDIR=/lib/modules/${kernelver}/build" CLEAN="make clean" -REMAKE_INITRD=no AUTOINSTALL=yes BUILT_MODULE_NAME[0]=Dta @@ -21,3 +20,7 @@ DEST_MODULE_LOCATION[2]=/kernel/drivers/misc BUILT_MODULE_NAME[3]=DtPcie BUILT_MODULE_LOCATION[3]=Drivers/DtPcie/Source/Linux DEST_MODULE_LOCATION[3]=/kernel/drivers/misc + +BUILT_MODULE_NAME[4]=DtPcieNw +BUILT_MODULE_LOCATION[4]=Drivers/DtPcieNw/Source/Linux +DEST_MODULE_LOCATION[4]=/kernel/drivers/misc diff --git a/config/postinst.template b/config/postinst.template index 4e9a98f..5d61694 100755 --- a/config/postinst.template +++ b/config/postinst.template @@ -1,5 +1,5 @@ #!/bin/bash -# QtlMovie post-installation script on Ubuntu and Debian systems. +# Dektec DKMS post-installation script on Ubuntu and Debian systems. if [[ "$1" = "configure" ]]; then # Fix file permissions and ownership.