Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=d729ab35ee1367b7690458ae9e050571cb055bd3
Commit:     d729ab35ee1367b7690458ae9e050571cb055bd3
Parent:     5f5cd8fd60c71ce47d2ce4e60e7ccbc306e91c64
Author:     Harvey Harrison <[EMAIL PROTECTED]>
AuthorDate: Wed Jan 30 13:33:23 2008 +0100
Committer:  Ingo Molnar <[EMAIL PROTECTED]>
CommitDate: Wed Jan 30 13:33:23 2008 +0100

    x86: use v8086_mode helper, trivial unification
    
    Use v8086_mode inline in fault_32.c, no functional change
    also ifdef the section for 32-bit only and add to fault_64.c
    
    Signed-off-by: Harvey Harrison <[EMAIL PROTECTED]>
    Signed-off-by: Ingo Molnar <[EMAIL PROTECTED]>
    Signed-off-by: Thomas Gleixner <[EMAIL PROTECTED]>
---
 arch/x86/mm/fault_32.c |    4 +++-
 arch/x86/mm/fault_64.c |   11 +++++++++++
 2 files changed, 14 insertions(+), 1 deletions(-)

diff --git a/arch/x86/mm/fault_32.c b/arch/x86/mm/fault_32.c
index 276863d..93ede2d 100644
--- a/arch/x86/mm/fault_32.c
+++ b/arch/x86/mm/fault_32.c
@@ -475,14 +475,16 @@ good_area:
        else
                tsk->min_flt++;
 
+#ifdef CONFIG_X86_32
        /*
         * Did it hit the DOS screen memory VA from vm86 mode?
         */
-       if (regs->flags & VM_MASK) {
+       if (v8086_mode(regs)) {
                unsigned long bit = (address - 0xA0000) >> PAGE_SHIFT;
                if (bit < 32)
                        tsk->thread.screen_bitmap |= 1 << bit;
        }
+#endif
        up_read(&mm->mmap_sem);
        return;
 
diff --git a/arch/x86/mm/fault_64.c b/arch/x86/mm/fault_64.c
index 9ef0306..2d9e6da 100644
--- a/arch/x86/mm/fault_64.c
+++ b/arch/x86/mm/fault_64.c
@@ -514,6 +514,17 @@ good_area:
                tsk->maj_flt++;
        else
                tsk->min_flt++;
+
+#ifdef CONFIG_X86_32
+       /*
+        * Did it hit the DOS screen memory VA from vm86 mode?
+        */
+       if (v8086_mode(regs)) {
+               unsigned long bit = (address - 0xA0000) >> PAGE_SHIFT;
+               if (bit < 32)
+                       tsk->thread.screen_bitmap |= 1 << bit;
+       }
+#endif
        up_read(&mm->mmap_sem);
        return;
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to