Bug 4401

Summary: Enable C2,C3 on SMP systems
Product: ACPI Reporter: Venkatesh Pallipadi (venki)
Component: Power-ProcessorAssignee: Venkatesh Pallipadi (venki)
Status: CLOSED CODE_FIX    
Severity: normal CC: acpi-bugzilla, linux
Priority: P2    
Hardware: i386   
OS: Linux   
Kernel Version: 2.6.11 Subsystem:
Regression: --- Bisected commit-id:
Attachments: Patch to enable C2 and C3 on SMP
Patch to enable C2 and C3 on SMP
Patch to enable C2 and C3 on SMP - Take 3
Patch to enable C2 and C3 on SMP - Take 4
Patch to enable C2 and C3 on SMP - Take 5
more changes related tp L2 cache and C3 state
Remove some debug printk's from above patch.

Description Venkatesh Pallipadi 2005-03-25 15:29:25 UTC
C2 and C3 are disabled on an SMP system. Enable it.
Comment 1 Venkatesh Pallipadi 2005-03-25 15:30:22 UTC
Created attachment 4800 [details]
Patch to enable C2 and C3 on SMP
Comment 2 Venkatesh Pallipadi 2005-03-25 15:30:33 UTC
Created attachment 4801 [details]
Patch to enable C2 and C3 on SMP
Comment 3 Venkatesh Pallipadi 2005-03-25 16:55:31 UTC
Created attachment 4803 [details]
Patch to enable C2 and C3 on SMP - Take 3
Comment 4 Venkatesh Pallipadi 2005-03-31 15:46:23 UTC
Created attachment 4834 [details]
Patch to enable C2 and C3 on SMP - Take 4

This patch obsoletes all the earlier patches.
Changes from Take 3 version:
- Do a invalid cache before C3 invocation. 
- BM_DISABLE is not required for SMP. Remove Enabling/Disabling and BM history
in SMP case.
Comment 5 Dominik Brodowski 2005-04-01 10:18:21 UTC
If you do an 
#ifdef ARCH_HAS_CSTATE_INIT
void arch_cstate_init(struct acpi_processor_power *pow, unsigned int cpu);
#else
static inline void arch_cstate_init(struct acpi_processor_power *pow, unsigned
int cpu) { return; }
#endif
somewhere in .h 

you can get rid of the #ifdef lines in .c files -- that's the common way of
doing this in the kernel.

also,
+ifdef CONFIG_X86
+processor-objs	+= ../../arch/i386/kernel/acpi/cstate.o
+endif
is ugly. Better EXPORT_SYMBOL() what you need in processor.o, and build
arch/i386/kernel/acpi/cstate.o into the kernel if _PRCOESSOR is m or y.
Comment 6 Venkatesh Pallipadi 2005-04-01 10:58:15 UTC
Created attachment 4837 [details]
Patch to enable C2 and C3 on SMP - Take 5

Obsoletes all earlier pactches.

Changes from patch 4:
- Minor formatting changes
- Changes based on Review comments
Comment 7 Venkatesh Pallipadi 2005-04-20 18:25:02 UTC
Created attachment 4959 [details]
more changes related tp L2 cache and C3 state
Comment 8 Len Brown 2005-04-22 20:29:41 UTC
applied patch in comment #7 to acpi-test tree 
Comment 9 Venkatesh Pallipadi 2005-04-25 14:38:46 UTC
Created attachment 4979 [details]
Remove some debug printk's from above patch.

Incremental patch over the previous one. Removes some debug printks that were
in the above patch by mistake.
Comment 10 Len Brown 2005-07-29 19:04:52 UTC
applied comment #9 to-linus
Comment 11 Len Brown 2005-08-03 18:45:59 UTC
shipped in 2.6.13-rc5 -- closing.