Re: Fwd: How do we read paged data ?? .. please help!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 9 Mar 2005 08:06:45 -0800 (PST)
Alok <wonder_years2000@xxxxxxxxx> wrote:

> 
>  Hi ..
>     
> I have to submit my project in networking in one of
> the competitions coming up ..on 15th march .. rest of
> my code is ready .. only some portion is left .. i'd
> be really glad if someone cud help me with this part
> of codin ... I am not able to solve this problem .. 
> 
>      I am having trouble while reading or writting
>  data from skb data structure (used in Networking)
>  i.e.  when data is present in Pages. Paged data
>  information  is stored in skb_shared_info structure
> .which  consists  of . pointer to page structure ,
> size and offset.  Whenever I try to read this data,
> kernel goes to  panic  state. I thought these pages
> might be locked or  sumthin ... but when i went
> through kernel code ...  there wasn't any mention of
> such locks (atleaset i  could not find one !).
> 
>  
>    In the kernel code it was all logical .. reading
>  from page n all .. but when i tried the same code ..
>  kernel paniced. Can anyone please help me with this
>  ??
>  . .how do i read this paged data ??
> 

Easiest would be to use:

	struct skb_iter iter;
	
	skb_iter_first(skb, &iter);
	process_data(itier.data, iter.len);
	while (skb_iter_next(skb, &iter)) 
		process_data(iter.data, iter.len);

-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux