From patchwork Tue Mar 1 02:57:27 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Long X-Patchwork-Id: 8461331 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 1BA1EC0553 for ; Tue, 1 Mar 2016 03:07:42 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 3A69B201C7 for ; Tue, 1 Mar 2016 03:07:41 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 552C2201BB for ; Tue, 1 Mar 2016 03:07:40 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1aaada-0001DC-JL; Tue, 01 Mar 2016 03:06:14 +0000 Received: from mail-qk0-x22c.google.com ([2607:f8b0:400d:c09::22c]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1aaaYb-00041F-W6 for linux-arm-kernel@lists.infradead.org; Tue, 01 Mar 2016 03:01:07 +0000 Received: by mail-qk0-x22c.google.com with SMTP id s5so64645700qkd.0 for ; Mon, 29 Feb 2016 19:00:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=/fYZc3jKfnIg/VrkHd0RwdakiR4lbb6j25MvYc0ToqY=; b=Cw5PVKJRgNA0wyPblKOEaHhvmvDGtWBYPoWQjJDH4yK+Qbq/f3HcozcRZSV2/GZ+kT rbHFKikrfyqXWNxjPGGzOaN20+lcqmNiTjmqTgyADbEoSw2r0u/qjer+XL3an9sDidsn 3Ytxt7hz6NMhqXLenkEo2U11y7zPfQQP1eA78= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=/fYZc3jKfnIg/VrkHd0RwdakiR4lbb6j25MvYc0ToqY=; b=Dznbs4q5Ggipz6cibxDozoZKBCB4JE5rwikzULSddJTmGQgRtbipjY+LhEi5BAWRWJ SFGFF9AHs3AiHNMH9nO/A12q9JPWhppvrTrO4ep7MoLEvl5ggoit8fIy8vP/Hn9eSwV0 rakP8GnoP5nzO3rr/WDvLcour1gFI6h8kuWR0ZFcAe2wvzdvpk5ihxRxSr4N8ZCpvrIL 8MKs7EkaMu4WsgQs+I5NyEQ2P+eKsvgl7L8WzR5Jwu8jXuvv/9a5PFxzkGecI0KuoyL6 cRnXUJTn01/WsZj8xsu7+7HHEQY8ExeRKEj9s9CZxVauvzTRR81JT3vG2qKsfdnv6WlG htzA== X-Gm-Message-State: AD7BkJLmQzc6VzioixffuWUJPqCEMhE3qAjzRjEfWdWchE2ccBCYlQtvlZdAz2p0FmFIwLrT X-Received: by 10.55.73.69 with SMTP id w66mr23754398qka.39.1456801246685; Mon, 29 Feb 2016 19:00:46 -0800 (PST) Received: from localhost.localdomain (pool-72-71-243-249.cncdnh.fast00.myfairpoint.net. [72.71.243.249]) by smtp.googlemail.com with ESMTPSA id h5sm12195344qge.48.2016.02.29.19.00.44 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 29 Feb 2016 19:00:46 -0800 (PST) From: David Long To: Catalin Marinas , Will Deacon , Sandeepa Prabhu , William Cohen , Pratyush Anand , Steve Capper , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Marc Zyngier Subject: [PATCH v10 9/9] kprobes: Add arm64 case in kprobe example module Date: Mon, 29 Feb 2016 21:57:27 -0500 Message-Id: <1456801047-29014-10-git-send-email-dave.long@linaro.org> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1456801047-29014-1-git-send-email-dave.long@linaro.org> References: <1456801047-29014-1-git-send-email-dave.long@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160229_190106_289287_533958A6 X-CRM114-Status: GOOD ( 10.95 ) X-Spam-Score: -2.7 (--) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Petr Mladek , Viresh Kumar , John Blackwood , Feng Kan , Zi Shen Lim , Dave P Martin , Yang Shi , Vladimir Murzin , Kees Cook , "Suzuki K. Poulose" , Mark Brown , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ard Biesheuvel , Greg Kroah-Hartman , Mark Salyzyn , James Morse , Christoffer Dall , Andrew Morton , Robin Murphy , Jens Wiklander , Balamurugan Shanmugam MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP 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 727eb21..0c72b8a 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 } /*