diff options
Diffstat (limited to 'drivers/cpufreq/powernow-k7.c')
-rw-r--r-- | drivers/cpufreq/powernow-k7.c | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/drivers/cpufreq/powernow-k7.c b/drivers/cpufreq/powernow-k7.c index 44d345bad6fb..946708a1d745 100644 --- a/drivers/cpufreq/powernow-k7.c +++ b/drivers/cpufreq/powernow-k7.c | |||
@@ -248,7 +248,7 @@ static void change_VID(int vid) | |||
248 | } | 248 | } |
249 | 249 | ||
250 | 250 | ||
251 | static void change_speed(struct cpufreq_policy *policy, unsigned int index) | 251 | static int powernow_target(struct cpufreq_policy *policy, unsigned int index) |
252 | { | 252 | { |
253 | u8 fid, vid; | 253 | u8 fid, vid; |
254 | struct cpufreq_freqs freqs; | 254 | struct cpufreq_freqs freqs; |
@@ -291,6 +291,8 @@ static void change_speed(struct cpufreq_policy *policy, unsigned int index) | |||
291 | local_irq_enable(); | 291 | local_irq_enable(); |
292 | 292 | ||
293 | cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE); | 293 | cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE); |
294 | |||
295 | return 0; | ||
294 | } | 296 | } |
295 | 297 | ||
296 | 298 | ||
@@ -533,22 +535,6 @@ static int powernow_decode_bios(int maxfid, int startvid) | |||
533 | } | 535 | } |
534 | 536 | ||
535 | 537 | ||
536 | static int powernow_target(struct cpufreq_policy *policy, | ||
537 | unsigned int target_freq, | ||
538 | unsigned int relation) | ||
539 | { | ||
540 | unsigned int newstate; | ||
541 | |||
542 | if (cpufreq_frequency_table_target(policy, powernow_table, target_freq, | ||
543 | relation, &newstate)) | ||
544 | return -EINVAL; | ||
545 | |||
546 | change_speed(policy, newstate); | ||
547 | |||
548 | return 0; | ||
549 | } | ||
550 | |||
551 | |||
552 | /* | 538 | /* |
553 | * We use the fact that the bus frequency is somehow | 539 | * We use the fact that the bus frequency is somehow |
554 | * a multiple of 100000/3 khz, then we compute sgtc according | 540 | * a multiple of 100000/3 khz, then we compute sgtc according |
@@ -694,7 +680,7 @@ static int powernow_cpu_exit(struct cpufreq_policy *policy) | |||
694 | 680 | ||
695 | static struct cpufreq_driver powernow_driver = { | 681 | static struct cpufreq_driver powernow_driver = { |
696 | .verify = cpufreq_generic_frequency_table_verify, | 682 | .verify = cpufreq_generic_frequency_table_verify, |
697 | .target = powernow_target, | 683 | .target_index = powernow_target, |
698 | .get = powernow_get, | 684 | .get = powernow_get, |
699 | #ifdef CONFIG_X86_POWERNOW_K7_ACPI | 685 | #ifdef CONFIG_X86_POWERNOW_K7_ACPI |
700 | .bios_limit = acpi_processor_get_bios_limit, | 686 | .bios_limit = acpi_processor_get_bios_limit, |