lkml.org 
[lkml]   [2015]   [Jul]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 4/8] x86/vm86: Use the normal pt_regs area for vm86
From
On Wed, Jul 29, 2015 at 10:36 AM, Brian Gerst <brgerst@gmail.com> wrote:
>
> I think I remember now what the issue was. Since entering vm86 mode
> uses force_iret(), the work_pending code path was being taken. I had
> to move the call to save_v86_state out of here to handle_signal(),
> otherwise it would just restore the 32-bit regs and exit the syscall
> without ever entering vm86 mode. But that meant that the test for
> kernel CS was seeing the vm86 regs instead of 32-bit regs, and was
> failing because it didn't account for the VM bit (if the real-mode CS
> looked like RPL 0). A fault would get stuck in a loop because it
> couldn't exit to the signal handling code.

Hmm. I think we'd want a big comment about that code then, and how it
is only used for user-space (including vm86 mode).

Linus


\
 
 \ /
  Last update: 2015-07-29 21:21    [W:0.129 / U:0.076 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site