<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/arch/powerpc, branch v3.0.41</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/arch/powerpc?h=v3.0.41</id>
<link rel='self' href='https://git.amat.us/linux/atom/arch/powerpc?h=v3.0.41'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2012-08-09T15:27:34Z</updated>
<entry>
<title>powerpc: Fix wrong divisor in usecs_to_cputime</title>
<updated>2012-08-09T15:27:34Z</updated>
<author>
<name>Andreas Schwab</name>
<email>schwab@linux-m68k.org</email>
</author>
<published>2011-12-09T11:35:08Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c43386c06d5d73a9b3a8604226b1e32d85a4c384'/>
<id>urn:sha1:c43386c06d5d73a9b3a8604226b1e32d85a4c384</id>
<content type='text'>
commit 9f5072d4f63f28d30d343573830ac6c85fc0deff upstream.

Commit d57af9b (taskstats: use real microsecond granularity for CPU times)
renamed msecs_to_cputime to usecs_to_cputime, but failed to update all
numbers on the way.  This causes nonsensical cpu idle/iowait values to be
displayed in /proc/stat (the only user of usecs_to_cputime so far).

This also renames __cputime_msec_factor to __cputime_usec_factor, adapting
its value and using it directly in cputime_to_usecs instead of doing two
multiplications.

Signed-off-by: Andreas Schwab &lt;schwab@linux-m68k.org&gt;
Acked-by: Anton Blanchard &lt;anton@samba.org&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Cc: Michal Hocko &lt;mhocko@suse.cz&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc: Add "memory" attribute for mfmsr()</title>
<updated>2012-08-09T15:27:33Z</updated>
<author>
<name>Tiejun Chen</name>
<email>tiejun.chen@windriver.com</email>
</author>
<published>2012-07-11T04:22:46Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=93487ce8d6edc7c550b1449770df5e44715f520f'/>
<id>urn:sha1:93487ce8d6edc7c550b1449770df5e44715f520f</id>
<content type='text'>
commit b416c9a10baae6a177b4f9ee858b8d309542fbef upstream.

Add "memory" attribute in inline assembly language as a compiler
barrier to make sure 4.6.x GCC don't reorder mfmsr().

Signed-off-by: Tiejun Chen &lt;tiejun.chen@windriver.com&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc/ftrace: Fix assembly trampoline register usage</title>
<updated>2012-08-09T15:27:33Z</updated>
<author>
<name>roger blofeld</name>
<email>blofeldus@yahoo.com</email>
</author>
<published>2012-06-21T05:27:14Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=a8ed5765b5a8bf44a86284d80afd24f37a23e369'/>
<id>urn:sha1:a8ed5765b5a8bf44a86284d80afd24f37a23e369</id>
<content type='text'>
commit fd5a42980e1cf327b7240adf5e7b51ea41c23437 upstream.

Just like the module loader, ftrace needs to be updated to use r12
instead of r11 with newer gcc's.

Signed-off-by: Roger Blofeld &lt;blofeldus@yahoo.com&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Paul Gortmaker &lt;paul.gortmaker@windriver.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc/xmon: Use cpumask iterator to avoid warning</title>
<updated>2012-07-16T15:47:35Z</updated>
<author>
<name>Anton Blanchard</name>
<email>anton@samba.org</email>
</author>
<published>2012-06-28T19:28:57Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=24ec2125f3c828af6446d8eeee2268a05e78724b'/>
<id>urn:sha1:24ec2125f3c828af6446d8eeee2268a05e78724b</id>
<content type='text'>
commit bc1d7702910c7c7e88eb60b58429dbfe293683ce upstream.

We have a bug report where the kernel hits a warning in the cpumask
code:

WARNING: at include/linux/cpumask.h:107

Which is:
        WARN_ON_ONCE(cpu &gt;= nr_cpumask_bits);

The backtrace is:
        cpu_cmd
        cmds
        xmon_core
        xmon
        die

xmon is iterating through 0 to NR_CPUS. I'm not sure why we are still
open coding this but iterating above nr_cpu_ids is definitely a bug.

This patch iterates through all possible cpus, in case we issue a
system reset and CPUs in an offline state call in.

Perhaps the old code was trying to handle CPUs that were in the
partition but were never started (eg kexec into a kernel with an
nr_cpus= boot option). They are going to die way before we get into
xmon since we haven't set any kernel state up for them.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc: Fix kernel panic during kernel module load</title>
<updated>2012-06-17T18:23:10Z</updated>
<author>
<name>Steffen Rumler</name>
<email>steffen.rumler.ext@nsn.com</email>
</author>
<published>2012-06-06T14:37:17Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=238607e0800c37b64868e6ec2323fc0e25cd7363'/>
<id>urn:sha1:238607e0800c37b64868e6ec2323fc0e25cd7363</id>
<content type='text'>
commit 3c75296562f43e6fbc6cddd3de948a7b3e4e9bcf upstream.

This fixes a problem which can causes kernel oopses while loading
a kernel module.

According to the PowerPC EABI specification, GPR r11 is assigned
the dedicated function to point to the previous stack frame.
In the powerpc-specific kernel module loader, do_plt_call()
(in arch/powerpc/kernel/module_32.c), GPR r11 is also used
to generate trampoline code.

This combination crashes the kernel, in the case where the compiler
chooses to use a helper function for saving GPRs on entry, and the
module loader has placed the .init.text section far away from the
.text section, meaning that it has to generate a trampoline for
functions in the .init.text section to call the GPR save helper.
Because the trampoline trashes r11, references to the stack frame
using r11 can cause an oops.

The fix just uses GPR r12 instead of GPR r11 for generating the
trampoline code.  According to the statements from Freescale, this is
safe from an EABI perspective.

