File kernel_64.diff of Package tp_smapi

diff -U 3 -dHrN -- a/tp_smapi-0.43/thinkpad_ec.c b/tp_smapi-0.43/thinkpad_ec.c
--- a/tp_smapi-0.43/thinkpad_ec.c	2018-02-24 16:59:51.000000000 +0100
+++ b/tp_smapi-0.43/thinkpad_ec.c	2023-07-19 20:40:49.994151707 +0200
@@ -90,8 +90,10 @@
 /* Locking: */
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)
 static DECLARE_MUTEX(thinkpad_ec_mutex);
-#else
+#elif LINUX_VERSION_CODE < KERNEL_VERSION(6,4,0)
 static DEFINE_SEMAPHORE(thinkpad_ec_mutex);
+#else
+static DEFINE_SEMAPHORE(thinkpad_ec_mutex, 1);
 #endif
 
 /* Kludge in case the ACPI DSDT reserves the ports we need. */
diff -U 3 -dHrN -- a/tp_smapi-0.43/tp_smapi.c b/tp_smapi-0.43/tp_smapi.c
--- a/tp_smapi-0.43/tp_smapi.c	2018-02-24 16:59:51.000000000 +0100
+++ b/tp_smapi-0.43/tp_smapi.c	2023-07-19 20:40:49.994151707 +0200
@@ -111,8 +111,10 @@
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)
 static DECLARE_MUTEX(smapi_mutex);
-#else
+#elif LINUX_VERSION_CODE < KERNEL_VERSION(6,4,0)
 static DEFINE_SEMAPHORE(smapi_mutex);
+#else
+static DEFINE_SEMAPHORE(smapi_mutex, 1);
 #endif
 
 /**
openSUSE Build Service is sponsored by