From: "Michael S. Tsirkin" <mst@redhat.com>
To: Blue Swirl <blauwirbel@gmail.com>
Cc: qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: comments on: get page size in device init
Date: Wed, 23 Sep 2009 22:13:40 +0300 [thread overview]
Message-ID: <20090923191340.GB18947@redhat.com> (raw)
In-Reply-To: <f43fc5580909231203l2b80116bi120efaa2752ca867@mail.gmail.com>
On Wed, Sep 23, 2009 at 10:03:26PM +0300, Blue Swirl wrote:
> On Wed, Sep 23, 2009 at 9:40 PM, Michael S. Tsirkin <mst@redhat.com> wrote:
> > On Wed, Sep 23, 2009 at 01:02:56PM -0500, Anthony Liguori wrote:
> >> Blue Swirl wrote:
> >>> On Wed, Sep 23, 2009 at 3:58 PM, Michael S. Tsirkin <mst@redhat.com> wrote:
> >>>
> >>>>> Compile msix only once
> >>>>>
> >>>>> Get page size in device init.
> >>>>>
> >>>>> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
> >>>>>
> >>>> What was the motivation for the page size change?
> >>>>
> >>>
> >>> "Compile msix only once"
> >>>
> >>>
> >>>> It seems the only user passes TARGET_PAGE_SIZE anyway,
> >>>> using a constant seems clearer and probably generates
> >>>> less code. No?
> >>>>
> >>>
> >>> Yes, but then the code would depend on TARGET_PAGE_SIZE, making it
> >>> impossible to compile the code only once.
> >>>
> >>
> >> We could probably get away with doing
> >>
> >> #define TARGET_PAGE_SIZE target_get_page_size()
> >>
> >> And take care of a big chunk of this without passing page size
> >> parameters around.
> >
> >
> > Sounds good.
>
> That would work and target_get_page_size() together with
> get_ram_size() would also handle the virtio case nicely, except for
> the if (!kvm_enabled() || kvm_has_sync_mmu()) part.
Where's get_ram_size needed?
--
MST
next prev parent reply other threads:[~2009-09-23 19:15 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-23 12:58 [Qemu-devel] comments on: get page size in device init Michael S. Tsirkin
2009-09-23 17:07 ` [Qemu-devel] " Blue Swirl
2009-09-23 18:02 ` Anthony Liguori
2009-09-23 18:40 ` Michael S. Tsirkin
2009-09-23 19:03 ` Blue Swirl
2009-09-23 19:13 ` Michael S. Tsirkin [this message]
2009-09-23 19:59 ` Blue Swirl
2009-09-23 19:19 ` Michael S. Tsirkin
2009-09-23 20:35 ` Anthony Liguori
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=20090923191340.GB18947@redhat.com \
--to=mst@redhat.com \
--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).