Subject: Re: [PATCH]: PowerPC: make sure the rtas stop-self token is defined.

From: [email-masked] (Linas Vepstas)
Date: Mon, 13 Nov 2006 13:39:40 -0600

On Mon, Nov 13, 2006 at 12:57:04PM -0600, Nathan Lynch wrote:
> 
> I'm still not clear on what problem this patch is intended to address.

There's a code path that is compiled unconditonally, that expects 
this token to be defined. 

> If the 'online' cpu attribute in sysfs can be used to attempt an
> offline operation on a kernel with CONFIG_HOTPLUG_CPU=n, that's what
> needs to be fixed.

There are many places where cpu_die() might be called, and
I am sufficiently lazy to not want to audit them to make sure
that none of these code paths are taken if CONFIG_HOTPLUG_CPU=n.

Besides, if I audit all of these code paths today, and find
that none of them are ever called when  CONFIG_HOTPLUG_CPU=n,
I still have no assurance that someone might not unwittingly
change one of the code paths in the future. 

Code that might fail because someone makes an unwitting change
in the future is "brittle". The goal of my patch was to remove
the brittleness.

Besides, I notice that platforms/powermac/smp.c defines
cpu_die() as well, which tells me that there are code paths
that lead to its being called, even if CONFIG_HOTPLUG_CPU=n.
That would seem to conclude the audit, right?

--linas