[PATCH 1/2] [powerpc] export symbols for use by lparcfg
Nathan Lynch
ntl at pobox.com
Tue Mar 13 07:24:00 EST 2007
Will Schmidt wrote:
>
> Updates the Kconfig to allow lparcfg to be built as a module, and
> add the necessary EXPORT_SYMBOLS needed for a successful build.
Well, almost exactly a year ago lparcfg was changed to bool. Do the
reasons for that change still stand?
commit 82dfdcae0d57c842e02f037758687eef42fb7af6
Author: Paul Mackerras <paulus at samba.org>
Date: Tue Mar 14 11:35:37 2006 +1100
powerpc: Disallow lparcfg being a module
The lparcfg code needs several things which are pretty arcane internal
details and which we don't want to export, which means that lparcfg
doesn't work when built as a module. This makes it a bool instead of
a tristate in the Kconfig so that users can't try to build it as a
module.
> +EXPORT_SYMBOL_GPL(lppaca);
> +EXPORT_PER_CPU_SYMBOL_GPL(cpu_usage_array);
> +EXPORT_SYMBOL_GPL(vdso_data);
Hmm, I don't think lparcfg needs to access vdso_data at all.
In pseries_lparcfg_data we have:
lrdrp = get_property(rtas_node, "ibm,lrdr-capacity", NULL);
if (lrdrp == NULL) {
partition_potential_processors = vdso_data->processorCount;
} else {
partition_potential_processors = *(lrdrp + 4);
}
partition_active_processors = lparcfg_count_active_processors();
But if there's no ibm,lrdr-capacity property then the system doesn't
support adding processors, so partition_potential_processors should be
equal to partition_active_processors.
More information about the Linuxppc-dev
mailing list