[Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-08 Thread Yijing Wang
From: Arnd Bergmann Use pci_scan_root_bus() instead of deprecated function pci_scan_bus_parented(). Signed-off-by: Arnd Bergmann Signed-off-by: Yijing Wang CC: Konrad Rzeszutek Wilk CC: xen-de...@lists.xenproject.org Signed-off-by: Bjorn Helgaas --- drivers/pci/xen-pcifront.c | 12 +++

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-11 Thread Bjorn Helgaas
On Mon, Mar 09, 2015 at 10:34:01AM +0800, Yijing Wang wrote: > From: Arnd Bergmann > > Use pci_scan_root_bus() instead of deprecated function > pci_scan_bus_parented(). > > Signed-off-by: Arnd Bergmann > Signed-off-by: Yijing Wang > CC: Konrad Rzeszutek Wilk > CC: xen-de...@lists.xenproject.o

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-12 Thread Yijing Wang
>> struct pci_bus *b; >> +LIST_HEAD(resources); >> struct pcifront_sd *sd = NULL; >> struct pci_bus_entry *bus_entry = NULL; >> int err = 0; >> @@ -470,17 +472,21 @@ static int pcifront_scan_root(struct pcifront_device >> *pdev, >> err = -ENOMEM; >>

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-12 Thread Bjorn Helgaas
On Thu, Mar 12, 2015 at 07:46:45PM +0800, Yijing Wang wrote: > >>struct pci_bus *b; > >> + LIST_HEAD(resources); > >>struct pcifront_sd *sd = NULL; > >>struct pci_bus_entry *bus_entry = NULL; > >>int err = 0; > >> @@ -470,17 +472,21 @@ static int pcifront_scan_root(struct pcifront_

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-12 Thread Yijing Wang
+ pci_add_resource(&resources, &ioport_resource); + pci_add_resource(&resources, &iomem_resource); + pci_add_resource(&resources, &busn_resource); >>> >>> Since I don't want to export busn_resource, you might have to allocate your >>> own struct resource for it here. And, of cour

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-13 Thread Bjorn Helgaas
On Thu, Mar 12, 2015 at 9:36 PM, Yijing Wang wrote: > + pci_add_resource(&resources, &ioport_resource); > + pci_add_resource(&resources, &iomem_resource); > + pci_add_resource(&resources, &busn_resource); Since I don't want to export busn_resource, you might have to alloca

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-13 Thread Konrad Rzeszutek Wilk
On Fri, Mar 13, 2015 at 08:24:58AM -0500, Bjorn Helgaas wrote: > On Thu, Mar 12, 2015 at 9:36 PM, Yijing Wang wrote: > > + pci_add_resource(&resources, &ioport_resource); > > + pci_add_resource(&resources, &iomem_resource); > > + pci_add_resource(&resources, &busn_resource); >

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-13 Thread Bjorn Helgaas
On Fri, Mar 13, 2015 at 9:01 AM, Konrad Rzeszutek Wilk wrote: > On Fri, Mar 13, 2015 at 08:24:58AM -0500, Bjorn Helgaas wrote: >> On Thu, Mar 12, 2015 at 9:36 PM, Yijing Wang wrote: >> > + pci_add_resource(&resources, &ioport_resource); >> > + pci_add_resource(&resources, &iomem_resourc

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-25 Thread Konrad Rzeszutek Wilk
On Fri, Mar 13, 2015 at 09:26:08AM -0500, Bjorn Helgaas wrote: > On Fri, Mar 13, 2015 at 9:01 AM, Konrad Rzeszutek Wilk > wrote: > > On Fri, Mar 13, 2015 at 08:24:58AM -0500, Bjorn Helgaas wrote: > >> On Thu, Mar 12, 2015 at 9:36 PM, Yijing Wang wrote: > >> > + pci_add_resource(&resources, &

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-25 Thread Yijing Wang
That seems OK to me. Probably still wrong, but no worse than it was before. >>> >>> Interesting. The mechanism for PCI passthrough can either synthesize >>> and PCI bus number starting at zero (so first device is always 0:0:0.0) >>> or it can replicate the backend PCI topology. That mea

Re: [Xen-devel] [PATCH v6 04/30] xen/PCI: Don't use deprecated function pci_scan_bus_parented()

2015-03-26 Thread Yijing Wang
>>> Is there an git tree with this so I can just try it out? >> >> git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git >> pci/enumeration-yw6 has similar code (it exports the single > > I presume now it is bjorn/pci/enumeration-yw8 ? Going to test this out > this week. Hi Konrad, I fixe