netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: jamal <hadi@cyberus.ca>
To: davem@davemloft.net
Cc: Herbert Xu <herbert@gondor.apana.org.au>,
	Jiri Pirko <jpirko@redhat.com>,
	netdev@vger.kernel.org
Subject: [PATCH net-next-2.6] net sched: make pedit check for clones instead
Date: Fri, 04 Jun 2010 08:43:06 -0400	[thread overview]
Message-ID: <1275655386.3445.62.camel@bigi> (raw)

[-- Attachment #1: Type: text/plain, Size: 198 bytes --]

And here's the second one. I noticed Changli's changes are not yet in
net-next. I will wait for that change to propagate and then send the
fix to pedit that i discussed with Herbert.

cheers,
jamal

[-- Attachment #2: pedit1 --]
[-- Type: text/plain, Size: 806 bytes --]

commit 0697bf778d48d155ef48f652cee8f103db3dcedb
Author: Jamal Hadi Salim <hadi@cyberus.ca>
Date:   Fri Jun 4 08:39:47 2010 -0400

    net sched: make pedit check for clones instead
    
    Now that the core path doesnt set OK to munge we detect
    writable skbs by looking to see if they are cloned.
    
    Signed-off-by: Jamal Hadi Salim <hadi@cyberus.ca>

diff --git a/net/sched/act_pedit.c b/net/sched/act_pedit.c
index fdbd0b7..8d15caf 100644
--- a/net/sched/act_pedit.c
+++ b/net/sched/act_pedit.c
@@ -127,8 +127,7 @@ static int tcf_pedit(struct sk_buff *skb, struct tc_action *a,
 	int i, munged = 0;
 	u8 *pptr;
 
-	if (!(skb->tc_verd & TC_OK2MUNGE)) {
-		/* should we set skb->cloned? */
+	if (skb_cloned(skb)) {
 		if (pskb_expand_head(skb, 0, 0, GFP_ATOMIC)) {
 			return p->tcf_action;
 		}

             reply	other threads:[~2010-06-04 12:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-04 12:43 jamal [this message]
2010-06-04 13:05 ` [PATCH net-next-2.6] net sched: make pedit check for clones instead Herbert Xu
2010-06-07  8:09   ` David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1275655386.3445.62.camel@bigi \
    --to=hadi@cyberus.ca \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=jpirko@redhat.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).