aboutsummaryrefslogtreecommitdiffstats
path: root/arch/i386/kernel/cpu/cpufreq (follow)
AgeCommit message (Collapse)AuthorFilesLines
2007-08-07acpi-cpufreq: Fix some x86/x86-64 acpi-cpufreq driver issuesFenghua Yu1-26/+15
This patch addresses some issues in x86/x86-64 acpi-cpufreq driver: 1. Current memory allocation for acpi_perf_data is actually open-coded alloc_percpu(). The patch defines and handles acpi_perf_data as percpu data. The code will be cleaner and easier to be maintained with this change. 2. Won't load driver in acpi_cpufreq_early_init() failure case. 3. Add __init for acpi_cpufreq_early_init(). Signed-off-by: Fenghua Yu <fenghua.yu@intel.com> Acked-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Cc: Dave Jones <davej@codemonkey.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Len Brown <len.brown@intel.com>
2007-07-31Fix uninitialized local variable "covered" in i386 acpi-cpufreq driverFenghua Yu1-3/+1
The local variable "covered" is used without initialization in i386 acpi-cpufreq driver. The initial value of covered should be 0. The bug will cause memory leak when hit. The following patch fixes this bug. Signed-off-by: Fenghua Yu <fenghua.yu@intel.com> Cc: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-26X86_POWERNOW_K8_ACPI must depend on ACPIAdrian Bunk1-1/+1
This patch fixes the following compile error introduced by commit e8666b2718fdb5bf0ea7c3126f7e292bbbf2946b and reported by Alexey Dobriyan: <-- snip --> CC arch/i386/kernel/acpi/cstate.o In file included from arch/i386/kernel/acpi/cstate.c:17: include/acpi/processor.h:88: error: expected specifier-qualifier-list before 'acpi_integer' <-- snip --> If you select something you must ensure that the dependencies of what you are selecting are fulfilled. Signed-off-by: Adrian Bunk <bunk@stusta.de> Cc: Alexey Dobriyan <adobriyan@sw.ru> Cc: Joshua Hoblitt <jhoblitt@ifa.hawaii.edu> Cc: Dave Jones <davej@redhat.com> Cc: Michal Piotrowski <michal.k.k.piotrowski@gmail.com> Cc: Len Brown <lenb@kernel.org> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-22Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6Linus Torvalds1-2/+2
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: (77 commits) ACPI: Populate /sys/firmware/acpi/tables/ ACPI: create CONFIG_ACPI_DEBUG_FUNC_TRACE ACPI: update ACPI proc I/F removal schedule ACPI: update feature-removal-schedule.txt, /sys/firmware/acpi/namespace is gone ACPI: export ACPI events via acpi_mc_group multicast group ACPI: fix empty macros found by -Wextra ACPI: drivers/acpi/pci_link.c: lower printk severity sony-laptop: Fix event reading in sony-laptop sony-laptop: Add Vaio FE to the special init sequence sony-laptop: Make the driver use MSC_SCAN and a setkeycode and getkeycode key table. sony-laptop: Invoke _INI for SNC devices that provide it sony-laptop: Add support for recent Vaios Fn keys (C series for now) sony-laptop: map wireless switch events to KEY_WLAN sony-laptop: add new SNC handlers ACPI: thinkpad-acpi: add locking to brightness subdriver ACPI: thinkpad-acpi: bump up version to 0.15 ACPI: thinkpad-acpi: make EC-based thermal readings non-experimental ACPI: thinkpad-acpi: make sure DSDT TMPx readings don't return +128 ACPI: thinkpad-acpi: react to Lenovo ThinkPad differences in hot key ACPI: thinkpad-acpi: allow use of CMOS NVRAM for brightness control ...
2007-07-22x86: Replace NSC/Cyrix specific chipset access macros by inlined functions.Juergen Beisert1-1/+1
Due to index register access ordering problems, when using macros a line like this fails (and does nothing): setCx86(CX86_CCR2, getCx86(CX86_CCR2) | 0x88); With inlined functions this line will work as expected. Note about a side effect: Seems on Geode GX1 based systems the "suspend on halt power saving feature" was never enabled due to this wrong macro expansion. With inlined functions it will be enabled, but this will stop the TSC when the CPU runs into a HLT instruction. Kernel output something like this: Clocksource tsc unstable (delta = -472746897 ns) This is the 3rd version of this patch. - Adding missed arch/i386/kernel/cpu/mtrr/state.c Thanks to Andres Salomon - Adding some big fat comments into the new header file Suggested by Andi Kleen AK: fixed x86-64 compilation Signed-off-by: Juergen Beisert <juergen@kreuzholzen.de> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-22Pull bugzilla-7880 into release branchLen Brown1-2/+2
2007-07-13[CPUFREQ] Fix typos in powernow-k8 printk's.Dave Jones1-8/+11
Based on a patch from Joachim which didn't apply, so I fixed it up by hand, and also corrected the surrounding indentation a little. Signed-off-by: Joachim.Deguara <joachim.deguara@amd.com> Acked-by: Mark Langsdorf <mark.langsdorf@amd.com> Signed-off-by: Dave Jones <davej@redhat.com>
2007-07-13[CPUFREQ] powernow-k8 compile fix.Andrew Morton1-1/+6
Make it compile on UP. Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Dave Jones <davej@redhat.com>
2007-07-13[CPUFREQ] the overdue removal of X86_SPEEDSTEP_CENTRINO_ACPIAdrian Bunk2-276/+18
This patch contains the overdue removal of X86_SPEEDSTEP_CENTRINO_ACPI. Signed-off-by: Adrian Bunk <bunk@stusta.de> Acked-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Dave Jones <davej@redhat.com>
2007-07-13[CPUFREQ] Longhaul - Option to disable ACPI C3 supportRafał Bilski1-0/+7
On some motherboards ACPI C3 is available, but it isn't causing frequency transition on VIA Nehemiah. Longhaul wasn't working at all earlier, but due to scaling_cur_speed returning true CPU frequency now, it looks like CPU is getting stuck at highest frequency since 2.6.21. I didn't find a reason. Halt is causing frequency transition. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-07-12Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreqLinus Torvalds5-90/+162
* master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq: [CPUFREQ] Fix sysfs_create_file return value handling [CPUFREQ] ondemand: fix tickless accounting and software coordination bug [CPUFREQ] ondemand: add a check to avoid negative load calculation [CPUFREQ] Keep userspace governor quiet when it is not being used [CPUFREQ] Longhaul - Proper register access [CPUFREQ] Kconfig powernow-k8 driver should depend on ACPI P-States driver [CPUFREQ] Longhaul - Replace ACPI functions with direct I/O [CPUFREQ] Longhaul - Remove duplicate multipliers [CPUFREQ] Longhaul - Embedded "conservative" [CPUFREQ] acpi-cpufreq: Proper ReadModifyWrite of PERF_CTL MSR [CPUFREQ] check return value of sysfs_create_file [CPUFREQ] Longhaul - Check ACPI "BM DMA in progress" bit [CPUFREQ] Longhaul - Move old_ratio to correct place [CPUFREQ] Longhaul - VT8237 support [CPUFREQ] Longhaul - Use all kinds of support [CPUFREQ] powernow-k8: clarify number of cores.
2007-07-11PCI: Change all drivers to use pci_device->revisionAuke Kok3-11/+3
Instead of all drivers reading pci config space to get the revision ID, they can now use the pci_device->revision member. This exposes some issues where drivers where reading a word or a dword for the revision number, and adding useless error-handling around the read. Some drivers even just read it for no purpose of all. In devices where the revision ID is being copied over and used in what appears to be the equivalent of hotpath, I have left the copy code and the cached copy as not to influence the driver's performance. Compile tested with make all{yes,mod}config on x86_64 and i386. Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com> Acked-by: Dave Jones <davej@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-06-21[CPUFREQ] Longhaul - Proper register accessRafał Bilski1-6/+6
In previous commit I used u32 for u16 register. This code will work only when ACPI block address is set. For now it is only for VT8235 and VT8237. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-06-13ACPI: Discard invalid elements in _PSS packageZhang Rui1-2/+2
Make sure that the _PSS list is sorted in descending order by typical power dissipation. http://bugzilla.kernel.org/show_bug.cgi?id=7880 Signed-off-by: Zhang Rui <rui.zhang@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
2007-06-06[CPUFREQ] Kconfig powernow-k8 driver should depend on ACPI P-States driverJoshua Hoblitt1-3/+10
powernow-k8 really needs to use ACPI to function on SMP systems. The current Kconfig allows us to build kernels which fail mysteriously for some users due to us trying to automatically enable this, and getting it wrong. It's easier to just present this as an option to the user. Signed-off-by: Joshua Hoblitt <jhoblitt@ifa.hawaii.edu> Signed-off-by: Dave Jones <davej@redhat.com>
2007-06-06[CPUFREQ] Longhaul - Replace ACPI functions with direct I/ORafał Bilski1-7/+16
Current version of "bm status" bit test works as long as no USB device is in use. When USB device is plugged in ACPI function in this context is always returning 1. Until reboot. Direct I/O is working fine even when many USB devices are connected. Change bm_timeout value to less annoying. 1000 is still much more then worst case observed and it is much better when status bit gets stuck. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-29[CPUFREQ] Longhaul - Remove duplicate multipliersRafał Bilski1-6/+6
Remove duplicate multipliers in clock_ratio table. On 1,4GHz Nehemiah two frequencies are present twice in table. It isn't fatal, but with voltage scaling enabled each will be set twice. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-29[CPUFREQ] Longhaul - Embedded "conservative"Rafał Bilski1-49/+96
Longhaul with voltage scaling enabled works great on Ezra CPU (Longhaul ver. 2). As long as "conservative" governor is used. Both "ondemand" and "userspace" can change voltage from min to max at once. Motherboard unfortunatly turns off when vid difference is big. Longhaul was printing warning message, but it is not enough. Now driver will have "conservative" governor built in and will split bigger changes to smaller ones. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-29[CPUFREQ] acpi-cpufreq: Proper ReadModifyWrite of PERF_CTL MSRVenki Pallipadi1-8/+5
During recent acpi-cpufreq changes, writing to PERF_CTL msr changed from RMW of entire 64 bit to RMW of low 32 bit and clearing of upper 32 bit. Fix it back to do a proper RMW of the MSR. Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-29[CPUFREQ] Longhaul - Check ACPI "BM DMA in progress" bitRafał Bilski1-0/+18
It is good idea to wait for PCI bus to become idle before frequency change. Thanks to ACPI it is possible. It makes sense only when northbridge support is in use because it is only case in which we can disable arbiter after check if PCI bus is busy. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-29[CPUFREQ] Longhaul - Move old_ratio to correct placeRafał Bilski1-1/+1
Move one line where it should be. After first transition Longhaul will skip frequency transition if destination frequency is already set. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-29[CPUFREQ] Longhaul - VT8237 supportRafał Bilski1-0/+4
Looks like VT8237 has the same bits which VT8235 has. Poke registers if it is found. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-29[CPUFREQ] Longhaul - Use all kinds of supportRafał Bilski1-22/+11
This patch is removing southbridge support as separate kind of support. Instead it is used to make other kinds of support more stable. Also northbridge and ACPI C3 support both will be used if both are available. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-21Detach sched.h from mm.hAlexey Dobriyan1-0/+1
First thing mm.h does is including sched.h solely for can_do_mlock() inline function which has "current" dereference inside. By dealing with can_do_mlock() mm.h can be detached from sched.h which is good. See below, why. This patch a) removes unconditional inclusion of sched.h from mm.h b) makes can_do_mlock() normal function in mm/mlock.c c) exports can_do_mlock() to not break compilation d) adds sched.h inclusions back to files that were getting it indirectly. e) adds less bloated headers to some files (asm/signal.h, jiffies.h) that were getting them indirectly Net result is: a) mm.h users would get less code to open, read, preprocess, parse, ... if they don't need sched.h b) sched.h stops being dependency for significant number of files: on x86_64 allmodconfig touching sched.h results in recompile of 4083 files, after patch it's only 3744 (-8.3%). Cross-compile tested on all arm defconfigs, all mips defconfigs, all powerpc defconfigs, alpha alpha-up arm i386 i386-up i386-defconfig i386-allnoconfig ia64 ia64-up m68k mips parisc parisc-up powerpc powerpc-up s390 s390-up sparc sparc-up sparc64 sparc64-up um-x86_64 x86_64 x86_64-up x86_64-defconfig x86_64-allnoconfig as well as my two usual configs. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-18[CPUFREQ] powernow-k8: clarify number of cores.Dave Jones1-2/+3
Indicate number of processors and cores more cleanly in startup messages. Signed-off-by: Mark Langsdorf <mark.langsdorf@amd.com> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-14[CPUFREQ] Correct revision mask for powernow-k8Dave Jones2-2/+2
Mark Langsdorf points out that the correct define for this revision bump is 0x80000. Also to save us having to keep renaming the #define, give it a more meaningful name. Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-13[CPUFREQ] powernow-k7: fix MHz rounding issue with perflibDaniel Drake1-8/+28
When the PST tables are broken, powernow-k7 uses ACPI's processor_perflib to deduce the available frequency multipliers from the _PSS tables. Upon frequency change, processor_perflib performs some verification on the frequency (checks that it's within allowable bounds). powernow-k7 deals with absolute frequencies in KHz, whereas perflib only deals with MHz values. When performing the above verification, perflib multiplies the MHz values by 1000 to obtain the KHz value. We then end up with situations like the following: - powernow-k7 multiplies the multiplier by the FSB, and obtains a value such as 1266768 KHz - perflib belives the same state has frequency of 1266 MHz - acpi_processor_ppc_notifier calls cpufreq_verify_within_limits to verify that 1266768 is in the allowable range of 0 to 1266000 (i.e. 1266 * 1000) - it's not, so that frequency is rejected - the maximum CPU frequency is not reachable This patch solves the problem by rounding up the MHz values stored in perflib's tables. Additionally it corrects a broken URL. It also fixes http://bugzilla.kernel.org/show_bug.cgi?id=8255 although this case is a bit different: the frequencies in the _PSS tables are wildly wrong, but we get better results if we force ACPI to respect the fsb * multiplier calculations (even though it seems that the multiplier values aren't entirely correct either). Signed-off-by: Daniel Drake <dsd@gentoo.org> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-13[CPUFREQ] Support rev H AMD64s in powernow-k8Dave Jones2-3/+3
Reported-by: Calvin Dodge <caldodge@gmail.com> Signed-off-by: Dave Jones <davej@redhat.com>
2007-05-04Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6Linus Torvalds2-2/+1
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6: (59 commits) PCI: Free resource files in error path of pci_create_sysfs_dev_files() pci-quirks: disable MSI on RS400-200 and RS480 PCI hotplug: Use menuconfig objects PCI: ZT5550 CPCI Hotplug driver fix PCI: rpaphp: Remove semaphores PCI: rpaphp: Ensure more pcibios_add/pcibios_remove symmetry PCI: rpaphp: Use pcibios_remove_pci_devices() symmetrically PCI: rpaphp: Document is_php_dn() PCI: rpaphp: Document find_php_slot() PCI: rpaphp: Rename rpaphp_register_pci_slot() to rpaphp_enable_slot() PCI: rpaphp: refactor tail call to rpaphp_register_slot() PCI: rpaphp: remove rpaphp_set_attention_status() PCI: rpaphp: remove print_slot_pci_funcs() PCI: rpaphp: Remove setup_pci_slot() PCI: rpaphp: remove a call that does nothing but a pointer lookup PCI: rpaphp: Remove another wrappered function PCI: rpaphp: Remve another call that is a wrapper PCI: rpaphp: remove a function that does nothing but wrap debug printks PCI: rpaphp: Remove un-needed goto PCI: rpaphp: Fix a memleak; slot->location string was never freed ...
2007-05-02PCI: Cleanup the includes of <linux/pci.h>Jean Delvare2-2/+1
I noticed that many source files include <linux/pci.h> while they do not appear to need it. Here is an attempt to clean it all up. In order to find all possibly affected files, I searched for all files including <linux/pci.h> but without any other occurence of "pci" or "PCI". I removed the include statement from all of these, then I compiled an allmodconfig kernel on both i386 and x86_64 and fixed the false positives manually. My tests covered 66% of the affected files, so there could be false positives remaining. Untested files are: arch/alpha/kernel/err_common.c arch/alpha/kernel/err_ev6.c arch/alpha/kernel/err_ev7.c arch/ia64/sn/kernel/huberror.c arch/ia64/sn/kernel/xpnet.c arch/m68knommu/kernel/dma.c arch/mips/lib/iomap.c arch/powerpc/platforms/pseries/ras.c arch/ppc/8260_io/enet.c arch/ppc/8260_io/fcc_enet.c arch/ppc/8xx_io/enet.c arch/ppc/syslib/ppc4xx_sgdma.c arch/sh64/mach-cayman/iomap.c arch/xtensa/kernel/xtensa_ksyms.c arch/xtensa/platform-iss/setup.c drivers/i2c/busses/i2c-at91.c drivers/i2c/busses/i2c-mpc.c drivers/media/video/saa711x.c drivers/misc/hdpuftrs/hdpu_cpustate.c drivers/misc/hdpuftrs/hdpu_nexus.c drivers/net/au1000_eth.c drivers/net/fec_8xx/fec_main.c drivers/net/fec_8xx/fec_mii.c drivers/net/fs_enet/fs_enet-main.c drivers/net/fs_enet/mac-fcc.c drivers/net/fs_enet/mac-fec.c drivers/net/fs_enet/mac-scc.c drivers/net/fs_enet/mii-bitbang.c drivers/net/fs_enet/mii-fec.c drivers/net/ibm_emac/ibm_emac_core.c drivers/net/lasi_82596.c drivers/parisc/hppb.c drivers/sbus/sbus.c drivers/video/g364fb.c drivers/video/platinumfb.c drivers/video/stifb.c drivers/video/valkyriefb.c include/asm-arm/arch-ixp4xx/dma.h sound/oss/au1550_ac97.c I would welcome test reports for these files. I am fine with removing the untested files from the patch if the general opinion is that these changes aren't safe. The tested part would still be nice to have. Note that this patch depends on another header fixup patch I submitted to LKML yesterday: [PATCH] scatterlist.h needs types.h http://lkml.org/lkml/2007/3/01/141 Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: Badari Pulavarty <pbadari@us.ibm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-04-30[CPUFREQ] Report the number of processors in PowerNow-k8 correctlyMark Langsdorf1-2/+4
The PowerNow! driver for Opteron reports the number of cores in the system, but claims to report the number of processors. Fix this minor cosmetic bug. Signed-off-by: Bhavana Nagendra <bhavana.nagendra@amd.com> Acked-by: Mark Langsdorf <mark.langsdorf@amd.com> Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-30[CPUFREQ] do not declare undefined functionsDavid Rientjes1-0/+2
fill_powernow_table_pstate() and fill_powernow_table_fidvid() are only defined and used for X86_POWERNOW_K8_ACPI. Signed-off-by: David Rientjes <rientjes@google.com> Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-26[CPUFREQ] Longhaul - Revert Longhaul ver. 2Rafal Bilski1-1/+1
There is something wrong with this code. It needs more testing. It is better to disable it for now because support for some machines will be broken. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-26Fix preemption warnings in speedstep-centrino.cDave Jones1-1/+9
BUG: using smp_processor_id() in preemptible [00000001] code: kondemand/0/2473 caller is centrino_target+0xfb/0x600 [<401e3646>] debug_smp_processor_id+0x9e/0xb0 [<40112afb>] centrino_target+0xfb/0x600 [<40112a00>] centrino_target+0x0/0x600 [<40305bd9>] __cpufreq_driver_target+0x5c/0x6b [<f897a537>] do_dbs_timer+0x1bc/0x208 [cpufreq_ondemand] [<40134a46>] run_workqueue+0x85/0x125 [<40374f7f>] _spin_lock_irqsave+0x18/0x66 [<f897a37b>] do_dbs_timer+0x0/0x208 [cpufreq_ondemand] [<401353fb>] worker_thread+0xf9/0x124 [<401213b9>] default_wake_function+0x0/0xc [<40135302>] worker_thread+0x0/0x124 [<40137b37>] kthread+0xb0/0xd9 [<40137a87>] kthread+0x0/0xd9 [<40104b2f>] kernel_thread_helper+0x7/0x10 Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-26[CPUFREQ] Longhaul - Correct PCI codeRafał Bilski1-7/+12
Replace obsolete pci_find_device with pci_get_device. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-26[CPUFREQ] p4-clockmod: switch to rdmsr_on_cpu/wrmsr_on_cpuAlexey Dobriyan1-25/+6
Dances with cpumasks go away. Signed-off-by: Alexey Dobriyan <adobriyan@sw.ru> Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-20Longhaul - Revert ACPI C3 on Longhaul ver. 2Dave Jones1-1/+1
Support for Longhaul ver. 2 broke driver for VIA C3 Eden 600MHz with Samuel 2 core. Processor is not able to switch frequency anymore. I don't know much about this issue at the moment, but until (if ever) I will know why, this part should be reversed. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-26Revert "[CPUFREQ] constify cpufreq_driver where possible."Linus Torvalds12-13/+13
This reverts commit aeeddc1435c37fa3fc844f31d39c185b08de4158, which was half-baked and broken. It just resulted in compile errors, since cpufreq_register_driver() still changes the 'driver_data' by setting bits in the flags field. So claiming it is 'const' _really_ doesn't work. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-22[CPUFREQ] constify some data tables.Dave Jones3-17/+17
Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-22[CPUFREQ] constify cpufreq_driver where possible.Dave Jones12-13/+13
Not all cases are possible due to ->flags being set at runtime on some drivers. Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-20[CPUFREQ] Revert default on deprecated config X86_SPEEDSTEP_CENTRINO_ACPIThomas Renninger1-1/+0
Revert default on deprecated config X86_SPEEDSTEP_CENTRINO_ACPI Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Dave Jones <davej@redhat.com> arch/i386/kernel/cpu/cpufreq/Kconfig | 1 - arch/x86_64/kernel/cpufreq/Kconfig | 1 - 2 files changed, 2 deletions(-)
2007-02-14[CPUFREQ] Longhaul - Redo Longhaul ver. 2Rafa³ Bilski1-22/+31
Start using v2 version of Longhaul when available. It provides voltage scaling and can use ACPI C3 state. That's curious. CPU will not change frequency on ACPI C3 when v1 is in use, but it will when v2 is used. Driver will return max frequency all the time if this isn't true for all processors. There is strange thing with mobile voltage. Looks like only Nehemiah (C3-M) supports it. Earlier processors have different mobile VRM (in docs), but I can't find any which is using it. Looks like all are using VRM 8.5. So fail for non Nehemiah with mobile VRM. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-13[CPUFREQ] EPS - Correct 2nd brand testRafa³ Bilski1-1/+1
Solution for small, but nasty bug: access beyond end of f_table for C7 brand. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-10[CPUFREQ] Fix up merge conflicts with recent ACPI changes.Dave Jones1-10/+8
Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-10[CPUFREQ] Longhaul - Separate frequency and voltage transitionRafa³ Bilski1-16/+93
This change should make Longhaul more compatible with both ver. 2 and Powersaver processors. Voltage transitions will be done before or after frequency transition. That depends on direction of change. I don't know how to force conservative governor when voltage scaling is enabled, so there is only a warning for user. Minimal voltage is calculated in different way now because in this way more power is saved at lower multipliers. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-10[CPUFREQ] Longhaul - Models of NehemiahRafa³ Bilski1-3/+3
Borowed from VIA driver. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-10[CPUFREQ] Longhaul - Simplier minmultRafa³ Bilski1-15/+8
Simple cleanup in code which is setting minmult. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-10[CPUFREQ] Enhanced PowerSaver driverRafa³ Bilski3-0/+344
This is driver for Enhanced Powersaver which is present in VIA C7 processors. Beta tested by Jorgen (jorgen (at) greven dot dk). Thanks! Based on documentation provided by Dave Jones (Thanks!) and C7 Eden datasheet available from www.via.com.tw. Looks like all these C7 Eden CPU's don't have P-states in BIOS. I know that 2 p-states is low, but Jorgen finds it usefull anyway because board is passive cooled. There are 3 different types of C7 processors (called brands): 0. C7-M - these processors can set any maultiplier between min and max, any voltage between min and max. 1. C7 - only min and max states are supported. Voltage is different for min and max states. 2. Eden - only min and max states are supported. Looks like this brand can only change multiplier. Voltage seems to be the same for min and max frequency. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-04[CPUFREQ] Longhaul - Add VT8235 supportRafa³ Bilski1-12/+50
I don't know why it is working and how, but it is working. On my Epia transition time is by default set to 100us. I'm changing it to 200us. After that I can change frequency from min (x4.0) to max (x7.5) without lockup. Many times. There is a paranoid check at a beginning of a patch. Probably dead code, but I don't have better ideas for CL10000 case at the moment. Only way to to detect broken chip seems to be looking in log for spurious interrupts. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>
2007-02-04[CPUFREQ] Longhaul - Fix guess_fsb functionRafa³ Bilski1-22/+10
This is bug reported by John-Marc Chandonia: > Detected 1002.292 MHz processor. > longhaul: VIA C3 'Nehemiah B' [C5N] CPU detected. Powersaver supported. > longhaul: Using throttling support. > longhaul: Invalid (reserved) FSB! FSB is correcly guessed for 999.554 MHz CPU. To fix this error: - ROUNDING should be range, not mask - at it's current value it is +7 -8, - more precise calculations inside guess_fsb - 7.5x133MHz is 1000MHz now. Signed-off-by: Rafal Bilski <rafalbilski@interia.pl> Signed-off-by: Dave Jones <davej@redhat.com>