linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Krzysztof Wilczynski <kw@linux.com>
To: Bjorn Helgaas <bhelgaas@google.com>
Cc: Dominik Brodowski <linux@dominikbrodowski.net>,
	Chuhong Yuan <hslester96@gmail.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Takashi Iwai <tiwai@suse.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-pci@vger.kernel.org
Subject: [PATCH v3 0/2] PCI: Reference bridge window resources explicitly
Date: Wed, 20 May 2020 18:34:09 +0000	[thread overview]
Message-ID: <20200520183411.1534621-1-kw@linux.com> (raw)
In-Reply-To: <20200520170609.GA1102503@bjorn-Precision-5520>

Add definitions to allow for more explicit mapping of Peer-to-Peer (P2P)
and CardBus bridge window resources.

Added for P2P:

  PCI_BRIDGE_RESOURCES + 0 -> PCI_BRIDGE_IO_WINDOW
  PCI_BRIDGE_RESOURCES + 1 -> PCI_BRIDGE_MEM_WINDOW
  PCI_BRIDGE_RESOURCES + 2 -> PCI_BRIDGE_PREF_MEM_WINDOW

Added for CardBus:

  PCI_BRIDGE_RESOURCES + 0 -> PCI_CB_BRIDGE_IO_0_WINDOW
  PCI_BRIDGE_RESOURCES + 1 -> PCI_CB_BRIDGE_IO_1_WINDOW
  PCI_BRIDGE_RESOURCES + 2 -> PCI_CB_BRIDGE_MEM_0_WINDOW
  PCI_BRIDGE_RESOURCES + 3 -> PCI_CB_BRIDGE_MEM_1_WINDOW

The old way of addressing resources using an index:

  bridge->resource[PCI_BRIDGE_RESOURCES+0]

Would now be replaced with:

  bridge->resource[PCI_BRIDGE_IO_WINDOW]

This series of patches builds on top of the changes proposed before:

  https://lore.kernel.org/r/20100203233931.10803.39854.stgit@bob.kio
  https://lore.kernel.org/r/20100212170022.19522.81135.stgit@bob.kio

Krzysztof Wilczynski (2):
  PCI: Move from using PCI_BRIDGE_RESOURCES to bridge resource
    definitions
  pcmcia: Use resources definitions when freeing CardBus resources

---
Changes in v2:
  Split patches based on the feedback from Bjorn allowing for the
  patch that correct the PCI quirk for the ALI chipset to be applied
  independently, if someone needs to cherry-pick it, before updating
  the said quirk to use definitions for bridge window resources.

Changes in v3:
  Remove the PCI quirk patch for ALI M7101 chipset as it's not needed.
  Remove surplus new variables added in pci_bus_size_cardbus().

 drivers/pci/quirks.c          |  37 +++++------
 drivers/pci/setup-bus.c       | 114 ++++++++++++++++++----------------
 drivers/pcmcia/yenta_socket.c |  46 +++++++++-----
 include/linux/pci.h           |  14 ++++-
 4 files changed, 122 insertions(+), 89 deletions(-)

-- 
2.26.2


  reply	other threads:[~2020-05-20 18:34 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-19 21:49 [PATCH] PCI: Reference bridge window resources explicitly Krzysztof Wilczynski
2020-05-20 10:31 ` [PATCH v2 0/3] " Krzysztof Wilczynski
2020-05-20 10:31   ` [PATCH v2 1/3] PCI: Correct the PCI quirk for the ALI M7101 chipset Krzysztof Wilczynski
2020-05-20 17:06     ` Bjorn Helgaas
2020-05-20 18:34       ` Krzysztof Wilczynski [this message]
2020-05-20 18:34         ` [PATCH v3 1/2] PCI: Move from using PCI_BRIDGE_RESOURCES to bridge resource definitions Krzysztof Wilczynski
2020-05-20 18:34         ` [PATCH v3 2/2] pcmcia: Use resources definitions when freeing CardBus resources Krzysztof Wilczynski
2020-05-20 20:30         ` [PATCH v3 0/2] PCI: Reference bridge window resources explicitly Bjorn Helgaas
2020-05-21  8:16           ` Krzysztof Wilczynski
2020-05-21  8:24             ` Dominik Brodowski
2020-05-21 11:20             ` [PATCH v4 " Krzysztof Wilczynski
2020-05-21 11:20               ` [PATCH v4 1/2] PCI: Move from using PCI_BRIDGE_RESOURCES to bridge resource definitions Krzysztof Wilczynski
2020-05-21 11:20               ` [PATCH v4 2/2] pcmcia: Use resources definitions when freeing CardBus resources Krzysztof Wilczynski
2020-05-20 10:31   ` [PATCH v2 2/3] PCI: Move from using PCI_BRIDGE_RESOURCES to bridge resource definitions Krzysztof Wilczynski
2020-05-20 10:31   ` [PATCH v2 3/3] pcmcia: Use resources definitions when freeing CardBus resources Krzysztof Wilczynski

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=20200520183411.1534621-1-kw@linux.com \
    --to=kw@linux.com \
    --cc=bhelgaas@google.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=hslester96@gmail.com \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux@dominikbrodowski.net \
    --cc=tglx@linutronix.de \
    --cc=tiwai@suse.de \
    /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).