Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp2881687ybv; Mon, 24 Feb 2020 13:34:42 -0800 (PST) X-Google-Smtp-Source: APXvYqw9wqGWgXCPf+Wn8bA83tZnPCILBHj0q9NcNYwWkTiWD9lU1IrIJYBHpFJVQvu7UUoGtiiv X-Received: by 2002:aca:4ece:: with SMTP id c197mr884562oib.53.1582580082061; Mon, 24 Feb 2020 13:34:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582580082; cv=none; d=google.com; s=arc-20160816; b=YPZeFU4XIldUsWI69UNnfuSGErCAFdb+axuSP7HtQ7oox/e2WAMF43LTiaM1uZtEaL 422tuhcvQOwGF5rK5D+CN8QbFfuFX8Pt4FZPqmso1X1kZ+Q3Dld7vodAa8yY+9UNSTvq H4MiZ5upOY1+EaKzHT9QU5lvIiqxjXBhPBMZO6aQ+kOCaDtc39ncwmbf1tG5imwzmERw nfiU6m+k8PMTpwGaf1VIy/sqfXGcGexdScazuhn8vgodVLMd53gN4eh98xFmYkJyE3sO Id5ksb42QwvMZKv99/T/EDfn3qZoYSpgTTT/5TgH/gF4WSdXSCfl/oiE8m/Io/h5vDnR A6gg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:date:from:dkim-signature; bh=jRWoeoOM8DL9OmT3+yYVal9mOTve0BZlMU96rBIIFe0=; b=Fd9X8rd9ypu5iGHEdQQzjhFH900WghCUWPGWNHdabGcfdyvhZeigFRNRvmfIlEd8XV g7915Z3jJhQ4hTUqf4KJ76CiG2A83al8Zl2TQhQHOIKETR1LwZ0bErAFFmBscNrnd2TN sWc9iN4x54R5hflNP2Wx9bR88ZO+nmtpgg8LdJeLnr3xleHyVEIoPth2ghbATxeok99s c4ZU73nmmrZlMePW/ePYx0Va+LJdHt9Yf0Mt5fmNHG68KubT1ywERjVNFNwIfpnUO1s4 Z2bZeouDdKuiQkFEcSgF6xNyrb816VTbSMqo12XhY80g2CESW2Q0XMRwZZjA8OQxC7BV dH4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=E9YB0nYW; 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 v21si1470259otp.189.2020.02.24.13.34.30; Mon, 24 Feb 2020 13:34:41 -0800 (PST) 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; dkim=fail header.i=@gmail.com header.s=20161025 header.b=E9YB0nYW; 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 S1727716AbgBXVdW (ORCPT + 99 others); Mon, 24 Feb 2020 16:33:22 -0500 Received: from mail-qk1-f194.google.com ([209.85.222.194]:39525 "EHLO mail-qk1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726980AbgBXVdW (ORCPT ); Mon, 24 Feb 2020 16:33:22 -0500 Received: by mail-qk1-f194.google.com with SMTP id e16so7256213qkl.6 for ; Mon, 24 Feb 2020 13:33:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:date:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=jRWoeoOM8DL9OmT3+yYVal9mOTve0BZlMU96rBIIFe0=; b=E9YB0nYWyyqpbnhocJZ8cG/fU3LFV5rYqfrQVQ6ggzZbU09l2ZOa+8zYB9o5rcQykY KkX+C5jQspLPr+su1sQHvmXtf8cebQcqN/URtvzxylUvBst7P49jC7Ka+QWawUifzD7O KJ+46Cfra+s7sfRvYu3LZ6bW62hG64FoVYV5l5iIGbAcf/QUkBSAz8DY2ABk3wsuKlNZ jqffs0SivE29ITfqb6DjFe9XecxTiK7kwIZzYr6Bd4rBpyPkbCKntST5NbJyIsmk3z5X WlGFxI8T/pl5ROuE4ftxTNgkIxFTJM8TyWCUlMScCiDGabeQBEMd46kn4Y8AzFwNtEj9 zLog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:date:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=jRWoeoOM8DL9OmT3+yYVal9mOTve0BZlMU96rBIIFe0=; b=paOISClX27NWDwR9xSNOucEzsA4bVmc9CaIRD3fTRvkv3rQr6AnNL5H/s58Gjnonks coVSVMuySL3Hy9kjIRgshVEkSKFdawomfM0nk9DFjys14L5dKUJhNtW23I6+804rgyM0 j+iJNkxSjrk1Mrf7aLvlpbY3oehRSS0jmQRMLv0enmuxgFsV/LF2RnQ8rxY+01kZN8Tk NlbNR7WJEOhv+kJNxSbxvfYdcWnc2gnspQ4Qu6jKxZQihtIDK89/HdawUmgsNg57/1Oz jx/lNOoXg9GY5EV8i8JL2ZL7Cs/kJ36IQSAjsd5s7BKkThJABKROaQQ4uOjCu15pjzhg f4zg== X-Gm-Message-State: APjAAAWKBSMIZRA0q9osQ9VPmbFCp9O3DzYLpT1qwCa1QqgMFNOsGTP/ 3E4wGvNEmrL/KsPZQKyJTE0= X-Received: by 2002:a05:620a:2224:: with SMTP id n4mr4141190qkh.21.1582580001588; Mon, 24 Feb 2020 13:33:21 -0800 (PST) Received: from rani.riverdale.lan ([2001:470:1f07:5f3::b55f]) by smtp.gmail.com with ESMTPSA id 132sm6409229qkn.109.2020.02.24.13.33.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 24 Feb 2020 13:33:21 -0800 (PST) From: Arvind Sankar X-Google-Original-From: Arvind Sankar Date: Mon, 24 Feb 2020 16:33:19 -0500 To: Nick Desaulniers Cc: Arvind Sankar , Borislav Petkov , Nathan Chancellor , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , LKML , clang-built-linux , Michael Matz , Fangrui Song , Kees Cook , Andy Lutomirski Subject: Re: [PATCH 2/2] arch/x86: Drop unneeded linker script discard of .eh_frame Message-ID: <20200224213319.GB409112@rani.riverdale.lan> References: <20200222235709.GA3786197@rani.riverdale.lan> <20200223193715.83729-3-nivedita@alum.mit.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Feb 24, 2020 at 12:45:51PM -0800, Nick Desaulniers wrote: > > grepping for eh_frame in arch/x86/ there's a comment in > arch/x86/include/asm/dwarf2.h: > 40 #ifndef BUILD_VDSO > 41 /* > 42 * Emit CFI data in .debug_frame sections, not .eh_frame > sections. > 43 * The latter we currently just discard since we don't do DWARF > 44 * unwinding at runtime. So only the offline DWARF information is > 45 * useful to anyone. Note we should not use this directive if > 46 * vmlinux.lds.S gets changed so it doesn't discard .eh_frame. > 47 */ > 48 .cfi_sections .debug_frame > > add via: > commit 7b956f035a9ef ("x86/asm: Re-add parts of the manual CFI infrastructure") > > https://sourceware.org/binutils/docs/as/CFI-directives.html#g_t_002ecfi_005fsections-section_005flist > is the manual's section on .cfi_sections directives, and states `The > default if this directive is not used is .cfi_sections .eh_frame.`. > So the comment is slightly stale since we're no longer explicitly > discarding .eh_frame in arch/x86/kernel/vmlinux.lds.S, rather > preventing the generation via -fno-asynchronous-unwind-tables in > KBUILD_CFLAGS (across a few different Makefiles). Would you mind also > updating the comment in arch/x86/include/asm/dwarf2.h in a V2? The > rest of this patch LGTM. > i.e. just replace that last sentence with "Note ... if we decide to use runtime DWARF unwinding again"? The whole ifdef-ery machinery there is obsolete, all the directives its checking support for have been there since binutils-2.18, so should probably also clean it up to just unconditionally define them.