<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/arch/powerpc/kernel/entry_64.S, branch linux-3.17.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.17.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.17.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2014-11-14T18:10:39Z</updated>
<entry>
<title>powerpc: do_notify_resume can be called with bad thread_info flags argument</title>
<updated>2014-11-14T18:10:39Z</updated>
<author>
<name>Anton Blanchard</name>
</author>
<published>2014-10-31T05:50:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ca2612cb0a0a3261a46e49997ec28ad4b029d7d8'/>
<id>urn:sha1:ca2612cb0a0a3261a46e49997ec28ad4b029d7d8</id>
<content type='text'>
commit 808be31426af57af22268ef0fcb42617beb3d15b upstream.

Back in 7230c5644188 ("powerpc: Rework lazy-interrupt handling") we
added a call out to restore_interrupts() (written in c) before calling
do_notify_resume:

        bl      restore_interrupts
        addi    r3,r1,STACK_FRAME_OVERHEAD
        bl      do_notify_resume

Unfortunately do_notify_resume takes two arguments, the second one
being the thread_info flags:

void do_notify_resume(struct pt_regs *regs, unsigned long thread_info_flags)

We do populate r4 (the second argument) earlier, but
restore_interrupts() is free to muck it up all it wants. My guess is
the gcc compiler gods shone down on us and its register allocator
never used r4. Sometimes, rarely, luck is on our side.

LLVM on the other hand did trample r4.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>powerpc/book3s: Add basic infrastructure to handle HMI in Linux.</title>
<updated>2014-08-05T06:33:48Z</updated>
<author>
<name>Mahesh Salgaonkar</name>
</author>
<published>2014-07-29T13:10:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0869b6fd209bda402576a9a559120ddd4f61198e'/>
<id>urn:sha1:0869b6fd209bda402576a9a559120ddd4f61198e</id>
<content type='text'>
Handle Hypervisor Maintenance Interrupt (HMI) in Linux. This patch implements
basic infrastructure to handle HMI in Linux host. The design is to invoke
opal handle hmi in real mode for recovery and set irq_pending when we hit HMI.
During check_irq_replay pull opal hmi event and print hmi info on console.

Signed-off-by: Mahesh Salgaonkar &lt;mahesh@linux.vnet.ibm.com&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
</content>
</entry>
<entry>
<title>powerpc: Remove MMU_FTR_SLB</title>
<updated>2014-07-28T04:10:23Z</updated>
<author>
<name>Michael Ellerman</name>
</author>
<published>2014-07-10T02:29:20Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=13b3d13b813ab834fac67dc05f8b86dbcc29c134'/>
<id>urn:sha1:13b3d13b813ab834fac67dc05f8b86dbcc29c134</id>
<content type='text'>
We now only support cpus that use an SLB, so we don't need an MMU
feature to indicate that.

Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
</content>
</entry>
<entry>
<title>powerpc: Correct DSCR during TM context switch</title>
<updated>2014-06-11T07:02:56Z</updated>
<author>
<name>Sam bobroff</name>
</author>
<published>2014-06-05T06:19:22Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=96d016108640bc2b7fb0ee800737f80923847294'/>
<id>urn:sha1:96d016108640bc2b7fb0ee800737f80923847294</id>
<content type='text'>
Correct the DSCR SPR becoming temporarily corrupted if a task is
context switched during a transaction.

The problem occurs while suspending the task and is caused by saving
the DSCR to thread.dscr after it has already been set to the CPU's
default value:

__switch_to() calls __switch_to_tm()
	which calls tm_reclaim_task()
	which calls tm_reclaim_thread()
	which calls tm_reclaim()
		where the DSCR is set to the CPU's default
__switch_to() calls _switch()
		where thread.dscr is set to the DSCR

When the task is resumed, it's transaction will be doomed (as usual)
and the DSCR SPR will be corrupted, although the checkpointed value
will be correct. Therefore the DSCR will be immediately corrected by
the transaction aborting, unless it has been suspended. In that case
the incorrect value can be seen by the task until it resumes the
transaction.

The fix is to treat the DSCR similarly to the TAR and save it early
in __switch_to().

A program exposing the problem is added to the kernel self tests as:
tools/testing/selftests/powerpc/tm/tm-resched-dscr.

