All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
To: Alistair Francis <alistair.francis@xilinx.com>
Cc: edgar.iglesias@xilinx.com, crosthwaitepeter@gmail.com,
	qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v1 1/1] target-microblaze: Set the PC in reset instead of realize
Date: Sat, 25 Jul 2015 12:45:08 +1000	[thread overview]
Message-ID: <20150725024508.GB3976@toto> (raw)
In-Reply-To: <5eded8311c4c16ac22956810a68497424d9ee62c.1437612120.git.alistair.francis@xilinx.com>

On Thu, Jul 23, 2015 at 08:13:56AM -0700, Alistair Francis wrote:
> Set the Microblaze CPU PC in the reset instead of setting it
> in the realize. This is required as the PC is zeroed in the
> reset function and causes problems in some situations.
> 
> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>

Looks good:

Reviewed-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>

I'll test and add this to my queue.


> ---
> 
>  target-microblaze/cpu.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/target-microblaze/cpu.c b/target-microblaze/cpu.c
> index 9ac509a..cbd84a2 100644
> --- a/target-microblaze/cpu.c
> +++ b/target-microblaze/cpu.c
> @@ -107,6 +107,8 @@ static void mb_cpu_reset(CPUState *s)
>      /* Disable stack protector.  */
>      env->shr = ~0;
>  
> +    env->sregs[SR_PC] = cpu->cfg.base_vectors;
> +
>  #if defined(CONFIG_USER_ONLY)
>      /* start in user mode with interrupts enabled.  */
>      env->sregs[SR_MSR] = MSR_EE | MSR_IE | MSR_VM | MSR_UM;
> @@ -183,8 +185,6 @@ static void mb_cpu_realizefn(DeviceState *dev, Error **errp)
>      env->pvr.regs[10] = 0x0c000000; /* Default to spartan 3a dsp family.  */
>      env->pvr.regs[11] = PVR11_USE_MMU | (16 << 17);
>  
> -    env->sregs[SR_PC] = cpu->cfg.base_vectors;
> -
>      mcc->parent_realize(dev, errp);
>  }
>  
> -- 
> 1.7.1
> 

  reply	other threads:[~2015-07-25  2:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-23 15:13 [Qemu-devel] [PATCH v1 1/1] target-microblaze: Set the PC in reset instead of realize Alistair Francis
2015-07-25  2:45 ` Edgar E. Iglesias [this message]
2015-10-02  1:02   ` Edgar E. Iglesias

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150725024508.GB3976@toto \
    --to=edgar.iglesias@gmail.com \
    --cc=alistair.francis@xilinx.com \
    --cc=crosthwaitepeter@gmail.com \
    --cc=edgar.iglesias@xilinx.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.