summaryrefslogtreecommitdiffstats
path: root/meta-xilinx-mali400/recipes-graphics/mali/kernel-module-mali/0021-Use-updated-timekeeping-functions-in-kernel-5.6.patch
diff options
context:
space:
mode:
authorJohn Toomey <john.toomey@amd.com>2024-05-15 14:16:28 +0100
committerMark Hatle <mark.hatle@amd.com>2024-11-21 10:43:43 -0600
commit661ee988c5cf2073d277c56aa98f55f7baf56c63 (patch)
tree2a6d05e3010e1476c974ecfe64339bf3118331a3 /meta-xilinx-mali400/recipes-graphics/mali/kernel-module-mali/0021-Use-updated-timekeeping-functions-in-kernel-5.6.patch
parent32bffbb8498f0297ed1e6deaca72ff8a5c500a39 (diff)
downloadmeta-xilinx-661ee988c5cf2073d277c56aa98f55f7baf56c63.tar.gz
meta-xilinx-mali400: Create new Mali400 layer
Create a new layer containing all code related to the Mali400 graphics stack and software. This includes the Mali kernel module / patches, libglu/libgles code, mesa, wayland, kernel recipe and udev rules. This layer also includes a dynamic layer for the qt5 bbappends and patches. Signed-off-by: Mark Hatle <mark.hatle@amd.com>
Diffstat (limited to 'meta-xilinx-mali400/recipes-graphics/mali/kernel-module-mali/0021-Use-updated-timekeeping-functions-in-kernel-5.6.patch')
-rw-r--r--meta-xilinx-mali400/recipes-graphics/mali/kernel-module-mali/0021-Use-updated-timekeeping-functions-in-kernel-5.6.patch37
1 files changed, 37 insertions, 0 deletions
diff --git a/meta-xilinx-mali400/recipes-graphics/mali/kernel-module-mali/0021-Use-updated-timekeeping-functions-in-kernel-5.6.patch b/meta-xilinx-mali400/recipes-graphics/mali/kernel-module-mali/0021-Use-updated-timekeeping-functions-in-kernel-5.6.patch
new file mode 100644
index 00000000..adef8e18
--- /dev/null
+++ b/meta-xilinx-mali400/recipes-graphics/mali/kernel-module-mali/0021-Use-updated-timekeeping-functions-in-kernel-5.6.patch
@@ -0,0 +1,37 @@
1From bc0f85271681532c7e394229f0155366d1de8779 Mon Sep 17 00:00:00 2001
2From: Dylan Yip <dylan.yip@xilinx.com>
3Date: Mon, 8 Feb 2021 23:47:01 -0800
4Subject: [PATCH 21/23] Use updated timekeeping functions in kernel 5.6
5
6As of commit 412c53a680a9 ("y2038: remove unused time32 interfaces"), 32
7bit timekeeping functions like getnstimeofday() have been removed. So
8use the 64 bit replacements.
9
10Signed-off-by: Dylan Yip <dylan.yip@xilinx.com>
11---
12 linux/mali_osk_time.c | 6 ++++++
13 1 file changed, 6 insertions(+)
14
15diff --git a/linux/mali_osk_time.c b/linux/mali_osk_time.c
16index bfcbf7f..583d82b 100644
17--- a/linux/mali_osk_time.c
18+++ b/linux/mali_osk_time.c
19@@ -46,9 +46,15 @@ void _mali_osk_time_ubusydelay(u32 usecs)
20
21 u64 _mali_osk_time_get_ns(void)
22 {
23+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0)
24+ struct timespec64 tsval;
25+ ktime_get_real_ts64(&tsval);
26+ return (u64)timespec64_to_ns(&tsval);
27+#else
28 struct timespec tsval;
29 getnstimeofday(&tsval);
30 return (u64)timespec_to_ns(&tsval);
31+#endif
32 }
33
34 u64 _mali_osk_boot_time_get_ns(void)
35--
362.17.1
37