From: Jacob Gorm Hansen <jacob@me...> - 2004-04-27 14:54:26
My situation is this:
- interrupts are off
- one xenolinux network device is active
- there are buffered rx requests in the rx_ring
- I need to reset this ring in a minute
- I wish to free all the out-of-band pages allocated in my guest OS, so
they are not leaked when I reset the ring
I am trying this:
NET_RING_IDX i = np->net_idx->rx_resp_prod;
while (i != np->net_idx->rx_req_prod)
unsigned short id =
struct sk_buff* skb = np->rx_skbs[id];
-- which crashes on dev_kfree_skb_any().
Can anyone tell my why I cannot free these skbs?
From: Jacob Gorm Hansen <jacob@me...> - 2004-04-27 16:40:17
On Tue, 2004-04-27 at 16:54, Jacob Gorm Hansen wrote:
> struct sk_buff* skb = np->rx_skbs[id];
> -- which crashes on dev_kfree_skb_any().
I guess I know why now. The skb->head ptrs all point to pages that are
no longer mapped, this is why accessing data pointed to by skb_shinfo()
(which the dealloc routine does) is bad. I could manually
kfree(skb->head); but this still leaves empty mappings in the virtual
memory map :-(
I guess I need to flush the rings instead, but I suppose that means
xen-queued outgoing packets will be dropped? Maybe I will just have to
live with that.