From patchwork Thu Jul 29 14:07:20 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Masami Hiramatsu (Google)" X-Patchwork-Id: 12408849 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 57DE9C4320E for ; Thu, 29 Jul 2021 14:09:39 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 45C2360EBD for ; Thu, 29 Jul 2021 14:09:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238535AbhG2OJk (ORCPT ); Thu, 29 Jul 2021 10:09:40 -0400 Received: from mail.kernel.org ([198.145.29.99]:57024 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238652AbhG2OHd (ORCPT ); Thu, 29 Jul 2021 10:07:33 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id A296860FE7; Thu, 29 Jul 2021 14:07:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1627567644; bh=KEe5WdEyJHtzuPMGzpiocUmfrX3xOnunn5dZvpKwBh8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=g7kMJSyTGhPNbxT3kA9PC39kYiBS/Ye1esT/cbIh/ApuGw7tznQMZMnoFdFL5dhk6 +5XDLAHAsLvnD76/etbLGieR/gJugg8L5gEgaK19GRFgpPkxUUfGy/SXYtdJxsrQdr bklQ8qkWUPdkP/FXdD4jo+CZXf1XUJjcklF107Ztpg67dBQJKPI8jaLbQNYtnnh9U+ 8dogW8Ums8slKEq2Fs024T7lmI9zvFZMF1mHXrZyob4Zys3fIyOCUxCzKJk5j9gg43 r8rYHXe+PXw4lmtesr9UtaK/nWyrEkQWMSSRFLs7Vyp9O+O4nNTHlCSyCWGdfCqAbz juOIKbMdeGkjQ== From: Masami Hiramatsu To: Steven Rostedt , Josh Poimboeuf , Ingo Molnar Cc: X86 ML , Masami Hiramatsu , Daniel Xu , linux-kernel@vger.kernel.org, bpf@vger.kernel.org, kuba@kernel.org, mingo@redhat.com, ast@kernel.org, Thomas Gleixner , Borislav Petkov , Peter Zijlstra , kernel-team@fb.com, yhs@fb.com, linux-ia64@vger.kernel.org, Abhishek Sagar , Andrii Nakryiko Subject: [PATCH -tip v10 09/16] ARC: Add instruction_pointer_set() API Date: Thu, 29 Jul 2021 23:07:20 +0900 Message-Id: <162756764030.301564.8584321072467173508.stgit@devnote2> X-Mailer: git-send-email 2.25.1 In-Reply-To: <162756755600.301564.4957591913842010341.stgit@devnote2> References: <162756755600.301564.4957591913842010341.stgit@devnote2> User-Agent: StGit/0.19 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: bpf@vger.kernel.org Add instruction_pointer_set() API for arc. Signed-off-by: Masami Hiramatsu --- arch/arc/include/asm/ptrace.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/arc/include/asm/ptrace.h b/arch/arc/include/asm/ptrace.h index 4c3c9be5bd16..cca8d6583e31 100644 --- a/arch/arc/include/asm/ptrace.h +++ b/arch/arc/include/asm/ptrace.h @@ -149,6 +149,11 @@ static inline long regs_return_value(struct pt_regs *regs) return (long)regs->r0; } +static inline void instruction_pointer_set(struct pt_regs *regs, + unsigned long val) +{ + instruction_pointer(regs) = val; +} #endif /* !__ASSEMBLY__ */ #endif /* __ASM_PTRACE_H */