patch-2.4.22 linux-2.4.22/drivers/net/8139cp.c

Next file: linux-2.4.22/drivers/net/8139too.c
Previous file: linux-2.4.22/drivers/net/3c59x.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.21/drivers/net/8139cp.c linux-2.4.22/drivers/net/8139cp.c
@@ -1771,7 +1771,6 @@
 	long pciaddr;
 	unsigned int addr_len, i;
 	u8 pci_rev, cache_size;
-	u16 pci_command;
 	unsigned int board_type = (unsigned int) ent->driver_data;
 
 #ifndef MODULE
@@ -1837,7 +1836,7 @@
 	}
 
 	/* Configure DMA attributes. */
-	if (!pci_set_dma_mask(pdev, (u64) 0xffffffffffffffff)) {
+	if (!pci_set_dma_mask(pdev, (u64) 0xffffffffffffffffULL)) {
 		cp->pci_using_dac = 1;
 	} else {
 		rc = pci_set_dma_mask(pdev, (u64) 0xffffffff);
@@ -1929,12 +1928,8 @@
 	}
 
 	/* enable busmastering and memory-write-invalidate */
-	pci_read_config_word(pdev, PCI_COMMAND, &pci_command);
-	if (!(pci_command & PCI_COMMAND_INVALIDATE)) {
-		pci_command |= PCI_COMMAND_INVALIDATE;
-		pci_write_config_word(pdev, PCI_COMMAND, pci_command);
-	}
 	pci_set_master(pdev);
+	pci_set_mwi(pdev);
 
 	if (cp->wol_enabled) cp_set_d3_state (cp);
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)