提交 ee811517 编写于 作者: M Markus Metzger 提交者: Ingo Molnar

x86, ds: use single debug store cpu configuration

Use a single configuration for all cpus.
Reported-by: NIngo Molnar <mingo@elte.hu>
Signed-off-by: NMarkus Metzger <markus.t.metzger@intel.com>
Cc: roland@redhat.com
Cc: eranian@googlemail.com
Cc: oleg@redhat.com
Cc: juan.villacis@intel.com
Cc: ak@linux.jf.intel.com
LKML-Reference: <20090403144602.191165000@intel.com>
Signed-off-by: NIngo Molnar <mingo@elte.hu>
上级 2311f0de
...@@ -47,9 +47,8 @@ struct ds_configuration { ...@@ -47,9 +47,8 @@ struct ds_configuration {
/* Control bit-masks indexed by enum ds_feature: */ /* Control bit-masks indexed by enum ds_feature: */
unsigned long ctl[dsf_ctl_max]; unsigned long ctl[dsf_ctl_max];
}; };
static DEFINE_PER_CPU(struct ds_configuration, ds_cfg_array); static struct ds_configuration ds_cfg __read_mostly;
#define ds_cfg per_cpu(ds_cfg_array, smp_processor_id())
/* Maximal size of a DS configuration: */ /* Maximal size of a DS configuration: */
#define MAX_SIZEOF_DS (12 * 8) #define MAX_SIZEOF_DS (12 * 8)
...@@ -1268,6 +1267,10 @@ ds_configure(const struct ds_configuration *cfg, ...@@ -1268,6 +1267,10 @@ ds_configure(const struct ds_configuration *cfg,
void __cpuinit ds_init_intel(struct cpuinfo_x86 *c) void __cpuinit ds_init_intel(struct cpuinfo_x86 *c)
{ {
/* Only configure the first cpu. Others are identical. */
if (ds_cfg.name)
return;
switch (c->x86) { switch (c->x86) {
case 0x6: case 0x6:
switch (c->x86_model) { switch (c->x86_model) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册