Signed-off-by: Sam Bobroff &lt;sam.bobroff@au1.ibm.com&gt;
CC: &lt;stable@vger.kernel.org&gt; [v3.10+]
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
</content>
</entry>
<entry>
<title>powerpc: Fix regression of per-CPU DSCR setting</title>
<updated>2014-05-28T03:35:40Z</updated>
<author>
<name>Sam bobroff</name>
</author>
<published>2014-05-21T06:32:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1739ea9e13e636590dd56c2f4ca85e783da512e7'/>
<id>urn:sha1:1739ea9e13e636590dd56c2f4ca85e783da512e7</id>
<content type='text'>
Since commit "efcac65 powerpc: Per process DSCR + some fixes (try#4)"
it is no longer possible to set the DSCR on a per-CPU basis.

The old behaviour was to minipulate the DSCR SPR directly but this is no
longer sufficient: the value is quickly overwritten by context switching.

This patch stores the per-CPU DSCR value in a kernel variable rather than
directly in the SPR and it is used whenever a process has not set the DSCR
itself. The sysfs interface (/sys/devices/system/cpu/cpuN/dscr) is unchanged.

Writes to the old global default (/sys/devices/system/cpu/dscr_default)
now set all of the per-CPU values and reads return the last written value.

The new per-CPU default is added to the paca_struct and is used everywhere
outside of sysfs.c instead of the old global default.

Signed-off-by: Sam Bobroff &lt;sam.bobroff@au1.ibm.com&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
</content>
</entry>
<entry>
<title>powerpc: ftrace_caller, _mcount is exported to modules so needs _GLOBAL_TOC()</title>
<updated>2014-04-23T00:05:33Z</updated>
<author>
<name>Anton Blanchard</name>
</author>
<published>2014-04-03T22:06:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5e66684fe4c71e4d62d6a5d313057185ac0890cc'/>
<id>urn:sha1:5e66684fe4c71e4d62d6a5d313057185ac0890cc</id>
<content type='text'>
When testing the ftrace function tracer, I realised that ftrace_caller
and mcount are called from modules and they both call into C, therefore
they need the ABIv2 global entry point to establish r2.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
</content>
</entry>
<entry>
<title>powerpc: Fix kernel thread creation on ABIv2</title>
<updated>2014-04-23T00:05:23Z</updated>
<author>
<name>Anton Blanchard</name>
</author>
<published>2014-02-04T05:08:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7cedd6014bfe353d4b552ed8d54d63f6e06e26ba'/>
<id>urn:sha1:7cedd6014bfe353d4b552ed8d54d63f6e06e26ba</id>
<content type='text'>
Change how we setup registers for ret_from_kernel_thread. In
ABIv1, instead of passing a function descriptor in, dereference
it and pass the target in directly.

Use ppc_global_function_entry to get it right on both ABIv1 and ABIv2.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
</content>
</entry>
<entry>
<title>powerpc: ABIv2 function calls must place target address in r12</title>
<updated>2014-04-23T00:05:20Z</updated>
<author>
<name>Anton Blanchard</name>
</author>
<published>2014-02-04T05:07:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=cc7efbf91933a4b59c20e60115c336b26dfc1195'/>
<id>urn:sha1:cc7efbf91933a4b59c20e60115c336b26dfc1195</id>
<content type='text'>
To establish addressability quickly, ABIv2 requires the target
address of the function being called to be in r12. Fix a number of
places in assembly code that we do indirect function calls.

We need to avoid function descriptors on ABIv2 too.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
</content>
</entry>
<entry>
<title>powerpc: Don't use a function descriptor for system call table</title>
<updated>2014-04-23T00:05:17Z</updated>
<author>
<name>Anton Blanchard</name>
</author>
<published>2014-02-04T05:05:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c857c43b34ecbfd686d860d4e85281d3750e3b47'/>
<id>urn:sha1:c857c43b34ecbfd686d860d4e85281d3750e3b47</id>
<content type='text'>
There is no need to create a function descriptor for the system call
table. By using one we force the system call table into the text
section and it really belongs in the rodata section.

This also removes another use of dot symbols.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
</content>
</entry>
<entry>
<title>powerpc: Remove superflous function descriptors in assembly only code</title>
<updated>2014-04-23T00:05:17Z</updated>
<author>
<name>Anton Blanchard</name>
</author>
<published>2014-02-04T05:04:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ad0289e4acf2bd6989e745cff3b4f0781a919e30'/>
<id>urn:sha1:ad0289e4acf2bd6989e745cff3b4f0781a919e30</id>
<content type='text'>
We have a number of places where we load the text address of a local
function and indirectly branch to it in assembly. Since it is an
indirect branch binutils will not know to use the function text
address, so that trick wont work.

There is no need for these functions to have a function descriptor
so we can replace it with a label and remove the dot symbol.

Signed-off-by: Anton Blanchard &lt;anton@samba.org&gt;
</content>
</entry>
</feed>
