aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/ata/pata_platform.c3
-rw-r--r--drivers/kvm/svm.c2
-rw-r--r--drivers/mtd/nand/cafe.c1
-rw-r--r--drivers/net/82596.c7
-rw-r--r--drivers/net/b44.c52
-rw-r--r--drivers/net/bonding/bonding.h7
-rw-r--r--drivers/net/e100.c2
-rw-r--r--drivers/net/ehea/ehea.h2
-rw-r--r--drivers/net/ehea/ehea_main.c31
-rw-r--r--drivers/net/fs_enet/mac-fec.c13
-rw-r--r--drivers/net/fs_enet/mac-scc.c6
-rw-r--r--drivers/net/ifb.c3
-rw-r--r--drivers/net/phy/fixed.c2
-rw-r--r--drivers/net/sky2.c25
-rw-r--r--drivers/scsi/pcmcia/sym53c500_cs.c2
-rw-r--r--drivers/serial/amba-pl010.c2
-rw-r--r--drivers/serial/amba-pl011.c2
-rw-r--r--drivers/serial/atmel_serial.c7
-rw-r--r--drivers/serial/atmel_serial.h2
19 files changed, 97 insertions, 74 deletions
diff --git a/drivers/ata/pata_platform.c b/drivers/ata/pata_platform.c
index 443b1d85c6c4..40ae11cbfda4 100644
--- a/drivers/ata/pata_platform.c
+++ b/drivers/ata/pata_platform.c
@@ -30,7 +30,7 @@ static int pio_mask = 1;
30 * Provide our own set_mode() as we don't want to change anything that has 30 * Provide our own set_mode() as we don't want to change anything that has
31 * already been configured.. 31 * already been configured..
32 */ 32 */
33static void pata_platform_set_mode(struct ata_port *ap) 33static int pata_platform_set_mode(struct ata_port *ap, struct ata_device **unused)
34{ 34{
35 int i; 35 int i;
36 36
@@ -44,6 +44,7 @@ static void pata_platform_set_mode(struct ata_port *ap)
44 dev->flags |= ATA_DFLAG_PIO; 44 dev->flags |= ATA_DFLAG_PIO;
45 } 45 }
46 } 46 }
47 return 0;
47} 48}
48 49
49static void pata_platform_host_stop(struct ata_host *host) 50static void pata_platform_host_stop(struct ata_host *host)
diff --git a/drivers/kvm/svm.c b/drivers/kvm/svm.c
index 9c70ff65e6b7..c79df79307ed 100644
--- a/drivers/kvm/svm.c
+++ b/drivers/kvm/svm.c
@@ -1163,7 +1163,7 @@ static int svm_set_msr(struct kvm_vcpu *vcpu, unsigned ecx, u64 data)
1163 case MSR_K6_STAR: 1163 case MSR_K6_STAR:
1164 vcpu->svm->vmcb->save.star = data; 1164 vcpu->svm->vmcb->save.star = data;
1165 break; 1165 break;
1166#ifdef CONFIG_X86_64_ 1166#ifdef CONFIG_X86_64
1167 case MSR_LSTAR: 1167 case MSR_LSTAR:
1168 vcpu->svm->vmcb->save.lstar = data; 1168 vcpu->svm->vmcb->save.lstar = data;
1169 break; 1169 break;
diff --git a/drivers/mtd/nand/cafe.c b/drivers/mtd/nand/cafe.c
index b8d9b64cccc0..65f9bd3ceebf 100644
--- a/drivers/mtd/nand/cafe.c
+++ b/drivers/mtd/nand/cafe.c
@@ -14,6 +14,7 @@
14#include <linux/pci.h> 14#include <linux/pci.h>
15#include <linux/delay.h> 15#include <linux/delay.h>
16#include <linux/interrupt.h> 16#include <linux/interrupt.h>
17#include <linux/dma-mapping.h>
17#include <asm/io.h> 18#include <asm/io.h>
18 19
19#define CAFE_NAND_CTRL1 0x00 20#define CAFE_NAND_CTRL1 0x00
diff --git a/drivers/net/82596.c b/drivers/net/82596.c
index 8236f26ffd46..640d7ca2ebcf 100644
--- a/drivers/net/82596.c
+++ b/drivers/net/82596.c
@@ -1066,8 +1066,8 @@ static int i596_start_xmit(struct sk_buff *skb, struct net_device *dev)
1066 short length = skb->len; 1066 short length = skb->len;
1067 dev->trans_start = jiffies; 1067 dev->trans_start = jiffies;
1068 1068
1069 DEB(DEB_STARTTX,printk(KERN_DEBUG "%s: i596_start_xmit(%x,%x) called\n", dev->name, 1069 DEB(DEB_STARTTX,printk(KERN_DEBUG "%s: i596_start_xmit(%x,%p) called\n",
1070 skb->len, (unsigned int)skb->data)); 1070 dev->name, skb->len, skb->data));
1071 1071
1072 if (skb->len < ETH_ZLEN) { 1072 if (skb->len < ETH_ZLEN) {
1073 if (skb_padto(skb, ETH_ZLEN)) 1073 if (skb_padto(skb, ETH_ZLEN))
@@ -1246,7 +1246,8 @@ struct net_device * __init i82596_probe(int unit)
1246 dev->priv = (void *)(dev->mem_start); 1246 dev->priv = (void *)(dev->mem_start);
1247 1247
1248 lp = dev->priv; 1248 lp = dev->priv;
1249 DEB(DEB_INIT,printk(KERN_DEBUG "%s: lp at 0x%08lx (%d bytes), lp->scb at 0x%08lx\n", 1249 DEB(DEB_INIT,printk(KERN_DEBUG "%s: lp at 0x%08lx (%zd bytes), "
1250 "lp->scb at 0x%08lx\n",
1250 dev->name, (unsigned long)lp, 1251 dev->name, (unsigned long)lp,
1251 sizeof(struct i596_private), (unsigned long)&lp->scb)); 1252 sizeof(struct i596_private), (unsigned long)&lp->scb));
1252 memset((void *) lp, 0, sizeof(struct i596_private)); 1253 memset((void *) lp, 0, sizeof(struct i596_private));
diff --git a/drivers/net/b44.c b/drivers/net/b44.c
index 5eb2ec68393f..303a8d94ad4b 100644
--- a/drivers/net/b44.c
+++ b/drivers/net/b44.c
@@ -110,6 +110,11 @@ MODULE_DEVICE_TABLE(pci, b44_pci_tbl);
110 110
111static void b44_halt(struct b44 *); 111static void b44_halt(struct b44 *);
112static void b44_init_rings(struct b44 *); 112static void b44_init_rings(struct b44 *);
113
114#define B44_FULL_RESET 1
115#define B44_FULL_RESET_SKIP_PHY 2
116#define B44_PARTIAL_RESET 3
117
113static void b44_init_hw(struct b44 *, int); 118static void b44_init_hw(struct b44 *, int);
114 119
115static int dma_desc_align_mask; 120static int dma_desc_align_mask;
@@ -752,7 +757,7 @@ static void b44_recycle_rx(struct b44 *bp, int src_idx, u32 dest_idx_unmasked)
752 dest_idx * sizeof(dest_desc), 757 dest_idx * sizeof(dest_desc),
753 DMA_BIDIRECTIONAL); 758 DMA_BIDIRECTIONAL);
754 759
755 pci_dma_sync_single_for_device(bp->pdev, src_desc->addr, 760 pci_dma_sync_single_for_device(bp->pdev, le32_to_cpu(src_desc->addr),
756 RX_PKT_BUF_SZ, 761 RX_PKT_BUF_SZ,
757 PCI_DMA_FROMDEVICE); 762 PCI_DMA_FROMDEVICE);
758} 763}
@@ -884,7 +889,7 @@ static int b44_poll(struct net_device *netdev, int *budget)
884 spin_lock_irqsave(&bp->lock, flags); 889 spin_lock_irqsave(&bp->lock, flags);
885 b44_halt(bp); 890 b44_halt(bp);
886 b44_init_rings(bp); 891 b44_init_rings(bp);
887 b44_init_hw(bp, 1); 892 b44_init_hw(bp, B44_FULL_RESET_SKIP_PHY);
888 netif_wake_queue(bp->dev); 893 netif_wake_queue(bp->dev);
889 spin_unlock_irqrestore(&bp->lock, flags); 894 spin_unlock_irqrestore(&bp->lock, flags);
890 done = 1; 895 done = 1;
@@ -954,7 +959,7 @@ static void b44_tx_timeout(struct net_device *dev)
954 959
955 b44_halt(bp); 960 b44_halt(bp);
956 b44_init_rings(bp); 961 b44_init_rings(bp);
957 b44_init_hw(bp, 1); 962 b44_init_hw(bp, B44_FULL_RESET);
958 963
959 spin_unlock_irq(&bp->lock); 964 spin_unlock_irq(&bp->lock);
960 965
@@ -1071,7 +1076,7 @@ static int b44_change_mtu(struct net_device *dev, int new_mtu)
1071 b44_halt(bp); 1076 b44_halt(bp);
1072 dev->mtu = new_mtu; 1077 dev->mtu = new_mtu;
1073 b44_init_rings(bp); 1078 b44_init_rings(bp);
1074 b44_init_hw(bp, 1); 1079 b44_init_hw(bp, B44_FULL_RESET);
1075 spin_unlock_irq(&bp->lock); 1080 spin_unlock_irq(&bp->lock);
1076 1081
1077 b44_enable_ints(bp); 1082 b44_enable_ints(bp);
@@ -1368,12 +1373,12 @@ static int b44_set_mac_addr(struct net_device *dev, void *p)
1368 * packet processing. Invoked with bp->lock held. 1373 * packet processing. Invoked with bp->lock held.
1369 */ 1374 */
1370static void __b44_set_rx_mode(struct net_device *); 1375static void __b44_set_rx_mode(struct net_device *);
1371static void b44_init_hw(struct b44 *bp, int full_reset) 1376static void b44_init_hw(struct b44 *bp, int reset_kind)
1372{ 1377{
1373 u32 val; 1378 u32 val;
1374 1379
1375 b44_chip_reset(bp); 1380 b44_chip_reset(bp);
1376 if (full_reset) { 1381 if (reset_kind == B44_FULL_RESET) {
1377 b44_phy_reset(bp); 1382 b44_phy_reset(bp);
1378 b44_setup_phy(bp); 1383 b44_setup_phy(bp);
1379 } 1384 }
@@ -1390,7 +1395,10 @@ static void b44_init_hw(struct b44 *bp, int full_reset)
1390 bw32(bp, B44_TXMAXLEN, bp->dev->mtu + ETH_HLEN + 8 + RX_HEADER_LEN); 1395 bw32(bp, B44_TXMAXLEN, bp->dev->mtu + ETH_HLEN + 8 + RX_HEADER_LEN);
1391 1396
1392 bw32(bp, B44_TX_WMARK, 56); /* XXX magic */ 1397 bw32(bp, B44_TX_WMARK, 56); /* XXX magic */
1393 if (full_reset) { 1398 if (reset_kind == B44_PARTIAL_RESET) {
1399 bw32(bp, B44_DMARX_CTRL, (DMARX_CTRL_ENABLE |
1400 (bp->rx_offset << DMARX_CTRL_ROSHIFT)));
1401 } else {
1394 bw32(bp, B44_DMATX_CTRL, DMATX_CTRL_ENABLE); 1402 bw32(bp, B44_DMATX_CTRL, DMATX_CTRL_ENABLE);
1395 bw32(bp, B44_DMATX_ADDR, bp->tx_ring_dma + bp->dma_offset); 1403 bw32(bp, B44_DMATX_ADDR, bp->tx_ring_dma + bp->dma_offset);
1396 bw32(bp, B44_DMARX_CTRL, (DMARX_CTRL_ENABLE | 1404 bw32(bp, B44_DMARX_CTRL, (DMARX_CTRL_ENABLE |
@@ -1401,9 +1409,6 @@ static void b44_init_hw(struct b44 *bp, int full_reset)
1401 bp->rx_prod = bp->rx_pending; 1409 bp->rx_prod = bp->rx_pending;
1402 1410
1403 bw32(bp, B44_MIB_CTRL, MIB_CTRL_CLR_ON_READ); 1411 bw32(bp, B44_MIB_CTRL, MIB_CTRL_CLR_ON_READ);
1404 } else {
1405 bw32(bp, B44_DMARX_CTRL, (DMARX_CTRL_ENABLE |
1406 (bp->rx_offset << DMARX_CTRL_ROSHIFT)));
1407 } 1412 }
1408 1413
1409 val = br32(bp, B44_ENET_CTRL); 1414 val = br32(bp, B44_ENET_CTRL);
@@ -1420,7 +1425,7 @@ static int b44_open(struct net_device *dev)
1420 goto out; 1425 goto out;
1421 1426
1422 b44_init_rings(bp); 1427 b44_init_rings(bp);
1423 b44_init_hw(bp, 1); 1428 b44_init_hw(bp, B44_FULL_RESET);
1424 1429
1425 b44_check_phy(bp); 1430 b44_check_phy(bp);
1426 1431
@@ -1629,7 +1634,7 @@ static int b44_close(struct net_device *dev)
1629 netif_poll_enable(dev); 1634 netif_poll_enable(dev);
1630 1635
1631 if (bp->flags & B44_FLAG_WOL_ENABLE) { 1636 if (bp->flags & B44_FLAG_WOL_ENABLE) {
1632 b44_init_hw(bp, 0); 1637 b44_init_hw(bp, B44_PARTIAL_RESET);
1633 b44_setup_wol(bp); 1638 b44_setup_wol(bp);
1634 } 1639 }
1635 1640
@@ -1905,7 +1910,7 @@ static int b44_set_ringparam(struct net_device *dev,
1905 1910
1906 b44_halt(bp); 1911 b44_halt(bp);
1907 b44_init_rings(bp); 1912 b44_init_rings(bp);
1908 b44_init_hw(bp, 1); 1913 b44_init_hw(bp, B44_FULL_RESET);
1909 netif_wake_queue(bp->dev); 1914 netif_wake_queue(bp->dev);
1910 spin_unlock_irq(&bp->lock); 1915 spin_unlock_irq(&bp->lock);
1911 1916
@@ -1948,7 +1953,7 @@ static int b44_set_pauseparam(struct net_device *dev,
1948 if (bp->flags & B44_FLAG_PAUSE_AUTO) { 1953 if (bp->flags & B44_FLAG_PAUSE_AUTO) {
1949 b44_halt(bp); 1954 b44_halt(bp);
1950 b44_init_rings(bp); 1955 b44_init_rings(bp);
1951 b44_init_hw(bp, 1); 1956 b44_init_hw(bp, B44_FULL_RESET);
1952 } else { 1957 } else {
1953 __b44_set_flow_ctrl(bp, bp->flags); 1958 __b44_set_flow_ctrl(bp, bp->flags);
1954 } 1959 }
@@ -2304,7 +2309,7 @@ static int b44_suspend(struct pci_dev *pdev, pm_message_t state)
2304 2309
2305 free_irq(dev->irq, dev); 2310 free_irq(dev->irq, dev);
2306 if (bp->flags & B44_FLAG_WOL_ENABLE) { 2311 if (bp->flags & B44_FLAG_WOL_ENABLE) {
2307 b44_init_hw(bp, 0); 2312 b44_init_hw(bp, B44_PARTIAL_RESET);
2308 b44_setup_wol(bp); 2313 b44_setup_wol(bp);
2309 } 2314 }
2310 pci_disable_device(pdev); 2315 pci_disable_device(pdev);
@@ -2315,21 +2320,32 @@ static int b44_resume(struct pci_dev *pdev)
2315{ 2320{
2316 struct net_device *dev = pci_get_drvdata(pdev); 2321 struct net_device *dev = pci_get_drvdata(pdev);
2317 struct b44 *bp = netdev_priv(dev); 2322 struct b44 *bp = netdev_priv(dev);
2323 int rc = 0;
2318 2324
2319 pci_restore_state(pdev); 2325 pci_restore_state(pdev);
2320 pci_enable_device(pdev); 2326 rc = pci_enable_device(pdev);
2327 if (rc) {
2328 printk(KERN_ERR PFX "%s: pci_enable_device failed\n",
2329 dev->name);
2330 return rc;
2331 }
2332
2321 pci_set_master(pdev); 2333 pci_set_master(pdev);
2322 2334
2323 if (!netif_running(dev)) 2335 if (!netif_running(dev))
2324 return 0; 2336 return 0;
2325 2337
2326 if (request_irq(dev->irq, b44_interrupt, IRQF_SHARED, dev->name, dev)) 2338 rc = request_irq(dev->irq, b44_interrupt, IRQF_SHARED, dev->name, dev);
2339 if (rc) {
2327 printk(KERN_ERR PFX "%s: request_irq failed\n", dev->name); 2340 printk(KERN_ERR PFX "%s: request_irq failed\n", dev->name);
2341 pci_disable_device(pdev);
2342 return rc;
2343 }
2328 2344
2329 spin_lock_irq(&bp->lock); 2345 spin_lock_irq(&bp->lock);
2330 2346
2331 b44_init_rings(bp); 2347 b44_init_rings(bp);
2332 b44_init_hw(bp, 1); 2348 b44_init_hw(bp, B44_FULL_RESET);
2333 netif_device_attach(bp->dev); 2349 netif_device_attach(bp->dev);
2334 spin_unlock_irq(&bp->lock); 2350 spin_unlock_irq(&bp->lock);
2335 2351
diff --git a/drivers/net/bonding/bonding.h b/drivers/net/bonding/bonding.h
index dc434fb6da85..0978c9ac6d2b 100644
--- a/drivers/net/bonding/bonding.h
+++ b/drivers/net/bonding/bonding.h
@@ -151,8 +151,8 @@ struct slave {
151 struct slave *next; 151 struct slave *next;
152 struct slave *prev; 152 struct slave *prev;
153 int delay; 153 int delay;
154 u32 jiffies; 154 unsigned long jiffies;
155 u32 last_arp_rx; 155 unsigned long last_arp_rx;
156 s8 link; /* one of BOND_LINK_XXXX */ 156 s8 link; /* one of BOND_LINK_XXXX */
157 s8 state; /* one of BOND_STATE_XXXX */ 157 s8 state; /* one of BOND_STATE_XXXX */
158 u32 original_flags; 158 u32 original_flags;
@@ -242,7 +242,8 @@ extern inline int slave_do_arp_validate(struct bonding *bond, struct slave *slav
242 return bond->params.arp_validate & (1 << slave->state); 242 return bond->params.arp_validate & (1 << slave->state);
243} 243}
244 244
245extern inline u32 slave_last_rx(struct bonding *bond, struct slave *slave) 245extern inline unsigned long slave_last_rx(struct bonding *bond,
246 struct slave *slave)
246{ 247{
247 if (slave_do_arp_validate(bond, slave)) 248 if (slave_do_arp_validate(bond, slave))
248 return slave->last_arp_rx; 249 return slave->last_arp_rx;
diff --git a/drivers/net/e100.c b/drivers/net/e100.c
index c2ae2a24629b..3208dac29168 100644
--- a/drivers/net/e100.c
+++ b/drivers/net/e100.c
@@ -2725,6 +2725,7 @@ static int e100_suspend(struct pci_dev *pdev, pm_message_t state)
2725 del_timer_sync(&nic->watchdog); 2725 del_timer_sync(&nic->watchdog);
2726 netif_carrier_off(nic->netdev); 2726 netif_carrier_off(nic->netdev);
2727 2727
2728 netif_device_detach(netdev);
2728 pci_save_state(pdev); 2729 pci_save_state(pdev);
2729 2730
2730 if ((nic->flags & wol_magic) | e100_asf(nic)) { 2731 if ((nic->flags & wol_magic) | e100_asf(nic)) {
@@ -2736,6 +2737,7 @@ static int e100_suspend(struct pci_dev *pdev, pm_message_t state)
2736 } 2737 }
2737 2738
2738 pci_disable_device(pdev); 2739 pci_disable_device(pdev);
2740 free_irq(pdev->irq, netdev);
2739 pci_set_power_state(pdev, PCI_D3hot); 2741 pci_set_power_state(pdev, PCI_D3hot);
2740 2742
2741 return 0; 2743 return 0;
diff --git a/drivers/net/ehea/ehea.h b/drivers/net/ehea/ehea.h
index be10a3a26b5b..272e1ec51aa2 100644
--- a/drivers/net/ehea/ehea.h
+++ b/drivers/net/ehea/ehea.h
@@ -39,7 +39,7 @@
39#include <asm/io.h> 39#include <asm/io.h>
40 40
41#define DRV_NAME "ehea" 41#define DRV_NAME "ehea"
42#define DRV_VERSION "EHEA_0044" 42#define DRV_VERSION "EHEA_0045"
43 43
44#define EHEA_MSG_DEFAULT (NETIF_MSG_LINK | NETIF_MSG_TIMER \ 44#define EHEA_MSG_DEFAULT (NETIF_MSG_LINK | NETIF_MSG_TIMER \
45 | NETIF_MSG_RX_ERR | NETIF_MSG_TX_ERR) 45 | NETIF_MSG_RX_ERR | NETIF_MSG_TX_ERR)
diff --git a/drivers/net/ehea/ehea_main.c b/drivers/net/ehea/ehea_main.c
index 1072e69ef85d..9de2d38a5321 100644
--- a/drivers/net/ehea/ehea_main.c
+++ b/drivers/net/ehea/ehea_main.c
@@ -2316,6 +2316,7 @@ static int ehea_setup_single_port(struct ehea_port *port,
2316 struct ehea_adapter *adapter = port->adapter; 2316 struct ehea_adapter *adapter = port->adapter;
2317 struct hcp_ehea_port_cb4 *cb4; 2317 struct hcp_ehea_port_cb4 *cb4;
2318 u32 *dn_log_port_id; 2318 u32 *dn_log_port_id;
2319 int jumbo = 0;
2319 2320
2320 sema_init(&port->port_lock, 1); 2321 sema_init(&port->port_lock, 1);
2321 port->state = EHEA_PORT_DOWN; 2322 port->state = EHEA_PORT_DOWN;
@@ -2357,13 +2358,25 @@ static int ehea_setup_single_port(struct ehea_port *port,
2357 if (!cb4) { 2358 if (!cb4) {
2358 ehea_error("no mem for cb4"); 2359 ehea_error("no mem for cb4");
2359 } else { 2360 } else {
2360 cb4->jumbo_frame = 1; 2361 hret = ehea_h_query_ehea_port(adapter->handle,
2361 hret = ehea_h_modify_ehea_port(adapter->handle, 2362 port->logical_port_id,
2362 port->logical_port_id, 2363 H_PORT_CB4,
2363 H_PORT_CB4, H_PORT_CB4_JUMBO, 2364 H_PORT_CB4_JUMBO, cb4);
2364 cb4); 2365
2365 if (hret != H_SUCCESS) { 2366 if (hret == H_SUCCESS) {
2366 ehea_info("Jumbo frames not activated"); 2367 if (cb4->jumbo_frame)
2368 jumbo = 1;
2369 else {
2370 cb4->jumbo_frame = 1;
2371 hret = ehea_h_modify_ehea_port(adapter->handle,
2372 port->
2373 logical_port_id,
2374 H_PORT_CB4,
2375 H_PORT_CB4_JUMBO,
2376 cb4);
2377 if (hret == H_SUCCESS)
2378 jumbo = 1;
2379 }
2367 } 2380 }
2368 kfree(cb4); 2381 kfree(cb4);
2369 } 2382 }
@@ -2402,6 +2415,9 @@ static int ehea_setup_single_port(struct ehea_port *port,
2402 goto out_free; 2415 goto out_free;
2403 } 2416 }
2404 2417
2418 ehea_info("%s: Jumbo frames are %sabled", dev->name,
2419 jumbo == 1 ? "en" : "dis");
2420
2405 port->netdev = dev; 2421 port->netdev = dev;
2406 ret = 0; 2422 ret = 0;
2407 goto out; 2423 goto out;
@@ -2582,6 +2598,7 @@ static int __devexit ehea_remove(struct ibmebus_dev *dev)
2582 destroy_workqueue(adapter->ehea_wq); 2598 destroy_workqueue(adapter->ehea_wq);
2583 2599
2584 ibmebus_free_irq(NULL, adapter->neq->attr.ist1, adapter); 2600 ibmebus_free_irq(NULL, adapter->neq->attr.ist1, adapter);
2601 tasklet_kill(&adapter->neq_tasklet);
2585 2602
2586 ehea_destroy_eq(adapter->neq); 2603 ehea_destroy_eq(adapter->neq);
2587 2604
diff --git a/drivers/net/fs_enet/mac-fec.c b/drivers/net/fs_enet/mac-fec.c
index c2c5fd419bd0..ff6839477306 100644
--- a/drivers/net/fs_enet/mac-fec.c
+++ b/drivers/net/fs_enet/mac-fec.c
@@ -104,9 +104,9 @@ static int do_pd_setup(struct fs_enet_private *fep)
104 fep->interrupt = platform_get_irq_byname(pdev,"interrupt"); 104 fep->interrupt = platform_get_irq_byname(pdev,"interrupt");
105 if (fep->interrupt < 0) 105 if (fep->interrupt < 0)
106 return -EINVAL; 106 return -EINVAL;
107 107
108 r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "regs"); 108 r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "regs");
109 fep->fec.fecp =(void*)r->start; 109 fep->fec.fecp = ioremap(r->start, r->end - r->start + 1);
110 110
111 if(fep->fec.fecp == NULL) 111 if(fep->fec.fecp == NULL)
112 return -EINVAL; 112 return -EINVAL;
@@ -319,11 +319,14 @@ static void restart(struct net_device *dev)
319 * Clear any outstanding interrupt. 319 * Clear any outstanding interrupt.
320 */ 320 */
321 FW(fecp, ievent, 0xffc0); 321 FW(fecp, ievent, 0xffc0);
322#ifndef CONFIG_PPC_MERGE
322 FW(fecp, ivec, (fep->interrupt / 2) << 29); 323 FW(fecp, ivec, (fep->interrupt / 2) << 29);
323 324#else
325 FW(fecp, ivec, (virq_to_hw(fep->interrupt) / 2) << 29);
326#endif
324 327
325 /* 328 /*
326 * adjust to speed (only for DUET & RMII) 329 * adjust to speed (only for DUET & RMII)
327 */ 330 */
328#ifdef CONFIG_DUET 331#ifdef CONFIG_DUET
329 if (fpi->use_rmii) { 332 if (fpi->use_rmii) {
@@ -418,6 +421,7 @@ static void stop(struct net_device *dev)
418 421
419static void pre_request_irq(struct net_device *dev, int irq) 422static void pre_request_irq(struct net_device *dev, int irq)
420{ 423{
424#ifndef CONFIG_PPC_MERGE
421 immap_t *immap = fs_enet_immap; 425 immap_t *immap = fs_enet_immap;
422 u32 siel; 426 u32 siel;
423 427
@@ -431,6 +435,7 @@ static void pre_request_irq(struct net_device *dev, int irq)
431 siel &= ~(0x80000000 >> (irq & ~1)); 435 siel &= ~(0x80000000 >> (irq & ~1));
432 out_be32(&immap->im_siu_conf.sc_siel, siel); 436 out_be32(&immap->im_siu_conf.sc_siel, siel);
433 } 437 }
438#endif
434} 439}
435 440
436static void post_free_irq(struct net_device *dev, int irq) 441static void post_free_irq(struct net_device *dev, int irq)
diff --git a/drivers/net/fs_enet/mac-scc.c b/drivers/net/fs_enet/mac-scc.c
index 95ec5872c507..afd7fca7c6c4 100644
--- a/drivers/net/fs_enet/mac-scc.c
+++ b/drivers/net/fs_enet/mac-scc.c
@@ -121,13 +121,13 @@ static int do_pd_setup(struct fs_enet_private *fep)
121 return -EINVAL; 121 return -EINVAL;
122 122
123 r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "regs"); 123 r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "regs");
124 fep->scc.sccp = (void *)r->start; 124 fep->scc.sccp = ioremap(r->start, r->end - r->start + 1);
125 125
126 if (fep->scc.sccp == NULL) 126 if (fep->scc.sccp == NULL)
127 return -EINVAL; 127 return -EINVAL;
128 128
129 r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "pram"); 129 r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "pram");
130 fep->scc.ep = (void *)r->start; 130 fep->scc.ep = ioremap(r->start, r->end - r->start + 1);
131 131
132 if (fep->scc.ep == NULL) 132 if (fep->scc.ep == NULL)
133 return -EINVAL; 133 return -EINVAL;
@@ -397,6 +397,7 @@ static void stop(struct net_device *dev)
397 397
398static void pre_request_irq(struct net_device *dev, int irq) 398static void pre_request_irq(struct net_device *dev, int irq)
399{ 399{
400#ifndef CONFIG_PPC_MERGE
400 immap_t *immap = fs_enet_immap; 401 immap_t *immap = fs_enet_immap;
401 u32 siel; 402 u32 siel;
402 403
@@ -410,6 +411,7 @@ static void pre_request_irq(struct net_device *dev, int irq)
410 siel &= ~(0x80000000 >> (irq & ~1)); 411 siel &= ~(0x80000000 >> (irq & ~1));
411 out_be32(&immap->im_siu_conf.sc_siel, siel); 412 out_be32(&immap->im_siu_conf.sc_siel, siel);
412 } 413 }
414#endif
413} 415}
414 416
415static void post_free_irq(struct net_device *dev, int irq) 417static void post_free_irq(struct net_device *dev, int irq)
diff --git a/drivers/net/ifb.c b/drivers/net/ifb.c
index ca2b21f9d444..c4ca7c930a46 100644
--- a/drivers/net/ifb.c
+++ b/drivers/net/ifb.c
@@ -271,8 +271,7 @@ static int __init ifb_init_module(void)
271 for (i = 0; i < numifbs && !err; i++) 271 for (i = 0; i < numifbs && !err; i++)
272 err = ifb_init_one(i); 272 err = ifb_init_one(i);
273 if (err) { 273 if (err) {
274 i--; 274 while (i--)
275 while (--i >= 0)
276 ifb_free_one(i); 275 ifb_free_one(i);
277 } 276 }
278 277
diff --git a/drivers/net/phy/fixed.c b/drivers/net/phy/fixed.c
index 096d4a100bf2..86135397f430 100644
--- a/drivers/net/phy/fixed.c
+++ b/drivers/net/phy/fixed.c
@@ -349,7 +349,7 @@ static int __init fixed_init(void)
349 fixed_mdio_register_device(0, 100, 1); 349 fixed_mdio_register_device(0, 100, 1);
350#endif 350#endif
351 351
352#ifdef CONFIX_FIXED_MII_10_FDX 352#ifdef CONFIG_FIXED_MII_10_FDX
353 fixed_mdio_register_device(0, 10, 1); 353 fixed_mdio_register_device(0, 10, 1);
354#endif 354#endif
355 return 0; 355 return 0;
diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c
index a2e804ddca6c..822dd0b13133 100644
--- a/drivers/net/sky2.c
+++ b/drivers/net/sky2.c
@@ -3639,29 +3639,6 @@ static int sky2_resume(struct pci_dev *pdev)
3639out: 3639out:
3640 return err; 3640 return err;
3641} 3641}
3642
3643/* BIOS resume runs after device (it's a bug in PM)
3644 * as a temporary workaround on suspend/resume leave MSI disabled
3645 */
3646static int sky2_suspend_late(struct pci_dev *pdev, pm_message_t state)
3647{
3648 struct sky2_hw *hw = pci_get_drvdata(pdev);
3649
3650 free_irq(pdev->irq, hw);
3651 if (hw->msi) {
3652 pci_disable_msi(pdev);
3653 hw->msi = 0;
3654 }
3655 return 0;
3656}
3657
3658static int sky2_resume_early(struct pci_dev *pdev)
3659{
3660 struct sky2_hw *hw = pci_get_drvdata(pdev);
3661 struct net_device *dev = hw->dev[0];
3662
3663 return request_irq(pdev->irq, sky2_intr, IRQF_SHARED, dev->name, hw);
3664}
3665#endif 3642#endif
3666 3643
3667static struct pci_driver sky2_driver = { 3644static struct pci_driver sky2_driver = {
@@ -3672,8 +3649,6 @@ static struct pci_driver sky2_driver = {
3672#ifdef CONFIG_PM 3649#ifdef CONFIG_PM
3673 .suspend = sky2_suspend, 3650 .suspend = sky2_suspend,
3674 .resume = sky2_resume, 3651 .resume = sky2_resume,
3675 .suspend_late = sky2_suspend_late,
3676 .resume_early = sky2_resume_early,
3677#endif 3652#endif
3678}; 3653};
3679 3654
diff --git a/drivers/scsi/pcmcia/sym53c500_cs.c b/drivers/scsi/pcmcia/sym53c500_cs.c
index 9fb0ea5c1fb9..5b458d2478f7 100644
--- a/drivers/scsi/pcmcia/sym53c500_cs.c
+++ b/drivers/scsi/pcmcia/sym53c500_cs.c
@@ -545,8 +545,6 @@ SYM53C500_release(struct pcmcia_device *link)
545 */ 545 */
546 if (shost->irq) 546 if (shost->irq)
547 free_irq(shost->irq, shost); 547 free_irq(shost->irq, shost);
548 if (shost->dma_channel != 0xff)
549 free_dma(shost->dma_channel);
550 if (shost->io_port && shost->n_io_port) 548 if (shost->io_port && shost->n_io_port)
551 release_region(shost->io_port, shost->n_io_port); 549 release_region(shost->io_port, shost->n_io_port);
552 550
diff --git a/drivers/serial/amba-pl010.c b/drivers/serial/amba-pl010.c
index 61db6973755a..f69bd097166e 100644
--- a/drivers/serial/amba-pl010.c
+++ b/drivers/serial/amba-pl010.c
@@ -589,6 +589,8 @@ static int __init pl010_console_setup(struct console *co, char *options)
589 */ 589 */
590 if (co->index >= UART_NR) 590 if (co->index >= UART_NR)
591 co->index = 0; 591 co->index = 0;
592 if (!amba_ports[co->index])
593 return -ENODEV;
592 port = &amba_ports[co->index]->port; 594 port = &amba_ports[co->index]->port;
593 595
594 if (options) 596 if (options)
diff --git a/drivers/serial/amba-pl011.c b/drivers/serial/amba-pl011.c
index 9a3b374b2a08..44639e71372a 100644
--- a/drivers/serial/amba-pl011.c
+++ b/drivers/serial/amba-pl011.c
@@ -661,6 +661,8 @@ static int __init pl011_console_setup(struct console *co, char *options)
661 if (co->index >= UART_NR) 661 if (co->index >= UART_NR)
662 co->index = 0; 662 co->index = 0;
663 uap = amba_ports[co->index]; 663 uap = amba_ports[co->index];
664 if (!uap)
665 return -ENODEV;
664 666
665 uap->port.uartclk = clk_get_rate(uap->clk); 667 uap->port.uartclk = clk_get_rate(uap->clk);
666 668
diff --git a/drivers/serial/atmel_serial.c b/drivers/serial/atmel_serial.c
index ed7f7209ea59..881f886b91c6 100644
--- a/drivers/serial/atmel_serial.c
+++ b/drivers/serial/atmel_serial.c
@@ -689,9 +689,9 @@ static void __devinit atmel_init_port(struct atmel_uart_port *atmel_port, struct
689 struct atmel_uart_data *data = pdev->dev.platform_data; 689 struct atmel_uart_data *data = pdev->dev.platform_data;
690 690
691 port->iotype = UPIO_MEM; 691 port->iotype = UPIO_MEM;
692 port->flags = UPF_BOOT_AUTOCONF; 692 port->flags = UPF_BOOT_AUTOCONF;
693 port->ops = &atmel_pops; 693 port->ops = &atmel_pops;
694 port->fifosize = 1; 694 port->fifosize = 1;
695 port->line = pdev->id; 695 port->line = pdev->id;
696 port->dev = &pdev->dev; 696 port->dev = &pdev->dev;
697 697
@@ -890,7 +890,6 @@ static int atmel_serial_suspend(struct platform_device *pdev, pm_message_t state
890 if (device_may_wakeup(&pdev->dev) && !at91_suspend_entering_slow_clock()) 890 if (device_may_wakeup(&pdev->dev) && !at91_suspend_entering_slow_clock())
891 enable_irq_wake(port->irq); 891 enable_irq_wake(port->irq);
892 else { 892 else {
893 disable_irq_wake(port->irq);
894 uart_suspend_port(&atmel_uart, port); 893 uart_suspend_port(&atmel_uart, port);
895 atmel_port->suspended = 1; 894 atmel_port->suspended = 1;
896 } 895 }
@@ -907,6 +906,8 @@ static int atmel_serial_resume(struct platform_device *pdev)
907 uart_resume_port(&atmel_uart, port); 906 uart_resume_port(&atmel_uart, port);
908 atmel_port->suspended = 0; 907 atmel_port->suspended = 0;
909 } 908 }
909 else
910 disable_irq_wake(port->irq);
910 911
911 return 0; 912 return 0;
912} 913}
diff --git a/drivers/serial/atmel_serial.h b/drivers/serial/atmel_serial.h
index fe1763b2a6d5..11b44360e108 100644
--- a/drivers/serial/atmel_serial.h
+++ b/drivers/serial/atmel_serial.h
@@ -106,7 +106,7 @@
106#define ATMEL_US_CSR 0x14 /* Channel Status Register */ 106#define ATMEL_US_CSR 0x14 /* Channel Status Register */
107#define ATMEL_US_RHR 0x18 /* Receiver Holding Register */ 107#define ATMEL_US_RHR 0x18 /* Receiver Holding Register */
108#define ATMEL_US_THR 0x1c /* Transmitter Holding Register */ 108#define ATMEL_US_THR 0x1c /* Transmitter Holding Register */
109#define ATMEL_US_SYNH (1 << 15) /* Transmit/Receive Sync [SAM9 only] */ 109#define ATMEL_US_SYNH (1 << 15) /* Transmit/Receive Sync [AT91SAM9261 only] */
110 110
111#define ATMEL_US_BRGR 0x20 /* Baud Rate Generator Register */ 111#define ATMEL_US_BRGR 0x20 /* Baud Rate Generator Register */
112#define ATMEL_US_CD (0xffff << 0) /* Clock Divider */ 112#define ATMEL_US_CD (0xffff << 0) /* Clock Divider */