Quote:
Originally Posted by bugsmakemylifehell
I have a kernel module that uses netfilter to catch the packets at NF_IP_LOCAL_OUT hook.These are udp packets which encapsulate tcp packets withing them like ip->udp->ip'->tcp.
In the hook, I strip the ip and udp header out to recover the ip->tcp original packet.Sometimes , I get this message.
ip_push_pending_frames+0x38b/0x46c
To strip the headers I do,
skb->data=skb->data+iph->ihl*4+sizeof(struct udphdr);
skb->network_header=skb->data;
skb->transport_header=skb->data+iph->ihl*4;
skb->len=ntohs(((struct iphdr*)skb->network_header)->tot_len);
skb->tail=skb->data+skb->len;
and it kills my process but I have a watchdog to restart it.
Any ideas on how to prevent this ? This is very important for me.
Thank you advanced
|
OK, I think, that you tried to access to unmapped space.
As you know only part of original packet may be placed in
skb->data, the rest is in scatter-gather list. So you have to check:
1. where a requested data is placed
2. map s-g page to linear space
3. access to needed offset.
I will be glad to help you.