Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 65205
b: refs/heads/master
c: 88f5f0c
h: refs/heads/master
i:
  65203: 0b098e5
v: v3
  • Loading branch information
Stephen Hemminger authored and Jeff Garzik committed Sep 28, 2007
1 parent 082ab49 commit 1a23e92
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 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: d6c9bc1ed4301cbc3df4565ff5348b64bf2a767c
refs/heads/master: 88f5f0cad396be594d6d55cb2d0cd69e8df9ab16
17 changes: 16 additions & 1 deletion trunk/drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -910,6 +910,20 @@ static inline struct sky2_tx_le *get_tx_le(struct sky2_port *sky2)
return le;
}

static void tx_init(struct sky2_port *sky2)
{
struct sky2_tx_le *le;

sky2->tx_prod = sky2->tx_cons = 0;
sky2->tx_tcpsum = 0;
sky2->tx_last_mss = 0;

le = get_tx_le(sky2);
le->addr = 0;
le->opcode = OP_ADDR64 | HW_OWNER;
sky2->tx_addr64 = 0;
}

static inline struct tx_ring_info *tx_le_re(struct sky2_port *sky2,
struct sky2_tx_le *le)
{
Expand Down Expand Up @@ -1320,7 +1334,8 @@ static int sky2_up(struct net_device *dev)
GFP_KERNEL);
if (!sky2->tx_ring)
goto err_out;
sky2->tx_prod = sky2->tx_cons = 0;

tx_init(sky2);

sky2->rx_le = pci_alloc_consistent(hw->pdev, RX_LE_BYTES,
&sky2->rx_le_map);
Expand Down

0 comments on commit 1a23e92

Please sign in to comment.