Am Sonntag 28 Juni 2009 19:56:42 schrieb Patrick Matthäi:
Hendrik Sattler schrieb:
Package: fglrx-source
Version: 1:9-6-1
Severity: important
The closed-source part calls a function called pci_enable_msi(). However,
on linux-2.6.30, this is only a define. Thus while loading the module,
the symbol cannot be found.
Thanks, I will fix it these days.
I attach the patch for the modules/fglrx dir that makes it compile (without
compiler warnings and works on my self-compiled 2.6.30).
Have fun
HS
BTW: the make.sh script and Makefile is broken as you do not ship the 2.6.x
directory.
Index: fglrx/firegl_public.c
===
--- fglrx.orig/firegl_public.c 2009-06-28 12:47:32.421193869 +0200
+++ fglrx/firegl_public.c 2009-06-28 12:55:08.429443844 +0200
@@ -175,6 +175,13 @@
//
+#if LINUX_VERSION_CODE = KERNEL_VERSION(2,6,30)
+#undef pci_enable_msi
+int pci_enable_msi(struct pci_dev *dev) {
+ return pci_enable_msi_block(dev, 1);
+}
+#endif
+
// VM_SHM is deleted in 2.6.18 or higher kernels.
#ifndef VM_SHM
#define VM_SHM 0
@@ -1228,8 +1235,6 @@
*/
int ATI_API_CALL KCL_SetPageCache_Array(unsigned long *pt, int pages, int enable)
{
-unsigned int i;
-int ret = 0;
#if LINUX_VERSION_CODE = KERNEL_VERSION(2,6,28)
if (enable)
{
@@ -1240,6 +1245,8 @@
return set_memory_array_uc(pt, pages);
}
#else
+unsigned int i;
+int ret = 0;
for( i = 0; i pages; i++ )
{
ret = KCL_SetPageCache((void *)pt[i], 1, enable);
Index: fglrx/drm_proc.h
===
--- fglrx.orig/drm_proc.h 2009-06-28 12:57:52.893189018 +0200
+++ fglrx/drm_proc.h 2009-06-28 12:58:22.604195690 +0200
@@ -496,7 +496,7 @@
DRM_PROC_PRINT(vma use count: %d, high_memory = %p, 0x%08lx\n,
atomic_read(dev-vma_count),
- high_memory, virt_to_phys(high_memory));
+ high_memory, (unsigned long)virt_to_phys(high_memory));
for (pt = dev-vmalist; pt; pt = pt-next) {
if (!(vma = pt-vma)) continue;
DRM_PROC_PRINT(\n%5d 0x%08lx-0x%08lx %c%c%c%c%c%c 0x%08lx,
Index: fglrx/firegl_public.h
===
--- fglrx.orig/firegl_public.h 2009-06-28 12:53:41.029442531 +0200
+++ fglrx/firegl_public.h 2009-06-28 13:00:21.494199179 +0200
@@ -601,10 +601,12 @@
#endif
/* #ifndef pgprot_writecombine */
+#undef pgprot_writecombine
#define pgprot_writecombine(prot) __pgprot((pgprot_val(prot) ~(_PAGE_PCD)) | _PAGE_PWT)
/* #endif */
/* #ifndef pgprot_noncached */
+#undef pgprot_noncached
#define pgprot_noncached(prot) __pgprot(pgprot_val(prot) | _PAGE_PCD | _PAGE_PWT)
/* #endif */