Skip to content

Commit bb2350b

Browse files
authored
Merge pull request #76 from horseface1110/fix/hrtimer-api-linux-6.15
Support Linux 6.15 about hrtimer_init
2 parents 34fe3b5 + 4a4d55e commit bb2350b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

vwifi.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1677,8 +1677,13 @@ static int vwifi_start_ap(struct wiphy *wiphy,
16771677

16781678
/* Initialize hrtimer of beacon */
16791679
pr_info("vwifi: init beacon_timer.\n");
1680+
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 15, 0)
1681+
hrtimer_setup(&vif->beacon_timer, vwifi_beacon, CLOCK_MONOTONIC,
1682+
HRTIMER_MODE_ABS_SOFT);
1683+
#else
16801684
hrtimer_init(&vif->beacon_timer, CLOCK_MONOTONIC, HRTIMER_MODE_ABS_SOFT);
16811685
vif->beacon_timer.function = vwifi_beacon;
1686+
#endif
16821687

16831688
if (!hrtimer_is_queued(&vif->beacon_timer)) {
16841689
u64 tsf, until_tbtt;

0 commit comments

Comments
 (0)