Skip to contentSkip to conversation

r6040: fix wrong assignment in r6040_free_txbufs

PATCH Applied Florian Fainelli 2 participants 2 messages Sep 24, 2008 – Sep 25, 2008

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 r6040: fix wrong assignment in r6040_free_txbufs

Hello Jeff, Francois,

This is 2.6.27 material but should be applied to your -next branch as well. Thank you. --
From: Florian Fainelli <[email protected]>
Subject: [PATCH] r6040: fix wrong assignment in r6040_free_txbufs

This patch fixes a wrong assignment in r6040_free_txbufs on a receive skb pointer while we should actually do this on the transmit skb pointer.

---

drivers/net/r6040.c +1 -1
index 396f0e4..5aff7c8 100644
@@ -261,7 +261,7 @@ static void r6040_free_txbufs(struct net_device *dev)
 				le32_to_cpu(lp->tx_insert_ptr->buf),
 				MAX_BUF_SIZE, PCI_DMA_TODEVICE);
 			dev_kfree_skb(lp->tx_insert_ptr->skb_ptr);
-			lp->rx_insert_ptr->skb_ptr = NULL;
+			lp->tx_insert_ptr->skb_ptr = NULL;
 		}
 		lp->tx_insert_ptr = lp->tx_insert_ptr->vndescp;
 	}
Applied
#1 lore raw
Quoted 18 lines · Florian Fainelli

Hello Jeff, Francois,

This is 2.6.27 material but should be applied to your -next branch as well. Thank you. --
From: Florian Fainelli <[email protected]>
Subject: [PATCH] r6040: fix wrong assignment in r6040_free_txbufs

This patch fixes a wrong assignment in r6040_free_txbufs on a receive skb pointer while we should actually do this on the transmit skb pointer.

---

drivers/net/r6040.c +0 -0
index 396f0e4..5aff7c8 100644

drivers/net/r6040.c static void r6040_free_txbufs(struct net_device *dev) · line 267

Quoted 8 lines
drivers/net/r6040.c +1 -1
@@ -261,7 +261,7 @@ static void r6040_free_txbufs(struct net_device *dev)
 				le32_to_cpu(lp->tx_insert_ptr->buf),
 				MAX_BUF_SIZE, PCI_DMA_TODEVICE);
 			dev_kfree_skb(lp->tx_insert_ptr->skb_ptr);
-			lp->rx_insert_ptr->skb_ptr = NULL;
+			lp->tx_insert_ptr->skb_ptr = NULL;
 		}
 		lp->tx_insert_ptr = lp->tx_insert_ptr->vndescp;
 	}

applied