From: Sam Bobroff <sam.bobroff@au1•ibm.com>
To: benh@au1•ibm.com
Cc: aik@ozlabs•ru, mikey@neuling•org, linuxppc-dev@lists•ozlabs.org
Subject: [PATCH 0/3] powerpc: fix regression of per-CPU DSCR setting
Date: Wed, 21 May 2014 16:32:36 +1000 [thread overview]
Message-ID: <cover.1400652868.git.sam.bobroff@au1.ibm.com> (raw)
Hello,
This patch corrects a regression on PowerPC CPUs that causes their
per-CPU DSCR SPR value (exposed via /sys/devices/system/cpuN/dscr) to
be quickly lost during context switching, effectively meaning that the
DSCR can no longer be set on a per-CPU basis.
My intent is to restore the functionality of the per-CPU value in a
way that is compatible with the newer global default and task-specific
DSCR setting system. Users of either the old or new systems should
now get pretty much what they expect.
A couple of notes:
I've split an existing "ifdef CONFIG_PPC_STD_MMU_64" block in
paca_struct into two parts because it allows dscr_default to be placed
into a cache line hole. (This seems be the case even without
CONFIG_PPC_STD_MMU_64 being defined.) Comments or ideas on alternative
placements are welcome.
PowerPC context switching is touched but there should not be any
performance cost; if anything it should get slightly faster due to the
per-CPU value being easier to access than the old global default.
Sam Bobroff (3):
powerpc: Split __SYSFS_SPRSETUP macro
powerpc: fix regression of per-CPU DSCR setting
powerpc: Document sysfs DSCR interface
Documentation/ABI/stable/sysfs-devices-system-cpu | 25 ++++++++++
arch/powerpc/include/asm/paca.h | 3 ++
arch/powerpc/kernel/asm-offsets.c | 1 +
arch/powerpc/kernel/entry_64.S | 9 +---
arch/powerpc/kernel/sysfs.c | 51 +++++++++++++--------
arch/powerpc/kernel/tm.S | 16 ++-----
arch/powerpc/kvm/book3s_hv_rmhandlers.S | 3 +-
7 files changed, 67 insertions(+), 41 deletions(-)
create mode 100644 Documentation/ABI/stable/sysfs-devices-system-cpu
--
1.7.10.4
next reply other threads:[~2014-05-21 6:32 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-21 6:32 Sam Bobroff [this message]
2014-05-21 6:32 ` [PATCH 1/3] powerpc: Split __SYSFS_SPRSETUP macro Sam Bobroff
2014-06-02 9:09 ` Madhavan Srinivasan
2014-05-21 6:32 ` [PATCH 2/3] powerpc: fix regression of per-CPU DSCR setting Sam Bobroff
2014-06-02 9:27 ` Madhavan Srinivasan
2014-05-21 6:32 ` [PATCH 3/3] powerpc: Document sysfs DSCR interface Sam Bobroff
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1400652868.git.sam.bobroff@au1.ibm.com \
--to=sam.bobroff@au1$(echo .)ibm.com \
--cc=aik@ozlabs$(echo .)ru \
--cc=benh@au1$(echo .)ibm.com \
--cc=linuxppc-dev@lists$(echo .)ozlabs.org \
--cc=mikey@neuling$(echo .)org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox