[lkml]   [2001]   [Apr]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: Zerocopy implementation issues

Russell King writes:
> I'm doing it _NOW_, but I'm having to rotate the checksum
> at the end if dst & 1, only to have it unrotated in an
> inefficient manner in csum_block_*. Seems a bit of a
> waste of CPU cycles.

This is certainly the kind of enhancement we can make, where
possible. No problem.

But I currently can't see how you would apply it even
in the net/ipv4/tcp.c:tcp_copy_to_page() case. Look:

page_address(page) + off

This determines whether you need to rotate at the end
in your checksum code, right? We know pages are aligned
so 'off' is all that is relevant for that determination.

Later we use:


to determine the behavior of csum_block_add() (to byte swap
or not).

There is no connection between 'off' and 'skb->len' so I
don't see how in this case we could make use of your optimization.

David S. Miller
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

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