17 Jun, 2009
18 commits
-
When the bus id part of error source id is equal to 0 or nosourceid=1,
make the kernel probe the AER status registers of all devices under the
root port to find the initial error reporter.Reviewed-by: Andrew Patterson
Signed-off-by: Zhang Yanmin
Signed-off-by: Jesse Barnes -
Based on PCI Express AER specs, a root port might receive multiple
TLP errors while it could only save a correctable error source id
and an uncorrectable error source id at the same time. In addition,
some root port hardware might be unable to provide a correct source
id, i.e., the source id, or the bus id part of the source id provided
by root port might be equal to 0.The patchset implements the support in kernel by searching the device
tree under the root port.Patch 1 changes parameter cb of function pci_walk_bus to return a value.
When cb return non-zero, pci_walk_bus stops more searching on the
device tree.Reviewed-by: Andrew Patterson
Signed-off-by: Zhang Yanmin
Signed-off-by: Jesse Barnes -
The "owner" field in struct hotplug_slot_ops is initialized by PCI
hotplug core. So each hotplug controller driver doesn't need to
initialize it.Signed-off-by: Kenji Kaneshige
Reviewed-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Create symbolic link to hotplug driver module in the PCI slot
directory (/sys/bus/pci/slots/). In the past, we need to load
hotplug drivers one by one to identify the hotplug driver that handles
the slot, and it was very inconvenient especially for trouble shooting.
With this change, we can easily identify the hotplug driver.Signed-off-by: Taku Izumi
Signed-off-by: Kenji Kaneshige
Reviewed-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Current has_foo() functions in pci_hotplug_core.c returns 0 if the
"foo" property is true. It would cause misunderstanding. In addition,
the error code of those functions is never checked, so this patch
changes those functions' error code to 'bool' and return true if the
property "foo" is true.Signed-off-by: Kenji Kaneshige
Reviewed-by: Alex Chiang
Signed-off-by: Jesse Barnes -
The EMI support in pciehp is obviously broken. It is implemented using
struct hotplug_slot_attribute, but sysfs_ops for pci_slot_ktype is NOT
for struct hotplug_slot_attribute, but for struct pci_slot_attribute.
This bug had been there for a long time, maybe it was introduced when
PCI slot framework was introduced. The reason why this bug didn't
cause any problem is maybe the EMI support is not tested at all
because of lack of test environment.As described above, the EMI support in pciehp seems not to be tested
at all. So this patch removes EMI support from pciehp, instead of
fixing the bug.Signed-off-by: Kenji Kaneshige
Signed-off-by: Jesse Barnes -
Describe check_enable_amd_mmconf.
Signed-off-by: Andreas Herrmann
Signed-off-by: Jesse Barnes -
This patch adds a minimal HOWTO for PCIE AER software error injection
in Documentation/PCI/pcieaer-howto.txt.Signed-off-by: Huang Ying
Signed-off-by: Jesse Barnes -
This is used by PCIE AER error injection to fake an PCI AER interrupt.
Signed-off-by: Huang Ying
Signed-off-by: Jesse Barnes -
pci_bus_set_ops changes pci_ops associated with a pci_bus. This can be
used by debug tools such as PCIE AER error injection to fake some PCI
configuration registers.Acked-by: Kenji Kaneshige
Signed-off-by: Huang Ying
Signed-off-by: Jesse Barnes -
Use pci_is_root_bus() in pci_common_swizzle() for checking if the pci
bus is root, for code consistency.Reviewed-by: Alex Chiang
Reviewed-by: Grant Grundler
Signed-off-by: Kenji Kaneshige
Signed-off-by: Jesse Barnes -
Use pci_is_root_bus() in pci_get_interrupt_pin() for checking if the
pci bus is root, for code consistency.Reviewed-by: Alex Chiang
Reviewed-by: Grant Grundler
Signed-off-by: Kenji Kaneshige
Signed-off-by: Jesse Barnes -
Use pci_is_root_bus() in pci_read_bridge_bases() to check if the pci
bus is root, for code consistency.Reviewed-by: Alex Chiang
Reviewed-by: Grant Grundler
Signed-off-by: Kenji Kaneshige
Signed-off-by: Jesse Barnes -
Use pci_is_root_bus() in pci_find_upstream_pcie_bridge() to check if
the pci bus is root, for code consistency.Reviewed-by: Alex Chiang
Reviewed-by: Grant Grundler
Signed-off-by: Kenji Kaneshige
Signed-off-by: Jesse Barnes -
Use pci_is_root_bus() in acpi_find_root_bridge_handle() to check if
the pci bus is root, for code consistency.Reviewed-by: Alex Chiang
Reviewed-by: Grant Grundler
Signed-off-by: Kenji Kaneshige
Signed-off-by: Jesse Barnes -
Use pci_is_root_bus() in acpi_pci_get_bridge_handle() to check if the
pci bus is root, for code consistency.Reviewed-by: Grant Grundler
Reviewed-by: Alex Chiang
Signed-off-by: Kenji Kaneshige
Signed-off-by: Jesse Barnes -
I found no references to SMBus in ACPI DSDT disassembly on my laptop
so this should be safe.Signed-off-by: Michal Miroslaw
Signed-off-by: Andrew Morton
Signed-off-by: Jesse Barnes -
Some BIOSes hide 'overflow' device (dev #6) for i82875P/PE chipsets.
The same happens for i82865P/PE. Add a quirk to enable this device.
This allows i82875 EDAC driver to bind to chipset's dev #6 and not
dev #0 as the latter is used by AGP driver.On my laptop (i82865P based) ACPI code is disabling this device
again in \_SB.PCI0._CRS method (called at least at PNP init time).
This can be easily worked around by patching DSDT.[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Michal Miroslaw
Acked-by: Doug Thompson
Signed-off-by: Andrew Morton
Signed-off-by: Jesse Barnes
12 Jun, 2009
22 commits
-
Addition of one unknown subsystem identifier to the quirks handler for
chipset i82855GM_HB on notebook Asus A6L. This exposes the otherwise
hidden SMBus controller within the south bridge ICH4-M.Signed-off-by: Mats Erik Andersson
Signed-off-by: Jesse Barnes -
Adds support for PCI Express transaction layer end-to-end CRC checking
(ECRC). This patch will enable/disable ECRC checking by setting/clearing
the ECRC Check Enable and/or ECRC Generation Enable bits for devices that
support ECRC.The ECRC setting is controlled by the "pci=ecrc=" command-line
option. If this option is not set or is set to 'bios", the enable and
generation bits are left in whatever state that firmware/BIOS set them to.
The "off" setting turns them off, and the "on" option turns them on (if the
device supports it).Turning ECRC on or off can be a data integrity versus performance
tradeoff. In theory, turning it on will catch more data errors, turning
it off means possibly better performance since CRC does not need to be
calculated by the PCIe hardware and packet sizes are reduced.Signed-off-by: Andrew Patterson
Signed-off-by: Jesse Barnes -
According to the PCI PM specification (PCI Bus Power Management
Interface Specification, Rev. 1.2, Section 5.4.1) we are supposed to
reinitialize devices that have PCI_PM_CTRL_NO_SOFT_RESET clear during
all transitions from PCI_D3hot to PCI_D0, but we only do it if the
device's current_state field is equal to PCI_UNKNOWN.This may lead to problems if a device with PCI_PM_CTRL_NO_SOFT_RESET
unset is put into PCI_D3hot at run time by its driver and
pci_set_power_state() is used to put it back into PCI_D0, because in
that case the device will remain uninitialized after
pci_set_power_state() has returned. Prevent that from happening by
modifying pci_raw_set_power_state() to reinitialize devices with
PCI_PM_CTRL_NO_SOFT_RESET unset during all transitions from D3 to D0.Cc: stable@kernel.org
Signed-off-by: Rafael J. Wysocki
Signed-off-by: Jesse Barnes -
PCIe root complex integrated endpoint does not implement ARI, so this
kind of endpoint uses 3-bit function number. The function dependency
link of the integrated endpoint should be calculated using the device
number plus the value from function dependency link register.Normal endpoint always implements ARI and the function dependency link
register contains 8-bit function number (i.e. `devfn' from software's
perspective).Signed-off-by: Yu Zhao
Signed-off-by: Jesse Barnes -
We always call pci_stop_bus_device before calling pci_destroy_dev.
Since pci_stop_bus_device calls pci_stop_dev, there is no need
for pci_destroy_dev to repeat the call.Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
pci_enable_msix currently returns -EINVAL if you ask
for more vectors than supported by the device, which would
typically cause fallback to regular interrupts.It's better to return the table size, making the driver retry
MSI-X with less vectors.Reviewed-by: Matthew Wilcox
Signed-off-by: Michael S. Tsirkin
Signed-off-by: Jesse Barnes -
VIA has a strange chipset, it has root port under a bridge. Disable ASPM
for such strange chipset.Cc: stable@kernel.org
Tested-by: Wolfgang Denk
Signed-off-by: Shaohua Li
Signed-off-by: Jesse Barnes -
At this point, it seems to solve more problems than it causes, so let's try using it by default. It's an easy revert if it ends up causing trouble.
Reviewed-by: Yinghai Lu
Acked-by: Bjorn Helgaas
Signed-off-by: Jesse Barnes -
The last in-tree caller of pci_find_slot has been converted, so
let's get rid of this deprecated interface.Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Convert uses of pci_find_slot to modern API.
In the conversion sites, we end up calling pci_dev_put() right away.
This may seem like it misses the entire point of doing something like
pci_get_bus_and_slot(), since we drop the reference so soon, but it turns
out we don't actually do much with the returned pci_dev.I plan on untangling cpqphp further, but clearly cpqphp never worried too
much about a properly refcounted pci_dev anyway. For now, this conversion
seems reasonable, as it gets rid of the last in-tree caller of pci_find_slot.Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Eliminate this warning:
warning: return discards qualifiers from pointer target typeSigned-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
I have no clue what the original intent here was, but the code as
written is useless.The old dbg() statement above the old callsite might lead one to think
that at one point, there was supposed to be some recursion, but any
sense of sanity here has been lost to the ravages of time.Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Instead of making multiple calls to pcibios_get_irq_routing_table, let's
just do it once and save the answer.The reason we were making multiple calls is because we liked to calculate
its length and perform some loop over it. Instead of open-coding the length
calculation every time, provide it in an inline helper function.Finally, since pci_print_IRQ_route() is used only for debug, let's only
do it when cpqhp_debug is set.Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Handle an empty slot at the top of the loop, and continue early.
This allows us to un-indent the rest of the function by one level.
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Clean up style, whitespace in cpqphp_pci.c
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Check for an empty slot, and return early if so.
This allows us to un-indent the rest of the function by one level.
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Style and whitespace cleanups, no functional change.
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Apply DeMorgan's theorem:
if ((pdev->revision > 2) || (vendor_id == PCI_VENDOR_ID_INTEL))
turns into
if ((pdev->revision
Signed-off-by: Jesse Barnes -
Clean up style and eliminate superfluous braces and parens.
No functional change.
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Impact: refactor
Refactor code to follow convention more closely and eliminate the need
for some useless prototypes.No functional change.
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Clean up cpqphp.h to follow 80 column convention.
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes -
Fix up comments from C++ to C-style, wrapping if necessary, etc.
Signed-off-by: Alex Chiang
Signed-off-by: Jesse Barnes