linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Daniel Axtens <dja@axtens.net>
To: Scott Wood <scottwood@freescale.com>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: [PATCH v3 16/19] powerpc: fsl_pci, swiotlb: Move controller ops from ppc_md to controller_ops
Date: Fri, 10 Apr 2015 12:36:28 +1000	[thread overview]
Message-ID: <1428633388.4486.14.camel@axtens.net> (raw)
In-Reply-To: <1428629330.22867.567.camel@freescale.com>

[-- Attachment #1: Type: text/plain, Size: 1876 bytes --]

Hi Scott,

This is part of the larger set to move controller ops into a generic
structure. The original cover letter is at
https://lists.ozlabs.org/pipermail/linuxppc-dev/2015-March/126837.html

The commit message should have been reworded when I sent out version 2.
Apologies. Here's a more accurate summary, which will appear in v4.

powerpc: fsl_pci, swiotlb: Move controller ops from ppc_md to
controller_ops

Move the installation of DMA operations out of swiotlb's subsys
initcall, and into the generic PCI controller operations struct.

These ops are installed conditionally, based on the ppc_swiotlb_enable
global. The global can be set in two places:
 - swiotlb_detect_4g, which is always called at the arch initcall level
 - setup_pci_atmu, which is called as part of the fsl_add_bridge and
fsl_pci_syscore_do_resume. fsl_pci_syscore_do_resume is called late
enough that any changes as a result of that call will have no effect.

As such, if we test the global and set the operations as part of
fsl_add_bridge, after the call to setup_pci_atmu, we can be confident
that it will cover all the PCI implementations affected by the changes
to dma-swiotlb.c.

Regards,
Daniel

On Thu, 2015-04-09 at 20:28 -0500, Scott Wood wrote:
> On Fri, 2015-04-10 at 10:11 +1000, Daniel Axtens wrote:
> > Moves the setup out of swiotlb's subsys init call, and into an new
> > structure.
> 
> "a new"
> 
> > fsl_pci.c is the only thing that checks the ppc_swiotlb_enable global,
> > so we can be confident that patching it will cover all the PCI
> > implementations affected by the changes to dma-swiotlb.c.
> 
> Do you mean the only thing that sets ppc_swiotlb_enable (fsl_pci.c
> doesn't check it)?  It's also set by swiotlb_detect_4g().
> 
> Where is the rest of this patchset?  What is the problem being solved?
> 
> -Scott
> 
> 


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 860 bytes --]

  reply	other threads:[~2015-04-10  2:36 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-31  5:00 [PATCH v2 00/19] Refactor PCI controller operations Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 01/19] powerpc: move find_and_init_phbs() to pSeries specific code Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 02/19] powerpc/powermac: move pmac_pci_probe_mode from setup.c to pci.c Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 03/19] powerpc: pcibios_enable_device_hook: return bool rather than int Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 04/19] powerpc: Create pci_controller_ops.dma_dev_setup and shim Daniel Axtens
2015-04-02 14:13   ` Arnd Bergmann
2015-04-07  0:31     ` Daniel Axtens
2015-04-07  7:44       ` Arnd Bergmann
2015-04-08  3:31         ` Michael Ellerman
2015-03-31  5:00 ` [PATCH v2 05/19] powerpc: Create pci_controller_ops.dma_bus_setup " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 06/19] powerpc: Create pci_controller_ops.probe_mode " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 07/19] powerpc: Create pci_controller_ops.enable_device_hook " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 08/19] powerpc: Create pci_controller_ops.window_alignment " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 09/19] powerpc: Create pci_controller_ops.reset_secondary_bus " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 10/19] powerpc: dart_iommu: optionally populate controller_ops on init Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 11/19] powerpc/powermac: Move controller ops from ppc_md to controller_ops Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 12/19] powerpc/pseries: " Daniel Axtens
2015-04-02  3:21   ` [PATCH v3 " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 13/19] powerpc/powernv: " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 14/19] powerpc/pasemi: " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 15/19] powerpc/maple: " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 16/19] powerpc: fsl_pci, swiotlb: " Daniel Axtens
2015-04-10  0:11   ` [PATCH v3 " Daniel Axtens
2015-04-10  1:28     ` Scott Wood
2015-04-10  2:36       ` Daniel Axtens [this message]
2015-04-10  3:15     ` [PATCH v4 " Daniel Axtens
2015-04-10  3:18       ` Scott Wood
2015-03-31  5:00 ` [PATCH v2 17/19] powerpc/cell: " Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 18/19] powerpc: Remove shims for pci_controller_ops operations Daniel Axtens
2015-03-31  5:00 ` [PATCH v2 19/19] powerpc: dart_iommu: Remove check for controller_ops == NULL case Daniel Axtens
2015-04-07  7:51 ` [PATCH v2 00/19] Refactor PCI controller operations Arnd Bergmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1428633388.4486.14.camel@axtens.net \
    --to=dja@axtens.net \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=scottwood@freescale.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).