- 09 Feb, 2004 2 commits
-
-
Greg Kroah-Hartman authored
-
Greg Kroah-Hartman authored
-
- 06 Feb, 2004 1 commit
-
-
Rolf Eike Beer authored
This patch converts the error paths in several functions in ibmphp to use goto to the end of the function to kill code duplication. It also kills some memsets of pointer members of a struct where the struct itself is freed directly after. This one has 2 modification from the first version: the if is back as discussed and one extra long line (>> 150 chars) is wrapped now.
-
- 04 Feb, 2004 3 commits
-
-
Rolf Eike Beer authored
These functions are only called from places marked __init or __exit, so we can mark them also.
-
Greg Kroah-Hartman authored
-
Matthew Dobson authored
John Rose wrote: > The function release_pcibus_dev() in probe.c defines the release procedure for > device class pcibus_class. I want to suggest that this function be scrapped :) > > This release function is called in the code path of class_device_unregister(). > The pcibus_class devices aren't currently unregistered anywhere, from what I > can tell, so this release function is currently unused. The runtime removal of > PCI buses from logical partitions on PPC64 requires the unregistration of these > class devices. The natural place to do this IMHO is in pci_remove_bus_device() > in remove.c. You're right that the class device isn't currently unregistered, and that was an oversight in the patch I originally sent. Attatched is a patch that remedies that situation. pci_remove_bus_device() *is* the natural place to unregister the class_dev, and that's just what the patch does. > The problem is that this calls pci_destroy_dev(), which calls put() on the same > "bridge" device that the release function does. This should only be done once > in the course of removing a pci_bus, and I doubt that we want to change > pci_destroy_dev(). The kfree() of the pci_bus struct is also done in both > pci_remove_bus_device() and release_pcibus_dev(). Yep. The patch pulls the kfree() out of pci_remove_bus_device() and calls class_device_unregister() in it's place. This will put() the bridge device and free the pci_bus as needed. put() does need to be called twice because the bridge device is get()'d twice: once when the device is registered and once when it's bus device grabs a reference to it.
-
- 03 Feb, 2004 6 commits
-
-
Rolf Eike Beer authored
ibm_unconfigure_device always returns 0, so we do not need to check for a return value != 0 and can kill the warning. And if the return value is always the same we don't need a return value. Also some whitespace fixing. And this time not line wrapped. Really. Absolutely sure. Checked twice.
-
Rolf Eike Beer authored
This patch kills the variable hpcrc from many places. It is used as a temporary storage for the return code before this is copied to rc which contains the "real" return code. There are some checks if to copy or not but at the end they will always have the same value, so we can directly put the return code in rc and kill hpcrc.
-
Rolf Eike Beer authored
-
Rolf Eike Beer authored
-
Rolf Eike Beer authored
This avoids a return direct before the final return of a function. Better only modify the return code and fall through to the final return.
-
David Brownell authored
-
- 02 Feb, 2004 7 commits
-
-
Dely Sy authored
Here is a patch for to get cpqphp working with IOAPIC. My earlier statement that a kernel patch is not needed for 2.6 is true only when ACPI is enabled. A similar patch is needed in pcibios_enable_irq() for 2.4 kernel and I will send it out later. The fix is in pirq_enable_irq(). This function is called indirectly by pci_enable_device(). For device present during boot up, it should get the proper dev->irq for pcibios_fixup_irqs() has been called to get the dev->irq from MP table. If the value is still zero, then this is properly caused by "buggy MP table". For hot-plug device, its dev->irq is 0 when the pci_enable_device() is called for it hasn't gone through the fixup. Therefore, the code (similiar to the code in pcibios_fixup_irqs) is needed here.
-
Rolf Eike Beer authored
This kills the explicit setting of rc to -ENODEV in 2 places where it is not necessary because it will have this value on this path anyway.
-
Rolf Eike Beer authored
Don't use a space directly before '\n' in error/debug messages. This adds extra code size, causes unneeded line breaks in xterms, noone else does it and it's just superfluos and ugly. This also adds a missing ")" in a comment.
-
Rolf Eike Beer authored
This are some whitespace fixes for acpiphp, in most cases killing spaces before the opening brace of function declarations.
-
Greg Kroah-Hartman authored
-
Deepak Saxena authored
include/linux changes: - Add dma_pools member to struct device - Add include/linux/dmapool.h - Remove pools memober from struct pci_dev - Replace pci_pool_* functions with macros that map to dma_pool_* functions
-
Deepak Saxena authored
- Move drivers/pci/pool.c to drivers/base/pool.c - Initialize struct device.dma_pools in device_initialize() - Remove initialization of struct pci_dev.pools from pci_setup_device()
-
- 30 Jan, 2004 5 commits
-
-
Rolf Eike Beer authored
here are some coding style fixes.
-
Adam Belay authored
The following patch remove irq_resource and dma_resource from pci_dev. It appears that the serial pci driver depends on irq_resource, however, it may be broken portions of an old quirk. I attempted to maintain the existing behavior while removing irq_resource. I changed FL_IRQRESOURCE to FL_NOIRQ. Russell, could you provide any comments? irq_resource and dma_resource are most likely remnants from when pci_dev was shared with pnp.
-
Greg Kroah-Hartman authored
-
Michael Hunold authored
This fixes some issues in the dvb subsystem and some nasty things in the v4l saa7146 driver. [DVB] - dvb-core: aquire -> acquire spelling fix - nxt600 frontend: don't send zero-byte messages when probing the PLL type - Kconfig: add a note that says that the CI of the budget-CI card is not actually supported by the budget-CI driver - ttusb-dec: Check for presence of crc32 function. Make unknown types of packet less likely to cause packet loss. [V4L] - saa7146: use kernel mint_t()/max_t() instead of homebrewn stuff - saa7146: disable video clipping before capturing for sure to prevent black pictures - saa7146: make sure to disable the right video dma upon device close - saa7146: don't free resources if disabling an already disabled video overlay
-
Dominik Brodowski authored
This is a simple fix for some of the problems with bad ACPI frequency values: Abort if the frequency field in _PSS is zero, as we're having a completely broken ACPI table then. A more complete overhaul of the acpi-cpufreq driver (where the cause of the problem lies) is in the latest acpi-test tree, but that's definitely something to be delayed for 2.6.3 -- and the same is true for the yet-to-be-written do_div64 conversion.
-
- 29 Jan, 2004 16 commits
-
-
Michael Schierl authored
This fixes my APM problems (without them my laptop, Acer TravelMate 210TEV (Celeron 700, 128 MB RAM), hangs after resuming from APM since 2.6.0-test4). Modified based on comments from Pavel Machek <pavel@suse.cz>, who has acked the updated patch.
-
Greg Kroah-Hartman authored
-
Kieran Morrissey authored
- Replaces pci.ids with a snapshot from pciids.sf.net from 14 Jan 2004
-
Kieran Morrissey authored
- Changes gen-devlist.c to truncate long device names rather than reject the database - Changes PCI_NAME_SIZE to 96 (and PCI_NAME_HALF to 43) to allow all current pci.ids names to fit - Modifies gen-devlist.c to truncate at 89 characters rather than 79 - allows for two digit instance numbers to be added to the name as well while staying within the 96 characters allocated. No names in the current pci.ids are any longer than this. - Modifies names.c to no longer limit device name length when displaying both vendor and device name; the truncation is done by gen-devlist.c.
-
John Rose authored
This lets the PPC pci hotplug driver initialize single devices, not just entire slots.
-
Leann Ogasawara authored
insert missing iounmap()
-
Ralf Bächle authored
-
Linda Xie authored
-
Takayoshi Kochi authored
This is the pending patch that adds 'address' file to show PCI-address and a few other minor fixes. As 2.6.0 is out, I'm resending the patch. Would you mind taking this? > > > Thanks. I had a little time to try your patch today. Sorry > > > to report that it isn't working for me. > > > > > > I first powered off (successfully the 1st time) a populated slot > > > and removed and reinserted the card into the same slot. The slot > > > powered back up but I was then unable to power it off. I believe > > > the following instruction that still exists in power_off_slot() > > > may be preventing the slot from being powered off more than once. > > > func->flags &= (~FUNC_EXISTS); > > > > > > I then tried to insert an adapter in an un-populated slot. For > > > some reason (which I don't understand yet) there was an enabling > > > error which I believe caused enable_device() to exit via a path > > > that bypassed the instruction that sets the FUNC_EXISTS flag. > > > I was then unable to power off the slot which I believe was due > > > to the FUNC_EXISTS flag not being set. > > > > > > I didn't have time to definitely confirmed the above theories. > > > I'll take a closer look at this tomorrow unless you are able > > > to diagnose using my vague clues :) > > > > It turns out that both of the above mentioned problems happened > > because the call to acpiphp_configure_slot() from enable_device() > > failed after inserting the card. When this happens enable_device() > > exits without setting the FUNC_EXISTS flag for any of the slot > > functions. Subsequent attempts to power off the same slot fail > > when power_off_slot() is unable to locate a function with both > > FUNC_HAS_EJ0 and FUNC_EXISTS flags set. > > > > The patch works okay when using a card that allows > > acpiphp_configure_slot() to succeed but I believe it should > > be improved to allow the slot to be powered off following > > device enablement errors. > > Thanks for testing and comments. > I really appreciate it. > > This problem turned out to be somewhat fragile state > transition: > > a lifecycle of a slot is (if there's no error) > > function state > ---------------------------------------------------- > 0 nothing > 1 power_on_slot() -> SLOT_POWERDON > 2 enable_device() -> SLOT_POWEREDON + SLOT_ENABLED > 3 disable_device() -> SLOT_POWEREDON > 4 power_off_slot() -> nothing > > but if any error occur during enable_device(), slot will remain > SLOT_POWERDON, but some functions on the card may not have > FUNC_EXISTS flags, which will eventually prevents powering > off in power_off_slot(), state transition from 1 to 4 directly. > I.e, the FUNC_EXISTS flag introduced more states to > complicate things. > > The FUNC_EXISTS flag was introduced after some discussion > between me and Irene Zubarev, but it has no more meaning > than that the function has corresponding 'pci_dev' structure. > So I eliminated the usage of FUNC_EXISTS and the result is > the patches attached to this mail (for both 2.4 and 2.6. > I think Greg already applied the 2.4 'cleanup' patch to his tree, > but it's not in Marcelo's release so I'm re-attaching to > this mail for anyone interested in this topic. It's identical > to the one I posted earlier). > These patches don't include Gary's patch in his post last week, > so please apply separately. > > Please note that current acpiphp driver cannot handle a > PCI card that has a PCI-to-PCI bridge on it (support > for such cards is incomplete). But if it's treated as > an error, it should be recoverable anyway.
-
Martin Hicks authored
This just gets rid of a stupid compile warning.
-
Matthew Wilcox authored
On Wed, Dec 17, 2003 at 04:24:44PM -0800, Greg KH wrote: > I've applied the pci portions of this patch to my trees and will send it > on after 2.6.0 is out. James Bottomley found a bug in it; could you also apply:
-
Greg Kroah-Hartman authored
This is in case others copy this code (which has already happened...)
-
Matthew Wilcox authored
tg3.c has a bug where it can find the wrong 5704 peer on a machine with PCI domains. The problem is that pci_find_slot() can't distinguish whether it has the correct domain or not. This patch fixes that problem by introducing pci_get_slot().
-
Matthew Dobson authored
This is needed to show pci bus topology to userspace properly.
-
Matthew Wilcox authored
When plugging a 33MHz card into a bus that's running at 66MHz, I'd like to see a better error message than: acpiphp_glue: notify_handler: unknown event type 0x5 for \_SB_.SBA0.PCI4.S2F0 The following patch would give us: Device \_SB_.SBA0.PCI4.S2F0 cannot be configured due to a frequency mismatch which I think is clearer.
-
Rolf Eike Beer authored
The functions are not named *_skel_*, so it seems useful not to call them with this.
-