packages: xorg-driver-video-fglrx/xorg-driver-video-fglrx-2.6.29.patch - be...
hawk
hawk at pld-linux.org
Wed Jul 15 00:28:59 CEST 2009
Author: hawk Date: Tue Jul 14 22:28:59 2009 GMT
Module: packages Tag: HEAD
---- Log message:
- better solution, taken from gentoo
---- Files affected:
packages/xorg-driver-video-fglrx:
xorg-driver-video-fglrx-2.6.29.patch (1.1 -> 1.2)
---- Diffs:
================================================================
Index: packages/xorg-driver-video-fglrx/xorg-driver-video-fglrx-2.6.29.patch
diff -u packages/xorg-driver-video-fglrx/xorg-driver-video-fglrx-2.6.29.patch:1.1 packages/xorg-driver-video-fglrx/xorg-driver-video-fglrx-2.6.29.patch:1.2
--- packages/xorg-driver-video-fglrx/xorg-driver-video-fglrx-2.6.29.patch:1.1 Fri Apr 10 17:48:01 2009
+++ packages/xorg-driver-video-fglrx/xorg-driver-video-fglrx-2.6.29.patch Wed Jul 15 00:28:54 2009
@@ -1685,69 +1685,101 @@
+#pragma pack()
+
+#endif /* _ACOBJECT_H */
-diff -Naurp a/common/lib/modules/fglrx/build_mod/common/lib/common/lib/modules/fglrx/build_mod/modules/fglrx/build_mod/firegl_public.c b/common/lib/modules/fglrx/build_mod/firegl_public.c
---- a/common/lib/modules/fglrx/build_mod/firegl_public.c 2009-02-28 22:31:33.000000000 +0100
-+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c 2009-02-28 22:30:23.000000000 +0100
-@@ -1402,7 +1402,7 @@ KCL_TYPE_Pid ATI_API_CALL KCL_GetTgid(vo
+diff -Nparu build_mod/firegl_public.c fglrx-8.573-new/common/lib/modules/fglrx/build_mod/firegl_public.c
+--- build_mod/firegl_public.c 2009-01-23 20:00:26.000000000 -0200
++++ fglrx-8.573-new/common/lib/modules/fglrx/build_mod/firegl_public.c 2009-02-13 15:25:00.000000000 -0200
+@@ -1460,7 +1460,11 @@ KCL_TYPE_Pid ATI_API_CALL KCL_GetTgid(vo
*/
KCL_TYPE_Uid ATI_API_CALL KCL_GetEffectiveUid(void)
{
-- return current->euid;
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)
+ return current->cred->euid;
++#else
+ return current->euid;
++#endif
}
/** /brief Delay execution for the specified number of microseconds
-@@ -1774,14 +1774,15 @@ int ATI_API_CALL KCL_PosixSecurityCapChe
+@@ -1832,15 +1836,30 @@ int ATI_API_CALL KCL_PosixSecurityCapChe
*/
void ATI_API_CALL KCL_PosixSecurityCapSetIPCLock(unsigned int lock)
{
-+ struct cred* currentCred = (struct cred*)get_current_cred();
++
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)
++ struct cred *new = prepare_creds();
++ if (!new) {
++ printk(KERN_ERR "fglrx: could not allocate memory\n");
++ return;
++ }
++#else
++#define new current
++#endif
if (lock == 0 )
{
- cap_lower(current->cap_effective, CAP_IPC_LOCK);
-+ cap_lower(currentCred->cap_effective, CAP_IPC_LOCK);
++ cap_lower(new->cap_effective, CAP_IPC_LOCK);
}
else
{
- cap_raise(current->cap_effective, CAP_IPC_LOCK);
-- }
-+ cap_raise(currentCred->cap_effective, CAP_IPC_LOCK);
-+ }
- return;
++ cap_raise(new->cap_effective, CAP_IPC_LOCK);
+ }
+- return;
++
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)
++ commit_creds(new);
++#else
++#undef new
++#endif
}
-diff -Naurp a/common/lib/modules/fglrx/build_mod/common/lib/common/lib/modules/fglrx/build_mod/modules/fglrx/build_mod/firegl_public.h b/common/lib/modules/fglrx/build_mod/firegl_public.h
---- a/common/lib/modules/fglrx/build_mod/firegl_public.h 2009-03-01 00:21:56.000000000 +0100
-+++ b/common/lib/modules/fglrx/build_mod/firegl_public.h 2009-03-01 00:21:17.000000000 +0100
-@@ -589,13 +589,13 @@ extern unsigned long KCL_SYSINFO_
+ /** \brief Get number of available RAM pages
+diff -Nparu build_mod/firegl_public.h fglrx-8.573-new/common/lib/modules/fglrx/build_mod/firegl_public.h
+--- build_mod/firegl_public.h 2009-01-23 20:00:26.000000000 -0200
++++ fglrx-8.573-new/common/lib/modules/fglrx/build_mod/firegl_public.h 2009-02-16 14:02:50.000000000 -0300
+@@ -18,6 +18,7 @@
+ #define _FIREGL_PUBLIC_H_
+
+ #include <stdarg.h>
++#include <asm/pgtable.h>
+ #include "kcl_pci.h"
+ #include "kcl_io.h"
+
+@@ -590,6 +591,11 @@ extern unsigned long KCL_SYSINFO_
#define cpu_has_pge test_bit(X86_FEATURE_PGE, &boot_cpu_data.x86_capability)
#endif
--#ifndef pgprot_writecombine
-+/* #ifndef pgprot_writecombine */
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)
++#undef pgprot_writecombine
++#undef pgprot_noncached
++#endif
++
+ #ifndef pgprot_writecombine
#define pgprot_writecombine(prot) __pgprot((pgprot_val(prot) & ~(_PAGE_PCD)) | _PAGE_PWT)
--#endif
-+/* #endif */
-
--#ifndef pgprot_noncached
-+/* #ifndef pgprot_noncached */
+ #endif
+@@ -598,6 +604,7 @@ extern unsigned long KCL_SYSINFO_
#define pgprot_noncached(prot) __pgprot(pgprot_val(prot) | _PAGE_PCD | _PAGE_PWT)
--#endif
-+/* #endif */
+ #endif
++
#endif //FIREGL_USWC_SUPPORT
-diff -Naurp a/common/lib/modules/fglrx/build_mod/common/lib/common/lib/modules/fglrx/build_mod/modules/fglrx/build_mod/kcl_acpi.c b/common/lib/modules/fglrx/build_mod/kcl_acpi.c
---- a/common/lib/modules/fglrx/build_mod/kcl_acpi.c 2009-02-28 21:39:21.000000000 +0100
-+++ b/common/lib/modules/fglrx/build_mod/kcl_acpi.c 2009-02-28 22:25:29.000000000 +0100
-@@ -17,6 +17,9 @@
- #include <linux/version.h>
+
+diff -Nparu build_mod/kcl_acpi.c fglrx-8.573-new/common/lib/modules/fglrx/build_mod/kcl_acpi.c
+--- build_mod/kcl_acpi.c 2009-01-23 20:00:26.000000000 -0200
++++ fglrx-8.573-new/common/lib/modules/fglrx/build_mod/kcl_acpi.c 2009-02-13 15:25:00.000000000 -0200
+@@ -18,6 +18,12 @@
#include <linux/autoconf.h>
#include <linux/acpi.h>
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)
+#include "acpica-acconfig.h"
+#include "acpica-aclocal.h"
+#include "acpica-acobject.h"
-
++#endif
++
#include "kcl_config.h"
#include "kcl_type.h"
+ #include "kcl_acpi.h"
+ #include "kcl_acpi.h"
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/xorg-driver-video-fglrx/xorg-driver-video-fglrx-2.6.29.patch?r1=1.1&r2=1.2&f=u
More information about the pld-cvs-commit
mailing list