From patchwork Tue Feb 17 23:11:41 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Long X-Patchwork-Id: 44756 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f198.google.com (mail-lb0-f198.google.com [209.85.217.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 2D5F321557 for ; Tue, 17 Feb 2015 23:12:05 +0000 (UTC) Received: by lbiw7 with SMTP id w7sf5152141lbi.0 for ; Tue, 17 Feb 2015 15:12:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=QPuP7FEzwxlXi3R4uMm4/M4/85EcoP8OoNN+mQd5pQI=; b=AoESm1TEayaJtKlECjuIbc3/ZLxHtU1k74tZTWfdAJd5Xk1/VHMMq7AFZX+qeMMwC0 EDwQt+uXknULMkQCUwbZ1OHH+Xr95aYWYAm/dAxT92xbVJia8uJ93Ykpw9+2dHGLrdG8 V0BCiaCjaNvYji8zqZ0H/tmhHISIF6vuCMYB9Ex4mw3FXRDsaW6qJjy27AsbKOaerQf+ V5WxzR7WEEwhf0+foM463JDHu1Imj0IT+3jL3u2bE4DEKZQjIXCejZnDDrVpY8qX5wdq P4NhAbegL78QBnIzTzNb5B7XxjGZiaufo9wCd8ZXNFA3dsiemDQXwA2kSRF0IJFrqeaC /vWw== X-Gm-Message-State: ALoCoQmbQDntVuUnt/9Fn5Q0aEWi4+jtdcBRwEUtvWEmavH+VprtSsgy1nm85gPFIfSwmWlY6XyZ X-Received: by 10.112.174.36 with SMTP id bp4mr3835040lbc.15.1424214724199; Tue, 17 Feb 2015 15:12:04 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.8.167 with SMTP id s7ls728713laa.80.gmail; Tue, 17 Feb 2015 15:12:04 -0800 (PST) X-Received: by 10.152.43.193 with SMTP id y1mr31680264lal.35.1424214724064; Tue, 17 Feb 2015 15:12:04 -0800 (PST) Received: from mail-la0-f46.google.com (mail-la0-f46.google.com. [209.85.215.46]) by mx.google.com with ESMTPS id ru4si11190535lbb.178.2015.02.17.15.12.04 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 Feb 2015 15:12:04 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) client-ip=209.85.215.46; Received: by labpn19 with SMTP id pn19so38869853lab.4 for ; Tue, 17 Feb 2015 15:12:04 -0800 (PST) X-Received: by 10.152.8.33 with SMTP id o1mr31797058laa.56.1424214723989; Tue, 17 Feb 2015 15:12:03 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.112.35.133 with SMTP id h5csp2502458lbj; Tue, 17 Feb 2015 15:12:03 -0800 (PST) X-Received: by 10.140.36.239 with SMTP id p102mr746397qgp.8.1424214711390; Tue, 17 Feb 2015 15:11:51 -0800 (PST) Received: from mail-qa0-f43.google.com (mail-qa0-f43.google.com. [209.85.216.43]) by mx.google.com with ESMTPS id bt3si19436793qcb.47.2015.02.17.15.11.50 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 Feb 2015 15:11:51 -0800 (PST) Received-SPF: pass (google.com: domain of dave.long@linaro.org designates 209.85.216.43 as permitted sender) client-ip=209.85.216.43; Received: by mail-qa0-f43.google.com with SMTP id bm13so28577069qab.2 for ; Tue, 17 Feb 2015 15:11:50 -0800 (PST) X-Received: by 10.140.88.80 with SMTP id s74mr649345qgd.28.1424214710782; Tue, 17 Feb 2015 15:11:50 -0800 (PST) Received: from localhost.localdomain (pool-72-71-243-249.cncdnh.fast00.myfairpoint.net. [72.71.243.249]) by mx.google.com with ESMTPSA id e2sm4320004qaf.47.2015.02.17.15.11.49 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 17 Feb 2015 15:11:50 -0800 (PST) From: David Long To: linux-arm-kernel@lists.infradead.org, Russell King Cc: Sandeepa Prabhu , William Cohen , Steve Capper , Catalin Marinas , Will Deacon , "Jon Medhurst (Tixy)" , Masami Hiramatsu , Ananth N Mavinakayanahalli , Anil S Keshavamurthy , , linux-kernel@vger.kernel.org Subject: [PATCH v5 6/6] kprobes: Add arm64 case in kprobe example module Date: Tue, 17 Feb 2015 18:11:41 -0500 Message-Id: <1424214701-4899-7-git-send-email-dave.long@linaro.org> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: <1424214701-4899-1-git-send-email-dave.long@linaro.org> References: <1424214701-4899-1-git-send-email-dave.long@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: dave.long@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Sandeepa Prabhu Add info prints in sample kprobe handlers for ARM64 Signed-off-by: Sandeepa Prabhu --- samples/kprobes/kprobe_example.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/samples/kprobes/kprobe_example.c b/samples/kprobes/kprobe_example.c index 366db1a..51d459c 100644 --- a/samples/kprobes/kprobe_example.c +++ b/samples/kprobes/kprobe_example.c @@ -42,6 +42,10 @@ static int handler_pre(struct kprobe *p, struct pt_regs *regs) " ex1 = 0x%lx\n", p->addr, regs->pc, regs->ex1); #endif +#ifdef CONFIG_ARM64 + pr_info("pre_handler: p->addr = 0x%p, pc = 0x%lx\n", + p->addr, (long)regs->pc); +#endif /* A dump_stack() here will give a stack backtrace */ return 0; @@ -67,6 +71,10 @@ static void handler_post(struct kprobe *p, struct pt_regs *regs, printk(KERN_INFO "post_handler: p->addr = 0x%p, ex1 = 0x%lx\n", p->addr, regs->ex1); #endif +#ifdef CONFIG_ARM64 + pr_info("post_handler: p->addr = 0x%p, pc = 0x%lx\n", + p->addr, (long)regs->pc); +#endif } /*