Re: [Qemu-devel] [PATCH 5/5] target-i386: Move user-mode exception actions out of user-exec.c

2016-05-17 Thread Peter Maydell
On 16 May 2016 at 18:54, Sergey Fedorov wrote: > On 16/05/16 19:09, Peter Maydell wrote: >> The exception_action() function in user-exec.c is just a call to >> cpu_loop_exit() for every target CPU except i386. Since this >> function is only called if the target's handle_mmu_fault() hook has >> in

Re: [Qemu-devel] [PATCH 5/5] target-i386: Move user-mode exception actions out of user-exec.c

2016-05-16 Thread Peter Maydell
On 16 May 2016 at 19:33, Peter Maydell wrote: > On 16 May 2016 at 18:54, Sergey Fedorov wrote: >> 'env->eip' was updated by restore_state_to_opc() from >> cpu_restore_state_from_tb() from cpu_restore_state() from >> handle_cpu_signal() _after_ calling 'handle_mmu_fault' hook but _before_ >> calli

Re: [Qemu-devel] [PATCH 5/5] target-i386: Move user-mode exception actions out of user-exec.c

2016-05-16 Thread Peter Maydell
On 16 May 2016 at 18:54, Sergey Fedorov wrote: > On 16/05/16 19:09, Peter Maydell wrote: >> The exception_action() function in user-exec.c is just a call to >> cpu_loop_exit() for every target CPU except i386. Since this >> function is only called if the target's handle_mmu_fault() hook has >> in

Re: [Qemu-devel] [PATCH 5/5] target-i386: Move user-mode exception actions out of user-exec.c

2016-05-16 Thread Sergey Fedorov
On 16/05/16 19:09, Peter Maydell wrote: > The exception_action() function in user-exec.c is just a call to > cpu_loop_exit() for every target CPU except i386. Since this > function is only called if the target's handle_mmu_fault() hook has > indicated an MMU fault, and that hook is only called fro

[Qemu-devel] [PATCH 5/5] target-i386: Move user-mode exception actions out of user-exec.c

2016-05-16 Thread Peter Maydell
The exception_action() function in user-exec.c is just a call to cpu_loop_exit() for every target CPU except i386. Since this function is only called if the target's handle_mmu_fault() hook has indicated an MMU fault, and that hook is only called from the handle_cpu_signal() code path, we can simp