lkml.org 
[lkml]   [2001]   [Oct]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: Oops on removing via-rhine [2.4.10-ac11]
On Thu, 11 Oct 2001, Andrew Over wrote:

> Trace; c010b6bc <pci_free_consistent+1c/20>
> Trace; e08fdbaa <[via-rhine]via_rhine_remove_one+2a/40>

remove_one shouldn't call pci_free_consistent as that is already done in
via_rhine_close (and I am assuming that if you open you must always close
before remove ...).

I could repeat some kind of crash, but could you please test if the patch
below fixes the crash you see. patch vs 2.4.13-pre2, but should apply vs
others as well.

/Urban


diff -urN -X exclude linux-2.4.13-pre2-orig/drivers/net/via-rhine.c linux/drivers/net/via-rhine.c
--- linux-2.4.13-pre2-orig/drivers/net/via-rhine.c Sat Oct 13 12:05:38 2001
+++ linux/drivers/net/via-rhine.c Sat Oct 13 12:34:00 2001
@@ -764,6 +764,7 @@
RX_RING_SIZE * sizeof(struct rx_desc) +
TX_RING_SIZE * sizeof(struct tx_desc),
np->rx_ring, np->rx_ring_dma);
+ np->tx_ring = NULL;

if (np->tx_bufs)
pci_free_consistent(np->pdev, PKT_BUF_SZ * TX_RING_SIZE,
@@ -1595,11 +1596,6 @@
#ifndef USE_IO
iounmap((char *)(dev->base_addr));
#endif
-
- pci_free_consistent(pdev,
- RX_RING_SIZE * sizeof(struct rx_desc) +
- TX_RING_SIZE * sizeof(struct tx_desc),
- np->rx_ring, np->rx_ring_dma);

kfree(dev);

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:08    [W:0.050 / U:0.680 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site