[PATCH 32/47] headers: Adapt signature of hrtimer_forward_now()

Hauke Mehrtens <[email protected]>
Newsgroups org.kernel.vger.backports
Message-ID <[email protected]>
The hrtimer_forward_now() function is now used by mac80211_hwsim.
In kernel 4.10 the type of the interval parameter of
hrtimer_forward_now() was changed from ktime_t to s64. This change
converts calls using the new version to the old one.

Signed-off-by: Hauke Mehrtens <[email protected]>
---
 backport/backport-include/linux/interrupt.h | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/backport/backport-include/linux/interrupt.h b/backport/backport-include/linux/interrupt.h
index 41d50d7c..f42f2ddd 100644
--- a/backport/backport-include/linux/interrupt.h
+++ b/backport/backport-include/linux/interrupt.h
@@ -16,6 +16,15 @@ backport_hrtimer_forward(struct hrtimer *timer, ktime_t now, s64 interval)
 }
 #define hrtimer_forward LINUX_BACKPORT(hrtimer_forward)
 
+static inline u64
+backport_hrtimer_forward_now(struct hrtimer *timer, s64 interval)
+{
+	ktime_t _interval = { .tv64 = interval };
+
+	return hrtimer_forward_now(timer, _interval);
+}
+#define hrtimer_forward_now LINUX_BACKPORT(hrtimer_forward_now)
+
 static inline s64 backport_ns_to_ktime(u64 ns)
 {
 	ktime_t _time = ns_to_ktime(ns);
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.