Description: support Linux 6.16 timer API
Author: Jan Engelhardt <jengelh@inai.de>
Origin: upstream, https://codeberg.org/jengelh/xtables-addons/commit/61762a5f2c07214ba8a9a3d7350bc63b98b25dd5
Bug-Ubuntu: https://bugs.launchpad.net/bugs/2133208
Last-Update: 2025-11-28 
--- a/extensions/pknock/xt_pknock.c
+++ b/extensions/pknock/xt_pknock.c
@@ -358,7 +358,11 @@
 static void peer_gc(struct timer_list *tl)
 {
 	unsigned int i;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
+	struct xt_pknock_rule *rule = timer_container_of(rule, tl, timer);
+#else
 	struct xt_pknock_rule *rule = from_timer(rule, tl, timer);
+#endif
 	struct peer *peer;
 	struct list_head *pos, *n;
 
