From: David Miller <davem@davemloft.net>
To: erik@hovland.org
Cc: netdev@vger.kernel.org, trivial@kernel.org
Subject: Re: [PATCH] Make dev_kfree_skb_any check if the skb is valid
Date: Wed, 18 Apr 2007 16:27:04 -0700 (PDT) [thread overview]
Message-ID: <20070418.162704.27783526.davem@davemloft.net> (raw)
In-Reply-To: <20070418231808.GF13146@hovland.org>
From: Erik Hovland <erik@hovland.org>
Date: Wed, 18 Apr 2007 16:18:15 -0700
> Heh, the reason I came up with this patch is that the code in
> drivers/usb/gadget/ether.c at about line 1653 will attempt to allocate
> an skb. If it fails then it uses a goto to jump to line 1672 where it
> will call dev_kfree_skb_any (skb) on a potentially null skb. I put a
> validity check there and sent it off to the USB gadget maintainer. He
> asked me to instead make the dev_kfree_skb_any call more robust and see
> how that went over on the netdev list. Like a lead balloon?
Yep, like a lead baloon.
The USB gadget driver maintainer should accept your patch
to check for NULL in the gadget driver as that is the one
and only case in the entire tree where that can happen and
we're not eating a conditional and a return just for that
one esoteric case.
prev parent reply other threads:[~2007-04-18 23:27 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-18 22:33 [PATCH] Make dev_kfree_skb_any check if the skb is valid Erik Hovland
2007-04-18 22:44 ` David Miller
2007-04-18 23:18 ` Erik Hovland
2007-04-18 23:27 ` David Miller [this message]
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=20070418.162704.27783526.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=erik@hovland.org \
--cc=netdev@vger.kernel.org \
--cc=trivial@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).