qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Laurent Vivier <lvivier@redhat.com>,
	David Gibson <david@gibson.dropbear.id.au>,
	qemu-ppc@nongnu.org, Michael Roth <mdroth@linux.vnet.ibm.com>,
	qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [Qemu-ppc] [PATCH v2] pci: allow 0 address for PCI IO/MEM regions
Date: Fri, 24 Jul 2015 00:18:27 +0300	[thread overview]
Message-ID: <20150724001710-mutt-send-email-mst@redhat.com> (raw)
In-Reply-To: <1437684537.7562.63.camel@kernel.crashing.org>

On Fri, Jul 24, 2015 at 06:48:57AM +1000, Benjamin Herrenschmidt wrote:
> On Thu, 2015-07-23 at 21:30 +0300, Michael S. Tsirkin wrote:
> > > @@ -1075,7 +1080,8 @@ static pcibus_t pci_bar_address(PCIDevice *d,
> > >          /* Check if 32 bit BAR wraps around explicitly.
> > >           * TODO: make priorities correct and remove this work
> > around.
> > >           */
> > > -        if (last_addr <= new_addr || new_addr == 0 || last_addr >=
> > UINT32_MAX) {
> > > +        if (last_addr <= new_addr || last_addr >= UINT32_MAX ||
> > > +            (!allow_0_address && new_addr == 0)) {
> > >              return PCI_BAR_UNMAPPED;
> > >          }
> 
> Talking of which, how can a BAR wrap around ? BARs are always power-of
> two aligned and naturally aligned (to their own size), they can't
> wrap...
> 
> Ben.
> 

True.

I seem to have thought it important:
https://lists.nongnu.org/archive/html/qemu-devel/2013-09/msg02594.html
but it makes no sense to me now.


-- 
MST

  reply	other threads:[~2015-07-23 21:18 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1437566099-10004-1-git-send-email-lvivier@redhat.com>
2015-07-23 18:24 ` [Qemu-devel] [PATCH v2] pci: allow 0 address for PCI IO/MEM regions Laurent Vivier
2015-07-23 18:30   ` Michael S. Tsirkin
2015-07-23 20:48     ` [Qemu-devel] [Qemu-ppc] " Benjamin Herrenschmidt
2015-07-23 21:18       ` Michael S. Tsirkin [this message]
2015-07-23 20:46   ` Benjamin Herrenschmidt
2015-07-23 21:00     ` Peter Maydell
2015-07-23 21:10       ` Michael S. Tsirkin
2015-07-23 21:19         ` Peter Maydell
2015-07-23 21:24           ` Peter Maydell
2015-07-23 21:38             ` Michael Roth
2015-07-23 21:49               ` Michael Roth
2015-07-24  8:46                 ` Peter Maydell
2015-07-24  8:58                   ` Laurent Vivier
2015-07-23 21:46       ` Benjamin Herrenschmidt
2015-07-23 22:42         ` Michael S. Tsirkin
2015-07-24  8:35 ` [Qemu-devel] [PATCH v3] " Laurent Vivier
2015-07-27  8:19   ` [Qemu-devel] [Qemu-ppc] " Laurent Vivier
2015-08-06  8:08     ` Laurent Vivier
2015-08-11  8:50     ` Alexander Graf
2015-08-11  9:04       ` Laurent Vivier

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=20150724001710-mutt-send-email-mst@redhat.com \
    --to=mst@redhat.com \
    --cc=benh@kernel.crashing.org \
    --cc=david@gibson.dropbear.id.au \
    --cc=lvivier@redhat.com \
    --cc=mdroth@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@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).