SOURCES: svgalib-2.6.27.patch (NEW) - fix for building with kernel 2.6.27
hawk
hawk at pld-linux.org
Sat Oct 25 23:38:35 CEST 2008
Author: hawk Date: Sat Oct 25 21:38:35 2008 GMT
Module: SOURCES Tag: HEAD
---- Log message:
- fix for building with kernel 2.6.27
---- Files affected:
SOURCES:
svgalib-2.6.27.patch (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: SOURCES/svgalib-2.6.27.patch
diff -u /dev/null SOURCES/svgalib-2.6.27.patch:1.1
--- /dev/null Sat Oct 25 23:38:36 2008
+++ SOURCES/svgalib-2.6.27.patch Sat Oct 25 23:38:29 2008
@@ -0,0 +1,30 @@
+--- svgalib/kernel/svgalib_helper/kernel26compat.h 2008/10/16 23:28:58 1.1
++++ svgalib/kernel/svgalib_helper/kernel26compat.h 2008/10/16 23:34:41
+@@ -130,7 +130,7 @@
+ MKDEV(SVGALIB_HELPER_MAJOR, _minor), \
+ &sh_pci_devs[_minor]->dev->dev, _name);
+ /* 2.6.26 changed class_device_create to device_create */
+-#else
++#elif LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27)
+ # define SLH_SYSFS_ADD_CONTROL \
+ device_create(svgalib_helper_class, NULL, \
+ MKDEV(SVGALIB_HELPER_MAJOR, 0), \
+@@ -140,6 +140,18 @@
+ device_create(svgalib_helper_class, &sh_pci_devs[_minor]->dev->dev, \
+ MKDEV(SVGALIB_HELPER_MAJOR, _minor), \
+ _name);
++/* 2.6.27 changed device_create to device_create_drvdata */
++#else
++# define SLH_SYSFS_ADD_CONTROL \
++ device_create_drvdata(svgalib_helper_class, NULL, \
++ MKDEV(SVGALIB_HELPER_MAJOR, 0), \
++ "%s%d", "svga", 0);
++
++# define SLH_SYSFS_ADD_DEVICE(_name, _minor) \
++ device_create_drvdata(svgalib_helper_class, \
++ &sh_pci_devs[_minor]->dev->dev, \
++ MKDEV(SVGALIB_HELPER_MAJOR, _minor), \
++ "%s%d", _name, _minor);
+ #endif
+
+ # define SLH_SYSFS_REMOVE_DEVICE(i) \
================================================================
More information about the pld-cvs-commit
mailing list