Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 26603
b: refs/heads/master
c: 0e44dc3
h: refs/heads/master
i:
  26601: 0c70d45
  26599: f739604
v: v3
  • Loading branch information
Linus Torvalds committed May 10, 2006
1 parent e3dbcf9 commit fa1e6ef
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 18 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ce477ae4f8c75c94587c3157deffad8219db09a0
refs/heads/master: 0e44dc383787b472a7f13564c6bd8a44cc07d408
10 changes: 6 additions & 4 deletions trunk/drivers/char/pcmcia/cm4000_cs.c
Original file line number Diff line number Diff line change
Expand Up @@ -1981,17 +1981,19 @@ static int __init cmm_init(void)
if (!cmm_class)
return -1;

rc = pcmcia_register_driver(&cm4000_driver);
if (rc < 0)
return rc;

major = register_chrdev(0, DEVICE_NAME, &cm4000_fops);
if (major < 0) {
printk(KERN_WARNING MODULE_NAME
": could not get major number\n");
return -1;
}

rc = pcmcia_register_driver(&cm4000_driver);
if (rc < 0) {
unregister_chrdev(major, DEVICE_NAME);
return rc;
}

return 0;
}

Expand Down
11 changes: 7 additions & 4 deletions trunk/drivers/char/pcmcia/cm4040_cs.c
Original file line number Diff line number Diff line change
Expand Up @@ -724,16 +724,19 @@ static int __init cm4040_init(void)
if (!cmx_class)
return -1;

rc = pcmcia_register_driver(&reader_driver);
if (rc < 0)
return rc;

major = register_chrdev(0, DEVICE_NAME, &reader_fops);
if (major < 0) {
printk(KERN_WARNING MODULE_NAME
": could not get major number\n");
return -1;
}

rc = pcmcia_register_driver(&reader_driver);
if (rc < 0) {
unregister_chrdev(major, DEVICE_NAME);
return rc;
}

return 0;
}

