Re: [v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-05-25 Thread Michael Ellerman
On Wed, 2016-05-25 at 10:03 -0300, Guilherme G. Piccoli wrote: > On 05/25/2016 02:45 AM, Michael Ellerman wrote: > > > > Yeah please increase the bitmap size to 65536. It will only take 8KB of > > memory, > > which is negligible. > > Well, since I sent a v6 and you replied there too, I guess we

Re: [v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-05-25 Thread Guilherme G. Piccoli
On 05/25/2016 02:45 AM, Michael Ellerman wrote: Hi Guilherme, Sorry for the very late reply, this got lost in my email filters. No problem Michael, thanks for replying! On Mon, 2016-03-28 at 09:36 -0300, Guilherme G. Piccoli wrote: On 03/25/2016 06:33 AM, Michael Ellerman wrote: +static

Re: [v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-05-24 Thread Michael Ellerman
Hi Guilherme, Sorry for the very late reply, this got lost in my email filters. On Mon, 2016-03-28 at 09:36 -0300, Guilherme G. Piccoli wrote: > On 03/25/2016 06:33 AM, Michael Ellerman wrote: > > > +static int get_phb_number(struct device_node *dn) > > > +{ > > > + const __be64 *prop64; > > >

Re: [PATCH v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-04-06 Thread Ian Munsie
Excerpts from Guilherme G. Piccoli's message of 2016-04-06 16:51:43 -0500: > And in the case a virtual PHB grabs the bitmap before, we just need to > add Michael's suggested check and fallback to bitmap PHB numbering in > this case. > > Do you think this is enough to avoid issues with cxl'a virt

Re: [PATCH v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-04-06 Thread Michael C Hollinger
Hey guys - our system test team opened a defect on this, since Ubuntu (as it stands) is broken now with CAPI Flash cards.   Dion opened bug https://bugzilla.linux.ibm.com/show_bug.cgi?id=140054 .   So - this is important. You need to tested to confirm that this is in-fact the root cause of Dion's

Re: [PATCH v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-04-06 Thread Guilherme G. Piccoli
On 04/06/2016 04:38 PM, Ian Munsie wrote: +/* try fixed PHB numbering first, by checking archs and reading + * the respective device-tree property. */ +if (machine_is(pseries)) { +regs = of_get_property(dn, "reg", NULL); +if (regs) +return (int)(be32_to_cpu

Re: [PATCH v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-04-06 Thread Ian Munsie
Excerpts from Guilherme G. Piccoli's message of 2016-03-18 16:49:06 -0500: > +static int get_phb_number(struct device_node *dn) ... > +/* try fixed PHB numbering first, by checking archs and reading > + * the respective device-tree property. */ > +if (machine_is(pseries)) { > +

Re: [v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-03-28 Thread Guilherme G. Piccoli
On 03/25/2016 06:33 AM, Michael Ellerman wrote: Hi Guilherme, Some comments below ... Hi Michael, thanks for the comments. +/* For dynamic PHB numbering on get_phb_number(): max number of PHBs. */ +#defineMAX_PHBS8192 Did we just make that up? It seems like a lot, but then

Re: [v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-03-25 Thread Michael Ellerman
Hi Guilherme, Some comments below ... On Fri, 2016-18-03 at 21:49:06 UTC, "Guilherme G. Piccoli" wrote: > The domain/PHB field of PCI addresses has its value obtained from a > global variable, incremented each time a new domain (represented by > struct pci_controller) is added on the system. The

[PATCH v4] powerpc/pci: Assign fixed PHB number based on device-tree properties

2016-03-20 Thread Guilherme G. Piccoli
The domain/PHB field of PCI addresses has its value obtained from a global variable, incremented each time a new domain (represented by struct pci_controller) is added on the system. The domain addition process happens during boot or due to PCI device hotplug. As recent kernels are using predictab