Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp381253pxu; Tue, 1 Dec 2020 13:42:20 -0800 (PST) X-Google-Smtp-Source: ABdhPJx01AZDenQxH275jtKiSjqmPZSw1o5k5FSa2/bTqLFruZ433aLC5jy6kQshKGXlI1tieSJJ X-Received: by 2002:a17:906:ae0c:: with SMTP id le12mr2167484ejb.283.1606858939903; Tue, 01 Dec 2020 13:42:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606858939; cv=none; d=google.com; s=arc-20160816; b=yppD2pUJkcHwIqOG6sCku+CF7VcrkgWL98Vo7T1+uT3MzjtKMdCBpLAKaws5LK38NS oPXoyMY2xjYngMfojbQJU00DeKg9/bWnKVixIhw0WQvvwtFty9txr0eYfOdijxdDU6G8 Pq77DF1tlA+2ZnuT4wsuOWikVHQYeNJ5ZOXbdZJdW9fb1tNYeDy/qbvBGflq4HQaMRgk bgr1eCumwZ1ous0wGj3LWZI49gawssgbKJOqQqrmJymxMwEvzDfQsZy/1ATAoPWOrNNw /SartJCWHfPPXAzkJ3Rnjk2/7QhNddRe7A4d1JSdfwPzeKMCcTuEPvBQUhU20a9g3MdM ncHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:subject:references:mime-version :message-id:in-reply-to:date:sender:dkim-signature; bh=sUICI29mkgxH8XDf6qhMCrhn46+Hzc1owynREvsajYA=; b=mvclhF5XRpSC75twRpFYxYxMDbAf4L9OKQkQDejC4PFApWQvKjftKZVkg5gpD4Xas+ 5KQYmVu5gVk8fc9nNqw+KQthdpE1nFLR2VmUU6TuvcGCnoVIOIwm648ON0SefN4IuEtq LO9pu3OYFB4qpbp6jnpQprpNPfnq9MsasKgZkM7gRH13f+BpRKhS5F+4S0D14XP7bN2W IE0pZ86XuyQuIRUPjisNjpF6dhxbreaXS2K73rsaVzRSYnWC6carAorT8AArE0gP2wUx mFw7nQi0Y5gYbWpzR2ejlcWInIhQLpU3NYI9xKDugZbEPZB/Lw74+QhZq4w0hN/0eQTm zz2A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b="oZ+MM9v/"; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u20si735947edr.287.2020.12.01.13.41.57; Tue, 01 Dec 2020 13:42:19 -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; dkim=pass header.i=@google.com header.s=20161025 header.b="oZ+MM9v/"; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389763AbgLAVjY (ORCPT + 99 others); Tue, 1 Dec 2020 16:39:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56336 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389600AbgLAVjW (ORCPT ); Tue, 1 Dec 2020 16:39:22 -0500 Received: from mail-yb1-xb4a.google.com (mail-yb1-xb4a.google.com [IPv6:2607:f8b0:4864:20::b4a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8CC5AC094255 for ; Tue, 1 Dec 2020 13:37:38 -0800 (PST) Received: by mail-yb1-xb4a.google.com with SMTP id k196so4028441ybf.9 for ; Tue, 01 Dec 2020 13:37:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=sender:date:in-reply-to:message-id:mime-version:references:subject :from:to:cc; bh=sUICI29mkgxH8XDf6qhMCrhn46+Hzc1owynREvsajYA=; b=oZ+MM9v/NqF/Ggik7eWdIKvvWz1hAClVJ55m2ya/8pnBTT4o/65pegfy91/nHJxuWW ng2vF4fEe4Kj1Wfo4enCljLrXc2mZuGKhe/N5E7LtdgFcAC58htdoc+UkHFNsGz4aAO6 TYAhpoNLG2sGulec3iEXV0wmrbA+e+YsFU8sNFgOxk4nqaFp778EB7curP1ohGdIJjsj jH7zCxSQUvDQVtB7+IQqbxbFDnA6gYb/Jb2c4ZAC83nAvZnZSoqo2Wh/6Eso5Pv41c0O eamKVAZq1cPjmGaxAjBPryDgnplTnhHhjw0xN8W2cnY2EG+4MSMt3K5GchHtvIv5V7pm oWsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=sUICI29mkgxH8XDf6qhMCrhn46+Hzc1owynREvsajYA=; b=WOFHhpS1VNzaYtF7aa9rOpBzSCB+585XxFYTSZhHXOZEA/517ymQv47xuoahCS6pmQ 3gRzKwNGZOSnFv9u3oPo3fViUb5mtu9H3xfqwOKyfEEFuimSKHm8ZOtQsWTY9WoIucTs 3pF27RN+dL6i+hVf0TM2l13Nae1+LXvd33XTI+qj2mFfc2Ld0X7MTmcoGQ3XgvJlrEcL zBfWJYzYO0+VfvbJ9wO79zysZPWxjOWxm1jAvaXp3KgePP+D2vh7CWzMUGo0Ci8dKXjm sZQjBGSl6DixwklO1myGiAL0lwpuMAyjnW5GQbCaXyO+r/d182dzTE9yxeyMPFXRUXOw 5qXw== X-Gm-Message-State: AOAM533isf12zPkJvZi5H5eqJxf74S+SrfPwxFUsuF7qILi5JPMIUlRc 3+O4Zt1C3glzHOed1eq/am8TZNrwIjQbDRvSiO4= Sender: "samitolvanen via sendgmr" X-Received: from samitolvanen1.mtv.corp.google.com ([2620:15c:201:2:f693:9fff:fef4:1b6d]) (user=samitolvanen job=sendgmr) by 2002:a25:38c1:: with SMTP id f184mr5273120yba.41.1606858657749; Tue, 01 Dec 2020 13:37:37 -0800 (PST) Date: Tue, 1 Dec 2020 13:37:02 -0800 In-Reply-To: <20201201213707.541432-1-samitolvanen@google.com> Message-Id: <20201201213707.541432-12-samitolvanen@google.com> Mime-Version: 1.0 References: <20201201213707.541432-1-samitolvanen@google.com> X-Mailer: git-send-email 2.29.2.576.ga3fc446d84-goog Subject: [PATCH v8 11/16] scripts/mod: disable LTO for empty.c From: Sami Tolvanen To: Masahiro Yamada , Steven Rostedt , Will Deacon Cc: Josh Poimboeuf , Peter Zijlstra , Greg Kroah-Hartman , "Paul E. McKenney" , Kees Cook , Nick Desaulniers , clang-built-linux@googlegroups.com, kernel-hardening@lists.openwall.com, linux-arch@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, Sami Tolvanen Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org With CONFIG_LTO_CLANG, clang generates LLVM IR instead of ELF object files. As empty.o is used for probing target properties, disable LTO for it to produce an object file instead. Signed-off-by: Sami Tolvanen Reviewed-by: Kees Cook --- scripts/mod/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/mod/Makefile b/scripts/mod/Makefile index 78071681d924..c9e38ad937fd 100644 --- a/scripts/mod/Makefile +++ b/scripts/mod/Makefile @@ -1,5 +1,6 @@ # SPDX-License-Identifier: GPL-2.0 OBJECT_FILES_NON_STANDARD := y +CFLAGS_REMOVE_empty.o += $(CC_FLAGS_LTO) hostprogs-always-y += modpost mk_elfconfig always-y += empty.o -- 2.29.2.576.ga3fc446d84-goog