[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <AANLkTinE4X0iAJAiatc7Qtj2QP6dhyBKo9fqxqUt40Y6@mail.gmail.com>
Date: Sun, 25 Jul 2010 14:37:38 -0600
From: Grant Likely <grant.likely@...retlab.ca>
To: Stephen Rothwell <sfr@...b.auug.org.au>
Cc: monstr@...str.eu, microblaze-uclinux@...e.uq.edu.au,
devicetree-discuss@...ts.ozlabs.org, linux-kernel@...r.kernel.org,
linuxppc-dev@...abs.org, benh@...nel.crashing.org,
sparclinux@...r.kernel.org, davem@...emloft.net
Subject: Re: [PATCH] of: Provide default of_node_to_nid() when CONFIG_NUMA is
not set
On Sat, Jul 24, 2010 at 9:07 PM, Stephen Rothwell <sfr@...b.auug.org.au> wrote:
> Hi Grant,
>
> On Sat, 24 Jul 2010 09:43:31 -0600 Grant Likely <grant.likely@...retlab.ca> wrote:
>>
>> of_node_to_nid() is only relevant for NUMA. Don't force architectures to
>> implement it if CONFIG_NUMA is not set.
>
> Why not just do:
>
> #ifndef of_node_to_nid
> static inline int of_node_to_nid(struct device_node *device) { return 0; }
> #define of_node_to_nid of_node_to_nid
> #endif
>
> in include/linux/of.h
>
> and then add:
>
> #define of_node_to_nid of_node_to_nid
>
> Where it is declared/defined for each arch ...
> (it would be nice if all the archs were consistent in where it was
> declared).
Two reasons; I had started doing that in topology.h, but it caused a
bunch of collateral damage with files missing the include, so I punted
and took the easy way out. Also, I didn't know if that was an
acceptable or safe pattern for override symbols.
I'll spin it again with this pattern and see what it looks.
g.
> --
> Cheers,
> Stephen Rothwell sfr@...b.auug.org.au
> http://www.canb.auug.org.au/~sfr/
>
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
--
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