diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-12 16:40:57 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-12 16:40:57 -0400 |
commit | 21ba0f88ae56da82a3a15fe54d729208b64c4f4b (patch) | |
tree | 17ce67f276fe3ea7284c3dc730bdd6a2ec7dfe2f /drivers/net/cassini.c | |
parent | dc690d8ef842b464f1c429a376ca16cb8dbee6ae (diff) | |
parent | 36e235901f90fb83215be43cbd8f1ca14661ea40 (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: (34 commits)
PCI: Only build PCI syscalls on architectures that want them
PCI: limit pci_get_bus_and_slot to domain 0
PCI: hotplug: acpiphp: avoid acpiphp "cannot get bridge info" PCI hotplug failure
PCI: hotplug: acpiphp: remove hot plug parameter write to PCI host bridge
PCI: hotplug: acpiphp: fix slot poweroff problem on systems without _PS3
PCI: hotplug: pciehp: wait for 1 second after power off slot
PCI: pci_set_power_state(): check for PM capabilities earlier
PCI: cpci_hotplug: Convert to use the kthread API
PCI: add pci_try_set_mwi
PCI: pcie: remove SPIN_LOCK_UNLOCKED
PCI: ROUND_UP macro cleanup in drivers/pci
PCI: remove pci_dac_dma_... APIs
PCI: pci-x-pci-express-read-control-interfaces cleanups
PCI: Fix typo in include/linux/pci.h
PCI: pci_ids, remove double or more empty lines
PCI: pci_ids, add atheros and 3com_2 vendors
PCI: pci_ids, reorder some entries
PCI: i386: traps, change VENDOR to DEVICE
PCI: ATM: lanai, change VENDOR to DEVICE
PCI: Change all drivers to use pci_device->revision
...
Diffstat (limited to 'drivers/net/cassini.c')
-rw-r--r-- | drivers/net/cassini.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/drivers/net/cassini.c b/drivers/net/cassini.c index 59b9943b077d..f6e4030c73d1 100644 --- a/drivers/net/cassini.c +++ b/drivers/net/cassini.c | |||
@@ -3422,21 +3422,19 @@ done: | |||
3422 | static void cas_check_pci_invariants(struct cas *cp) | 3422 | static void cas_check_pci_invariants(struct cas *cp) |
3423 | { | 3423 | { |
3424 | struct pci_dev *pdev = cp->pdev; | 3424 | struct pci_dev *pdev = cp->pdev; |
3425 | u8 rev; | ||
3426 | 3425 | ||
3427 | cp->cas_flags = 0; | 3426 | cp->cas_flags = 0; |
3428 | pci_read_config_byte(pdev, PCI_REVISION_ID, &rev); | ||
3429 | if ((pdev->vendor == PCI_VENDOR_ID_SUN) && | 3427 | if ((pdev->vendor == PCI_VENDOR_ID_SUN) && |
3430 | (pdev->device == PCI_DEVICE_ID_SUN_CASSINI)) { | 3428 | (pdev->device == PCI_DEVICE_ID_SUN_CASSINI)) { |
3431 | if (rev >= CAS_ID_REVPLUS) | 3429 | if (pdev->revision >= CAS_ID_REVPLUS) |
3432 | cp->cas_flags |= CAS_FLAG_REG_PLUS; | 3430 | cp->cas_flags |= CAS_FLAG_REG_PLUS; |
3433 | if (rev < CAS_ID_REVPLUS02u) | 3431 | if (pdev->revision < CAS_ID_REVPLUS02u) |
3434 | cp->cas_flags |= CAS_FLAG_TARGET_ABORT; | 3432 | cp->cas_flags |= CAS_FLAG_TARGET_ABORT; |
3435 | 3433 | ||
3436 | /* Original Cassini supports HW CSUM, but it's not | 3434 | /* Original Cassini supports HW CSUM, but it's not |
3437 | * enabled by default as it can trigger TX hangs. | 3435 | * enabled by default as it can trigger TX hangs. |
3438 | */ | 3436 | */ |
3439 | if (rev < CAS_ID_REV2) | 3437 | if (pdev->revision < CAS_ID_REV2) |
3440 | cp->cas_flags |= CAS_FLAG_NO_HW_CSUM; | 3438 | cp->cas_flags |= CAS_FLAG_NO_HW_CSUM; |
3441 | } else { | 3439 | } else { |
3442 | /* Only sun has original cassini chips. */ | 3440 | /* Only sun has original cassini chips. */ |
@@ -4919,13 +4917,13 @@ static int __devinit cas_init_one(struct pci_dev *pdev, | |||
4919 | pci_cmd &= ~PCI_COMMAND_SERR; | 4917 | pci_cmd &= ~PCI_COMMAND_SERR; |
4920 | pci_cmd |= PCI_COMMAND_PARITY; | 4918 | pci_cmd |= PCI_COMMAND_PARITY; |
4921 | pci_write_config_word(pdev, PCI_COMMAND, pci_cmd); | 4919 | pci_write_config_word(pdev, PCI_COMMAND, pci_cmd); |
4922 | if (pci_set_mwi(pdev)) | 4920 | if (pci_try_set_mwi(pdev)) |
4923 | printk(KERN_WARNING PFX "Could not enable MWI for %s\n", | 4921 | printk(KERN_WARNING PFX "Could not enable MWI for %s\n", |
4924 | pci_name(pdev)); | 4922 | pci_name(pdev)); |
4925 | 4923 | ||
4926 | /* | 4924 | /* |
4927 | * On some architectures, the default cache line size set | 4925 | * On some architectures, the default cache line size set |
4928 | * by pci_set_mwi reduces perforamnce. We have to increase | 4926 | * by pci_try_set_mwi reduces perforamnce. We have to increase |
4929 | * it for this case. To start, we'll print some configuration | 4927 | * it for this case. To start, we'll print some configuration |
4930 | * data. | 4928 | * data. |
4931 | */ | 4929 | */ |