From: Daniel Lezcano <daniel.lezcano@linaro.org>
To: tglx@linutronix.de
Cc: Jisheng Zhang <jszhang@marvell.com>,
Barry Song <baohua@kernel.org>,
linux-arm-kernel@lists.infradead.org (moderated list:ARM/CSR
SIRFPRIMA...),
linux-kernel@vger.kernel.org (open list:CLOCKSOURCE, CLOC...)
Subject: [PATCH 4/8] clocksource/drivers/prima2: Prevent ftrace recursion
Date: Wed, 28 Oct 2015 14:11:29 +0100 [thread overview]
Message-ID: <1446037894-22601-4-git-send-email-daniel.lezcano@linaro.org> (raw)
In-Reply-To: <1446037894-22601-1-git-send-email-daniel.lezcano@linaro.org>
From: Jisheng Zhang <jszhang@marvell.com>
Currently prima2 timer can be used as a scheduler clock. We properly
marked sirfsoc_read_sched_clock() as notrace but we then call another
function sirfsoc_timer_read() that _wasn't_ notrace.
Having a traceable function in the sched_clock() path leads to a recursion
within ftrace and a kernel crash.
Fix this by adding notrace attribute to the sirfsoc_timer_read() function.
Signed-off-by: Jisheng Zhang <jszhang@marvell.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
---
drivers/clocksource/timer-prima2.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clocksource/timer-prima2.c b/drivers/clocksource/timer-prima2.c
index 78de982..2854c66 100644
--- a/drivers/clocksource/timer-prima2.c
+++ b/drivers/clocksource/timer-prima2.c
@@ -73,7 +73,7 @@ static irqreturn_t sirfsoc_timer_interrupt(int irq, void *dev_id)
}
/* read 64-bit timer counter */
-static cycle_t sirfsoc_timer_read(struct clocksource *cs)
+static cycle_t notrace sirfsoc_timer_read(struct clocksource *cs)
{
u64 cycles;
--
1.9.1
next prev parent reply other threads:[~2015-10-28 13:20 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-28 13:10 [PULL] clockevents: fixes for 4.3-rc7 Daniel Lezcano
2015-10-28 13:11 ` [PATCH 1/8] clocksource/drivers/arm_global_timer: Prevent ftrace recursion Daniel Lezcano
2015-10-28 13:11 ` [PATCH 2/8] clocksource/drivers/pistachio: " Daniel Lezcano
2015-10-28 13:11 ` [PATCH 3/8] clocksource/drivers/samsung_pwm_timer: " Daniel Lezcano
2015-10-28 13:11 ` Daniel Lezcano [this message]
2015-10-28 13:11 ` [PATCH 5/8] clocksource/drivers/vf_pit_timer: " Daniel Lezcano
2015-10-28 13:11 ` [PATCH 6/8] clocksource/drivers/fsl_ftm_timer: " Daniel Lezcano
2015-10-28 13:11 ` [PATCH 7/8] clocksource/drivers/digicolor: " Daniel Lezcano
2015-10-28 13:11 ` [PATCH 8/8] clocksource/drivers/sh_mtu2: Fix multiple shutdown call issue Daniel Lezcano
2015-10-30 9:43 ` [PULL] clockevents: fixes for 4.3-rc7 Thomas Gleixner
2015-10-30 9:53 ` Daniel Lezcano
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=1446037894-22601-4-git-send-email-daniel.lezcano@linaro.org \
--to=daniel.lezcano@linaro.org \
--cc=baohua@kernel.org \
--cc=jszhang@marvell.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
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
Powered by JetHome