From: "James C. Georgas" <jgeorgas@rogers.com>
To: Kyle Moffett <mrmacman_g4@mac.com>
Cc: linux-kernel@vger.kernel.org, Adrian Bunk <bunk@stusta.de>
Subject: Re: [2.6 patch] make UNIX a bool
Date: Mon, 06 Mar 2006 18:59:14 -0500 [thread overview]
Message-ID: <1141689554.19207.35.camel@Rainsong.home> (raw)
In-Reply-To: <6D8D14D2-4ED3-46ED-8FB9-FF8567DC9F70@mac.com>
Excuse me - sent half a response earlier.
On Sat, 2006-04-03 at 17:57 -0500, Kyle Moffett wrote:
> On Mar 3, 2006, at 16:31:51, James C. Georgas wrote:
> > On Thu, 2006-02-03 at 23:32 -0500, Kyle Moffett wrote:
> >> af_unix (IE: CONFIG_UNIX) currently uses the symbol
> >> get_max_files. It is the only module that uses that symbol, and
> >> that symbol probably should not be exported as it's kind of an
> >> internal API. Therefore if we mandate that CONFIG_UNIX != m, then
> >> that symbol may be properly unexported and made private, because
> >> nothing modular would use it. Does that clear things up?
> >
> > Yes, I think I understand.
> >
> > However, even if you don't export the symbol, I don't see how you
> > can make it private (i.e. static declaration) to file_table.c,
> > since it has to remain extern, in order to be visible to af_unix.c.
>
> You're missing some crucial information about how Linux operates.
> EXPORT_SYMBOL != extern. Basically, Linux maintains a list of
> symbols that dynamically loaded modules are allowed to use, along
> with some technical usage restrictions on each (Symbols exported
> with EXPORT_SYMBOL_GPL may only be used by modules that declare
> 'MODULE_LICENSE("GPL");'.) Exporting a symbol increases the
> likliehood that some module author will use it inappropriately, and
> bloats the kernel. In this case, removing the EXPORT_SYMBOL() would
> be a good thing.
Isn't it kind of pointless to not EXPORT a symbol if the symbol is still
declared globally in an include/linux/ header file? If the intent is to
prevent abuse of the symbol, then this doesn't do it, because I can just
statically compile my module into the kernel, and keep on using that
symbol.
It makes sense to me to remove the EXPORT of get_max_files only if the
intent is to eventually remove the get_max_files function from
include/linux/fs.h.
This would require that af_unix.c calculate the maximum number of
allowed open Unix sockets from information other than the
files_stat.max_files value is fs/file_table.c.
If that's the intent, then there's no point in disallowing AF_UNIX=m.
Doing this just so one can unEXPORT a symbol only fixes half the issue.
> Cheers,
> Kyle Moffett
>
--
James C. Georgas <jgeorgas@rogers.com>
next prev parent reply other threads:[~2006-03-07 0:03 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-03 4:06 [Fwd: Re: [2.6 patch] make UNIX a bool] James C. Georgas
2006-03-03 4:14 ` [2.6 patch] make UNIX a bool James C. Georgas
2006-03-03 4:32 ` Kyle Moffett
2006-03-03 21:31 ` James C. Georgas
2006-03-04 22:57 ` Kyle Moffett
2006-03-06 23:42 ` James C. Georgas
2006-03-06 23:59 ` James C. Georgas [this message]
-- strict thread matches above, loose matches on Subject: below --
2006-02-25 16:01 Adrian Bunk
2006-02-25 17:13 ` Stephen Hemminger
2006-02-25 17:28 ` Arjan van de Ven
2006-02-26 18:19 ` Diego Calleja
2006-02-25 22:46 ` Olaf Hering
2006-03-25 19:47 ` Adrian Bunk
2006-03-26 15:20 ` Jan-Benedict Glaw
2006-03-26 21:48 ` Joshua Hudson
2006-02-27 22:18 ` James C. Georgas
2006-02-27 22:29 ` Adrian Bunk
2006-03-01 3:09 ` Dmitry Torokhov
2006-03-01 17:58 ` Adrian Bunk
2006-03-02 1:31 ` Herbert Xu
2006-03-02 17:38 ` Adrian Bunk
2006-03-02 19:51 ` Jan-Benedict Glaw
2006-03-02 20:39 ` Adrian Bunk
2006-03-02 20:51 ` Jan-Benedict Glaw
2006-03-02 21:28 ` Adrian Bunk
2006-03-03 9:27 ` Jan-Benedict Glaw
2006-03-02 20:28 ` Jesper Juhl
2006-03-02 20:32 ` Adrian Bunk
2006-03-02 20:40 ` Jesper Juhl
2006-03-02 21:40 ` Adrian Bunk
2006-03-02 21:53 ` Jan Engelhardt
2006-03-02 22:32 ` Adrian Bunk
2006-03-02 21:46 ` Adrian Bunk
2006-03-03 9:30 ` Jan-Benedict Glaw
2006-03-03 4:28 ` James C. Georgas
[not found] ` <1141335521.3582.14.camel@Rainsong.home>
[not found] ` <20060302214423.GI9295@stusta.de>
2006-03-03 4:44 ` James C. Georgas
2006-03-03 11:46 ` Adrian Bunk
2006-03-03 14:48 ` James C. Georgas
2006-03-03 15:10 ` Adrian Bunk
2006-03-03 17:50 ` James C. Georgas
2006-03-03 17:55 ` Adrian Bunk
2006-03-03 21:11 ` James C. Georgas
2006-03-02 20:34 ` Randy.Dunlap
2006-02-28 14:52 ` Jan-Benedict Glaw
2006-02-28 15:30 ` James C. Georgas
2006-02-28 19:15 ` Jan Engelhardt
2006-03-02 21:47 ` Adrian Bunk
2006-02-17 15:41 [PATCH 0/2] RCU updates Dipankar Sarma
2006-02-17 15:43 ` [PATCH 1/2] rcu batch tuning Dipankar Sarma
2006-02-17 15:46 ` [PATCH 2/2] fix file counting Dipankar Sarma
2006-02-18 9:04 ` Andrew Morton
2006-02-18 9:25 ` Dipankar Sarma
2006-02-18 12:14 ` Christoph Hellwig
2006-02-18 12:31 ` Arjan van de Ven
2006-02-20 22:36 ` [2.6 patch] make UNIX a bool Adrian Bunk
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=1141689554.19207.35.camel@Rainsong.home \
--to=jgeorgas@rogers.com \
--cc=bunk@stusta.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mrmacman_g4@mac.com \
/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
all inboxes | Powered by JetHome®