<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/arch/x86/kernel/cpu, branch linux-2.6.28.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.28.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.28.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2009-05-02T17:56:39Z</updated>
<entry>
<title>x86: mtrr: don't modify RdDram/WrDram bits of fixed MTRRs</title>
<updated>2009-05-02T17:56:39Z</updated>
<author>
<name>Andreas Herrmann</name>
</author>
<published>2009-03-30T18:50:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=32c4e663de535b524a9c6c9e7b0ab85371097f5e'/>
<id>urn:sha1:32c4e663de535b524a9c6c9e7b0ab85371097f5e</id>
<content type='text'>
upstream commit: 3ff42da5048649503e343a32be37b14a6a4e8aaf

Impact: bug fix + BIOS workaround

BIOS is expected to clear the SYSCFG[MtrrFixDramModEn] on AMD CPUs
after fixed MTRRs are configured.

Some BIOSes do not clear SYSCFG[MtrrFixDramModEn] on BP (and on APs).

This can lead to obfuscation in Linux when this bit is not cleared on
BP but cleared on APs. A consequence of this is that the saved
fixed-MTRR state (from BP) differs from the fixed-MTRRs of APs --
because RdDram/WrDram bits are read as zero when
SYSCFG[MtrrFixDramModEn] is cleared -- and Linux tries to sync
fixed-MTRR state from BP to AP. This implies that Linux sets
SYSCFG[MtrrFixDramEn] and activates those bits.

More important is that (some) systems change these bits in SMM when
ACPI is enabled. Hence it is racy if Linux modifies RdMem/WrMem bits,
too.

