From: Russell King <rmk+lkml@arm.linux.org.uk>
To: Marcelo Tosatti <marcelo.tosatti@cyclades.com>
Cc: Christoph Hellwig <hch@infradead.org>,
torvalds@osdl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] PC300 update
Date: Thu, 29 Jan 2004 09:02:22 +0000 [thread overview]
Message-ID: <20040129090222.A20867@flint.arm.linux.org.uk> (raw)
In-Reply-To: <Pine.LNX.4.58L.0401282203170.2163@logos.cnet>; from marcelo.tosatti@cyclades.com on Wed, Jan 28, 2004 at 10:06:25PM -0200
On Wed, Jan 28, 2004 at 10:06:25PM -0200, Marcelo Tosatti wrote:
> On Wed, 28 Jan 2004, Christoph Hellwig wrote:
> > > - Mark pci_device_id list with __devinitdata
> >
> > This is bogus and can crash the kernel if you're unlucky.
>
> Other wan drivers are doing the same:
>
> [marcelo@logos wan]$ grep __devinitdata *
> farsync.c:static char *type_strings[] __devinitdata = {
> wanxl.c:static struct pci_device_id wanxl_pci_tbl[] __devinitdata = {
>
> I believe a handful of others are using "__devinitdata". How can the
> kernel crash because of this? Who will try to touch the data?
It is particularly notable when someone inserts a Cardbus device. A
new PCI device is added, and we scan all drivers looking for a match
using the PCI ID tables.
If _any_ PCI ID table which is part registered as part of a driver is
marked using __devinitdata or __initdata, this will either cause the
kernel to read invalid data (possibly entering a long loop) or oops.
--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of: 2.6 PCMCIA - http://pcmcia.arm.linux.org.uk/
2.6 Serial core
next prev parent reply other threads:[~2004-01-29 9:02 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-28 19:42 [PATCH] PC300 update Marcelo Tosatti
2004-01-28 21:21 ` Christoph Hellwig
2004-01-29 0:06 ` Marcelo Tosatti
2004-01-29 8:16 ` Christoph Hellwig
2004-01-29 9:02 ` Russell King [this message]
2004-01-29 13:02 ` Russell King
2004-01-28 21:43 ` Greg KH
2004-01-29 0:02 ` Marcelo Tosatti
-- strict thread matches above, loose matches on Subject: below --
2004-01-30 17:52 Marcelo Tosatti
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=20040129090222.A20867@flint.arm.linux.org.uk \
--to=rmk+lkml@arm.linux.org.uk \
--cc=hch@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marcelo.tosatti@cyclades.com \
--cc=torvalds@osdl.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.