Hi Stephane,I discovered why I was able to link a kernel without adding the EXPORT_PER_CPU_SYMBOL(pmu_ctx) macro: I had accidentally linked the prcoessor-specific code in statically to the kernel instead of as modules.
With that in mind, I've attached a suggested patch to perfmon_init.c to export pmu_ctx, so that my latest patch for perfmon_power6.c can be used when it's built as a module.
Thanks for your consideration, - Corey Corey Ashford Software Engineer IBM Linux Technology Center, Linux Toolchain Beaverton, OR 503-578-3507 cjash...@us.ibm.com
diff --git a/perfmon/perfmon_init.c b/perfmon/perfmon_init.c index ecdc480..b3b5980 100644 --- a/perfmon/perfmon_init.c +++ b/perfmon/perfmon_init.c @@ -37,6 +37,7 @@ * 02111-1307 USA */ #include <linux/kernel.h> +#include <linux/module.h> #include <linux/perfmon_kern.h> #include "perfmon_priv.h" @@ -48,6 +49,7 @@ DEFINE_PER_CPU(struct pfm_context *, pmu_ctx); DEFINE_PER_CPU(u64, pmu_activation_number); DEFINE_PER_CPU(struct pfm_stats, pfm_stats); DEFINE_PER_CPU(struct hrtimer, pfm_hrtimer); +EXPORT_PER_CPU_SYMBOL(pmu_ctx); int perfmon_disabled; /* >0 if perfmon is disabled */
------------------------------------------------------------------------------ This SF.net email is sponsored by: SourcForge Community SourceForge wants to tell your story. http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________ perfmon2-devel mailing list perfmon2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/perfmon2-devel