From: "andrzej zaborowski" <balrogg@gmail.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Re: MMIO address changes
Date: Thu, 25 Dec 2008 23:33:56 +0100 [thread overview]
Message-ID: <fb249edb0812251433r2560652aga15f2c2fb0985d52@mail.gmail.com> (raw)
In-Reply-To: <ghqkh7$5os$1@ger.gmane.org>
2008/12/11 Vladimir Prus <vladimir@codesourcery.com>:
> Paul Brook wrote:
>
>> I've just committed a patch that changes the MMIO callback interface for
>> devices. Instead of being passed an absolute address these are now passed an
>> offset from the start[1] of the memory region that was registered.
> ...
>> [1] It's actually the offset from the start of the first page of that region.
>> In practice this difference doesn't matter, and makes the implementation a
>> lot simpler.
>
> This breaks something for me. I have:
>
> smc91c111_init(&nd_table[0], (0xb4000000 + 0x01800000 + 0x300) & 0x1fffffff,
> get_irq(s, 7));
>
> and smc91c111_init presently does:
>
> cpu_register_physical_memory(base, 16, iomemtype);
>
> and smc emulation promptly dies because an access with address of 0x30e is made,
> with 0x300 apparently being the offset from the page start, with 0xe being the desired
> offset. What is the cleanest way to address this? Reverting your change to
> sms91c111.c works, fwiw.
Masking the address with 15 should be acceptable for smc91c111.c I
think. The other possibility is reverting the change to keep
subtracting the base address, but which would be masked with
TARGET_PAGE_MASK.
Cheers
prev parent reply other threads:[~2008-12-25 22:34 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-01 18:59 [Qemu-devel] MMIO address changes Paul Brook
2008-12-02 16:47 ` takasi-y
2008-12-02 17:09 ` Paul Brook
2008-12-02 17:10 ` Paul Brook
2008-12-03 14:37 ` [Qemu-devel] [PATCH] sh4: Followup to commit #5849 "Change MMIO callbacks..." takasi-y
2008-12-10 17:44 ` [Qemu-devel] " Vladimir Prus
2008-12-14 16:54 ` takasi-y
2008-12-03 12:17 ` [Qemu-devel] MMIO address changes Edgar E. Iglesias
2008-12-03 14:03 ` Paul Brook
2008-12-07 20:24 ` Edgar E. Iglesias
2009-01-07 15:39 ` Edgar E. Iglesias
2008-12-05 13:52 ` [Qemu-devel] [PATCH] usb-ohci: Add address masking takasi-y
2008-12-07 16:05 ` andrzej zaborowski
2008-12-08 13:04 ` Paul Brook
2008-12-08 10:15 ` Thomas Bandelier
2008-12-09 15:21 ` takasi-y
2008-12-11 8:55 ` [Qemu-devel] Re: MMIO address changes Vladimir Prus
2008-12-25 22:33 ` andrzej zaborowski [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=fb249edb0812251433r2560652aga15f2c2fb0985d52@mail.gmail.com \
--to=balrogg@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).