Received: by 2002:ac0:a591:0:0:0:0:0 with SMTP id m17-v6csp823543imm; Thu, 5 Jul 2018 09:28:03 -0700 (PDT) X-Google-Smtp-Source: AAOMgpe5eaEGcD2m7B86BeBHcldEMJlHTtpKsn7a1Zq28ObXR9CD8o81+DUYIw1RtYPaLlIVE7y6 X-Received: by 2002:a17:902:42c3:: with SMTP id h61-v6mr6855611pld.319.1530808083332; Thu, 05 Jul 2018 09:28:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530808083; cv=none; d=google.com; s=arc-20160816; b=eTw2EFwQZi0qdoebap0jMEfs0u+T22ozdlYpXaC+YfQHsn1MRyGcsksSuJMEC3c155 ZyzKkeKFzvBraIHopbpw6rGH09BBDF5XVqH2S65W5eTLj+JVcCU+2wIChgJXyejzTLmk UtuSEtgnHe1hExIKE1Vfhhjc1cZ37Rl8yJTI6T581xMDfXCy1inCjUqdk/rVCAmCrJ+5 pKmhfUG0WcqLRhrD0Qp9VLVe4tu6YvQu1HxWTw+oiHNCwoSDoouSjAaZZCz5+ohM2+Iy L+sxFMXhlAy5gp788f4qWiynXVUtQ9CNMkiS6j4Vvenv3xZyWcPBpUzilNHBlTT5NXUO auOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:cc:to:subject:from:references :in-reply-to:message-id:arc-authentication-results; bh=1apC4OCqgnHJX7Z73aPY8xGrZqfBscjWfreTdpylAnU=; b=dBzFsl7TzCFsvego+vYt4Xj0lVlKKZucu76EUDfR1yDHRE0s7sk8nnjIVzX4BIY4jB Plo8rrY4qOqV79jRfERZzi/LH7G/O6S6qB4o/gcDDufXIxfDZTBnSb7NDKhQXJUREdpB lDRxgG68K3JZVznBtpfYgRdW9b1ElG/xDstEzlcRLljLUNSUOsAHYM1z7jc1Lp63DimR jaTBKzm+n8bRXSGg3BXwLTZHy6HsmAg2RQ/IAwUIWEQNNwVXK3PvhoxYrDQ+gCaBTIty F1iqBoysFSFnzwOTYX34wKSr1M+GwzqcjUy1vgo4SLbs7AA1/zXTf97MU8bDPQDjsetA GaGA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v3-v6si5783234pgr.44.2018.07.05.09.27.38; Thu, 05 Jul 2018 09:28:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754440AbeGEQ02 (ORCPT + 99 others); Thu, 5 Jul 2018 12:26:28 -0400 Received: from pegase1.c-s.fr ([93.17.236.30]:4409 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753982AbeGEQZh (ORCPT ); Thu, 5 Jul 2018 12:25:37 -0400 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 41M39W6qnPz9ttmc; Thu, 5 Jul 2018 18:25:03 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at c-s.fr Received: from pegase1.c-s.fr ([192.168.12.234]) by localhost (pegase1.c-s.fr [192.168.12.234]) (amavisd-new, port 10024) with ESMTP id zy3HnuvlWcsv; Thu, 5 Jul 2018 18:25:03 +0200 (CEST) Received: from messagerie.si.c-s.fr (messagerie.si.c-s.fr [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id 41M39W6N3Zz9ttm7; Thu, 5 Jul 2018 18:25:03 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id B3C7C8B8CF; Thu, 5 Jul 2018 18:25:05 +0200 (CEST) X-Virus-Scanned: amavisd-new at c-s.fr Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id xroyHCPOAe3P; Thu, 5 Jul 2018 18:25:05 +0200 (CEST) Received: from po14934vm.idsi0.si.c-s.fr (po15451.idsi0.si.c-s.fr [172.25.231.4]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 9CC338B8BC; Thu, 5 Jul 2018 18:25:05 +0200 (CEST) Received: by po14934vm.idsi0.si.c-s.fr (Postfix, from userid 0) id 82168711E2; Thu, 5 Jul 2018 16:25:05 +0000 (UTC) Message-Id: <918a4533548b1f2b5ffc16c05cac1c6b0a808142.1530807556.git.christophe.leroy@c-s.fr> In-Reply-To: References: From: Christophe Leroy Subject: [PATCH v3 08/16] powerpc: declare set_breakpoint() static To: Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org Date: Thu, 5 Jul 2018 16:25:05 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org set_breakpoint() is only used in process.c so make it static Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/debug.h | 1 - arch/powerpc/kernel/process.c | 14 +++++++------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/arch/powerpc/include/asm/debug.h b/arch/powerpc/include/asm/debug.h index ce5da214ffe5..7756026b95ca 100644 --- a/arch/powerpc/include/asm/debug.h +++ b/arch/powerpc/include/asm/debug.h @@ -45,7 +45,6 @@ static inline int debugger_break_match(struct pt_regs *regs) { return 0; } static inline int debugger_fault_handler(struct pt_regs *regs) { return 0; } #endif -void set_breakpoint(struct arch_hw_breakpoint *brk); void __set_breakpoint(struct arch_hw_breakpoint *brk); bool ppc_breakpoint_available(void); #ifdef CONFIG_PPC_ADV_DEBUG_REGS diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process.c index 9ef4aea9fffe..6061efb369e8 100644 --- a/arch/powerpc/kernel/process.c +++ b/arch/powerpc/kernel/process.c @@ -716,6 +716,13 @@ void switch_booke_debug_regs(struct debug_reg *new_debug) EXPORT_SYMBOL_GPL(switch_booke_debug_regs); #else /* !CONFIG_PPC_ADV_DEBUG_REGS */ #ifndef CONFIG_HAVE_HW_BREAKPOINT +static void set_breakpoint(struct arch_hw_breakpoint *brk) +{ + preempt_disable(); + __set_breakpoint(brk); + preempt_enable(); +} + static void set_debug_reg_defaults(struct thread_struct *thread) { thread->hw_brk.address = 0; @@ -828,13 +835,6 @@ void __set_breakpoint(struct arch_hw_breakpoint *brk) WARN_ON_ONCE(1); } -void set_breakpoint(struct arch_hw_breakpoint *brk) -{ - preempt_disable(); - __set_breakpoint(brk); - preempt_enable(); -} - /* Check if we have DAWR or DABR hardware */ bool ppc_breakpoint_available(void) { -- 2.13.3