I've tested the fix for kernel 2.6.33 on MPC8541.

Signed-off-by: Steffen Rumler &lt;steffen.rumler.ext@nsn.com&gt;
[paulus@samba.org: reworded the description]
Signed-off-by: Paul Mackerras &lt;paulus@samba.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc/pmac: Fix SMP kernels on pre-core99 UP machines</title>
<updated>2012-03-23T18:20:52Z</updated>
<author>
<name>Benjamin Herrenschmidt</name>
<email>benh@kernel.crashing.org</email>
</author>
<published>2011-12-09T04:06:18Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=029a9375e40af22c2f75d7a15615d2c87731f366'/>
<id>urn:sha1:029a9375e40af22c2f75d7a15615d2c87731f366</id>
<content type='text'>
commit 78c5c68a4cf4329d17abfa469345ddf323d4fd62 upstream.

The code for "powersurge" SMP would kick in and cause a crash
at boot due to the lack of a NULL test.

Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Jeremy Kerr &lt;jeremy.kerr@canonical.com&gt;
Reported-by: Adam Conrad &lt;adconrad@ubuntu.com&gt;
Tested-by: Adam Conrad &lt;adconrad@ubuntu.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc/perf: power_pmu_start restores incorrect values, breaking frequency events</title>
<updated>2012-03-01T00:33:39Z</updated>
<author>
<name>Anton Blanchard</name>
<email>anton@samba.org</email>
</author>
<published>2012-02-15T18:48:22Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=49f936fe90802f0923f47d28f755c83d358feac9'/>
<id>urn:sha1:49f936fe90802f0923f47d28f755c83d358feac9</id>
<content type='text'>
commit 9a45a9407c69d068500923480884661e2b9cc421 upstream.

perf on POWER stopped working after commit e050e3f0a71b (perf: Fix
broken interrupt rate throttling). That patch exposed a bug in
the POWER perf_events code.

Since the PMCs count upwards and take an exception when the top bit
is set, we want to write 0x80000000 - left in power_pmu_start. We were
instead programming in left which effectively disables the counter
until we eventually hit 0x80000000. This could take seconds or longer.

With the patch applied I get the expected number of samples:

          SAMPLE events:       9948

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
Acked-by: Paul Mackerras &lt;paulus@samba.org&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc: Fix unpaired probe_hcall_entry and probe_hcall_exit</title>
<updated>2012-01-12T19:35:03Z</updated>
<author>
<name>Li Zhong</name>
<email>zhong@linux.vnet.ibm.com</email>
</author>
<published>2011-12-18T16:03:04Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=ec0d3233562d591c892841fcfa73edd3700a6ca6'/>
<id>urn:sha1:ec0d3233562d591c892841fcfa73edd3700a6ca6</id>
<content type='text'>
commit e4f387d8db3ba3c2dae4d8bdfe7bb5f4fe1bcb0d upstream.

Unpaired calling of probe_hcall_entry and probe_hcall_exit might happen
as following, which could cause incorrect preempt count.

__trace_hcall_entry =&gt; trace_hcall_entry -&gt; probe_hcall_entry =&gt;
get_cpu_var =&gt; preempt_disable

__trace_hcall_exit =&gt; trace_hcall_exit -&gt; probe_hcall_exit =&gt;
put_cpu_var =&gt; preempt_enable

where:
A =&gt; B and A -&gt; B means A calls B, but
=&gt; means A will call B through function name, and B will definitely be
called.
-&gt; means A will call B through function pointer, so B might not be
called if the function pointer is not set.

So error happens when only one of probe_hcall_entry and probe_hcall_exit
get called during a hcall.

This patch tries to move the preempt count operations from
probe_hcall_entry and probe_hcall_exit to its callers.

Reported-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Signed-off-by: Li Zhong &lt;zhong@linux.vnet.ibm.com&gt;
Tested-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>powerpc/time: Handle wrapping of decrementer</title>
<updated>2012-01-12T19:35:02Z</updated>
<author>
<name>Anton Blanchard</name>
<email>anton@samba.org</email>
</author>
<published>2011-11-23T20:07:17Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=bfaebb8af017d443937022cf3d5735d726e4f711'/>
<id>urn:sha1:bfaebb8af017d443937022cf3d5735d726e4f711</id>
<content type='text'>
commit 37fb9a0231ee43d42d069863bdfd567fca2b61af upstream.

When re-enabling interrupts we have code to handle edge sensitive
decrementers by resetting the decrementer to 1 whenever it is negative.
If interrupts were disabled long enough that the decrementer wrapped to
positive we do nothing. This means interrupts can be delayed for a long
time until it finally goes negative again.

While we hope interrupts are never be disabled long enough for the
decrementer to go positive, we have a very good test team that can
drive any kernel into the ground. The softlockup data we get back
from these fails could be seconds in the future, completely missing
the cause of the lockup.

We already keep track of the timebase of the next event so use that
to work out if we should trigger a decrementer exception.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>powerpc: Copy down exception vectors after feature fixups</title>
<updated>2011-11-21T22:31:25Z</updated>
<author>
<name>Anton Blanchard</name>
<email>anton@samba.org</email>
</author>
<published>2011-11-14T12:54:47Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=214af5d355ce204cd0bcf630245cdc37853cb484'/>
<id>urn:sha1:214af5d355ce204cd0bcf630245cdc37853cb484</id>
<content type='text'>
commit d715e433b7ad19c02fc4becf0d5e9a59f97925de upstream.

kdump fails because we try to execute an HV only instruction. Feature
fixups are being applied after we copy the exception vectors down to 0
so they miss out on any updates.

We have always had this issue but it only became critical in v3.0
when we added CFAR support (breaks POWER5) and v3.1 when we added
POWERNV (breaks everyone).

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
</feed>
