From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:38884) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QBtcL-0002Wz-0y for qemu-devel@nongnu.org; Mon, 18 Apr 2011 14:56:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QBtcJ-0001N8-OP for qemu-devel@nongnu.org; Mon, 18 Apr 2011 14:56:12 -0400 Received: from hall.aurel32.net ([88.191.126.93]:54395) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QBtcJ-0001N1-Ht for qemu-devel@nongnu.org; Mon, 18 Apr 2011 14:56:11 -0400 Date: Mon, 18 Apr 2011 20:56:09 +0200 From: Aurelien Jarno Message-ID: <20110418185609.GH16178@volta.aurel32.net> References: <1302881578-5357-1-git-send-email-agraf@suse.de> <1302881578-5357-8-git-send-email-agraf@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <1302881578-5357-8-git-send-email-agraf@suse.de> Subject: Re: [Qemu-devel] [PATCH 07/17] s390x: Enable s390x-softmmu target List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alexander Graf Cc: peter.maydell@linaro.org, QEMU-devel Developers , Richard Henderson On Fri, Apr 15, 2011 at 05:32:48PM +0200, Alexander Graf wrote: > This patch adds some code paths for running s390x guest OSs without the > need for KVM. > > Signed-off-by: Alexander Graf > > --- > > v3 -> v4: > > - declare non-working when EXT is masked > - remove obsolete cpu_halted > --- > cpu-exec.c | 8 ++++++++ > target-s390x/exec.h | 11 ++++++++++- > target-s390x/helper.c | 4 ++++ > 3 files changed, 22 insertions(+), 1 deletions(-) Thanks for the fixes. This patch hasn't really changed since the last review, so I have just applied it. This way we can concentrate on the remaining patches. > diff --git a/cpu-exec.c b/cpu-exec.c > index 5d6c9a8..d57afef 100644 > --- a/cpu-exec.c > +++ b/cpu-exec.c > @@ -346,6 +346,8 @@ int cpu_exec(CPUState *env1) > do_interrupt(env); > #elif defined(TARGET_M68K) > do_interrupt(0); > +#elif defined(TARGET_S390X) > + do_interrupt(env); > #endif > env->exception_index = -1; > #endif > @@ -560,6 +562,12 @@ int cpu_exec(CPUState *env1) > do_interrupt(1); > next_tb = 0; > } > +#elif defined(TARGET_S390X) && !defined(CONFIG_USER_ONLY) > + if ((interrupt_request & CPU_INTERRUPT_HARD) && > + (env->psw.mask & PSW_MASK_EXT)) { > + do_interrupt(env); > + next_tb = 0; > + } > #endif > /* Don't use the cached interupt_request value, > do_interrupt may have updated the EXITTB flag. */ > diff --git a/target-s390x/exec.h b/target-s390x/exec.h > index f7893f3..7a87fff 100644 > --- a/target-s390x/exec.h > +++ b/target-s390x/exec.h > @@ -31,7 +31,16 @@ register struct CPUS390XState *env asm(AREG0); > > static inline int cpu_has_work(CPUState *env) > { > - return env->interrupt_request & CPU_INTERRUPT_HARD; // guess > + return ((env->interrupt_request & CPU_INTERRUPT_HARD) && > + (env->psw.mask & PSW_MASK_EXT)); > +} > + > +static inline void regs_to_env(void) > +{ > +} > + > +static inline void env_to_regs(void) > +{ > } > > static inline void cpu_pc_from_tb(CPUState *env, TranslationBlock* tb) > diff --git a/target-s390x/helper.c b/target-s390x/helper.c > index 4a5297b..629dfd9 100644 > --- a/target-s390x/helper.c > +++ b/target-s390x/helper.c > @@ -82,3 +82,7 @@ int cpu_s390x_handle_mmu_fault (CPUState *env, target_ulong address, int rw, > return 0; > } > #endif /* CONFIG_USER_ONLY */ > + > +void do_interrupt (CPUState *env) > +{ > +} > -- > 1.6.0.2 > > > > -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurelien@aurel32.net http://www.aurel32.net