lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <6146693.UZIeGQtNL9@wuerfel>
Date:   Tue, 06 Sep 2016 21:14:27 +0200
From:   Arnd Bergmann <arnd@...db.de>
To:     linux-arm-kernel@...ts.infradead.org
Cc:     Tomasz Nowicki <tn@...ihalf.com>,
        Bjorn Helgaas <helgaas@...nel.org>,
        gabriele.paoloni@...wei.com, rafael@...nel.org,
        catalin.marinas@....com, will.deacon@....com, okaya@...eaurora.org,
        wangyijing@...wei.com, andrea.gallo@...aro.org,
        Lorenzo.Pieralisi@....com, jhugo@...eaurora.org,
        linaro-acpi@...ts.linaro.org, ddaney@...iumnetworks.com,
        linux-acpi@...r.kernel.org, robert.richter@...iumnetworks.com,
        liudongdong3@...wei.com, linux-pci@...r.kernel.org,
        Liviu.Dudau@....com, jcm@...hat.com, msalter@...hat.com,
        cov@...eaurora.org, mw@...ihalf.com, jchandra@...adcom.com,
        ard.biesheuvel@...aro.org, dhdang@....com,
        linux-kernel@...r.kernel.org, jeremy.linton@....com,
        hanjun.guo@...aro.org
Subject: Re: [RFC PATCH V5 3/5] PCI: Check platform specific ECAM quirks

On Tuesday, September 6, 2016 7:49:49 PM CEST Tomasz Nowicki wrote:
> On 05.09.2016 04:25, Bjorn Helgaas wrote:
> > On Mon, Aug 08, 2016 at 03:05:39PM +0200, Tomasz Nowicki wrote:
> >> Some platforms may not be fully compliant with generic set of PCI config
> >> accessors. For these cases we implement the way to overwrite accessors
> >> set. Algorithm traverses available quirk list (static array),
> >> matches against <oem_id, oem_table_id, rev, domain, bus number range> and
> >> returns pci_config_window structure with fancy PCI config ops.
> >> oem_id, oem_table_id and rev come from MCFG table standard header.
> >>
> >> It is possible to define custom init call which is responsible for
> >> setting up PCI configuration access accordingly to quirk requirements.
> >> If custom init call is not defined, use standard pci_acpi_setup_ecam_mapping().
> >>
> >> pci_generic_ecam_ops will be used for platforms free from quirks.
> >>
> >> Signed-off-by: Tomasz Nowicki <tn@...ihalf.com>
> >> Signed-off-by: Dongdong Liu <liudongdong3@...wei.com>
> >> Signed-off-by: Christopher Covington <cov@...eaurora.org>
> >> ---
> >>  drivers/pci/host/Makefile      |  1 +
> >>  drivers/pci/host/mcfg-quirks.c | 86 ++++++++++++++++++++++++++++++++++++++++++
> >>  drivers/pci/host/mcfg-quirks.h | 20 ++++++++++
> >>  include/linux/pci-acpi.h       |  2 +
> >>  4 files changed, 109 insertions(+)
> >>  create mode 100644 drivers/pci/host/mcfg-quirks.c
> >>  create mode 100644 drivers/pci/host/mcfg-quirks.h
> >
> > If the object is to work around defects in the ACPI MCFG table, I
> > think I'd put the quirks closer to drivers/acpi/pci_mcfg.c, where we
> > parse that table.  What if we actually put them directly *in*
> > drivers/acpi/pci_mcfg.c?
> 
> Then we need to export quirk init calls or ecam ops from 
> drivers/pci/host/* directory.
> 
> Currently we keep mcfg quirk handling code and related drivers in one 
> place drivers/pci/host/

I think that's the wrong place to have it, it just leads to people
trying to share code with the host drivers in that directory, which
hasn't really worked out so far, it just adds complexity.

	Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