This is a note to let you know that I've just added the patch titled

    sparc64: Like x86 we should check current->mm during perf backtrace 
generation.

to the 3.6-stable tree which can be found at:
    
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     
sparc64-like-x86-we-should-check-current-mm-during-perf-backtrace-generation.patch
and it can be found in the queue-3.6 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.


>From 3149157b67ae8b5a96dce0a444137248cd1c9672 Mon Sep 17 00:00:00 2001
From: "David S. Miller" <[email protected]>
Date: Sun, 14 Oct 2012 17:59:40 -0700
Subject: sparc64: Like x86 we should check current->mm during perf backtrace 
generation.


From: "David S. Miller" <[email protected]>

[ Upstream commit 08280e6c4c2e8049ac61d9e8e3536ec1df629c0d ]

If the MM is not active, only report the top-level PC.  Do not try to
access the address space.

Signed-off-by: David S. Miller <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---
 arch/sparc/kernel/perf_event.c |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

--- a/arch/sparc/kernel/perf_event.c
+++ b/arch/sparc/kernel/perf_event.c
@@ -1426,8 +1426,6 @@ static void perf_callchain_user_64(struc
 {
        unsigned long ufp;
 
-       perf_callchain_store(entry, regs->tpc);
-
        ufp = regs->u_regs[UREG_I6] + STACK_BIAS;
        do {
                struct sparc_stackf *usf, sf;
@@ -1448,8 +1446,6 @@ static void perf_callchain_user_32(struc
 {
        unsigned long ufp;
 
-       perf_callchain_store(entry, regs->tpc);
-
        ufp = regs->u_regs[UREG_I6] & 0xffffffffUL;
        do {
                struct sparc_stackf32 *usf, sf;
@@ -1468,6 +1464,11 @@ static void perf_callchain_user_32(struc
 void
 perf_callchain_user(struct perf_callchain_entry *entry, struct pt_regs *regs)
 {
+       perf_callchain_store(entry, regs->tpc);
+
+       if (!current->mm)
+               return;
+
        flushw_user();
        if (test_thread_flag(TIF_32BIT))
                perf_callchain_user_32(entry, regs);


Patches currently in stable-queue which might be from [email protected] are

queue-3.6/net-remove-skb-recycling.patch
queue-3.6/infiniband-pass-rdma_cm-module-to-netlink_dump_start.patch
queue-3.6/net-fix-skb_under_panic-oops-in-neigh_resolve_output.patch
queue-3.6/ipv4-fix-sending-of-redirects.patch
queue-3.6/ipvs-fix-arp-resolving-for-direct-routing-mode.patch
queue-3.6/ipv4-add-flowi_flag_known_nh.patch
queue-3.6/netlink-add-reference-of-module-in-netlink_dump_start.patch
queue-3.6/rds-fix-rds-ping-spinlock-recursion.patch
queue-3.6/sparc64-like-x86-we-should-check-current-mm-during-perf-backtrace-generation.patch
queue-3.6/sparc64-fix-ptrace-interaction-with-force_successful_syscall_return.patch
queue-3.6/ipv4-fix-forwarding-for-strict-source-routes.patch
queue-3.6/sparc64-fix-bit-twiddling-in-sparc_pmu_enable_event.patch
queue-3.6/skge-add-dma-mask-quirk-for-marvell-88e8001-on-asus-p5nsli-motherboard.patch
queue-3.6/ipv4-make-sure-nh_pcpu_rth_output-is-always-allocated.patch
queue-3.6/ipv6-gro-should-be-ecn-friendly.patch
queue-3.6/ipv4-always-invalidate-or-update-the-route-on-pmtu-events.patch
queue-3.6/ipv6-addrconf-fix-proc-net-if_inet6.patch
queue-3.6/ipv4-don-t-report-stale-pmtu-values-to-userspace.patch
queue-3.6/ipv4-don-t-create-nh-exeption-when-the-device-mtu-is-smaller-than-the-reported-pmtu.patch
queue-3.6/ipv4-introduce-rt_uses_gateway.patch
queue-3.6/vlan-don-t-deliver-frames-for-unknown-vlans-to-protocols.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to