include $(TOPDIR)/rules.mk
PKG_NAME:=coova-chilli
-PKG_VERSION:=1.6
-PKG_RELEASE:=13
+PKG_VERSION:=1.7
+PKG_RELEASE:=1
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=https://codeload.github.com/coova/coova-chilli/tar.gz/$(PKG_VERSION)?
-PKG_HASH:=26b2bead6fd9c18eb736fb0a0f8709922de4e4fedee1122193f82706eb2b9305
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_URL:=https://github.com/coova/coova-chilli
+PKG_SOURCE_VERSION:=$(PKG_VERSION)
+PKG_MIRROR_HASH:=adf30c6c61d803770d2f9bcc225e85465edd816396bcf409cc503832cd45c2a3
PKG_LICENSE:=GPL-2.0-or-later
static u_int32_t hash_rnd;
static bool hash_rnd_initted;
-@@ -577,6 +581,14 @@ coova_mt_proc_write(struct file *file, c
+@@ -582,6 +586,14 @@ coova_mt_proc_write(struct file *file, c
return size + 1;
}
static const struct file_operations coova_mt_fops = {
.open = coova_seq_open,
.read = seq_read,
-@@ -584,6 +596,7 @@ static const struct file_operations coov
+@@ -589,6 +601,7 @@ static const struct file_operations coov
.release = seq_release_private,
.owner = THIS_MODULE,
};
+++ /dev/null
-Date: 21 Oct 2022 13:00:00 +1000
-Subject: [PATCH] xt_coova: fix kernel>=5.17
-
-Linux kernel 5.17 removed PDE_DATA, and replaced it with pde_data [0]
-
-[0]: https://github.com/torvalds/linux/commit/359745d78351c6f5442435f81549f0207ece28aa
-
-
---- a/src/linux/xt_coova.c
-+++ b/src/linux/xt_coova.c
-@@ -470,7 +470,9 @@ static int coova_seq_open(struct inode *
- if (st == NULL)
- return -ENOMEM;
-
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,10,0)
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,17,0)
-+ st->table = pde_data(inode);
-+#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3,10,0)
- st->table = PDE_DATA(inode);
- #else
- st->table = pde->data;
-@@ -482,7 +484,9 @@ static ssize_t
- coova_mt_proc_write(struct file *file, const char __user *input,
- size_t size, loff_t *loff)
- {
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,10,0)
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,17,0)
-+ struct coova_table *t = pde_data(file_inode(file));
-+#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3,10,0)
- struct coova_table *t = PDE_DATA(file_inode(file));
- #else
- const struct proc_dir_entry *pde = PDE(file->f_path.dentry->d_inode);
+++ /dev/null
---- a/src/chilli.c
-+++ b/src/chilli.c
-@@ -7867,7 +7867,7 @@ int chilli_main(int argc, char **argv) {
- */
-
- #ifdef ENABLE_CHILLIQUERY
-- cmdsock_shutdown();
-+ cmdsock_shutdown(cmdsock);
- #endif
-
- #ifdef ENABLE_CHILLIREDIR
---- a/src/chilli.h
-+++ b/src/chilli.h
-@@ -266,7 +266,7 @@ int cmdsock_init(void);
-
- int cmdsock_port_init(void);
-
--void cmdsock_shutdown();
-+void cmdsock_shutdown(int s);
-
- time_t mainclock_tick(void);
- time_t mainclock_now(void);