qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Avi Kivity <avi@redhat.com>
To: Blue Swirl <blauwirbel@gmail.com>
Cc: "Alexander Graf" <agraf@suse.de>,
	"Andreas Färber" <afaerber@suse.de>,
	qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH 1/2] m48t59: drop obsolete address base arithmetic
Date: Sun, 08 Jan 2012 14:16:11 +0200	[thread overview]
Message-ID: <4F09890B.9020108@redhat.com> (raw)
In-Reply-To: <CAAu8pHvgWBtox9L0xK+ygF4Hwp3aaLonKy8q_i=AzMn1DJ6dsQ@mail.gmail.com>

On 01/08/2012 01:43 PM, Blue Swirl wrote:
> On Sun, Jan 8, 2012 at 02:48, Andreas Färber <afaerber@suse.de> wrote:
> > Am 07.01.2012 18:29, schrieb Blue Swirl:
> >> On Thu, Jan 5, 2012 at 17:45, Andreas Färber <afaerber@suse.de> wrote:
> >>> Am 15.10.2011 15:50, schrieb Blue Swirl:
> >>>> Remove now incorrect address base arithmetic, missed by
> >>>> 9936d6e42392f1440505dfa9df065eabd251cadf. Fixes Sparc64 boot.
> >>>
> >>> ...but breaks PReP boot:
> >>>
> >>> ERROR: BUG caught...
> >>> BIOS execution exception
> >>> nip=0x05800000 msr=0x00002000 dar=0x00000000 dsisr=0x00000000
> >>> Stopping execution
> >>>
> >>> I verified by checking out the preceding commit, applying a variation of
> >>> http://patchwork.ozlabs.org/patch/134519/ on top; that restored PReP
> >>> boot to what it used to look like.
> >>>
> >>> Any insights?
> >>
> >> Sparc64 problem was that the io_base did not match what was passed to
> >> the functions and then the calculation made the offset totally
> >> incorrect. Could you add printfs to see what is the offset?
> >
> > info qtree:
> >
> >  dev: m48t59, id ""
> >    dev-prop: size = 8192
> >    dev-prop: type = 59
> >    dev-prop: io_base = 0x74
> >    irq 1
> >    mmio ffffffffffffffff/0000000000002000
> >
> > #define DEBUG_NVRAM:
> >
> > NVRAM_writeb: 0x00000074 => 0x00000000
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000001
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000002
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000003
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000004
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000005
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000006
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000007
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000008
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x00000009
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x0000000a
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x0000000b
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x0000000c
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x0000000d
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x0000000e
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
> > NVRAM_writeb: 0x00000074 => 0x0000000f
> > NVRAM_writeb: 0x00000075 => 0x00000000
> > NVRAM_readb: 0x00000077 <= 0xffffffff
>
> This is what happens on Sparc64:
> NVRAM_writeb: 0x00000000 => 0x00000000
> NVRAM_writeb: 0x00000001 => 0x00000000
> NVRAM_readb: 0x00000003 <= 0x00000070
> NVRAM_writeb: 0x00000000 => 0x00000001
> NVRAM_writeb: 0x00000001 => 0x00000000
> NVRAM_readb: 0x00000003 <= 0x0000001a
> NVRAM_writeb: 0x00000000 => 0x00000002
> NVRAM_writeb: 0x00000001 => 0x00000000
> NVRAM_readb: 0x00000003 <= 0x00000000
> NVRAM_writeb: 0x00000000 => 0x00000003
> NVRAM_writeb: 0x00000001 => 0x00000000
> NVRAM_readb: 0x00000003 <= 0x00000002
> NVRAM_writeb: 0x00000000 => 0x00000004
> NVRAM_writeb: 0x00000001 => 0x00000000
> NVRAM_readb: 0x00000003 <= 0x00000073
> NVRAM_writeb: 0x00000000 => 0x00000005
> NVRAM_writeb: 0x00000001 => 0x00000000
> NVRAM_readb: 0x00000003 <= 0x00000079
> NVRAM_writeb: 0x00000000 => 0x00000006
> NVRAM_writeb: 0x00000001 => 0x00000000
> NVRAM_readb: 0x00000003 <= 0x00000073
> NVRAM_writeb: 0x00000000 => 0x00000007
> NVRAM_writeb: 0x00000001 => 0x00000000
>
> I/O base offset is kept with PIO but removed from MMIO, which is not
> consistent. Avi, could we fix this?

Yes, I'll work on it.

-- 
error compiling committee.c: too many arguments to function

      reply	other threads:[~2012-01-08 12:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-15 13:50 [Qemu-devel] [PATCH 1/2] m48t59: drop obsolete address base arithmetic Blue Swirl
2012-01-05 17:45 ` Andreas Färber
2012-01-07 17:29   ` Blue Swirl
2012-01-08  2:48     ` Andreas Färber
2012-01-08 11:43       ` Blue Swirl
2012-01-08 12:16         ` Avi Kivity [this message]

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=4F09890B.9020108@redhat.com \
    --to=avi@redhat.com \
    --cc=afaerber@suse.de \
    --cc=agraf@suse.de \
    --cc=blauwirbel@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).