Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755709AbbKCSBf (ORCPT ); Tue, 3 Nov 2015 13:01:35 -0500 Received: from lhrrgout.huawei.com ([194.213.3.17]:18262 "EHLO lhrrgout.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754129AbbKCSBd convert rfc822-to-8bit (ORCPT ); Tue, 3 Nov 2015 13:01:33 -0500 From: Gabriele Paoloni To: David Daney , Hanjun Guo CC: Lorenzo Pieralisi , Sinan Kaya , Tomasz Nowicki , "bhelgaas@google.com" , "arnd@arndb.de" , "will.deacon@arm.com" , "catalin.marinas@arm.com" , "rjw@rjwysocki.net" , "jiang.liu@linux.intel.com" , "robert.richter@caviumnetworks.com" , "Narinder.Dhillon@caviumnetworks.com" , "Liviu.Dudau@arm.com" , "tglx@linutronix.de" , Wangyijing , "Suravee.Suthikulpanit@amd.com" , "msalter@redhat.com" , "linux-pci@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-acpi@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "Wangzhou (B)" , "liudongdong (C)" Subject: RE: [PATCH V1 11/11] arm64, pci, acpi: Support for ACPI based PCI hostbridge init Thread-Topic: [PATCH V1 11/11] arm64, pci, acpi: Support for ACPI based PCI hostbridge init Thread-Index: AQHRENZLK9Q0oYMLs0aWGtXNSKVAeZ6BQEaAgAkiKACAABHvgIAAJwyAgAAFkIA= Date: Tue, 3 Nov 2015 18:00:10 +0000 Message-ID: References: <1445963922-22711-1-git-send-email-tn@semihalf.com> <1445963922-22711-12-git-send-email-tn@semihalf.com> <5631180D.2000902@codeaurora.org> <20151103141512.GC3574@red-moon> <5638D07B.2030001@linaro.org> <5638F13D.3080406@caviumnetworks.com> In-Reply-To: <5638F13D.3080406@caviumnetworks.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.47.94.66] Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A090201.5638F64D.0014,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0, ip=0.0.0.0, so=2013-06-18 04:22:30, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: 66d38e706539196417f8bf218093110b Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2661 Lines: 79 Hi David > -----Original Message----- > From: David Daney [mailto:ddaney@caviumnetworks.com] > Sent: 03 November 2015 17:39 > To: Hanjun Guo > Cc: Lorenzo Pieralisi; Sinan Kaya; Tomasz Nowicki; bhelgaas@google.com; > arnd@arndb.de; will.deacon@arm.com; catalin.marinas@arm.com; rjw@rjwysocki.net; > jiang.liu@linux.intel.com; robert.richter@caviumnetworks.com; > Narinder.Dhillon@caviumnetworks.com; Liviu.Dudau@arm.com; tglx@linutronix.de; > Wangyijing; Suravee.Suthikulpanit@amd.com; msalter@redhat.com; linux- > pci@vger.kernel.org; linux-arm-kernel@lists.infradead.org; linux- > acpi@vger.kernel.org; linux-kernel@vger.kernel.org; Gabriele Paoloni; Wangzhou > (B); liudongdong (C) > Subject: Re: [PATCH V1 11/11] arm64, pci, acpi: Support for ACPI based PCI > hostbridge init > > On 11/03/2015 07:19 AM, Hanjun Guo wrote: > > On 11/03/2015 10:15 PM, Lorenzo Pieralisi wrote: > >> On Wed, Oct 28, 2015 at 02:46:37PM -0400, Sinan Kaya wrote: > >> > >> [...] > >> > >>>> -int raw_pci_write(unsigned int domain, unsigned int bus, > >>>> - unsigned int devfn, int reg, int len, u32 val) > >>>> +struct pci_ops pci_root_ops = { > >>>> + .map_bus = pci_mcfg_dev_base, > >>>> + .read = pci_generic_config_read, > >>>> + .write = pci_generic_config_write, > >>> > >>> > >>> Can you change these with pci_generic_config_read32 and > >>> pci_generic_config_write32? We have some targets that can only do 32 > >>> bits PCI config space access. > >> > >> No. > >> > >> http://www.spinics.net/lists/linux-pci/msg44869.html > >> > >> Can you be a bit more specific please ? > >> > >> Sigh. Looks like we have to start adding platform specific quirks even > >> before we merged the generic ACPI PCIe host controller implementation. > > > > Cc Gab, Zhou, and Dondong who upstream the hip05 (designware) PCIe host > > support. > > > > I think so, some platform may not support ECAM for root complex, > > which needs special handling of access config space, we may need > > to consider those cases. > > > > Yes, it is indeed true. For example, some Cavium ThunderX processors > fall into this category. > > Some options I thought of are: > > o Use DECLARE_ACPI_MCFG_FIXUP() in the kernel to supply the needed > config space accessors. > > o Define additional root_device_ids that imply the needed config space > accessors. Yes I like this it would fit designware too Gab > > > > Thanks > > Hanjun -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/