From: Will Deacon <will.deacon@arm.com>
To: Yang Shi <yang.shi@linaro.org>
Cc: rostedt@goodmis.org, catalin.marinas@arm.com,
linux-kernel@vger.kernel.org, linux-rt-users@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linaro-kernel@lists.linaro.org
Subject: Re: [v2 PATCH] arm64: convert patch_lock to raw lock
Date: Wed, 7 Oct 2015 10:28:23 +0100 [thread overview]
Message-ID: <20151007092822.GB16065@arm.com> (raw)
In-Reply-To: <1444165951-26065-1-git-send-email-yang.shi@linaro.org>
On Tue, Oct 06, 2015 at 02:12:31PM -0700, Yang Shi wrote:
> When running kprobe test on arm64 rt kernel, it reports the below warning:
>
> root@qemu7:~# modprobe kprobe_example
> BUG: sleeping function called from invalid context at kernel/locking/rtmutex.c:917
> in_atomic(): 0, irqs_disabled(): 128, pid: 484, name: modprobe
> CPU: 0 PID: 484 Comm: modprobe Not tainted 4.1.6-rt5 #2
> Hardware name: linux,dummy-virt (DT)
> Call trace:
> [<ffffffc0000891b8>] dump_backtrace+0x0/0x128
> [<ffffffc000089300>] show_stack+0x20/0x30
> [<ffffffc00061dae8>] dump_stack+0x1c/0x28
> [<ffffffc0000bbad0>] ___might_sleep+0x120/0x198
> [<ffffffc0006223e8>] rt_spin_lock+0x28/0x40
> [<ffffffc000622b30>] __aarch64_insn_write+0x28/0x78
> [<ffffffc000622e48>] aarch64_insn_patch_text_nosync+0x18/0x48
> [<ffffffc000622ee8>] aarch64_insn_patch_text_cb+0x70/0xa0
> [<ffffffc000622f40>] aarch64_insn_patch_text_sync+0x28/0x48
> [<ffffffc0006236e0>] arch_arm_kprobe+0x38/0x48
> [<ffffffc00010e6f4>] arm_kprobe+0x34/0x50
> [<ffffffc000110374>] register_kprobe+0x4cc/0x5b8
> [<ffffffbffc002038>] kprobe_init+0x38/0x7c [kprobe_example]
> [<ffffffc000084240>] do_one_initcall+0x90/0x1b0
> [<ffffffc00061c498>] do_init_module+0x6c/0x1cc
> [<ffffffc0000fd0c0>] load_module+0x17f8/0x1db0
> [<ffffffc0000fd8cc>] SyS_finit_module+0xb4/0xc8
>
> Convert patch_lock to raw lock to avoid this issue.
>
> Although the problem is found on rt kernel, the fix should be applicable to
> mainline kernel too.
>
> Signed-off-by: Yang Shi <yang.shi@linaro.org>
> Acked-by: Steven Rostedt <rostedt@goodmis.org>
> ---
> v1 -> v2:
> Add Steven's Acked-by
> Fix subject (remove unnecessary "make")
> Fix a typo error in commit log
I already queued with this Steve's Ack, so we'll just have to live with
the typos.
Will
WARNING: multiple messages have this Message-ID (diff)
From: will.deacon@arm.com (Will Deacon)
To: linux-arm-kernel@lists.infradead.org
Subject: [v2 PATCH] arm64: convert patch_lock to raw lock
Date: Wed, 7 Oct 2015 10:28:23 +0100 [thread overview]
Message-ID: <20151007092822.GB16065@arm.com> (raw)
In-Reply-To: <1444165951-26065-1-git-send-email-yang.shi@linaro.org>
On Tue, Oct 06, 2015 at 02:12:31PM -0700, Yang Shi wrote:
> When running kprobe test on arm64 rt kernel, it reports the below warning:
>
> root at qemu7:~# modprobe kprobe_example
> BUG: sleeping function called from invalid context at kernel/locking/rtmutex.c:917
> in_atomic(): 0, irqs_disabled(): 128, pid: 484, name: modprobe
> CPU: 0 PID: 484 Comm: modprobe Not tainted 4.1.6-rt5 #2
> Hardware name: linux,dummy-virt (DT)
> Call trace:
> [<ffffffc0000891b8>] dump_backtrace+0x0/0x128
> [<ffffffc000089300>] show_stack+0x20/0x30
> [<ffffffc00061dae8>] dump_stack+0x1c/0x28
> [<ffffffc0000bbad0>] ___might_sleep+0x120/0x198
> [<ffffffc0006223e8>] rt_spin_lock+0x28/0x40
> [<ffffffc000622b30>] __aarch64_insn_write+0x28/0x78
> [<ffffffc000622e48>] aarch64_insn_patch_text_nosync+0x18/0x48
> [<ffffffc000622ee8>] aarch64_insn_patch_text_cb+0x70/0xa0
> [<ffffffc000622f40>] aarch64_insn_patch_text_sync+0x28/0x48
> [<ffffffc0006236e0>] arch_arm_kprobe+0x38/0x48
> [<ffffffc00010e6f4>] arm_kprobe+0x34/0x50
> [<ffffffc000110374>] register_kprobe+0x4cc/0x5b8
> [<ffffffbffc002038>] kprobe_init+0x38/0x7c [kprobe_example]
> [<ffffffc000084240>] do_one_initcall+0x90/0x1b0
> [<ffffffc00061c498>] do_init_module+0x6c/0x1cc
> [<ffffffc0000fd0c0>] load_module+0x17f8/0x1db0
> [<ffffffc0000fd8cc>] SyS_finit_module+0xb4/0xc8
>
> Convert patch_lock to raw lock to avoid this issue.
>
> Although the problem is found on rt kernel, the fix should be applicable to
> mainline kernel too.
>
> Signed-off-by: Yang Shi <yang.shi@linaro.org>
> Acked-by: Steven Rostedt <rostedt@goodmis.org>
> ---
> v1 -> v2:
> Add Steven's Acked-by
> Fix subject (remove unnecessary "make")
> Fix a typo error in commit log
I already queued with this Steve's Ack, so we'll just have to live with
the typos.
Will
next prev parent reply other threads:[~2015-10-07 9:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-06 21:12 [v2 PATCH] arm64: convert patch_lock to raw lock Yang Shi
2015-10-06 21:12 ` Yang Shi
2015-10-07 9:28 ` Will Deacon [this message]
2015-10-07 9:28 ` Will Deacon
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=20151007092822.GB16065@arm.com \
--to=will.deacon@arm.com \
--cc=catalin.marinas@arm.com \
--cc=linaro-kernel@lists.linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rt-users@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=yang.shi@linaro.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.