Skip to content

Commit c2f491f

Browse files
committed
Fix build with Kernel 6.16: Rename from_timer() to timer_container_of()
1 parent 27aa922 commit c2f491f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

include/osdep_service_linux.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,9 @@ static inline void timer_hdl(struct timer_list *in_timer)
359359
static inline void timer_hdl(unsigned long cntx)
360360
#endif
361361
{
362-
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 0))
362+
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0))
363+
_timer *ptimer = timer_container_of(ptimer, in_timer, timer);
364+
#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 0))
363365
_timer *ptimer = from_timer(ptimer, in_timer, timer);
364366
#else
365367
_timer *ptimer = (_timer *)cntx;

0 commit comments

Comments
 (0)