Re: 2.6.13-rc6-mm1

Russell King
2005-08-19T13:45:19Z

On Fri, Aug 19, 2005 at 03:41:29PM +0200, Brice Goglin wrote:
> Le 19.08.2005 15:27, Russell King a écrit :
> > Since you're going to be adding #ifdef CONFIG_SMP...#endif around each
> > of these, why not fix where it's declared/defined to be empty?
>
> Probably because I'm too lazy to find a nice way to fix it :)
>
> smp_nmi_call_function may return an error but I don't see any place
> where the return value is actually checked. If the error case is
> actually possible, we should check the return value, and the warning
> would disappear.
>
> Sorry but I'm not familiar enough with this code to know what's the
> good solution :(

Well, I don't have access to the code you're looking at so I'll make
the following suggestion completely blind. You want the header file
which defines smp_nmi_call_function() to contain something like:

#ifdef CONFIG_SMP
extern int smp_nmi_call_function(void (*fn)(void *), void *priv, int whatever);
#else
static inline int smp_nmi_call_function(void (*fn)(void *), void *priv, int whatever)
{
return 0;
}
#endif

Obviously I've probably got the arguments to smp_nmi_call_function()
wrong, so they'll need fixing. I'm sure the above will point you in
the right direction though.

--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of: 2.6 Serial core