1 |
lxnay 10/11/05 16:31:23 |
2 |
|
3 |
Added: svgalib-1.9.25-linux2.6.36.patch |
4 |
Log: |
5 |
add 2.6.36 Linux kernel support |
6 |
|
7 |
(Portage version: 2.2_rc91/cvs/Linux x86_64) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 media-libs/svgalib/files/svgalib-1.9.25-linux2.6.36.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/svgalib/files/svgalib-1.9.25-linux2.6.36.patch?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/svgalib/files/svgalib-1.9.25-linux2.6.36.patch?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: svgalib-1.9.25-linux2.6.36.patch |
16 |
=================================================================== |
17 |
--- svgalib-1.9.25.orig/kernel/svgalib_helper/main.c |
18 |
+++ svgalib-1.9.25/kernel/svgalib_helper/main.c |
19 |
@@ -162,10 +162,16 @@ static void task_startad(void *data) { |
20 |
get_user(pciv.address, &user_pciv->address); \ |
21 |
get_user(pciv.val, &user_pciv->val); |
22 |
#define PUT_PCIV \ |
23 |
- put_user(pciv.val, &user_pciv->val); |
24 |
+ put_user(pciv.val, &user_pciv->val); |
25 |
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36) |
26 |
static int svgalib_helper_ioctl( struct inode *inode, struct file *filp, |
27 |
unsigned int cmd, unsigned long arg) { |
28 |
+#else |
29 |
+static int svgalib_helper_ioctl(struct file *filp, |
30 |
+ unsigned int cmd, unsigned long arg) { |
31 |
+#endif |
32 |
|
33 |
+ struct inode *inode=filp->f_dentry->d_inode; |
34 |
io_t iov, *user_iov=(io_t *)arg; |
35 |
pcic_t pciv, *user_pciv=(pcic_t *)arg; |
36 |
int minor = my_minor(inode->i_rdev); |
37 |
@@ -595,7 +601,11 @@ struct file_operations svgalib_helper_fo |
38 |
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,3,0) |
39 |
.owner = THIS_MODULE, |
40 |
#endif |
41 |
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36) |
42 |
.ioctl = svgalib_helper_ioctl, |
43 |
+#else |
44 |
+ .unlocked_ioctl = svgalib_helper_ioctl, |
45 |
+#endif |
46 |
.mmap = svgalib_helper_mmap, |
47 |
.open = svgalib_helper_open, |
48 |
.release = svgalib_helper_release, |