Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 80278
b: refs/heads/master
c: 2c6b8c0
h: refs/heads/master
v: v3
  • Loading branch information
travis@sgi.com authored and Ingo Molnar committed Jan 30, 2008
1 parent c9a4181 commit 2bc4ff7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3cc87e3f4042a099fb649c5df33d3ccfae36173f
refs/heads/master: 2c6b8c030cfca334c3d700ee504036c585c4c6a3
12 changes: 6 additions & 6 deletions trunk/arch/x86/kernel/cpu/cpufreq/powernow-k8.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
/* serialize freq changes */
static DEFINE_MUTEX(fidvid_mutex);

static struct powernow_k8_data *powernow_data[NR_CPUS];
static DEFINE_PER_CPU(struct powernow_k8_data *, powernow_data);

static int cpu_family = CPU_OPTERON;

Expand Down Expand Up @@ -1018,7 +1018,7 @@ static int transition_frequency_pstate(struct powernow_k8_data *data, unsigned i
static int powernowk8_target(struct cpufreq_policy *pol, unsigned targfreq, unsigned relation)
{
cpumask_t oldmask = CPU_MASK_ALL;
struct powernow_k8_data *data = powernow_data[pol->cpu];
struct powernow_k8_data *data = per_cpu(powernow_data, pol->cpu);
u32 checkfid;
u32 checkvid;
unsigned int newstate;
Expand Down Expand Up @@ -1094,7 +1094,7 @@ static int powernowk8_target(struct cpufreq_policy *pol, unsigned targfreq, unsi
/* Driver entry point to verify the policy and range of frequencies */
static int powernowk8_verify(struct cpufreq_policy *pol)
{
struct powernow_k8_data *data = powernow_data[pol->cpu];
struct powernow_k8_data *data = per_cpu(powernow_data, pol->cpu);

if (!data)
return -EINVAL;
Expand Down Expand Up @@ -1202,7 +1202,7 @@ static int __cpuinit powernowk8_cpu_init(struct cpufreq_policy *pol)
dprintk("cpu_init done, current fid 0x%x, vid 0x%x\n",
data->currfid, data->currvid);

powernow_data[pol->cpu] = data;
per_cpu(powernow_data, pol->cpu) = data;

return 0;

Expand All @@ -1216,7 +1216,7 @@ static int __cpuinit powernowk8_cpu_init(struct cpufreq_policy *pol)

static int __devexit powernowk8_cpu_exit (struct cpufreq_policy *pol)
{
struct powernow_k8_data *data = powernow_data[pol->cpu];
struct powernow_k8_data *data = per_cpu(powernow_data, pol->cpu);

if (!data)
return -EINVAL;
Expand All @@ -1237,7 +1237,7 @@ static unsigned int powernowk8_get (unsigned int cpu)
cpumask_t oldmask = current->cpus_allowed;
unsigned int khz = 0;

data = powernow_data[first_cpu(per_cpu(cpu_core_map, cpu))];
data = per_cpu(powernow_data, first_cpu(per_cpu(cpu_core_map, cpu)));

if (!data)
return -EINVAL;
Expand Down

0 comments on commit 2bc4ff7

Please sign in to comment.