aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-12 18:50:23 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-12 18:50:23 -0400
commit6a84258e5f5bb8b9bd72e06a5837fa6fdacaf5c5 (patch)
tree3c4911a489c85e908b0ef3ed83d78264788f858c /Documentation
parentefefc6eb38d43b8e5daef482f575d767b002004e (diff)
parentf3e6f164c2389853432454c89b316a8ab7485e2f (diff)
Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6: (37 commits) PCI: merge almost all of pci_32.h and pci_64.h together PCI: X86: Introduce and enable PCI domain support PCI: Add 'nodomains' boot option, and pci_domains_supported global PCI: modify PCI bridge control ISA flag for clarity PCI: use _CRS for PCI resource allocation PCI: avoid P2P prefetch window for expansion ROMs PCI: skip ISA ioresource alignment on some systems PCI: remove transparent bridge sizing pci: write file size to inode on proc bus file write pci: use size stored in proc_dir_entry for proc bus files pci: implement "pci=noaer" PCI: fix IDE legacy mode resources MSI: Use correct data offset for 32-bit MSI in read_msi_msg() PCI: Fix incorrect argument order to list_add_tail() in PCI dynamic ID code PCI: i386: Compaq EVO N800c needs PCI bus renumbering PCI: Remove no longer correct documentation regarding MSI vector assignment PCI: re-enable onboard sound on "MSI K8T Neo2-FIR" PCI: quirk_vt82c586_acpi: Omit reading PCI revision ID PCI: quirk amd_8131_mmrbc: Omit reading pci revision ID cpqphp: Use PCI_CLASS_REVISION instead of PCI_REVISION_ID for read ...
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/DMA-API.txt3
-rw-r--r--Documentation/MSI-HOWTO.txt69
-rw-r--r--Documentation/kernel-parameters.txt8
3 files changed, 15 insertions, 65 deletions
diff --git a/Documentation/DMA-API.txt b/Documentation/DMA-API.txt
index cc7a8c39fb6f..b939ebb62871 100644
--- a/Documentation/DMA-API.txt
+++ b/Documentation/DMA-API.txt
@@ -68,6 +68,9 @@ size and dma_handle must all be the same as those passed into the
68consistent allocate. cpu_addr must be the virtual address returned by 68consistent allocate. cpu_addr must be the virtual address returned by
69the consistent allocate. 69the consistent allocate.
70 70
71Note that unlike their sibling allocation calls, these routines
72may only be called with IRQs enabled.
73
71 74
72Part Ib - Using small dma-coherent buffers 75Part Ib - Using small dma-coherent buffers
73------------------------------------------ 76------------------------------------------
diff --git a/Documentation/MSI-HOWTO.txt b/Documentation/MSI-HOWTO.txt
index 0d8240774fca..a51f693c1541 100644
--- a/Documentation/MSI-HOWTO.txt
+++ b/Documentation/MSI-HOWTO.txt
@@ -241,68 +241,7 @@ address space of the MSI-X table/MSI-X PBA. Otherwise, the PCI subsystem
241will fail enabling MSI-X on its hardware device when it calls the function 241will fail enabling MSI-X on its hardware device when it calls the function
242pci_enable_msix(). 242pci_enable_msix().
243 243
2445.3.2 Handling MSI-X allocation 2445.3.2 API pci_enable_msix
245
246Determining the number of MSI-X vectors allocated to a function is
247dependent on the number of MSI capable devices and MSI-X capable
248devices populated in the system. The policy of allocating MSI-X
249vectors to a function is defined as the following:
250
251#of MSI-X vectors allocated to a function = (x - y)/z where
252
253x = The number of available PCI vector resources by the time
254 the device driver calls pci_enable_msix(). The PCI vector
255 resources is the sum of the number of unassigned vectors
256 (new) and the number of released vectors when any MSI/MSI-X
257 device driver switches its hardware device back to a legacy
258 mode or is hot-removed. The number of unassigned vectors
259 may exclude some vectors reserved, as defined in parameter
260 NR_HP_RESERVED_VECTORS, for the case where the system is
261 capable of supporting hot-add/hot-remove operations. Users
262 may change the value defined in NR_HR_RESERVED_VECTORS to
263 meet their specific needs.
264
265y = The number of MSI capable devices populated in the system.
266 This policy ensures that each MSI capable device has its
267 vector reserved to avoid the case where some MSI-X capable
268 drivers may attempt to claim all available vector resources.
269
270z = The number of MSI-X capable devices populated in the system.
271 This policy ensures that maximum (x - y) is distributed
272 evenly among MSI-X capable devices.
273
274Note that the PCI subsystem scans y and z during a bus enumeration.
275When the PCI subsystem completes configuring MSI/MSI-X capability
276structure of a device as requested by its device driver, y/z is
277decremented accordingly.
278
2795.3.3 Handling MSI-X shortages
280
281For the case where fewer MSI-X vectors are allocated to a function
282than requested, the function pci_enable_msix() will return the
283maximum number of MSI-X vectors available to the caller. A device
284driver may re-send its request with fewer or equal vectors indicated
285in the return. For example, if a device driver requests 5 vectors, but
286the number of available vectors is 3 vectors, a value of 3 will be
287returned as a result of pci_enable_msix() call. A function could be
288designed for its driver to use only 3 MSI-X table entries as
289different combinations as ABC--, A-B-C, A--CB, etc. Note that this
290patch does not support multiple entries with the same vector. Such
291attempt by a device driver to use 5 MSI-X table entries with 3 vectors
292as ABBCC, AABCC, BCCBA, etc will result as a failure by the function
293pci_enable_msix(). Below are the reasons why supporting multiple
294entries with the same vector is an undesirable solution.
295
296 - The PCI subsystem cannot determine the entry that
297 generated the message to mask/unmask MSI while handling
298 software driver ISR. Attempting to walk through all MSI-X
299 table entries (2048 max) to mask/unmask any match vector
300 is an undesirable solution.
301
302 - Walking through all MSI-X table entries (2048 max) to handle
303 SMP affinity of any match vector is an undesirable solution.
304
3055.3.4 API pci_enable_msix
306 245
307int pci_enable_msix(struct pci_dev *dev, struct msix_entry *entries, int nvec) 246int pci_enable_msix(struct pci_dev *dev, struct msix_entry *entries, int nvec)
308 247
@@ -339,7 +278,7 @@ a failure. This failure may be a result of duplicate entries
339specified in second argument, or a result of no available vector, 278specified in second argument, or a result of no available vector,
340or a result of failing to initialize MSI-X table entries. 279or a result of failing to initialize MSI-X table entries.
341 280
3425.3.5 API pci_disable_msix 2815.3.3 API pci_disable_msix
343 282
344void pci_disable_msix(struct pci_dev *dev) 283void pci_disable_msix(struct pci_dev *dev)
345 284
@@ -349,7 +288,7 @@ always call free_irq() on all MSI-X vectors it has done request_irq()
349on before calling this API. Failure to do so results in a BUG_ON() and 288on before calling this API. Failure to do so results in a BUG_ON() and
350a device will be left with MSI-X enabled and leaks its vectors. 289a device will be left with MSI-X enabled and leaks its vectors.
351 290
3525.3.6 MSI-X mode vs. legacy mode diagram 2915.3.4 MSI-X mode vs. legacy mode diagram
353 292
354The below diagram shows the events which switch the interrupt 293The below diagram shows the events which switch the interrupt
355mode on the MSI-X capable device function between MSI-X mode and 294mode on the MSI-X capable device function between MSI-X mode and
@@ -407,7 +346,7 @@ between MSI mod MSI-X mode during a run-time.
407MSI/MSI-X support requires support from both system hardware and 346MSI/MSI-X support requires support from both system hardware and
408individual hardware device functions. 347individual hardware device functions.
409 348
4105.5.1 System hardware support 3495.5.1 Required x86 hardware support
411 350
412Since the target of MSI address is the local APIC CPU, enabling 351Since the target of MSI address is the local APIC CPU, enabling
413MSI/MSI-X support in the Linux kernel is dependent on whether existing 352MSI/MSI-X support in the Linux kernel is dependent on whether existing
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index 912c57c2334e..9cbc82e37ed0 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -68,6 +68,7 @@ parameter is applicable:
68 PARIDE The ParIDE (parallel port IDE) subsystem is enabled. 68 PARIDE The ParIDE (parallel port IDE) subsystem is enabled.
69 PARISC The PA-RISC architecture is enabled. 69 PARISC The PA-RISC architecture is enabled.
70 PCI PCI bus support is enabled. 70 PCI PCI bus support is enabled.
71 PCIE PCI Express support is enabled.
71 PCMCIA The PCMCIA subsystem is enabled. 72 PCMCIA The PCMCIA subsystem is enabled.
72 PNP Plug & Play support is enabled. 73 PNP Plug & Play support is enabled.
73 PPC PowerPC architecture is enabled. 74 PPC PowerPC architecture is enabled.
@@ -1277,6 +1278,11 @@ and is between 256 and 4096 characters. It is defined in the file
1277 Mechanism 1. 1278 Mechanism 1.
1278 conf2 [X86-32] Force use of PCI Configuration 1279 conf2 [X86-32] Force use of PCI Configuration
1279 Mechanism 2. 1280 Mechanism 2.
1281 noaer [PCIE] If the PCIEAER kernel config parameter is
1282 enabled, this kernel boot option can be used to
1283 disable the use of PCIE advanced error reporting.
1284 nodomains [PCI] Disable support for multiple PCI
1285 root domains (aka PCI segments, in ACPI-speak).
1280 nommconf [X86-32,X86_64] Disable use of MMCONFIG for PCI 1286 nommconf [X86-32,X86_64] Disable use of MMCONFIG for PCI
1281 Configuration 1287 Configuration
1282 nomsi [MSI] If the PCI_MSI kernel config parameter is 1288 nomsi [MSI] If the PCI_MSI kernel config parameter is
@@ -1321,6 +1327,8 @@ and is between 256 and 4096 characters. It is defined in the file
1321 IRQ routing is enabled. 1327 IRQ routing is enabled.
1322 noacpi [X86-32] Do not use ACPI for IRQ routing 1328 noacpi [X86-32] Do not use ACPI for IRQ routing
1323 or for PCI scanning. 1329 or for PCI scanning.
1330 use_crs [X86-32] Use _CRS for PCI resource
1331 allocation.
1324 routeirq Do IRQ routing for all PCI devices. 1332 routeirq Do IRQ routing for all PCI devices.
1325 This is normally done in pci_enable_device(), 1333 This is normally done in pci_enable_device(),
1326 so this option is a temporary workaround 1334 so this option is a temporary workaround