mapping address pointer to page structure
swathi suresh
swathi.suresh07 at gmail.com
Tue Mar 29 09:17:47 EDT 2011
Hi All,
Is it possible to map a address like skb->data in to struct page. My
requirement is to convert multiple skb
to a single master skb, having all the data of other skb. i.e, i want add
skb->data of multiple skb to a single skb
as the fragments. So instead of making a memcpy every time, i just call
skb_add_rx_frag
my requirement is some thing like this
*.*
*.*
*struct page *page = virt_to_page(skb->data);*
*
*
*skb_add_rx_frag(master_skb, skb_shinfo(master_skb)->nr_frags, page, off,
skb->len)*
*.*
*.*
And can some one please tell what is the use of the functions like *
virt_to_page* and *kmap_atomic_to_page*,
i tried calling virt_to_page(skb->data), but when i print the data in the
page address ( page_address(page) ) and
the data in pointed by skb->data, i came to know its mapping to a wrong
page. so can some one please explain
me what is correct way to do this.
Thanks in advance.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20110329/1a6e4569/attachment.html
More information about the Kernelnewbies
mailing list