From: Stephen Hemminger <stephen@networkplumber.org>
To: Cong Wang <cwang@twopensource.com>
Cc: David Laight <David.Laight@aculab.com>,
Linux Netdev List <netdev@vger.kernel.org>,
David Miller <davem@davemloft.net>
Subject: Re: [PATCH net] core: Don't attempt to load the "" driver.
Date: Wed, 3 Sep 2014 11:18:11 -0700 [thread overview]
Message-ID: <20140903111811.2717fb59@urahara> (raw)
In-Reply-To: <CAHA+R7OoBp=ZAJeg_hXRjNhT6_n2siVQidJK6hx8EtHW7iRwqA@mail.gmail.com>
On Wed, 3 Sep 2014 10:02:26 -0700
Cong Wang <cwang@twopensource.com> wrote:
> On Wed, Sep 3, 2014 at 2:02 AM, David Laight <David.Laight@aculab.com> wrote:
> >> On Tue, Sep 2, 2014 at 6:48 AM, David Laight <David.Laight@aculab.com> wrote:
> >> > While the applications shouldn't be calling an SIOCxxx ioctl with ifr_name[0] == 0
> >> > the kernel shouldn't be tracing the error either.
> >> >
> >>
> >> Why don't we reject this empty string? It doesn't look like a valid one.
> >> I assume this is for compatibility?
> >
> > The ioctl code will error it later on - the module load is 'speculative'.
> > Analysing whether all the ioctls need dev_load() to succeed is another issue.
> >
> > Indeed I'm not sure anything stops the module being unloaded before the
> > ioctl action tries to take a real reference on the interface.
> >
> > Whether request_module("") should be an error is a different question,
> > probably much harder to analyse.
> >
>
> If an empty string is an invalid name, we definitely should reject it from
> the very beginning, so that you would not need to worry about the above
> issues.
>
> Something like the attached patch.
This will break for many things where the code randomly tries
to load something based on name, but the module is already there.
next prev parent reply other threads:[~2014-09-03 18:18 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-02 13:48 [PATCH net] core: Don't attempt to load the "" driver David Laight
2014-09-02 18:25 ` Cong Wang
2014-09-03 9:02 ` David Laight
2014-09-03 17:02 ` Cong Wang
2014-09-03 18:18 ` Stephen Hemminger [this message]
2014-09-02 21:03 ` David Miller
2014-09-03 8:55 ` [PATCH V2 " David Laight
2014-09-05 21:32 ` David Miller
2014-09-08 13:23 ` David Laight
2014-09-10 0:24 ` David Miller
2014-09-10 8:50 ` David Laight
2014-09-10 20:06 ` 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=20140903111811.2717fb59@urahara \
--to=stephen@networkplumber.org \
--cc=David.Laight@aculab.com \
--cc=cwang@twopensource.com \
--cc=davem@davemloft.net \
--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