summaryrefslogtreecommitdiffstats
path: root/drivers/crypto/caam/intern.h
diff options
context:
space:
mode:
authorDaniel Thompson <daniel.thompson@linaro.org>2015-03-26 12:23:22 -0700
committerIngo Molnar <mingo@kernel.org>2015-03-27 08:33:56 +0100
commit8710e914027e4f64058ebbf0501cc6db3cc8454f (patch)
treeaab1f5735303d0fae22a7208784e99f7a323a66a /drivers/crypto/caam/intern.h
parent2557d215a36d18c8bbaa35f65749349ac603360b (diff)
downloadop-kernel-dev-8710e914027e4f64058ebbf0501cc6db3cc8454f.zip
op-kernel-dev-8710e914027e4f64058ebbf0501cc6db3cc8454f.tar.gz
timers, sched/clock: Match scope of read and write seqcounts
Currently the scope of the raw_write_seqcount_begin/end() in sched_clock_register() far exceeds the scope of the read section in sched_clock(). This gives the impression of safety during cursory review but achieves little. Note that this is likely to be a latent issue at present because sched_clock_register() is typically called before we enable interrupts, however the issue does risk bugs being needlessly introduced as the code evolves. This patch fixes the problem by increasing the scope of the read locking performed by sched_clock() to cover all data modified by sched_clock_register. We also improve clarity by moving writes to struct clock_data that do not impact sched_clock() outside of the critical section. Signed-off-by: Daniel Thompson <daniel.thompson@linaro.org> [ Reworked it slightly to apply to tip/timers/core] Signed-off-by: John Stultz <john.stultz@linaro.org> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Russell King <linux@arm.linux.org.uk> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Will Deacon <will.deacon@arm.com> Link: http://lkml.kernel.org/r/1427397806-20889-2-git-send-email-john.stultz@linaro.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'drivers/crypto/caam/intern.h')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud