netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] Documentation: add a guideline for hard_start_xmit method
@ 2008-01-13  5:33 Matti Linnanvuori
  2008-01-13 21:45 ` Herbert Xu
  0 siblings, 1 reply; 2+ messages in thread
From: Matti Linnanvuori @ 2008-01-13  5:33 UTC (permalink / raw)
  To: jgarzik, netdev

From: Matti Linnanvuori <mattilinnanvuori@yahoo.com>
 
Add a guideline for hard_start_xmit method not to
modify SKB.
 
Signed-off-by: Matti Linnanvuori <mattilinnanvuori@yahoo.com>
---
--- a/Documentation/networking/driver.txt 2008-01-13 07:14:01.608291500 +0200
+++ b/Documentation/networking/driver.txt 2008-01-13 07:13:40.535421500 +0200
@@ -61,7 +61,9 @@
 2) Do not forget to update netdev->trans_start to jiffies after
    each new tx packet is given to the hardware.
 
-3) Do not forget that once you return 0 from your hard_start_xmit
+3) A hard_start_xmit method must not modify the shared parts of the SKB.
+
+4) Do not forget that once you return 0 from your hard_start_xmit
    method, it is your driver's responsibility to free up the SKB
    and in some finite amount of time.


      ____________________________________________________________________________________
Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  http://tools.search.yahoo.com/newsearch/category.php?category=shopping

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH v2] Documentation: add a guideline for hard_start_xmit method
  2008-01-13  5:33 [PATCH v2] Documentation: add a guideline for hard_start_xmit method Matti Linnanvuori
@ 2008-01-13 21:45 ` Herbert Xu
  0 siblings, 0 replies; 2+ messages in thread
From: Herbert Xu @ 2008-01-13 21:45 UTC (permalink / raw)
  To: Matti Linnanvuori; +Cc: jgarzik, netdev

Matti Linnanvuori <mattilinnanvuori@yahoo.com> wrote:
>
> -3) Do not forget that once you return 0 from your hard_start_xmit
> +3) A hard_start_xmit method must not modify the shared parts of the SKB.

Only if it's cloned.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-01-13 21:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-13  5:33 [PATCH v2] Documentation: add a guideline for hard_start_xmit method Matti Linnanvuori
2008-01-13 21:45 ` Herbert Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).