Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp335569imm; Mon, 1 Oct 2018 10:39:32 -0700 (PDT) X-Google-Smtp-Source: ACcGV62aj0kiPSQ4qWPeh9IfW4ZXuddVnE7x1VwubxOAxJtM8PsBSf4Hs27jkY6G5K4Nvv7d2/gE X-Received: by 2002:a17:902:7109:: with SMTP id a9-v6mr13063667pll.310.1538415572018; Mon, 01 Oct 2018 10:39:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538415571; cv=none; d=google.com; s=arc-20160816; b=m++nBW+G3Uk4KwoyrnGNmsbhc72cziebJlRb3hQvD3A0C0Wr6MZur8V28Bs7e1pvQn KFPfDVKKvCqRqz3GqGxYsdbdMfmioCxlfnsxPzugownzFc+Lexc9aEc+uKAfttr2dI8p dIj/6I0A3zBtpJmjScmSZhy5qSiVUMa5eVwjgd5YXmR6Gbfo1S1FUDdBzkcwq9cFel+F GF2vAlzXbTuZWA1CiGaCD85ZLWgXWCwu7+RA1e/5xLTm//X3hFjMImaa2YGgMMGmsb4h +h9zCrI5IouiEHLuMpPIkBpw5/QhQftFmrPUwu2QVkBvtO2+XoQwX6wAM3e5z3uo8iun uy8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=sVA52Gzz4K5WA5fVLvOBJSW4cjvGRJMrcyF3Lz56p1A=; b=spplLlpnH1HNE1GiRZyHGSlZEaiH6+73AZH259w9MiuhaHcWjPsl5H3rMvXSWlpGYq C9JFPHR6nJ4C1qDY46hbWVPXvzJu+DiEBTo72h61zIzYcFz7cpFytz04DnigZdfsSp30 08h/bED9mbBSukP8SnycMkJTZSabga4pSnnR44A3Uf0dK6u05duhcGqWOBuKKhQBg+yi DWH8Wb/Z+rPf8/w1hTRkwP0Xqxq/MZI5TNcqcNT5o3y+dp0rnbm1ya0V0xW49R73wYt5 pfOoKtXpT0/iAEUBMW93Ny3vNH+FA3a6NsWnxiu1bY+hAhQw8XOks3D0Gz6rAItRW0Q6 4uRw== 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 k12-v6si12930802plt.115.2018.10.01.10.39.16; Mon, 01 Oct 2018 10:39:31 -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 S1726317AbeJBARy (ORCPT + 99 others); Mon, 1 Oct 2018 20:17:54 -0400 Received: from terminus.zytor.com ([198.137.202.136]:43141 "EHLO mail.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725740AbeJBARy (ORCPT ); Mon, 1 Oct 2018 20:17:54 -0400 Received: from hanvin-mobl2.amr.corp.intel.com (jfdmzpr03-ext.jf.intel.com [134.134.139.72]) (authenticated bits=0) by mail.zytor.com (8.15.2/8.15.2) with ESMTPSA id w91HccaW1651456 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO); Mon, 1 Oct 2018 10:38:39 -0700 Subject: Re: [PATCH v2] x86/boot: define CC_HAVE_ASM_GOTO To: ndesaulniers@google.com, bp@alien8.de, mingo@redhat.com, tglx@linutronix.de Cc: x86@kernel.org, "Kirill A. Shutemov" , Masahiro Yamada , Greg Kroah-Hartman , Matthias Kaehlcke , Kees Cook , Cao jin , linux-kernel@vger.kernel.org References: <20180927204800.32210-1-ndesaulniers@google.com> From: "H. Peter Anvin" Message-ID: Date: Mon, 1 Oct 2018 10:38:33 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20180927204800.32210-1-ndesaulniers@google.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/27/18 13:47, ndesaulniers@google.com wrote: > Early prototypes of Clang with asm goto support produce 6 instances of > the following warning: > > In file included from arch/x86/boot/compressed/misc.h:20: > In file included from ./include/linux/elf.h:5: > In file included from ./arch/x86/include/asm/elf.h:8: > In file included from ./include/linux/thread_info.h:38: > In file included from ./arch/x86/include/asm/thread_info.h:53: > ./arch/x86/include/asm/cpufeature.h:150:2: warning: "Compiler lacks > ASM_GOTO support. Add -D __BPF_TRACING__ to your compiler arguments" > [-W#warnings] > your compiler arguments" > ^ > > Since 6 files under arch/x86/boot/compressed/ include > arch/x86/boot/compressed/misc.h AND > arch/x86/boot/compressed/Makefile happens to redefine KBUILD_CFLAGS, > which set these variables in the top level MAKEFILE. > The Right Thing[TM] would probably be to split the CFLAGS into those that are independent of x86_64 vs i386. After all, there is no fundamental reason we couldn't want to use asm goto in the setup or real-mode code in the future. In addition to BIOS entry code there is the EFI32 code. -hpa