[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <266fd881-8117-967a-b70c-5db9b6211ab9@au1.ibm.com>
Date: Tue, 19 Dec 2017 12:14:58 +1100
From: Andrew Donnellan <andrew.donnellan@....ibm.com>
To: Frederic Barrat <fbarrat@...ux.vnet.ibm.com>,
linuxppc-dev@...ts.ozlabs.org, linux-kernel@...r.kernel.org
Cc: arnd@...db.de, gregkh@...uxfoundation.org, mpe@...erman.id.au,
alastair@....ibm.com
Subject: Re: [PATCH 02/13] powerpc/powernv: Set correct configuration space
size for opencapi devices
On 19/12/17 02:21, Frederic Barrat wrote:
> From Andrew Donnellan <andrew.donnellan@....ibm.com>
Good try :) That should be "From: ..."
git format-patch/send-email will handle this automatically if the commit
author is set correctly, ie:
git commit --amend --author="Andrew Donnellan
<andrew.donnellan@....ibm.com>"
>
> The configuration space for opencapi devices doesn't have a PCI
> Express capability, therefore confusing linux in thinking it's of an
> old PCI type with a 256-byte configuration space size, instead of the
> desired 4k. So add a PCI fixup to declare the correct size.
>
>
> Signed-off-by: Andrew Donnellan <andrew.donnellan@....ibm.com>
> Signed-off-by: Frederic Barrat <fbarrat@...ux.vnet.ibm.com>
> ---
> arch/powerpc/platforms/powernv/pci-ioda.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c b/arch/powerpc/platforms/powernv/pci-ioda.c
> index c37b5d288f9c..b8ec76aa266f 100644
> --- a/arch/powerpc/platforms/powernv/pci-ioda.c
> +++ b/arch/powerpc/platforms/powernv/pci-ioda.c
> @@ -4079,6 +4079,16 @@ void __init pnv_pci_init_npu2_opencapi_phb(struct device_node *np)
> pnv_pci_init_ioda_phb(np, 0, PNV_PHB_NPU_OCAPI);
> }
>
> +static void pnv_npu2_opencapi_cfg_size_fixup(struct pci_dev *dev)
> +{
> + struct pci_controller *hose = pci_bus_to_host(dev->bus);
> + struct pnv_phb *phb = hose->private_data;
> +
> + if (phb->type == PNV_PHB_NPU_OCAPI)
> + dev->cfg_size = PCI_CFG_SPACE_EXP_SIZE;
> +}
> +DECLARE_PCI_FIXUP_EARLY(PCI_ANY_ID, PCI_ANY_ID, pnv_npu2_opencapi_cfg_size_fixup);
> +
> void __init pnv_pci_init_ioda_hub(struct device_node *np)
> {
> struct device_node *phbn;
>
--
Andrew Donnellan OzLabs, ADL Canberra
andrew.donnellan@....ibm.com IBM Australia Limited
Powered by blists - more mailing lists