r2709 - trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches
Andres Salomon
dilinger-guest@costa.debian.org
Mon, 14 Mar 2005 11:43:04 +0100
Author: dilinger-guest
Date: 2005-03-14 11:43:03 +0100 (Mon, 14 Mar 2005)
New Revision: 2709
Modified:
trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/143-sysfs_write_file_signedness_problem.dpatch
Log:
make 143 apply
Modified: trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/143-sysfs_write_file_signedness_problem.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/143-sysfs_write_file_signedness_problem.dpatch 2005-03-14 10:18:52 UTC (rev 2708)
+++ trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/143-sysfs_write_file_signedness_problem.dpatch 2005-03-14 10:43:03 UTC (rev 2709)
@@ -1,24 +1,22 @@
diff -Naru a/fs/sysfs/file.c b/fs/sysfs/file.c
--- a/fs/sysfs/file.c 2005-03-09 20:20:22 -08:00
+++ b/fs/sysfs/file.c 2005-03-09 20:20:22 -08:00
-@@ -231,15 +231,16 @@
+@@ -231,13 +231,14 @@
sysfs_write_file(struct file *file, const char __user *buf, size_t count, loff_t *ppos)
{
struct sysfs_buffer * buffer = file->private_data;
+ ssize_t len;
- down(&buffer->sem);
- count = fill_write_buffer(buffer,buf,count);
- if (count > 0)
-- count = flush_write_buffer(file->f_dentry,buffer,count);
+- count = flush_write_buffer(file,buffer,count);
- if (count > 0)
- *ppos += count;
+ len = fill_write_buffer(buffer, buf, count);
+ if (len > 0)
-+ len = flush_write_buffer(file->f_dentry, buffer, len);
++ len = flush_write_buffer(file, buffer, len);
+ if (len > 0)
+ *ppos += len;
- up(&buffer->sem);
- return count;
+ return len;
}