Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1353710pxu; Thu, 17 Dec 2020 08:06:41 -0800 (PST) X-Google-Smtp-Source: ABdhPJxJX3AqrHS1Qzh85KN0UAY9Jdw0YM/9fu9xf192LfjYa34Anti/AMFeLQZw0f6MEz5RE2tq X-Received: by 2002:a17:906:608:: with SMTP id s8mr16068180ejb.371.1608221201042; Thu, 17 Dec 2020 08:06:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608221201; cv=none; d=google.com; s=arc-20160816; b=jqZ5/wdEeEuKn0s9eSh/pX6IWJvFGdT35bWCFPJduIUlsoZ0DYBE/olb1IPt6jU+Dr sak5HWIz8LSYlIjBufwampP+q+KALAaVf8e8kXv8PtfWZKOKCbOMXmUcjTYtJ9U+P2yT IONVXMHOr1zPY8vx0MX43g7dKBDcLM8Gv1yQwaYL8283npPdHRNBQm02UUmaY0yxY+no j17h/s2fNIaEIlXsK+wHv2vX1swoqRW19VSmYFiFVEhL/X0URkx9h1jCEhW6lSDmeBrv s2AoewDFqbDMJHBA0RreP42jI8s/h5S7QMCzmXOk9X/68oHtejGb/WN0HU0LOtR5nGIe ARCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from; bh=3wFLUw+KX/jNx+W0dWk3K9SqjkbrSYkbLzsEb0lVUDg=; b=ftw1LijTRTOrqPvpe8wwqvKMKkvNYpfan6iI8I60X3rOqJbUhkZFqCva5Qb3gh/uYV iffbbpV3SIf5bT8/ZlZnarzhoqdlnGtd0GONAknQ8HbkXspuoa9kmR++4Hv86N8UcxnA qjp1Ztk7TGHmJ6jYI0ki8bJpKYf6AwPgNMk8ynSITJwRFmPQ7wMKwesNJv8oCR6N2ee6 xFcrr+0NZr2uVFep7ukG/ngcNmrtTz7cd21wok0IiRgkDDyJcfw0bOUbZCJeFm/G3aOf a65+yzHuJ92NCENxrR8SDby6Ia5TE11kl4adkmT5uKsm1+nkXnQl/PbCWF1GV9eK5RZz /O0A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i11si4627494edu.256.2020.12.17.08.06.18; Thu, 17 Dec 2020 08:06:41 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729053AbgLQQEc (ORCPT + 99 others); Thu, 17 Dec 2020 11:04:32 -0500 Received: from mail.kernel.org ([198.145.29.99]:53040 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729037AbgLQQEc (ORCPT ); Thu, 17 Dec 2020 11:04:32 -0500 From: guoren@kernel.org Authentication-Results: mail.kernel.org; dkim=permerror (bad message/signature format) To: palmerdabbelt@google.com, paul.walmsley@sifive.com, mhiramat@kernel.org, alankao@andestech.com, rostedt@goodmis.org, bjorn.topel@intel.com, pdp7pdp7@gmail.com Cc: linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, anup@brainfault.org, linux-csky@vger.kernel.org, greentime.hu@sifive.com, zong.li@sifive.com, guoren@kernel.org, me@packi.ch, Guo Ren Subject: [PATCH v5 3/9] riscv: Fixup wrong ftrace remove cflag Date: Thu, 17 Dec 2020 16:01:39 +0000 Message-Id: <1608220905-1962-4-git-send-email-guoren@kernel.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1608220905-1962-1-git-send-email-guoren@kernel.org> References: <1608220905-1962-1-git-send-email-guoren@kernel.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Guo Ren We must use $(CC_FLAGS_FTRACE) instead of directly using -pg. It will cause -fpatchable-function-entry error. Signed-off-by: Guo Ren --- arch/riscv/kernel/Makefile | 4 ++-- arch/riscv/mm/Makefile | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/riscv/kernel/Makefile b/arch/riscv/kernel/Makefile index fa896c5..27f10eb 100644 --- a/arch/riscv/kernel/Makefile +++ b/arch/riscv/kernel/Makefile @@ -4,8 +4,8 @@ # ifdef CONFIG_FTRACE -CFLAGS_REMOVE_ftrace.o = -pg -CFLAGS_REMOVE_patch.o = -pg +CFLAGS_REMOVE_ftrace.o = $(CC_FLAGS_FTRACE) +CFLAGS_REMOVE_patch.o = $(CC_FLAGS_FTRACE) endif extra-y += head.o diff --git a/arch/riscv/mm/Makefile b/arch/riscv/mm/Makefile index c0185e5..6b4b7ec 100644 --- a/arch/riscv/mm/Makefile +++ b/arch/riscv/mm/Makefile @@ -2,7 +2,7 @@ CFLAGS_init.o := -mcmodel=medany ifdef CONFIG_FTRACE -CFLAGS_REMOVE_init.o = -pg +CFLAGS_REMOVE_init.o = $(CC_FLAGS_FTRACE) endif KCOV_INSTRUMENT_init.o := n -- 2.7.4