diff options
author | Paul Mackerras <paulus@samba.org> | 2007-04-12 13:50:03 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2007-04-12 13:50:03 -0400 |
commit | e049d1ca3094f3d1d94617f456a9961202f96e3a (patch) | |
tree | a30397ad22f2fbea268bd28fa69c60aad9dfa62a /arch/i386/lib/usercopy.c | |
parent | edfac96a92b88d3b0b53e3f8231b74beee9ecd1d (diff) | |
parent | 80584ff3b99c36ead7e130e453b3a48b18072d18 (diff) |
Merge branch 'linux-2.6' into for-2.6.22
Diffstat (limited to 'arch/i386/lib/usercopy.c')
-rw-r--r-- | arch/i386/lib/usercopy.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/i386/lib/usercopy.c b/arch/i386/lib/usercopy.c index d22cfc9d656c..086b3726862a 100644 --- a/arch/i386/lib/usercopy.c +++ b/arch/i386/lib/usercopy.c | |||
@@ -10,6 +10,7 @@ | |||
10 | #include <linux/blkdev.h> | 10 | #include <linux/blkdev.h> |
11 | #include <linux/module.h> | 11 | #include <linux/module.h> |
12 | #include <linux/backing-dev.h> | 12 | #include <linux/backing-dev.h> |
13 | #include <linux/interrupt.h> | ||
13 | #include <asm/uaccess.h> | 14 | #include <asm/uaccess.h> |
14 | #include <asm/mmx.h> | 15 | #include <asm/mmx.h> |
15 | 16 | ||
@@ -719,6 +720,14 @@ unsigned long __copy_to_user_ll(void __user *to, const void *from, | |||
719 | #ifndef CONFIG_X86_WP_WORKS_OK | 720 | #ifndef CONFIG_X86_WP_WORKS_OK |
720 | if (unlikely(boot_cpu_data.wp_works_ok == 0) && | 721 | if (unlikely(boot_cpu_data.wp_works_ok == 0) && |
721 | ((unsigned long )to) < TASK_SIZE) { | 722 | ((unsigned long )to) < TASK_SIZE) { |
723 | /* | ||
724 | * When we are in an atomic section (see | ||
725 | * mm/filemap.c:file_read_actor), return the full | ||
726 | * length to take the slow path. | ||
727 | */ | ||
728 | if (in_atomic()) | ||
729 | return n; | ||
730 | |||
722 | /* | 731 | /* |
723 | * CPU does not honor the WP bit when writing | 732 | * CPU does not honor the WP bit when writing |
724 | * from supervisory mode, and due to preemption or SMP, | 733 | * from supervisory mode, and due to preemption or SMP, |