From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56708) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YnHFo-000813-3J for qemu-devel@nongnu.org; Tue, 28 Apr 2015 21:57:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YnHFk-0006Hf-QK for qemu-devel@nongnu.org; Tue, 28 Apr 2015 21:57:36 -0400 Date: Wed, 29 Apr 2015 11:51:36 +1000 From: David Gibson Message-ID: <20150429015136.GB32589@voom.redhat.com> References: <1429684100-13354-1-git-send-email-mdroth@linux.vnet.ibm.com> <1429684100-13354-15-git-send-email-mdroth@linux.vnet.ibm.com> <20150428073103.GD24753@voom.redhat.com> <20150428103406-mutt-send-email-mst@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="uZ3hkaAS1mZxFaxD" Content-Disposition: inline In-Reply-To: <20150428103406-mutt-send-email-mst@redhat.com> Subject: Re: [Qemu-devel] [PATCH v8 14/16] pci: make pci_bar useable outside pci.c List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Michael S. Tsirkin" Cc: qemu-devel@nongnu.org, aik@ozlabs.ru, agraf@suse.de, Michael Roth , qemu-ppc@nongnu.org, tyreld@linux.vnet.ibm.com, bharata.rao@gmail.com, nfont@linux.vnet.ibm.com --uZ3hkaAS1mZxFaxD Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Apr 28, 2015 at 10:37:08AM +0200, Michael S. Tsirkin wrote: > On Tue, Apr 28, 2015 at 05:31:03PM +1000, David Gibson wrote: > > On Wed, Apr 22, 2015 at 01:28:18AM -0500, Michael Roth wrote: > > > We need to work with PCI BARs to generate OF properties > > > during PCI hotplug for sPAPR guests. > > >=20 > > > Signed-off-by: Michael Roth > > > Reviewed-by: David Gibson > > > Cc: mst@redhat.com > >=20 > > Michael Tsirkin, > >=20 > > Interested to see your comment on this. Are you ok with this? Can > > you take this through your tree? Because it affects general PCI code, >=20 > I'm not too happy but I just chulk it up as > "yet another spapr weirdness". Ok. > I'd like a comment added, see below. > With that >=20 > Acked-by: Michael S. Tsirkin Sorry, not entirely clear on your suggested plan here. Are you saying resend with the adjusted comment and you'll push it through your tree, or that I should take it through my tree (with the adjusted comment)? >=20 > > I'm not really comfortable merging this through my spapr-next tree, > > which is where I plan to put all the rest. > >=20 > > > --- > > > hw/pci/pci.c | 2 +- > > > include/hw/pci/pci.h | 1 + > > > 2 files changed, 2 insertions(+), 1 deletion(-) > > >=20 > > > diff --git a/hw/pci/pci.c b/hw/pci/pci.c > > > index 6941a82..7d14657 100644 > > > --- a/hw/pci/pci.c > > > +++ b/hw/pci/pci.c > > > @@ -123,7 +123,7 @@ static uint16_t pci_default_sub_device_id =3D PCI= _SUBDEVICE_ID_QEMU; > > > =20 > > > static QLIST_HEAD(, PCIHostState) pci_host_bridges; > > > =20 > > > -static int pci_bar(PCIDevice *d, int reg) > > > +int pci_bar(PCIDevice *d, int reg) >=20 >=20 > Please add a comment >=20 > /* > * Should not normally be used by devices. For use by > * sPAPR target where QEMU emulates firmware. > */ >=20 > > > { > > > uint8_t type; > > > =20 > > > diff --git a/include/hw/pci/pci.h b/include/hw/pci/pci.h > > > index be2d9b8..1a4e0be 100644 > > > --- a/include/hw/pci/pci.h > > > +++ b/include/hw/pci/pci.h > > > @@ -332,6 +332,7 @@ void pci_device_save(PCIDevice *s, QEMUFile *f); > > > int pci_device_load(PCIDevice *s, QEMUFile *f); > > > MemoryRegion *pci_address_space(PCIDevice *dev); > > > MemoryRegion *pci_address_space_io(PCIDevice *dev); > > > +int pci_bar(PCIDevice *d, int reg); > > > =20 > > > typedef void (*pci_set_irq_fn)(void *opaque, int irq_num, int level); > > > typedef int (*pci_map_irq_fn)(PCIDevice *pci_dev, int irq_num); > >=20 >=20 >=20 --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --uZ3hkaAS1mZxFaxD Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJVQDknAAoJEGw4ysog2bOS43oP/0Kb+iUkxTY2G4dHfT11+jyr m/WeI77KwiGMVQfTOU+IVB38TrHi9xhcUjZffE7Gl3JQrXwpAix4R7XOhleYmRLg G2a8YJHNs0nqhNS/Y6eMotV1A7AOkOBGJrW8HCAVm+1LPQFWpM74hXPO5cchRbVg quCj6OI2jduAyteof+1TO8fduQjrYd3r9fhv0SQ8F7JZzypdxfqqqblzmz860CDK 59tlnm2RtsEE/XBtucCeWC3rWa0rvbLqlKniJ1n3OFdERr5leryJNSFxmPgCEy4d zfyW/qwzOoWk7B/m55r2d3yE0XiQtqukamcEpSOlZCY3nv/sNWLd7csKmnQQJFuB spa3MzH0mtRCOSkbqUBtpLWh7wXceBqNZ9oXNBa/USUpDyJ+MVZIIJsb3IHlo7eG PEFl28Vdv4/dNMlLx2m2l0VN60QBdCGqer8nQZhQA9rY5yIuWezC8I7l2K5277Hp LR1j3Y+PwvdyTJAVw2bM+RX8+DleDQDT8mFNu1/R+OKbObL77TPoIxBsGeiRKOUF 3q6xtEANq0r87wHnpPRK7D4hh9+p7QJBxLMWWGf7bp4Xu2f9iDlzTqlaugAc4O9W mjcnFe0WUnvlAJFVAN/yWrf1wdSvEoGUEVM/78rqRiZiuLofotIxs0NXw3Jq4Nhc indxmnYkmQR7JOlSi8Md =gzb0 -----END PGP SIGNATURE----- --uZ3hkaAS1mZxFaxD--