From 32e894d44f5c39ca3e93667d9152146253690873 Mon Sep 17 00:00:00 2001 From: Larry Finger Date: Fri, 30 Nov 2018 16:55:08 -0600 Subject: [PATCH] rtl8188eu: Fix missing divide routine for 32-bit systems Signed-off-by: Larry Finger --- os_dep/ioctl_cfg80211.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/os_dep/ioctl_cfg80211.c b/os_dep/ioctl_cfg80211.c index 46b1a32..db4b1aa 100644 --- a/os_dep/ioctl_cfg80211.c +++ b/os_dep/ioctl_cfg80211.c @@ -350,9 +350,9 @@ static const struct ieee80211_txrx_stypes static u64 rtw_get_systime_us(void) { #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 20, 0)) - ktime_t ts; + u64 ts; ts = ktime_get_boottime(); - return ts / 1000; + return do_div(ts, 1000); #elif (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 39)) struct timespec ts; get_monotonic_boottime(&ts);