The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Myron Stowe <myron.stowe@redhat.com>
To: jbarnes@virtuousgeek.org
Cc: linux-pci@vger.kernel.org, bhelgaas@google.com,
	linux-kernel@vger.kernel.org
Subject: [PATCH -v2 0/3] PCI: Convert maintaining FW-assigned BIOS BAR values to a list of temporary entries
Date: Mon, 21 Nov 2011 11:54:01 -0700	[thread overview]
Message-ID: <20111121185401.9603.34587.stgit@amt.stowe> (raw)

In commit 58c84eda075 functionality was introduced that attempts to
reinstate the original, FW-assigned, BAR addresses of a PCI device when
normal resource assignment fails.  To keep track of the BIOS BAR
addresses, struct pci_dev was augmented with an array to hold the device's
BAR addresses: 'resource_size_t fw_addr[DEVICE_COUNT_RESOURCE]'.

The reinstatement of BAR addresses is an uncommon event leaving the
'fw_addr' array unused under normal circumstances.  As the use of struct
pci_dev is so prevalent, this seems wasteful.

This patch series introduces a stand alone data structure and
corresponding interface routine that is used in converting the
underlying aspects of the existing maintanence scheme to a list of
temporary BIOS BAR value entries.

[v2]
 - Simplified list maintenance by adding a routine, and call to such,
   to delete the entire list once PCI enumeration is complete (as opposed
   to keeping reference counters and deleting entries as the reference
   counts go to 0).
 - Reinstatement of FW-assigned BAR addresses is currently only
   implemented for x86 so I relocated the stand alone data structure and
   maintenance routines within an x86 architecture specific file and
   introduced a '__weak' attribute generic interface routine -
   'pcibios_retrieve_fw_addr()' which returns a failure condition - into
   the PCI core that resolves the interface for all other architectures.

---

Myron Stowe (3):
      x86/PCI: Convert maintaining FW-assigned BIOS BAR values to use a list
      x86/PCI: Infrastructure to maintain a list of FW-assigned BIOS BAR values
      PCI: Fix starting basis for resource requests


 arch/x86/pci/i386.c     |   83 ++++++++++++++++++++++++++++++++++++++++++++++-
 drivers/pci/setup-res.c |   36 ++++++++++++++++----
 include/linux/pci.h     |    2 +
 3 files changed, 112 insertions(+), 9 deletions(-)

-- 

             reply	other threads:[~2011-11-21 18:54 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-21 18:54 Myron Stowe [this message]
2011-11-21 18:54 ` [PATCH -v2 1/3] PCI: Fix starting basis for resource requests Myron Stowe
2012-01-27 17:15   ` Jesse Barnes
2011-11-21 18:54 ` [PATCH -v2 2/3] x86/PCI: Infrastructure to maintain a list of FW-assigned BIOS BAR values Myron Stowe
2011-11-21 18:54 ` [PATCH -v2 3/3] x86/PCI: Convert maintaining FW-assigned BIOS BAR values to use a list Myron Stowe

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=20111121185401.9603.34587.stgit@amt.stowe \
    --to=myron.stowe@redhat.com \
    --cc=bhelgaas@google.com \
    --cc=jbarnes@virtuousgeek.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    /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