From mboxrd@z Thu Jan 1 00:00:00 1970 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=-8.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_2 autolearn=unavailable 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 02101CA9EA0 for ; Fri, 25 Oct 2019 09:32:00 +0000 (UTC) Received: from mother.openwall.net (mother.openwall.net [195.42.179.200]) by mail.kernel.org (Postfix) with SMTP id 4EEFF21D71 for ; Fri, 25 Oct 2019 09:31:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4EEFF21D71 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=goodmis.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kernel-hardening-return-17124-kernel-hardening=archiver.kernel.org@lists.openwall.com Received: (qmail 24171 invoked by uid 550); 25 Oct 2019 09:31:52 -0000 Mailing-List: contact kernel-hardening-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Received: (qmail 21533 invoked from network); 25 Oct 2019 01:43:14 -0000 Date: Thu, 24 Oct 2019 21:42:59 -0400 From: Steven Rostedt To: Masahiro Yamada Cc: Sami Tolvanen , Will Deacon , Catalin Marinas , Masami Hiramatsu , Ard Biesheuvel , Dave Martin , Kees Cook , Laura Abbott , Mark Rutland , Nick Desaulniers , Jann Horn , Miguel Ojeda , clang-built-linux , Kernel Hardening , linux-arm-kernel , Linux Kernel Mailing List Subject: Re: [PATCH v2 16/17] arm64: disable SCS for hypervisor code Message-ID: <20191024214259.1b37535c@gandalf.local.home> In-Reply-To: References: <20191018161033.261971-1-samitolvanen@google.com> <20191024225132.13410-1-samitolvanen@google.com> <20191024225132.13410-17-samitolvanen@google.com> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Fri, 25 Oct 2019 10:29:47 +0900 Masahiro Yamada wrote: > On Fri, Oct 25, 2019 at 7:52 AM wrote: > > > > Signed-off-by: Sami Tolvanen > > --- > > arch/arm64/kvm/hyp/Makefile | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/arch/arm64/kvm/hyp/Makefile b/arch/arm64/kvm/hyp/Makefile > > index ea710f674cb6..8289ea086e5e 100644 > > --- a/arch/arm64/kvm/hyp/Makefile > > +++ b/arch/arm64/kvm/hyp/Makefile > > @@ -28,3 +28,6 @@ GCOV_PROFILE := n > > KASAN_SANITIZE := n > > UBSAN_SANITIZE := n > > KCOV_INSTRUMENT := n > > + > > +ORIG_CFLAGS := $(KBUILD_CFLAGS) > > +KBUILD_CFLAGS = $(subst $(CC_FLAGS_SCS),,$(ORIG_CFLAGS)) > > > $(subst ... ) is not the correct use here. > > It works like sed, s/$(CC_CFLAGS_SCS)// > instead of matching by word. > > > > > KBUILD_CFLAGS := $(filter-out $(CC_FLAGS_SCS), $(KBUILD_CFLAGS)) > > is more correct, and simpler. I guess that would work too. Not sure why I never used it. I see mips used it for their -pg flags. -- Steve