diff options
author | Jon Smirl <jonsmirl@gmail.com> | 2005-06-14 09:54:54 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2005-06-20 15:15:38 -0700 |
commit | 9d9d27fb651a7c95a46f276bacb4329db47470a6 (patch) | |
tree | cf25134082cb61e860f65af73adc91674ec74258 /fs/sysfs/file.c | |
parent | 42b16c051c3f462095fb8c9bad1bc05b34518cb9 (diff) | |
download | kernel_samsung_smdk4412-9d9d27fb651a7c95a46f276bacb4329db47470a6.tar.gz kernel_samsung_smdk4412-9d9d27fb651a7c95a46f276bacb4329db47470a6.tar.bz2 kernel_samsung_smdk4412-9d9d27fb651a7c95a46f276bacb4329db47470a6.zip |
[PATCH] SYSFS: fix PAGE_SIZE check
Without this change I can't set an attribute exactly PAGE_SIZE in
length. There is no need for zero termination because the interface
uses lengths.
From: Jon Smirl <jonsmirl@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'fs/sysfs/file.c')
-rw-r--r-- | fs/sysfs/file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/sysfs/file.c b/fs/sysfs/file.c index 1481cae7d99..849aac11546 100644 --- a/fs/sysfs/file.c +++ b/fs/sysfs/file.c @@ -182,7 +182,7 @@ fill_write_buffer(struct sysfs_buffer * buffer, const char __user * buf, size_t return -ENOMEM; if (count >= PAGE_SIZE) - count = PAGE_SIZE - 1; + count = PAGE_SIZE; error = copy_from_user(buffer->page,buf,count); buffer->needs_read_fill = 1; return error ? -EFAULT : count; |