Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=4352d82647f679fb8dd9440b34400fa49beedb2c
Commit:     4352d82647f679fb8dd9440b34400fa49beedb2c
Parent:     d30f53aeb31d453a5230f526bea592af07944564
Author:     Olof Johansson <[EMAIL PROTECTED]>
AuthorDate: Mon Dec 3 21:34:14 2007 -0600
Committer:  Jeff Garzik <[EMAIL PROTECTED]>
CommitDate: Tue Dec 4 14:53:49 2007 -0500

    pasemi_mac: Fix reuse of free'd skb
    
    Turns out we're freeing the skb when we detect CRC error, but we're
    not clearing out info->skb. We could either clear it and have the stack
    reallocate it, or just leave it and the rx ring refill code will reuse
    the one that was allocated.
    
    Reusing a freed skb obviously caused some nasty crashes of various kind,
    as reported by Brent Baude and David Woodhouse.
    
    Signed-off-by: Olof Johansson <[EMAIL PROTECTED]>
    Signed-off-by: Jeff Garzik <[EMAIL PROTECTED]>
---
 drivers/net/pasemi_mac.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/pasemi_mac.c b/drivers/net/pasemi_mac.c
index a8db5d7..816a59e 100644
--- a/drivers/net/pasemi_mac.c
+++ b/drivers/net/pasemi_mac.c
@@ -586,7 +586,7 @@ static int pasemi_mac_clean_rx(struct pasemi_mac *mac, int 
limit)
                        /* CRC error flagged */
                        mac->netdev->stats.rx_errors++;
                        mac->netdev->stats.rx_crc_errors++;
-                       dev_kfree_skb_irq(skb);
+                       /* No need to free skb, it'll be reused */
                        goto next;
                }
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to