aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/b44.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2007-01-29 15:36:54 -0500
committerJeff Garzik <jeff@garzik.org>2007-02-06 19:03:56 -0500
commita7bed27dc69e3bc9238549a4964ea94ec318362c (patch)
treeec8fc1780794a8b8e4a992727462a03cb437873c /drivers/net/b44.c
parentf5cd7872768d5856b1b409a33f516e5ac7798f75 (diff)
b44 endian annotations
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/b44.c')
-rw-r--r--drivers/net/b44.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/b44.c b/drivers/net/b44.c
index 303a8d94ad4b..5ff7882297d6 100644
--- a/drivers/net/b44.c
+++ b/drivers/net/b44.c
@@ -721,7 +721,7 @@ static void b44_recycle_rx(struct b44 *bp, int src_idx, u32 dest_idx_unmasked)
721 struct ring_info *src_map, *dest_map; 721 struct ring_info *src_map, *dest_map;
722 struct rx_header *rh; 722 struct rx_header *rh;
723 int dest_idx; 723 int dest_idx;
724 u32 ctrl; 724 __le32 ctrl;
725 725
726 dest_idx = dest_idx_unmasked & (B44_RX_RING_SIZE - 1); 726 dest_idx = dest_idx_unmasked & (B44_RX_RING_SIZE - 1);
727 dest_desc = &bp->rx_ring[dest_idx]; 727 dest_desc = &bp->rx_ring[dest_idx];
@@ -783,7 +783,7 @@ static int b44_rx(struct b44 *bp, int budget)
783 RX_PKT_BUF_SZ, 783 RX_PKT_BUF_SZ,
784 PCI_DMA_FROMDEVICE); 784 PCI_DMA_FROMDEVICE);
785 rh = (struct rx_header *) skb->data; 785 rh = (struct rx_header *) skb->data;
786 len = cpu_to_le16(rh->len); 786 len = le16_to_cpu(rh->len);
787 if ((len > (RX_PKT_BUF_SZ - bp->rx_offset)) || 787 if ((len > (RX_PKT_BUF_SZ - bp->rx_offset)) ||
788 (rh->flags & cpu_to_le16(RX_FLAG_ERRORS))) { 788 (rh->flags & cpu_to_le16(RX_FLAG_ERRORS))) {
789 drop_it: 789 drop_it:
@@ -799,7 +799,7 @@ static int b44_rx(struct b44 *bp, int budget)
799 do { 799 do {
800 udelay(2); 800 udelay(2);
801 barrier(); 801 barrier();
802 len = cpu_to_le16(rh->len); 802 len = le16_to_cpu(rh->len);
803 } while (len == 0 && i++ < 5); 803 } while (len == 0 && i++ < 5);
804 if (len == 0) 804 if (len == 0)
805 goto drop_it; 805 goto drop_it;
@@ -2061,7 +2061,7 @@ out:
2061static int b44_read_eeprom(struct b44 *bp, u8 *data) 2061static int b44_read_eeprom(struct b44 *bp, u8 *data)
2062{ 2062{
2063 long i; 2063 long i;
2064 u16 *ptr = (u16 *) data; 2064 __le16 *ptr = (__le16 *) data;
2065 2065
2066 for (i = 0; i < 128; i += 2) 2066 for (i = 0; i < 128; i += 2)
2067 ptr[i / 2] = cpu_to_le16(readw(bp->regs + 4096 + i)); 2067 ptr[i / 2] = cpu_to_le16(readw(bp->regs + 4096 + i));