(1) The patch modifies an old fix from Bernhard Kaindl to get
    suspend/resume working on some Acer Laptops. Bernhard's patch
    tried to sync RdMem/WrMem bits of fixed MTRR registers and that
    helped on those old Laptops. (Don't ask me why -- can't test it
    myself). But this old problem was not the motivation for the
    patch. (See http://lkml.org/lkml/2007/4/3/110)

(2) The more important effect is to fix issues on some more current systems.

    On those systems Linux panics or just freezes, see

    http://bugzilla.kernel.org/show_bug.cgi?id=11541
    (and also duplicates of this bug:
    http://bugzilla.kernel.org/show_bug.cgi?id=11737
    http://bugzilla.kernel.org/show_bug.cgi?id=11714)

    The affected systems boot only using acpi=ht, acpi=off or
    when the kernel is built with CONFIG_MTRR=n.

    The acpi options prevent full enablement of ACPI.  Obviously when
    ACPI is enabled the BIOS/SMM modfies RdMem/WrMem bits.  When
    CONFIG_MTRR=y Linux also accesses and modifies those bits when it
    needs to sync fixed-MTRRs across cores (Bernhard's fix, see (1)).
    How do you synchronize that? You can't. As a consequence Linux
    shouldn't touch those bits at all (Rationale are AMD's BKDGs which
    recommend to clear the bit that makes RdMem/WrMem accessible).
    This is the purpose of this patch. And (so far) this suffices to
    fix (1) and (2).

I suggest not to touch RdDram/WrDram bits of fixed-MTRRs and
SYSCFG[MtrrFixDramEn] and to clear SYSCFG[MtrrFixDramModEn] as
suggested by AMD K8, and AMD family 10h/11h BKDGs.
BIOS is expected to do this anyway. This should avoid that
Linux and SMM tread on each other's toes ...

Signed-off-by: Andreas Herrmann &lt;andreas.herrmann3@amd.com&gt;
Cc: trenn@suse.de
Cc: Yinghai Lu &lt;yinghai@kernel.org&gt;
LKML-Reference: &lt;20090312163937.GH20716@alberich.amd.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Chris Wright &lt;chrisw@sous-sol.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>Fix misreporting of #cores as #hyperthreads for Q9550</title>
<updated>2009-03-23T21:55:23Z</updated>
<author>
<name>Joe Korty</name>
</author>
<published>2009-03-19T17:28:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=157b13d83e8430243b1f075532ed42ecfc10a26b'/>
<id>urn:sha1:157b13d83e8430243b1f075532ed42ecfc10a26b</id>
<content type='text'>
For the Q9550, in x86_64 mode, /proc/cpuinfo mistakenly
thinks the #cores present is the #hyperthreads present.
i386 mode was not examined but is assumed to have the
same problem.

A backport of the following three 2.6.29-rc1 patches
fixes the problem:

 066941bd4eeb159307a5d7d795100d0887c00442:
    [PATCH] x86: unmask CPUID levels on Intel CPUs
 99fb4d349db7e7dacb2099c5cc320a9e2d31c1ef:
    [PATCH] x86: unmask CPUID levels on Intel CPUs, fix
 bdf21a49bab28f0d9613e8d8724ef9c9168b61b9:
    [PATCH] x86: add MSR_IA32_MISC_ENABLE bits to &lt;asm/msr-index.h&gt;

From the first patch: "If the CPUID limit bit in
MSR_IA32_MISC_ENABLE is set, clear it to make all CPUID
information available.  This is required for some features
to work, in particular XSAVE."

Originally-Developed-by: H. Peter Anvin &lt;hpa@linux.intel.com&gt;
Backported-by: Joe Korty &lt;joe.korty@ccur.com&gt;
Signed-off-by: Joe Korty &lt;joe.korty@ccur.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>x86: tone down mtrr_trim_uncached_memory() warning</title>
<updated>2009-03-17T00:32:20Z</updated>
<author>
<name>Ingo Molnar</name>
</author>
<published>2009-01-29T10:45:35Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c8788afb460005ffb5f591ef854eb8630f3eab73'/>
<id>urn:sha1:c8788afb460005ffb5f591ef854eb8630f3eab73</id>
<content type='text'>
commit bf3647c44bc76c43c4b2ebb4c37a559e899ac70e upstream.

kerneloops.org is reporting a lot of these warnings that come due to
vmware not setting up any MTRRs for emulated CPUs:

| Reported 709 times (14696 total reports)
| BIOS bug (often in VMWare) where the MTRR's are set up incorrectly
| or not at all
|
| This warning was last seen in version 2.6.29-rc2-git1, and first
| seen in 2.6.24.
|
| More info:
|   http://www.kerneloops.org/searchweek.php?search=mtrr_trim_uncached_memory

Keep a one-liner KERN_INFO about it - so that we have so notice if empty
MTRRs are caused by native hardware/BIOS weirdness.

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Cc: Chuck Ebbert &lt;cebbert@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>x86: fix intel x86_64 llc_shared_map/cpu_llc_id anomolies</title>
<updated>2009-01-18T18:43:44Z</updated>
<author>
<name>Suresh Siddha</name>
</author>
<published>2008-12-19T02:09:21Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6c2c40d1f8d457306f77524dfc0bf6f60b831fca'/>
<id>urn:sha1:6c2c40d1f8d457306f77524dfc0bf6f60b831fca</id>
<content type='text'>
commit 345077cd98ff5532b2d1158013c3fec7b1ae85ec upstream.

Impact: fix wrong cache sharing detection on platforms supporting &gt; 8 bit apicid's

In the presence of extended topology eumeration leaf 0xb provided
by cpuid, 32bit extended initial_apicid in cpuinfo_x86 struct will be
updated by detect_extended_topology(). At this instance, we should also
reinit the apicid (which could also potentially be extended to 32bit).

With out this there will potentially be duplicate apicid's populated in the
per cpu's cpuinfo_x86 struct, resulting in wrong cache sharing topology etc
detected by init_intel_cacheinfo().

Reported-by: Dimitri Sivanich &lt;sivanich@sgi.com&gt;
Signed-off-by: Suresh Siddha &lt;suresh.b.siddha@intel.com&gt;
Acked-by: Dimitri Sivanich &lt;sivanich@sgi.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>x86: re-enable MCE on secondary CPUS after suspend/resume</title>
<updated>2008-12-16T22:03:02Z</updated>
<author>
<name>Andi Kleen</name>
</author>
<published>2008-12-15T22:33:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=cf9b303e55da810255638c0b616b1a3f7eda9320'/>
<id>urn:sha1:cf9b303e55da810255638c0b616b1a3f7eda9320</id>
<content type='text'>
Impact: fix disabled MCE after resume

Don't prevent multiple initialization of MCEs.

Back from early prehistory mcheck_init() has a reentry check. Presumably
that was needed in very old kernels to prevent it entering twice.

But as Andreas points out this prevents CPU hotplug (and therefore resume)
to correctly reinitialize MCEs when a AP boots again after being
offlined.

Just drop the check.

Reported-by: Andreas Herrmann &lt;andreas.herrmann3@amd.com&gt;
Signed-off-by: Andi Kleen &lt;ak@linux.intel.com&gt;
Tested-by: Andreas Herrmann &lt;andreas.herrmann3@amd.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>[CPUFREQ] powernow-k8: ignore out-of-range PstateStatus value</title>
<updated>2008-11-25T18:38:29Z</updated>
<author>
<name>Andreas Herrmann</name>
</author>
<published>2008-11-21T13:49:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a266d9f1253a38ec2d5655ebcd6846298b0554f4'/>
<id>urn:sha1:a266d9f1253a38ec2d5655ebcd6846298b0554f4</id>
<content type='text'>
A workaround for AMD CPU family 11h erratum 311 might cause that the
P-state Status Register shows a "current P-state" which is larger than
the "current P-state limit" in P-state Current Limit Register. For the
wrong P-state value there is no ACPI _PSS object defined and
powernow-k8/cpufreq can't determine the proper CPU frequency for that
state.

As a consequence this can cause a panic during boot (potentially with
all recent kernel versions -- at least I have reproduced it with
various 2.6.27 kernels and with the current .28 series), as an
example:

powernow-k8: Found 1 AMD Turion(tm)X2 Ultra DualCore Mobile ZM-82 processors (2 \
)
powernow-k8:    0 : pstate 0 (2200 MHz)
powernow-k8:    1 : pstate 1 (1100 MHz)
powernow-k8:    2 : pstate 2 (600 MHz)
BUG: unable to handle kernel paging request at ffff88086e7528b8
IP: [&lt;ffffffff80486361&gt;] cpufreq_stats_update+0x4a/0x5f
PGD 202063 PUD 0
Oops: 0002 [#1] SMP
last sysfs file:
CPU 1
Modules linked in:
Pid: 1, comm: swapper Not tainted 2.6.28-rc3-dirty #16
RIP: 0010:[&lt;ffffffff80486361&gt;]  [&lt;ffffffff80486361&gt;] cpufreq_stats_update+0x4a/0\
f
Synaptics claims to have extended capabilities, but I'm not able to read them.&lt;6\
6
RAX: 0000000000000000 RBX: 0000000000000001 RCX: ffff88006e7528c0
RDX: 00000000ffffffff RSI: ffff88006e54af00 RDI: ffffffff808f056c
RBP: 00000000fffee697 R08: 0000000000000003 R09: ffff88006e73f080
R10: 0000000000000001 R11: 00000000002191c0 R12: ffff88006fb83c10
R13: 00000000ffffffff R14: 0000000000000001 R15: 0000000000000000
FS:  0000000000000000(0000) GS:ffff88006fb50740(0000) knlGS:0000000000000000
Unable to initialize Synaptics hardware.
CS:  0010 DS: 0018 ES: 0018 CR0: 000000008005003b
CR2: ffff88086e7528b8 CR3: 0000000000201000 CR4: 00000000000006e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process swapper (pid: 1, threadinfo ffff88006fb82000, task ffff88006fb816d0)
Stack:
 ffff88006e74da50 0000000000000000 ffff88006e54af00 ffffffff804863c7
 ffff88006e74da50 0000000000000000 00000000ffffffff 0000000000000000
 ffff88006fb83c10 ffffffff8024b46c ffffffff808f0560 ffff88006fb83c10
Call Trace:
 [&lt;ffffffff804863c7&gt;] ? cpufreq_stat_notifier_trans+0x51/0x83
 [&lt;ffffffff8024b46c&gt;] ? notifier_call_chain+0x29/0x4c
 [&lt;ffffffff8024b561&gt;] ? __srcu_notifier_call_chain+0x46/0x61
 [&lt;ffffffff8048496d&gt;] ? cpufreq_notify_transition+0x93/0xa9
 [&lt;ffffffff8021ab8d&gt;] ? powernowk8_target+0x1e8/0x5f3
 [&lt;ffffffff80486687&gt;] ? cpufreq_governor_performance+0x1b/0x20
 [&lt;ffffffff80484886&gt;] ? __cpufreq_governor+0x71/0xa8
 [&lt;ffffffff80484b21&gt;] ? __cpufreq_set_policy+0x101/0x13e
 [&lt;ffffffff80485bcd&gt;] ? cpufreq_add_dev+0x3f0/0x4cd
 [&lt;ffffffff8048577a&gt;] ? handle_update+0x0/0x8
 [&lt;ffffffff803c2062&gt;] ? sysdev_driver_register+0xb6/0x10d
 [&lt;ffffffff8056592c&gt;] ? powernowk8_init+0x0/0x7e
 [&lt;ffffffff8048604c&gt;] ? cpufreq_register_driver+0x8f/0x140
 [&lt;ffffffff80209056&gt;] ? _stext+0x56/0x14f
 [&lt;ffffffff802c2234&gt;] ? proc_register+0x122/0x17d
 [&lt;ffffffff802c23a0&gt;] ? create_proc_entry+0x73/0x8a
 [&lt;ffffffff8025c259&gt;] ? register_irq_proc+0x92/0xaa
 [&lt;ffffffff8025c2c8&gt;] ? init_irq_proc+0x57/0x69
 [&lt;ffffffff807fc85f&gt;] ? kernel_init+0x116/0x169
 [&lt;ffffffff8020cc79&gt;] ? child_rip+0xa/0x11
 [&lt;ffffffff807fc749&gt;] ? kernel_init+0x0/0x169
 [&lt;ffffffff8020cc6f&gt;] ? child_rip+0x0/0x11
Code: 05 c5 83 36 00 48 c7 c2 48 5d 86 80 48 8b 04 d8 48 8b 40 08 48 8b 34 02 48\

RIP  [&lt;ffffffff80486361&gt;] cpufreq_stats_update+0x4a/0x5f
 RSP &lt;ffff88006fb83b20&gt;
CR2: ffff88086e7528b8
---[ end trace 0678bac75e67a2f7 ]---
Kernel panic - not syncing: Attempted to kill init!

In short, aftereffect of the wrong P-state is that
cpufreq_stats_update() uses "-1" as index for some array in

cpufreq_stats_update (unsigned int cpu)
{
...
     if (stat-&gt;time_in_state)
                stat-&gt;time_in_state[stat-&gt;last_index] =
                        cputime64_add(stat-&gt;time_in_state[stat-&gt;last_index],
                                      cputime_sub(cur_time, stat-&gt;last_time));
...
}

Fortunately, the wrong P-state value is returned only if the core is
in P-state 0. This fix solves the problem by detecting the
out-of-range P-state, ignoring it, and using "0" instead.

Cc: Mark Langsdorf &lt;mark.langsdorf@amd.com&gt;
Signed-off-by: Andreas Herrmann &lt;andreas.herrmann3@amd.com&gt;
Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
</content>
</entry>
<entry>
<title>x86: build fix</title>
<updated>2008-10-31T08:31:38Z</updated>
<author>
<name>Ingo Molnar</name>
</author>
<published>2008-10-31T08:31:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b342797c1e5116a130841527b47dfaa462ed0968'/>
<id>urn:sha1:b342797c1e5116a130841527b47dfaa462ed0968</id>
<content type='text'>
Impact: build fix on certain UP configs

fix:

 arch/x86/kernel/cpu/common.c: In function 'cpu_init':
 arch/x86/kernel/cpu/common.c:1141: error: 'boot_cpu_id' undeclared (first use in this function)
 arch/x86/kernel/cpu/common.c:1141: error: (Each undeclared identifier is reported only once
 arch/x86/kernel/cpu/common.c:1141: error: for each function it appears in.)

Pull in asm/smp.h on UP, so that we get the definition of
boot_cpu_id.

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>x86: cpu_index build fix</title>
<updated>2008-10-30T23:43:03Z</updated>
<author>
<name>Ingo Molnar</name>
</author>
<published>2008-10-30T23:43:03Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1c4acdb467f8a6704855a5670ff3d82e3c18eb0b'/>
<id>urn:sha1:1c4acdb467f8a6704855a5670ff3d82e3c18eb0b</id>
<content type='text'>
fix:

 arch/x86/kernel/cpu/common.c: In function 'early_identify_cpu':
 arch/x86/kernel/cpu/common.c:553: error: 'struct cpuinfo_x86' has no member named 'cpu_index'

as cpu_index is only available on SMP.

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>x86/voyager: fix missing cpu_index initialisation</title>
<updated>2008-10-30T23:19:37Z</updated>
<author>
<name>James Bottomley</name>
</author>
<published>2008-10-30T21:13:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bfcb4c1becf93b1592f4a03a4d6e00a3ab89d5ec'/>
<id>urn:sha1:bfcb4c1becf93b1592f4a03a4d6e00a3ab89d5ec</id>
<content type='text'>
Impact: fix /proc/cpuinfo output on x86/Voyager

Ever since

| commit 92cb7612aee39642d109b8d935ad265e602c0563
| Author: Mike Travis &lt;travis@sgi.com&gt;
| Date:   Fri Oct 19 20:35:04 2007 +0200
|
|     x86: convert cpuinfo_x86 array to a per_cpu array

We've had an extra field in cpuinfo_x86 which is cpu_index.
Unfortunately, voyager has never initialised this, although the only
noticeable impact seems to be that /proc/cpuinfo shows all zeros for
the processor ids.

Anyway, fix this by initialising the boot CPU properly and setting the
index when the secondaries update.

Signed-off-by: James Bottomley &lt;James.Bottomley@HansenPartnership.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>x86/voyager: fix compile breakage caused by dc1e35c6e95e8923cf1d3510438b63c600fee1e2</title>
<updated>2008-10-30T23:19:33Z</updated>
<author>
<name>James Bottomley</name>
</author>
<published>2008-10-30T21:00:59Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b3572e361b6b2ac5e724bc4bb932b7774b720b95'/>
<id>urn:sha1:b3572e361b6b2ac5e724bc4bb932b7774b720b95</id>
<content type='text'>
Impact: build fix on x86/Voyager

Given commits like this:

| Author: Suresh Siddha &lt;suresh.b.siddha@intel.com&gt;
| Date:   Tue Jul 29 10:29:19 2008 -0700
|
|     x86, xsave: enable xsave/xrstor on cpus with xsave support

Which deliberately expose boot cpu dependence to pieces of the system,
I think it's time to explicitly have a variable for it to prevent this
continual misassumption that the boot CPU is zero.

Signed-off-by: James Bottomley &lt;James.Bottomley@HansenPartnership.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
</feed>