Expand Down
12 changes: 6 additions & 6 deletions trunk/drivers/net/dl2k.c
Original file line number Diff line number Diff line change
Expand Up @@ -765,7 +765,7 @@ rio_free_tx (struct net_device *dev, int irq)
break;
skb = np->tx_skbuff[entry];
pci_unmap_single (np->pdev,
np->tx_ring[entry].fraginfo & 0xffffffffffff,
np->tx_ring[entry].fraginfo & DMA_48BIT_MASK,
skb->len, PCI_DMA_TODEVICE);
if (irq)
dev_kfree_skb_irq (skb);
Expand Down Expand Up @@ -893,15 +893,15 @@ receive_packet (struct net_device *dev)
/* Small skbuffs for short packets */
if (pkt_len > copy_thresh) {
pci_unmap_single (np->pdev,
desc->fraginfo & 0xffffffffffff,
desc->fraginfo & DMA_48BIT_MASK,
np->rx_buf_sz,
PCI_DMA_FROMDEVICE);
skb_put (skb = np->rx_skbuff[entry], pkt_len);
np->rx_skbuff[entry] = NULL;
} else if ((skb = dev_alloc_skb (pkt_len + 2)) != NULL) {
pci_dma_sync_single_for_cpu(np->pdev,
desc->fraginfo &
0xffffffffffff,
DMA_48BIT_MASK,
np->rx_buf_sz,
PCI_DMA_FROMDEVICE);
skb->dev = dev;
Expand All @@ -913,7 +913,7 @@ receive_packet (struct net_device *dev)
skb_put (skb, pkt_len);
pci_dma_sync_single_for_device(np->pdev,
desc->fraginfo &
0xffffffffffff,
DMA_48BIT_MASK,
np->rx_buf_sz,
PCI_DMA_FROMDEVICE);
}
Expand Down Expand Up @@ -1800,7 +1800,7 @@ rio_close (struct net_device *dev)
skb = np->rx_skbuff[i];
if (skb) {
pci_unmap_single(np->pdev,
np->rx_ring[i].fraginfo & 0xffffffffffff,
np->rx_ring[i].fraginfo & DMA_48BIT_MASK,
skb->len, PCI_DMA_FROMDEVICE);
dev_kfree_skb (skb);
np->rx_skbuff[i] = NULL;
Expand All @@ -1810,7 +1810,7 @@ rio_close (struct net_device *dev)
skb = np->tx_skbuff[i];
if (skb) {
pci_unmap_single(np->pdev,
np->tx_ring[i].fraginfo & 0xffffffffffff,
np->tx_ring[i].fraginfo & DMA_48BIT_MASK,
skb->len, PCI_DMA_TODEVICE);
dev_kfree_skb (skb);
np->tx_skbuff[i] = NULL;
Expand Down
4 changes: 3 additions & 1 deletion trunk/drivers/net/phy/mdio_bus.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,10 @@ int mdiobus_register(struct mii_bus *bus)
for (i = 0; i < PHY_MAX_ADDR; i++) {
struct phy_device *phydev;

if (bus->phy_mask & (1 << i))
if (bus->phy_mask & (1 << i)) {
bus->phy_map[i] = NULL;
continue;
}

phydev = get_phy_device(bus, i);

Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/net/sis900.c
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ static const struct mii_chip_info {
} mii_chip_table[] = {
{ "SiS 900 Internal MII PHY", 0x001d, 0x8000, LAN },
{ "SiS 7014 Physical Layer Solution", 0x0016, 0xf830, LAN },
{ "SiS 900 on Foxconn 661 7MI", 0x0143, 0xBC70, LAN },
{ "Altimata AC101LF PHY", 0x0022, 0x5520, LAN },
{ "ADM 7001 LAN PHY", 0x002e, 0xcc60, LAN },
{ "AMD 79C901 10BASE-T PHY", 0x0000, 0x6B70, LAN },
Expand Down
5 changes: 3 additions & 2 deletions trunk/drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ MODULE_DEVICE_TABLE(pci, sky2_id_table);
/* Avoid conditionals by using array */
static const unsigned txqaddr[] = { Q_XA1, Q_XA2 };
static const unsigned rxqaddr[] = { Q_R1, Q_R2 };
static const u32 portirq_msk[] = { Y2_IS_PORT_1, Y2_IS_PORT_2 };

/* This driver supports yukon2 chipset only */
static const char *yukon2_name[] = {
Expand Down Expand Up @@ -1084,7 +1085,7 @@ static int sky2_up(struct net_device *dev)

/* Enable interrupts from phy/mac for port */
imask = sky2_read32(hw, B0_IMSK);
imask |= (port == 0) ? Y2_IS_PORT_1 : Y2_IS_PORT_2;
imask |= portirq_msk[port];
sky2_write32(hw, B0_IMSK, imask);

return 0;
Expand Down Expand Up @@ -1435,7 +1436,7 @@ static int sky2_down(struct net_device *dev)

/* Disable port IRQ */
imask = sky2_read32(hw, B0_IMSK);
imask &= ~(sky2->port == 0) ? Y2_IS_PORT_1 : Y2_IS_PORT_2;
imask &= ~portirq_msk[port];
sky2_write32(hw, B0_IMSK, imask);

/* turn off LED's */
Expand Down
1 change: 1 addition & 0 deletions trunk/include/linux/dma-mapping.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ enum dma_data_direction {
};

#define DMA_64BIT_MASK 0xffffffffffffffffULL
#define DMA_48BIT_MASK 0x0000ffffffffffffULL
#define DMA_40BIT_MASK 0x000000ffffffffffULL
#define DMA_39BIT_MASK 0x0000007fffffffffULL
#define DMA_32BIT_MASK 0x00000000ffffffffULL
Expand Down

0 comments on commit fa1e6ef

Please sign in to comment.