Received: by 2002:ac2:464d:0:0:0:0:0 with SMTP id s13csp3300413lfo; Mon, 23 May 2022 01:05:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyifQvyO/fLXlhPpXdAbzu3AEQXYxa+eoeaO26rFjOOrerz70wpwcdIFhFAn2LA3ZztseWm X-Received: by 2002:a17:902:ebc8:b0:15f:3f5d:9d08 with SMTP id p8-20020a170902ebc800b0015f3f5d9d08mr21549534plg.121.1653293149324; Mon, 23 May 2022 01:05:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653293149; cv=none; d=google.com; s=arc-20160816; b=xQ5zYf8Xw8tHyFLlTof92dsXNGYlTFZIPM79Ie6vrwIoxryj/AfkXzcGNjvvW4OohD NEiCXSUZ9NaAw9kfks2DtJ6PeKafqB4xje+Xkv+BcS0SEwkO85LKvtbipOA8UZTvQi6I 1KXCBxxrwunym8xrfPgvzvDXVNxqLC9Bt7cw22yxB5yWlK5dQVdvkTzVECRDi277Umwg IJQ+G1Px9mOpjCMcHiz67tGHdCXrKPa3MOhctMxggMwxJhsnJvXZyRjiBKBxEq3a+lDL 9aCKveTKGK1AYgFfdz8jLna/TjsDFeX17WaYvUVva1WPe7eVG7sk+mIgNGaakcmeUvnK BMkg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=2vbo8dVhOWsS3T/T45k7TXjX4PO3epNeie4gRP2qiWc=; b=gpzeR2El2roaOIMwSuIu4rEIDmINSoHNWAzS63twu2ZftGWvPc4DhHGKcA7MTLdTnr hJixFcLGtEYiEdn1ngdrtYujyWKKYWESOzuSOFqJzmgTKiA/sx5H7RaLxT+iRaX5jVKt zVFfAnplBG18ES9F8anQSaCLsBTqFrPa0vK7exNjjyS87+2wQzyIAEaquXbbX/90Tc9i U4Av3zjeh+Fwiqh/5fU1Ro8fkStAh6OgNFjXS3yLT0hipR42w5r53HGBcXYkeIPFu4lA 7wHWd/StqkZnkKA8vlziWhAhyh0sj2MAfYr5VapUq+qAr0tYJv4274wAJ1s0Qq+nMqwh beCw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@canb.auug.org.au header.s=201702 header.b=mQIUg7Sd; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id e17-20020a170902e0d100b001567b004ecdsi7733381pla.551.2022.05.23.01.05.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 May 2022 01:05:49 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@canb.auug.org.au header.s=201702 header.b=mQIUg7Sd; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E352085EE6; Mon, 23 May 2022 00:10:14 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231586AbiEWFsc (ORCPT + 99 others); Mon, 23 May 2022 01:48:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59318 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229849AbiEWFsG (ORCPT ); Mon, 23 May 2022 01:48:06 -0400 Received: from gandalf.ozlabs.org (gandalf.ozlabs.org [150.107.74.76]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5ED8524F37; Sun, 22 May 2022 22:48:02 -0700 (PDT) Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 4L65vz57zfz4xYY; Mon, 23 May 2022 15:47:59 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canb.auug.org.au; s=201702; t=1653284880; bh=2vbo8dVhOWsS3T/T45k7TXjX4PO3epNeie4gRP2qiWc=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=mQIUg7SdDCPN09lVSVL82p7NyxA0OQaQPm5Fm/QDCfblXjoW4L3zhs9xMxFZeYwiq Kko4kGOFwLCn+61kC64ZNxjOuXnnT+ZP9WFElyHZyiqSvjrJgDCDf5DlK233p/gb7Y JCJAspwhfAG5j/or8+l8TisvAwXnHf5xJMHK4GcnlLQQ6RWKEZZSsVlcF+rZ6sPDqV IDhH41SFm6liaovTXQyitYWHgWFi7OfOdNIcvYC2nuo0+FO7ZnbZWJCVOyCk/r5hjG 9NV/qZ7lKdTMPU7u7doN9jX04vFpnTnksfETKCyoX3Wmbg8Tt1x7eRKMpIhteBarKw NZmumd989cmlw== Date: Mon, 23 May 2022 15:47:58 +1000 From: Stephen Rothwell To: Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Peter Zijlstra Cc: Josh Poimboeuf , Linux Kernel Mailing List , Linux Next Mailing List , Masahiro Yamada Subject: Re: linux-next: manual merge of the tip tree with the kbuild tree Message-ID: <20220523154758.11668628@canb.auug.org.au> In-Reply-To: <20220523142431.10ff2f77@canb.auug.org.au> References: <20220523142431.10ff2f77@canb.auug.org.au> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/r=uakva=tlJuhr8mplG/2nv"; protocol="application/pgp-signature"; micalg=pgp-sha256 X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --Sig_/r=uakva=tlJuhr8mplG/2nv Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Hi all, On Mon, 23 May 2022 14:24:31 +1000 Stephen Rothwell = wrote: > > Today's linux-next merge of the tip tree got a conflict in: >=20 > scripts/Makefile.build >=20 > between commit: >=20 > 0212301af7bb ("kbuild: do not create *.prelink.o for Clang LTO or IBT") >=20 > from the kbuild tree and commit: >=20 > 753da4179d08 ("objtool: Remove --lto and --vmlinux in favor of --link") >=20 > from the tip tree. >=20 > I am not sure if I fixed this up correctly, please check the final result > when linux-next is released. >=20 > I fixed it up (I used the former version) and can carry the fix as > necessary. This is now fixed as far as linux-next is concerned, but any > non trivial conflicts should be mentioned to your upstream maintainer > when your tree is submitted for merging. You may also want to consider > cooperating with the maintainer of the conflicting tree to minimise any > particularly complex conflicts. That produced may warnings :-( so I tried the below resolution instead. --=20 Cheers, Stephen Rothwell 70023a983b831421d2bac71f46b94bce024a147b diff --cc scripts/Makefile.build index 48712bfc8740,f89d3fcff39f..cbe9b45e7b7d --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@@ -226,18 -244,23 +230,19 @@@ objtool_args =3D =09 cmd_objtool =3D $(if $(objtool-enabled), ; $(objtool) $(objtool_args) $@) cmd_gen_objtooldep =3D $(if $(objtool-enabled), { echo ; echo '$@: $$(wil= dcard $(objtool))' ; } >> $(dot-target).cmd) =20 - endif # CONFIG_STACK_VALIDATION + endif # CONFIG_OBJTOOL =20 -ifneq ($(CONFIG_LTO_CLANG)$(CONFIG_X86_KERNEL_IBT),) - -# Skip objtool for LLVM bitcode -$(obj)/%.o: objtool-enabled :=3D - -else =20 # 'OBJECT_FILES_NON_STANDARD :=3D y': skip objtool checking for a directo= ry # 'OBJECT_FILES_NON_STANDARD_foo.o :=3D 'y': skip objtool checking for a = file # 'OBJECT_FILES_NON_STANDARD_foo.o :=3D 'n': override directory skip for = a file =20 -$(obj)/%.o: objtool-enabled =3D $(if $(filter-out y%, \ - $(OBJECT_FILES_NON_STANDARD_$(basetarget).o)$(OBJECT_FILES_NON_STANDARD)= n),y) +is-standard-object =3D $(if $(filter-out y%, $(OBJECT_FILES_NON_STANDARD_= $(basetarget).o)$(OBJECT_FILES_NON_STANDARD)n),y) =20 -endif +delay-objtool :=3D $(or $(CONFIG_LTO_CLANG),$(CONFIG_X86_KERNEL_IBT)) + +$(obj)/%.o: objtool-enabled =3D $(if $(is-standard-object),$(if $(delay-o= bjtool),$(is-single-obj-m),y)) ++$(obj)/%.o: linked-object :=3D y =20 ifdef CONFIG_TRIM_UNUSED_KSYMS cmd_gen_ksymdeps =3D \ @@@ -404,24 -464,32 +409,25 @@@ $(obj)/modules.order: $(obj-m) FORC # # Rule to compile a set of .o files into one .a file (with symbol table) # -quiet_cmd_ar_lib =3D AR $@ - cmd_ar_lib =3D $(cmd_update_lto_symversions); $(cmd_ar) =20 $(obj)/lib.a: $(lib-y) FORCE - $(call if_changed,ar_lib) - -# NOTE: -# Do not replace $(filter %.o,^) with $(real-prereqs). When a single obje= ct -# module is turned into a multi object module, $^ will contain header file -# dependencies recorded in the .*.cmd file. -ifneq ($(CONFIG_LTO_CLANG)$(CONFIG_X86_KERNEL_IBT),) -quiet_cmd_link_multi-m =3D AR [M] $@ -cmd_link_multi-m =3D \ - $(cmd_update_lto_symversions); \ - rm -f $@; \ - $(AR) cDPrsT $@ $(filter %.o,$^) -else -quiet_cmd_link_multi-m =3D LD [M] $@ - cmd_link_multi-m =3D $(LD) $(ld_flags) -r -o $@ $(filter %.o,$^) -endif + $(call if_changed,ar) + +quiet_cmd_ld_multi_m =3D LD [M] $@ + cmd_ld_multi_m =3D $(LD) $(ld_flags) -r -o $@ @$(patsubst %.o,%.mod= ,$@) $(cmd_objtool) + +define rule_ld_multi_m + $(call cmd_and_savecmd,ld_multi_m) + $(call cmd,gen_objtooldep) +endef =20 -$(multi-obj-m): FORCE - $(call if_changed,link_multi-m) +$(multi-obj-m): objtool-enabled :=3D $(delay-objtool) +$(multi-obj-m): part-of-module :=3D y ++$(multi-obj-m): linked-object :=3D y +$(multi-obj-m): %.o: %.mod FORCE + $(call if_changed_rule,ld_multi_m) $(call multi_depend, $(multi-obj-m), .o, -objs -y -m) =20 -targets +=3D $(multi-obj-m) targets :=3D $(filter-out $(PHONY), $(targets)) =20 # Add intermediate targets: --Sig_/r=uakva=tlJuhr8mplG/2nv Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEENIC96giZ81tWdLgKAVBC80lX0GwFAmKLIA4ACgkQAVBC80lX 0GzgFAf/YsLs4lF4Wy0WQ0L4S1SiJAJ2ZwZkORz6oOL5r+9Dme7ov8fGamHFFD/e O5VCjluO06DURxrQKHRtGkinP+NmjyEIX/1NFlVbR924AhEOZGocs302R+63Tfcy cbEAjIKY8FVGnZ/kcUr7pC4PqQqW/LgHW/wdKI1RljDlGjWISt9Tj7enhjpQMQnc fngP5s0VT3M1CPZwVQt5DeSyer0+mrK/E39orSepVxcgKwiy/eANJMQF+0NgPajN tu9B2+yULakxnV0tRTCYKnloMXz0KdGBYwVLdyaU8RCfYDjQSDtZQGy81TChhSB/ oiu4Rf0uawimFK+bgJRSui6Mc6jYJw== =dfAm -----END PGP SIGNATURE----- --Sig_/r=uakva=tlJuhr8mplG/2nv--