Re: [PATCHv2] x86: Use v8086_mode helper, trivial unification

2008-01-18 Thread H. Peter Anvin
Harvey Harrison wrote: On Fri, 2008-01-18 at 16:00 +0100, Ingo Molnar wrote: + /* +* Did it hit the DOS screen memory VA from vm86 mode? +*/ + if (v8086_mode(regs)) { + unsigned long bit = (address - 0xA) >> PAGE_SHIFT; + if (bit < 32)

Re: [PATCHv2] x86: Use v8086_mode helper, trivial unification

2008-01-18 Thread Harvey Harrison
On Fri, 2008-01-18 at 16:00 +0100, Ingo Molnar wrote: > > > + /* > > > + * Did it hit the DOS screen memory VA from vm86 mode? > > > + */ > > > + if (v8086_mode(regs)) { > > > + unsigned long bit = (address - 0xA) >> PAGE_SHIFT; > > > + if (bit < 32) > > > + ts

Re: [PATCHv2] x86: Use v8086_mode helper, trivial unification

2008-01-18 Thread Ingo Molnar
> > + /* > > +* Did it hit the DOS screen memory VA from vm86 mode? > > +*/ > > + if (v8086_mode(regs)) { > > + unsigned long bit = (address - 0xA) >> PAGE_SHIFT; > > + if (bit < 32) > > + tsk->thread.screen_bitmap |= 1 << bit; > > + } this

Re: [PATCHv2] x86: Use v8086_mode helper, trivial unification

2008-01-18 Thread Harvey Harrison
On Fri, 2008-01-18 at 10:12 +0100, Ingo Molnar wrote: > * Harvey Harrison <[EMAIL PROTECTED]> wrote: > > > 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 > > > - if (regs->flags & VM_MASK) { > > + if (v8086_mode(regs

Re: [PATCHv2] x86: Use v8086_mode helper, trivial unification

2008-01-18 Thread Ingo Molnar
* Harvey Harrison <[EMAIL PROTECTED]> wrote: > 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 > - if (regs->flags & VM_MASK) { > + if (v8086_mode(regs)) { > --- a/arch/x86/mm/fault_64.c > +++ b/arch/x86/mm/fault_

[PATCHv2] x86: Use v8086_mode helper, trivial unification

2008-01-17 Thread Harvey Harrison
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]> --- HPA noted that v8086_mode is always zero on X86_64, no ifdef needed. arch/x86/mm/fault_32.c |3 ++- arch/x86/mm/fault_