Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp3427970pxv; Sun, 4 Jul 2021 19:06:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyN/neEZ7MnkNsHwk557lwOdqol0WQp5GhAqJGef04eAYWhFtYQSVb9gw0XOL+qXipUzL6y X-Received: by 2002:a05:6e02:bed:: with SMTP id d13mr8316546ilu.259.1625450802691; Sun, 04 Jul 2021 19:06:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1625450802; cv=none; d=google.com; s=arc-20160816; b=GSjN9riMBiPPQvwN4g6tsv++NYXbuLU7vyp75s+idhSFjf/S1yE3yZzs57vqK1WwCp fU3H0UowWhM9pz/kReaFhgChdMH59CShEB5zHF9wK64/QYoJuHpVQbHbM2q7Hf8UVRB3 e2ybQ+tCyudUSN21ur3rXzoGkBwBjTueDZbsRjzWvqS1He83SKH8Z4RZWcv/svFiBfkd NTTSIwNVHooCV0Z5EijPdWMJ1J9IeJEqfEskVcjBQvv744389ocal3OTFKyc+gJ+VJEL hU2g4iT6zUG5rgax26QGaTIrNpwfE6G1udCAK2KkVJXSSUd6xaljze4QCOkS3PmInm8e sW2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature:dkim-filter; bh=451ugBOIOf/0IdhMd6fN3sH6gq6e2woUEJhYewTR8bc=; b=no95gyds6TaYCbyrGI+zl2OgpoN/SSAZQ9i1Pbowz2q+vFa2MytOnQKTtIN/xV79NB aGPfNbPokUS2yaKxMh5FnSFTpEXozKpL1jBj3UjuOt6lZDWrpg7qhr/hPDA5aHGWicNh 7mxdV0OhKhLzGHbRFSILmDyf+ukcyBCEvHXs1KOj4VI2j6ddl34jEMS4qdRVJdbtSZa9 7TfDwYfsaA1m9R4vZ9e8+hMtEbvVmfEzU+afUAtm8egBWlHskHwoLqbR46VdNA4Bz5/O /w0bv/P9A3+wSJUrpixARgevyzAlPyFSsT5FyFnHRQQVX7e9dXF9ViiJ2hxvHlI+P+GV ViiA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=L7NQs2NB; 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 i26si12075470iol.73.2021.07.04.19.06.31; Sun, 04 Jul 2021 19:06:42 -0700 (PDT) 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=@nifty.com header.s=dec2015msa header.b=L7NQs2NB; 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 S229728AbhGECIh (ORCPT + 99 others); Sun, 4 Jul 2021 22:08:37 -0400 Received: from conssluserg-05.nifty.com ([210.131.2.90]:49705 "EHLO conssluserg-05.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229689AbhGECIg (ORCPT ); Sun, 4 Jul 2021 22:08:36 -0400 Received: from mail-pf1-f170.google.com (mail-pf1-f170.google.com [209.85.210.170]) (authenticated) by conssluserg-05.nifty.com with ESMTP id 16525Vwk011894; Mon, 5 Jul 2021 11:05:31 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-05.nifty.com 16525Vwk011894 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1625450731; bh=451ugBOIOf/0IdhMd6fN3sH6gq6e2woUEJhYewTR8bc=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=L7NQs2NBOwDOkOm1yM/SkUg2FvQPQiA3A140gin/TB0wihJz7bW9m2tMyoGG03qrZ qSLHEYIl2CCl+QGyKaSxhtMyxbiVj+9gCvDX1lqy2kIuDk24vEFSnEo/bo1ydalNS3 bFLQdsL83ZXvMPfDAbur+R1zSPaLbRwH8rto5Kgb8EWN3xzthKd+yhKwbPI//HvENi ZX/XJSdJR2V5AcwfW+HXJOQMTY3Tzt4hPzOlxLpYoNunrFTGFRIbAdOQ6worWkV1Qd vdOwVx6pC2og1V2ca96rnD9cGWrETuFWUHRNBesCT3RrTLDyRl0U/WAwf6wHj7TDAC ccgmWgQfrymHw== X-Nifty-SrcIP: [209.85.210.170] Received: by mail-pf1-f170.google.com with SMTP id y4so15386892pfi.9; Sun, 04 Jul 2021 19:05:31 -0700 (PDT) X-Gm-Message-State: AOAM531+udDyJGPKrJGAJ6z8C3uteMOlD3fxJvkiuZ0+PwY0Dj6SecjS xR2FszKOUWuwpWJmx/cFZ5kFt04LQugcTaLS/N0= X-Received: by 2002:a62:8309:0:b029:312:d19:ac8b with SMTP id h9-20020a6283090000b02903120d19ac8bmr12594417pfe.63.1625450730678; Sun, 04 Jul 2021 19:05:30 -0700 (PDT) MIME-Version: 1.0 References: <20210702032943.7865-1-lecopzer.chen@mediatek.com> <20210702032943.7865-3-lecopzer.chen@mediatek.com> In-Reply-To: <20210702032943.7865-3-lecopzer.chen@mediatek.com> From: Masahiro Yamada Date: Mon, 5 Jul 2021 11:04:54 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v3 2/2] Kbuild: lto: add make version checking To: Lecopzer Chen Cc: Nick Desaulniers , Kees Cook , Sami Tolvanen , Linux Kbuild mailing list , Nathan Chancellor , clang-built-linux , Linux Kernel Mailing List , yj.chiang@mediatek.com, Michal Marek Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 2, 2021 at 12:29 PM Lecopzer Chen wrote: > > LTO with MODVERSIONS will fail in generating correct CRC because > the makefile rule doesn't work for make with version 3.8X.[1] > > Thus we need to check make version during selecting on LTO Kconfig. > and the suitable version should be 4.2(40200) which released in 2016[2]. > > [1] https://lore.kernel.org/lkml/20210616080252.32046-1-lecopzer.chen@mediatek.com/ > [2] https://ftp.gnu.org/gnu/make/ > Signed-off-by: Lecopzer Chen > --- NACK for the same reason as 1/2. We need to write correct code. If we cannot, we need to add 'depends on BROKEN'. > arch/Kconfig | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/Kconfig b/arch/Kconfig > index 129df498a8e1..beee68149da8 100644 > --- a/arch/Kconfig > +++ b/arch/Kconfig > @@ -639,6 +639,7 @@ config HAS_LTO_CLANG > def_bool y > # Clang >= 11: https://github.com/ClangBuiltLinux/linux/issues/510 > depends on CC_IS_CLANG && CLANG_VERSION >= 110000 && LD_IS_LLD && AS_IS_LLVM > + depends on !MODVERSIONS || MAKE_VERSION >= 40200 > depends on $(success,$(NM) --help | head -n 1 | grep -qi llvm) > depends on $(success,$(AR) --help | head -n 1 | grep -qi llvm) > depends on ARCH_SUPPORTS_LTO_CLANG > -- > 2.18.0 > -- Best Regards Masahiro Yamada