summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Severance2021-09-13 21:22:14 -0400
committerChris Severance2021-09-13 21:22:14 -0400
commite88fd4d41b4be6e291fde6234b44ea04cec40a6a (patch)
tree8a2438ef3a7ca61dc7d1a24fa7c0ab5ab5f30950
parentbd0c85adb1161b9c6a8686b9d8b8472b291f9b02 (diff)
downloadaur-e88fd4d41b4be6e291fde6234b44ea04cec40a6a.tar.gz
autu: Update to 1.3.29-5
-rw-r--r--.SRCINFO12
-rw-r--r--0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch17
-rw-r--r--0005-kernel-5.13-dropped-tty_check_change.patch17
-rw-r--r--0006-kernel-5.14-task_struct.state-unsigned-tty.patch73
-rw-r--r--PKGBUILD27
5 files changed, 141 insertions, 5 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 57d5ff3f4d34..55840174d0ac 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = digi-dgnc
pkgdesc = tty driver for Digi Neo and legacy ClassicBoard PCI PCIe RS-232 serial port
pkgver = 1.3.29
- pkgrel = 4
+ pkgrel = 5
url = https://www.digi.com/
install = digi-dgnc-install.sh
arch = i686
@@ -16,16 +16,24 @@ pkgbase = digi-dgnc
source = 0001-Kernel-4-15-timers.patch
source = 0002-kernel-5.0.0-do_gettimeofday.patch
source = 0003-kernel-5.6--proc_dir_entry-proc_ops.patch
+ source = 0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch
+ source = 0005-kernel-5.13-dropped-tty_check_change.patch
+ source = 0006-kernel-5.14-task_struct.state-unsigned-tty.patch
md5sums = 6171349852f6d02228d6e30c79b7a434
md5sums = a171e9ea1a4ff8340c3c58b303632edf
md5sums = 6c16c3c24c79fb558bcf27f780829c75
md5sums = 8e46a778c648ab4f0ca63a337d36df60
md5sums = 394d24a150676d8123300d6715b81fb8
+ md5sums = 44b0a7b0ab4dbe661b822fcba9423121
+ md5sums = 10ba960da22684d2da89872df1d822cc
+ md5sums = 89de6a694ecf827a3358bcd8aea03a6a
sha256sums = e121a31569e3e1f156caeed70742971ec32fef598429ef647bde98f56aa048f5
sha256sums = 625bb794d31690b45ad7469f811e7422dac938cf8e9b777aba4d97b60b3c6eae
sha256sums = 88d5a8589dca55ca98089dfa4570aa1fbde1095957d0788ad710a27b348c2f4f
sha256sums = 737df02a12fc76841325d1059d90451467637eab2df016efc20d84976eb5de7d
sha256sums = 3496e90914e1fa2f209dd85c336e7b1c0b784dbbf67cc45e0f0f55f0b1ef5a0e
+ sha256sums = f215451df4a01f0875a53425b6d8452c344f19b61b59b821f8c949b1b276c022
+ sha256sums = 13257318895327e7438f7f357c5dc7d67310ec0468802df083815414d4743805
+ sha256sums = dcedb22e0f3fb0c8197630b38217f86c5468d065ab2d67708c16c17351d6944e
pkgname = digi-dgnc
-
diff --git a/0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch b/0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch
new file mode 100644
index 000000000000..e38924f7c83f
--- /dev/null
+++ b/0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch
@@ -0,0 +1,17 @@
+diff -pNaru5 driver/2.6.27.orig/dgnc_driver.c driver/2.6.27/dgnc_driver.c
+--- driver/2.6.27.orig/dgnc_driver.c 2021-09-13 20:59:15.005962528 -0400
++++ driver/2.6.27/dgnc_driver.c 2021-09-13 21:01:14.600755648 -0400
+@@ -55,11 +55,13 @@
+ #include "dgnc_sysfs.h"
+
+ MODULE_LICENSE("GPL");
+ MODULE_AUTHOR("Digi International, http://www.digi.com");
+ MODULE_DESCRIPTION("Driver for the Digi International Neo and Classic PCI based product line");
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5,12,0)
+ MODULE_SUPPORTED_DEVICE("dgnc");
++#endif
+
+ /*
+ * insmod command line overrideable parameters
+ *
+ * NOTE: we use a set of macros to create the variables, which allows
diff --git a/0005-kernel-5.13-dropped-tty_check_change.patch b/0005-kernel-5.13-dropped-tty_check_change.patch
new file mode 100644
index 000000000000..8c12d7c09d3a
--- /dev/null
+++ b/0005-kernel-5.13-dropped-tty_check_change.patch
@@ -0,0 +1,17 @@
+diff -pNaru5 driver/2.6.27.orig/dgnc_tty.c driver/2.6.27/dgnc_tty.c
+--- driver/2.6.27.orig/dgnc_tty.c 2021-09-13 21:09:08.726233822 -0400
++++ driver/2.6.27/dgnc_tty.c 2021-09-13 21:09:55.913091170 -0400
+@@ -3249,10 +3249,13 @@ static void dgnc_tty_flush_buffer(struct
+ DGNC_UNLOCK(ch->ch_lock, lock_flags);
+
+ DPR_IOCTL(("dgnc_tty_flush_buffer finish\n"));
+ }
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,13,0)
++int tty_check_change(struct tty_struct *tty);
++#endif
+
+
+ /*****************************************************************************
+ *
+ * The IOCTL function and all of its helpers
diff --git a/0006-kernel-5.14-task_struct.state-unsigned-tty.patch b/0006-kernel-5.14-task_struct.state-unsigned-tty.patch
new file mode 100644
index 000000000000..761aeaa679b8
--- /dev/null
+++ b/0006-kernel-5.14-task_struct.state-unsigned-tty.patch
@@ -0,0 +1,73 @@
+diff -pNaru5 driver/2.6.27.orig/dgnc_driver.c driver/2.6.27/dgnc_driver.c
+--- driver/2.6.27.orig/dgnc_driver.c 2021-09-13 21:13:41.814470344 -0400
++++ driver/2.6.27/dgnc_driver.c 2021-09-13 21:13:52.344550262 -0400
+@@ -1031,11 +1031,11 @@ static void dgnc_mbuf(struct board_t *br
+ *
+ * Returns 0 if timed out, !0 (showing signal) if interrupted by a signal.
+ */
+ int dgnc_ms_sleep(ulong ms)
+ {
+- current->state = TASK_INTERRUPTIBLE;
++ set_current_state(TASK_INTERRUPTIBLE);
+ schedule_timeout((ms * HZ) / 1000);
+ return (signal_pending(current));
+ }
+
+
+diff -pNaru5 driver/2.6.27.orig/dgnc_tty.c driver/2.6.27/dgnc_tty.c
+--- driver/2.6.27.orig/dgnc_tty.c 2021-09-13 21:13:41.817803703 -0400
++++ driver/2.6.27/dgnc_tty.c 2021-09-13 21:17:10.562916701 -0400
+@@ -119,13 +119,21 @@ static int dgnc_tty_ioctl(struct tty_str
+ #else
+ static int dgnc_tty_ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg);
+ #endif
+ static int dgnc_tty_digigeta(struct tty_struct *tty, struct digi_t __user *retinfo);
+ static int dgnc_tty_digiseta(struct tty_struct *tty, struct digi_t __user *new_info);
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,14,0)
++static unsigned int dgnc_tty_write_room(struct tty_struct* tty);
++#else
+ static int dgnc_tty_write_room(struct tty_struct* tty);
++#endif
+ static int dgnc_tty_put_char(struct tty_struct *tty, unsigned char c);
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,14,0)
++static unsigned int dgnc_tty_chars_in_buffer(struct tty_struct* tty);
++#else
+ static int dgnc_tty_chars_in_buffer(struct tty_struct* tty);
++#endif
+ static void dgnc_tty_start(struct tty_struct *tty);
+ static void dgnc_tty_stop(struct tty_struct *tty);
+ static void dgnc_tty_throttle(struct tty_struct *tty);
+ static void dgnc_tty_unthrottle(struct tty_struct *tty);
+ static void dgnc_tty_flush_chars(struct tty_struct *tty);
+@@ -2034,11 +2042,15 @@ static void dgnc_tty_close(struct tty_st
+ * Return number of characters that have not been transmitted yet.
+ *
+ * This routine is used by the line discipline to determine if there
+ * is data waiting to be transmitted/drained/flushed or not.
+ */
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,14,0)
++static unsigned int dgnc_tty_chars_in_buffer(struct tty_struct *tty)
++#else
+ static int dgnc_tty_chars_in_buffer(struct tty_struct *tty)
++#endif
+ {
+ struct channel_t *ch = NULL;
+ struct un_t *un = NULL;
+ ushort thead;
+ ushort ttail;
+@@ -2142,11 +2154,15 @@ static int dgnc_maxcps_room(struct tty_s
+ /*
+ * dgnc_tty_write_room()
+ *
+ * Return space available in Tx buffer
+ */
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,14,0)
++static unsigned int dgnc_tty_write_room(struct tty_struct *tty)
++#else
+ static int dgnc_tty_write_room(struct tty_struct *tty)
++#endif
+ {
+ struct channel_t *ch = NULL;
+ struct un_t *un = NULL;
+ ushort head;
+ ushort tail;
diff --git a/PKGBUILD b/PKGBUILD
index d4b93fb7fd73..8db85b15b89b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -17,7 +17,7 @@ pkgname='digi-dgnc'
#_pkgver='1.3-28'; _dl='40002369_G.tgz'
_pkgver='1.3-29'; _dl='40002369_H.src.rpm'
pkgver="${_pkgver//-/.}"
-pkgrel='4'
+pkgrel='5'
pkgdesc='tty driver for Digi Neo and legacy ClassicBoard PCI PCIe RS-232 serial port'
arch=('i686' 'x86_64')
url='https://www.digi.com/'
@@ -31,17 +31,26 @@ source=(
'0001-Kernel-4-15-timers.patch'
'0002-kernel-5.0.0-do_gettimeofday.patch'
'0003-kernel-5.6--proc_dir_entry-proc_ops.patch'
+ '0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch'
+ '0005-kernel-5.13-dropped-tty_check_change.patch'
+ '0006-kernel-5.14-task_struct.state-unsigned-tty.patch'
)
md5sums=('6171349852f6d02228d6e30c79b7a434'
'a171e9ea1a4ff8340c3c58b303632edf'
'6c16c3c24c79fb558bcf27f780829c75'
'8e46a778c648ab4f0ca63a337d36df60'
- '394d24a150676d8123300d6715b81fb8')
+ '394d24a150676d8123300d6715b81fb8'
+ '44b0a7b0ab4dbe661b822fcba9423121'
+ '10ba960da22684d2da89872df1d822cc'
+ '89de6a694ecf827a3358bcd8aea03a6a')
sha256sums=('e121a31569e3e1f156caeed70742971ec32fef598429ef647bde98f56aa048f5'
'625bb794d31690b45ad7469f811e7422dac938cf8e9b777aba4d97b60b3c6eae'
'88d5a8589dca55ca98089dfa4570aa1fbde1095957d0788ad710a27b348c2f4f'
'737df02a12fc76841325d1059d90451467637eab2df016efc20d84976eb5de7d'
- '3496e90914e1fa2f209dd85c336e7b1c0b784dbbf67cc45e0f0f55f0b1ef5a0e')
+ '3496e90914e1fa2f209dd85c336e7b1c0b784dbbf67cc45e0f0f55f0b1ef5a0e'
+ 'f215451df4a01f0875a53425b6d8452c344f19b61b59b821f8c949b1b276c022'
+ '13257318895327e7438f7f357c5dc7d67310ec0468802df083815414d4743805'
+ 'dcedb22e0f3fb0c8197630b38217f86c5468d065ab2d67708c16c17351d6944e')
if [ "${_opt_DKMS}" -ne 0 ]; then
depends+=('linux' 'dkms' 'linux-headers')
@@ -97,6 +106,18 @@ prepare() {
#diff -pNaru5 driver/2.6.27{.orig,} > '0003-kernel-5.6--proc_dir_entry-proc_ops.patch'
patch -Nbup0 -i "${srcdir}/0003-kernel-5.6--proc_dir_entry-proc_ops.patch"
+ #rm -f driver/2.6.27/*.orig; cp -pr driver/2.6.27{,.orig}; false
+ #diff -pNaru5 driver/2.6.27{.orig,} > '0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch'
+ patch -Nbup0 -i "${srcdir}/0004-kernel-5.12-MODULE_SUPPORTED_DEVICE.patch"
+
+ #rm -f driver/2.6.27/*.orig; cp -pr driver/2.6.27{,.orig}; false
+ #diff -pNaru5 driver/2.6.27{.orig,} > '0005-kernel-5.13-dropped-tty_check_change.patch'
+ patch -Nbup0 -i "${srcdir}/0005-kernel-5.13-dropped-tty_check_change.patch"
+
+ #rm -f driver/2.6.27/*.orig; cp -pr driver/2.6.27{,.orig}; false
+ #diff -pNaru5 driver/2.6.27{.orig,} > '0006-kernel-5.14-task_struct.state-unsigned-tty.patch'
+ patch -Nbup0 -i "${srcdir}/0006-kernel-5.14-task_struct.state-unsigned-tty.patch"
+
# Version check
local _ver
_ver="$(grep -e 'TRUE_VERSION=' ./Makefile.inc | cut -d'"' -f2)"