[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.LFD.2.01.0909180949420.4950@localhost.localdomain>
Date: Fri, 18 Sep 2009 09:51:01 -0700 (PDT)
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Yinghai Lu <yinghai@...nel.org>
cc: Ingo Molnar <mingo@...e.hu>,
Jesse Barnes <jbarnes@...tuousgeek.org>,
Greg Kroah-Hartman <gregkh@...e.de>,
Rusty Russell <rusty@...tcorp.com.au>,
Tejun Heo <tj@...nel.org>, linux-pci@...r.kernel.org,
linux-kernel@...r.kernel.org, Thomas Gleixner <tglx@...utronix.de>,
"H. Peter Anvin" <hpa@...or.com>
Subject: Re: [crash] BUG: unable to handle kernel NULL pointer dereference
at (null), last sysfs file:
/sys/devices/pci0000:00/0000:00:01.0/local_cpus
On Fri, 18 Sep 2009, Yinghai Lu wrote:
>
> exposed by Jesse's patch too.
>
> please check
>
> ---
> arch/x86/include/asm/pci.h | 9 ++++++++-
> 1 file changed, 8 insertions(+), 1 deletion(-)
>
> Index: linux-2.6/arch/x86/include/asm/pci.h
> ===================================================================
> --- linux-2.6.orig/arch/x86/include/asm/pci.h
> +++ linux-2.6/arch/x86/include/asm/pci.h
> @@ -143,7 +143,14 @@ static inline int __pcibus_to_node(const
> static inline const struct cpumask *
> cpumask_of_pcibus(const struct pci_bus *bus)
> {
> - return cpumask_of_node(__pcibus_to_node(bus));
> + int node;
> +
> + node = __pcibus_to_node(bus);
> +
> + if (node == -1)
> + node = numa_node_id();
> +
> + return cpumask_of_node(node);
This looks like the wrong fix. Why would the pcibus cpumask depend on the
node we happen to run on right now? All the other code says "no node means
all online cpus", which makes much more sense.
Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists