From: Tsutomu OWA <tsutomu.owa@toshiba•co.jp>
To: mingo@elte•hu
Cc: linuxppc-dev@ozlabs•org, linux-kernel@vger•kernel.org
Subject: [patch 3/6 -rt] powerpc 2.6.20-rt8: fix a runtime warning for smp_processor_id()
Date: Wed, 07 Mar 2007 10:39:42 +0900 [thread overview]
Message-ID: <yyi4pox25nl.wl@toshiba.co.jp> (raw)
In-Reply-To: <yyi8xe925vg.wl@toshiba.co.jp>
To fix the following runtime warning.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
BUG: using smp_processor_id() in preemptible [00000000] code: init/371
caller is .pgtable_free_tlb+0x2c/0x14c
Call Trace:
[C00000000FF6B770] [C00000000000FAAC] .show_stack+0x68/0x1b0 (unreliable)
[C00000000FF6B810] [C0000000001F7190] .debug_smp_processor_id+0xc8/0xf8
[C00000000FF6B8A0] [C00000000002C52C] .pgtable_free_tlb+0x2c/0x14c
[C00000000FF6B940] [C0000000000B6528] .free_pgd_range+0x234/0x3bc
[C00000000FF6BA40] [C0000000000B6AB8] .free_pgtables+0x224/0x260
[C00000000FF6BB00] [C0000000000B7FE8] .exit_mmap+0x100/0x208
[C00000000FF6BBC0] [C000000000055FB0] .mmput+0x70/0x12c
[C00000000FF6BC50] [C00000000005B728] .exit_mm+0x150/0x170
[C00000000FF6BCE0] [C00000000005D80C] .do_exit+0x28c/0x9bc
[C00000000FF6BDA0] [C00000000005DFF0] .sys_exit_group+0x0/0x8
[C00000000FF6BE30] [C000000000008634] syscall_exit+0x0/0x40
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Would it be better to just use raw_smp_processor_id() rather than tlb->cpu?
Signed-off-by: Tsutomu Owa <tsutomu.owa@toshiba•co.jp>
-- owa
diff -rup linux-rt8/arch/powerpc/mm/tlb_64.c rt/arch/powerpc/mm/tlb_64.c
--- linux-rt8/arch/powerpc/mm/tlb_64.c 2007-02-20 14:30:38.000000000 +0900
+++ rt/arch/powerpc/mm/tlb_64.c 2007-03-05 13:31:24.000000000 +0900
@@ -94,8 +94,11 @@ static void pte_free_submit(struct pte_f
void pgtable_free_tlb(struct mmu_gather *tlb, pgtable_free_t pgf)
{
- /* This is safe since tlb_gather_mmu has disabled preemption */
- cpumask_t local_cpumask = cpumask_of_cpu(smp_processor_id());
+ /*
+ * This is safe since tlb_gather_mmu has disabled preemption.
+ * tlb->cpu is set by tlb_gather_mmu as well.
+ */
+ cpumask_t local_cpumask = cpumask_of_cpu(tlb->cpu);
struct pte_freelist_batch **batchp = &__get_cpu_var(pte_freelist_cur);
if (atomic_read(&tlb->mm->mm_users) < 2 ||
next prev parent reply other threads:[~2007-03-07 1:40 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-07 1:34 [patch 0/6 -rt] powerpc 2.6.20-rt8: fix boot/runtime errors/warnings for PowerPC(ppc64) Tsutomu OWA
2007-03-07 1:36 ` [patch 1/6 -rt] powerpc 2.6.20-rt8: add preemption checks for NEED_RESCHED_DELAYED Tsutomu OWA
2007-03-16 19:20 ` Sergei Shtylyov
2007-03-19 0:00 ` Tsutomu OWA
2007-03-07 1:37 ` [patch 2/6 -rt] powerpc 2.6.20-rt8: to convert spinlocks to raw ones Tsutomu OWA
2007-03-07 14:38 ` Sergei Shtylyov
2007-03-07 14:43 ` Benjamin Herrenschmidt
2007-03-07 14:54 ` Sergei Shtylyov
2007-03-07 16:49 ` Paul Mackerras
2007-03-07 17:30 ` Sergei Shtylyov
2007-03-07 19:21 ` Paul Mackerras
2007-03-07 21:21 ` Sergei Shtylyov
2007-03-07 21:30 ` Paul Mackerras
2007-03-08 0:43 ` Bill Huey
2007-03-08 3:26 ` Paul Mackerras
2007-03-08 4:00 ` Bill Huey
2007-03-07 1:39 ` Tsutomu OWA [this message]
2007-03-07 1:42 ` [RFC] [patch 4/6 -rt] powerpc 2.6.20-rt8: fix a runtime warnings for xmon Tsutomu OWA
2007-03-07 9:16 ` Ingo Molnar
2007-03-07 10:10 ` Benjamin Herrenschmidt
2007-03-07 10:54 ` Tsutomu OWA
2007-03-07 11:06 ` Arnd Bergmann
2007-03-07 1:45 ` [RFC] [patch 5/6] powerpc 2.6.20-rt8: fix a boot error for handle_percpu_irq Tsutomu OWA
2007-03-07 21:29 ` Sergei Shtylyov
2007-03-07 1:47 ` [patch 6/6 -rt] powerpc 2.6.20-rt8: fix boot/runtime errors/warnings Tsutomu OWA
2007-03-07 9:13 ` [patch 0/6 -rt] powerpc 2.6.20-rt8: fix boot/runtime errors/warnings for PowerPC(ppc64) Ingo Molnar
2007-03-07 14:26 ` Sergei Shtylyov
2007-03-08 2:28 ` Tsutomu OWA
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=yyi4pox25nl.wl@toshiba.co.jp \
--to=tsutomu.owa@toshiba$(echo .)co.jp \
--cc=linux-kernel@vger$(echo .)kernel.org \
--cc=linuxppc-dev@ozlabs$(echo .)org \
--cc=mingo@elte$(echo .)hu \
/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