mirror of
https://github.com/archlinux-jerry/nvidia-340xx
synced 2024-11-18 13:50:40 +08:00
Merge commit 'e552e832774284eee3a84ecdce2af17d97529bcd'
This commit is contained in:
commit
27546b002e
2 changed files with 64 additions and 1 deletions
61
0012-kernel-6.2.patch
Normal file
61
0012-kernel-6.2.patch
Normal file
|
@ -0,0 +1,61 @@
|
|||
--- a/kernel/conftest.sh 2023-02-24 10:35:02.633467500 +0100
|
||||
+++ b/kernel/conftest.sh 2023-02-24 11:13:02.892079164 +0100
|
||||
@@ -794,12 +794,19 @@
|
||||
|
||||
echo "$CONFTEST_PREAMBLE
|
||||
#include <linux/acpi.h>
|
||||
+ #include <linux/version.h>
|
||||
|
||||
acpi_op_remove conftest_op_remove_routine;
|
||||
|
||||
+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 2, 0)
|
||||
+ void conftest_acpi_device_ops_remove(struct acpi_device *device) {
|
||||
+ conftest_op_remove_routine(device);
|
||||
+ }
|
||||
+ #else
|
||||
int conftest_acpi_device_ops_remove(struct acpi_device *device) {
|
||||
return conftest_op_remove_routine(device);
|
||||
- }" > conftest$$.c
|
||||
+ }
|
||||
+ #endif" > conftest$$.c
|
||||
|
||||
$CC $CFLAGS -c conftest$$.c > /dev/null 2>&1
|
||||
rm -f conftest$$.c
|
||||
--- a/kernel/nv-acpi.c 2023-02-24 10:35:02.643467765 +0100
|
||||
+++ b/kernel/nv-acpi.c 2023-02-24 11:09:14.821580592 +0100
|
||||
@@ -26,8 +26,12 @@
|
||||
#if !defined(NV_ACPI_DEVICE_OPS_REMOVE_ARGUMENT_COUNT) || (NV_ACPI_DEVICE_OPS_REMOVE_ARGUMENT_COUNT == 2)
|
||||
static int nv_acpi_remove_two_args(struct acpi_device *device, int type);
|
||||
#else
|
||||
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 2, 0)
|
||||
+static void nv_acpi_remove_one_arg(struct acpi_device *device);
|
||||
+#else
|
||||
static int nv_acpi_remove_one_arg(struct acpi_device *device);
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
static void nv_acpi_event (acpi_handle, u32, void *);
|
||||
static acpi_status nv_acpi_find_methods (acpi_handle, u32, void *, void **);
|
||||
@@ -356,8 +360,12 @@
|
||||
#if !defined(NV_ACPI_DEVICE_OPS_REMOVE_ARGUMENT_COUNT) || (NV_ACPI_DEVICE_OPS_REMOVE_ARGUMENT_COUNT == 2)
|
||||
static int nv_acpi_remove_two_args(struct acpi_device *device, int type)
|
||||
#else
|
||||
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 2, 0)
|
||||
+static void nv_acpi_remove_one_arg(struct acpi_device *device)
|
||||
+#else
|
||||
static int nv_acpi_remove_one_arg(struct acpi_device *device)
|
||||
#endif
|
||||
+#endif
|
||||
{
|
||||
/*
|
||||
* This function will cause RM to relinquish control of the VGA ACPI device.
|
||||
@@ -407,7 +415,9 @@
|
||||
device->driver_data = NULL;
|
||||
}
|
||||
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 2, 0)
|
||||
return status;
|
||||
+#endif
|
||||
}
|
||||
|
||||
static void nv_acpi_event(acpi_handle handle, u32 event_type, void *data)
|
4
PKGBUILD
4
PKGBUILD
|
@ -28,6 +28,7 @@ source=("https://us.download.nvidia.com/XFree86/Linux-x86_64/${pkgver}/NVIDIA-Li
|
|||
0009-kernel-5.17.patch
|
||||
0010-kernel-5.18.patch
|
||||
0011-kernel-6.0.patch
|
||||
0012-kernel-6.2.patch
|
||||
)
|
||||
b2sums=('6538bbec53b10f8d20977f9b462052625742e9709ef06e24cf2e55de5d0c55f1620a4bb21396cfd89ebc54c32f921ea17e3e47eaa95abcbc24ecbd144fb89028'
|
||||
'49d99f612e8eee3ab5e34083c25348bfd14ed5fc8a7984dafc0dad7c0ae0df2c0b2a63a1bb993da440eb0a60293d7c753ca3889bd2f51991b8ddc51bce2fe4a8'
|
||||
|
@ -41,7 +42,8 @@ b2sums=('6538bbec53b10f8d20977f9b462052625742e9709ef06e24cf2e55de5d0c55f1620a4bb
|
|||
'caedc5651bfd14c02fb677f9c5e87adef298d871c6281b78ce184108310e4243ded82210873014be7fedee0dd6251305fa9bbce0c872b76438e0895ef76109d9'
|
||||
'0266e1baaac9ffbb94d9e916a693b1663d8686b15e970bfc30f7c51f051a0af9267aa5f6a12b68586c69d2e9796a1124488b3997ba4b26db1a5ac10a892f0df2'
|
||||
'd69c9acbe550d5fccca68ca6a0d5095cbcaf887d2bc43704a8eb85533896692f16701eef07ead297881f596f5502c3105bb5bea77b2dcaf6c4dc2b49941f9f19'
|
||||
'682a7b8e58d2a008531b7e5179e32c0c71adad673891a1057acd1aa26e410d9d93ff607e46257c6701619621cee1a27e613ec9ae19a580acdd6f68f1c1fdedea')
|
||||
'682a7b8e58d2a008531b7e5179e32c0c71adad673891a1057acd1aa26e410d9d93ff607e46257c6701619621cee1a27e613ec9ae19a580acdd6f68f1c1fdedea'
|
||||
'47681d1e4b16f0b50775120b0a02bc6d279de692cde6086b895eef80bb4598e914ffe1fae81707a771d00f23df60ee4df591dfe042f5b764856d2e07306f3821')
|
||||
_pkg="NVIDIA-Linux-x86_64-${pkgver}-no-compat32"
|
||||
|
||||
# default is 'linux' substitute custom name here
|
||||
|
|
Loading…
Reference in a new issue