public inbox for linux-arch@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: Arnd Bergmann <arnd@arndb.de>
Cc: rusty@rustcorp.com.au, linux-arch@vger.kernel.org,
	epasch@de.ibm.com, hare@suse.de
Subject: Re: static DEFINE_PER_CPU vs. modules
Date: Mon, 3 May 2004 19:38:35 -0700	[thread overview]
Message-ID: <20040503193835.72c62ad8.akpm@osdl.org> (raw)
In-Reply-To: <200405031741.52504.arnd@arndb.de>

Arnd Bergmann <arnd@arndb.de> wrote:
>
> The idea I had for preventing the same bug from happening
>  in the future is to provoke a compile error for modules using
>  'static DEFINE_PER_CPU', see patch below.

It's not a big success with CONFIG_SMP=n.

kernel/fork.c:55: warning: return-type defaults to `int'
kernel/fork.c: In function `__PER_CPU_NOSTATIC':
kernel/fork.c:55: parameter `per_cpu__process_counts' is initialized
kernel/fork.c:57: parameter `tasklist_lock' is initialized
kernel/fork.c:57: alignment may not be specified for `tasklist_lock'
kernel/fork.c:57: section attribute not allowed for `tasklist_lock'
kernel/fork.c:59: storage class specified for parameter `__crc_tasklist_lock'
kernel/fork.c:59: weak declaration of `__crc_tasklist_lock' must be public
kernel/fork.c:59: storage class specified for parameter `__kcrctab_tasklist_lock'
kernel/fork.c:59: parameter `__kcrctab_tasklist_lock' is initialized
kernel/fork.c:59: section attribute not allowed for `__kcrctab_tasklist_lock'
kernel/fork.c:59: storage class specified for parameter `__kstrtab_tasklist_lock'
kernel/fork.c:59: parameter `__kstrtab_tasklist_lock' is initialized
kernel/fork.c:59: section attribute not allowed for `__kstrtab_tasklist_lock'
kernel/fork.c:59: storage class specified for parameter `__ksymtab_tasklist_lock'
kernel/fork.c:59: parameter `__ksymtab_tasklist_lock' is initialized
kernel/fork.c:59: section attribute not allowed for `__ksymtab_tasklist_lock'
kernel/fork.c:62: parse error before `{'
kernel/fork.c:55: parm types given both in parmlist and separately

  parent reply	other threads:[~2004-05-04  2:38 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-03 15:41 static DEFINE_PER_CPU vs. modules Arnd Bergmann
2004-05-03 17:50 ` David Mosberger
2004-05-03 18:01   ` Richard Henderson
2004-05-03 18:37     ` David Mosberger
2004-05-03 22:24       ` Arnd Bergmann
2004-05-03 23:12         ` David Mosberger
2004-05-04  8:56           ` Arnd Bergmann
2004-05-04  2:38 ` Andrew Morton [this message]
2004-05-04 14:17   ` Arnd Bergmann
2004-05-04 16:29     ` David Mosberger
2004-05-04 19:03       ` Andrew Morton
2004-05-04 19:15         ` David Mosberger
2004-05-04 19:23           ` Andrew Morton
2004-05-04 19:45             ` David Mosberger
2004-05-05  8:21               ` Arnd Bergmann
2004-05-05  8:29                 ` Andrew Morton
2004-05-05  9:24                   ` Arnd Bergmann
2004-05-05  9:33                 ` Rusty Russell
2004-05-05 16:17                 ` David Mosberger
2004-05-05  3:18         ` Richard Henderson
  -- strict thread matches above, loose matches on Subject: below --
2004-05-05 17:42 Martin Schwidefsky

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=20040503193835.72c62ad8.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=arnd@arndb.de \
    --cc=epasch@de.ibm.com \
    --cc=hare@suse.de \
    --cc=linux-arch@vger.kernel.org \
    --cc=rusty@rustcorp.com.au \
    /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