Received: by 10.223.185.116 with SMTP id b49csp2267439wrg; Mon, 12 Feb 2018 07:06:23 -0800 (PST) X-Google-Smtp-Source: AH8x227urgva5+/PKUF+3nGqLfhjzygojnbGFTyigHYe0rNu6lvlc0ggd6s7EafP3XmzF5AbzAa5 X-Received: by 10.99.67.66 with SMTP id q63mr9392589pga.175.1518447983677; Mon, 12 Feb 2018 07:06:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518447983; cv=none; d=google.com; s=arc-20160816; b=z7Z4ur7paTMTKEqH3WlWEUf7NekKDYilbyRgCKnDGwYkciKvgTqx+6CeYn3uoF7Ccj 7+m3bV7AKiN6FHgZx0h6jlf6oQjC7WWKSpjA5LrlWj1zCEvbMVxo9xkG6xyVOvTPvPiz ePhpsteQTpSmXShtxnuc0Z0/rhKNreC/tnPhYLGLj1CGDtjbH3kDjNw63pBPDTNruj7A G5RKlFhz5g9lyN8G9i4AFU3cipgWKKjk2PvzroCeTA4rGBl3wDRYohFGqrMkzSpiA90b 0kOLDnpjrrNBFUcofRjWM0iJw6k42pwQLiE4QPT/cZFEYIVjS+NOT1uk/uIfki7fnzc6 OwEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature:dkim-filter :arc-authentication-results; bh=UZn+9ANzjGVd/CrIeVdPlFbK3Szd+f0/1KjuFTKZs8U=; b=hvQflRjcDCgEha4U969+tWe+VmQ5V5R9oYrVX/mwkTKo1gZp0ULU5J//Dr3a5SGesD qKsj70dVvXogBoruSRm07gDGrUHPhOdh9aJtjH4eCSbmOSDg1poVPv3SvJQuEyR9LJbd wmQ9JF2Px7DVTzwbIFXbxohtaBezpvKL66PooS0aAEHY/vBJXbYggDjeIwNmrUS3767F hVav9kOQ67mKBATVTxqPQoj8WDpERUdsdo7xYLw04IkgS0MKPmgsbiquHSvwtMjsZdDf N3WVbSL5qxC4zmICgHZi2Jg7mJJYQHWyOTSfyw67BlZra49J/whNtIVgzzncL1tBW+Gt ektw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=zejV0CpQ; 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 i35-v6si3933475plg.751.2018.02.12.07.06.05; Mon, 12 Feb 2018 07:06:23 -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=pass header.i=@nifty.com header.s=dec2015msa header.b=zejV0CpQ; 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 S1754326AbeBLOtr (ORCPT + 99 others); Mon, 12 Feb 2018 09:49:47 -0500 Received: from conssluserg-05.nifty.com ([210.131.2.90]:18757 "EHLO conssluserg-05.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751623AbeBLOto (ORCPT ); Mon, 12 Feb 2018 09:49:44 -0500 Received: from mail-vk0-f51.google.com (mail-vk0-f51.google.com [209.85.213.51]) (authenticated) by conssluserg-05.nifty.com with ESMTP id w1CEnTJw014046; Mon, 12 Feb 2018 23:49:30 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-05.nifty.com w1CEnTJw014046 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1518446970; bh=UZn+9ANzjGVd/CrIeVdPlFbK3Szd+f0/1KjuFTKZs8U=; h=In-Reply-To:References:From:Date:Subject:To:Cc:From; b=zejV0CpQjPPQ2YZQdc+98V5JDnatwhfF6GUNp1VOYJqP4Fq9L5plrGTqj/3OzB3Iq uaR2gLTz6fD+qmyfYGHVJRdF0slt1Cki2w2JgCA5UfvFz3P0z5q9QtPT/i7y5QrivJ IRg2vVrWMD1cvOGpGPzUX1pP2tFjZ791fkmbIIHUp4gLT63gcIBFYuqX114TLJrnpJ 3sVGylTPPbngL6T3g9YnqDaVq+GUEMuvkRmTS2iOXUta+nEip/S9zkRVP86FED6e+F dk5iUidP7RDHkFsxDJRJovrXtSmciG4pNwTZFpInhKqh8Nl5steHOAVzLvxCkclqvK hPhfibxMiMuAw== X-Nifty-SrcIP: [209.85.213.51] Received: by mail-vk0-f51.google.com with SMTP id o17so1626288vke.7; Mon, 12 Feb 2018 06:49:30 -0800 (PST) X-Gm-Message-State: APf1xPCgEhCl8WeWZmXmJXAtbl3AA7LRJ/Wt0Wrn+mkFrKKouNggshDa +KRPpAU39TiM40CKJJwbLD3qYroKf044eaOpzZM= X-Received: by 10.31.130.194 with SMTP id e185mr1790530vkd.34.1518446969268; Mon, 12 Feb 2018 06:49:29 -0800 (PST) MIME-Version: 1.0 Received: by 10.176.83.212 with HTTP; Mon, 12 Feb 2018 06:48:48 -0800 (PST) In-Reply-To: References: From: Masahiro Yamada Date: Mon, 12 Feb 2018 23:48:48 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: why scripts/link-vmlinux.sh has a final build of init/ To: Cao jin Cc: Michal Marek , Linux Kbuild mailing list , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 2018-02-12 13:22 GMT+09:00 Cao jin : > Hi Masahiro-san, > > As I remember, init/ is already built during recursive make, and I did > a clean build(make mrproper, make localmodconfig) with all plugins > included on x86_64 with following patch, the kernel can boot without any > obvious problem. So, I don't figure out why we need this final build? > > > diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh > index e6818b8e7141..086b2efd4d53 100755 > --- a/scripts/link-vmlinux.sh > +++ b/scripts/link-vmlinux.sh > @@ -247,9 +247,6 @@ else > expr 0$(cat .old_version) + 1 >.version; > fi; > > -# final build of init/ > -${MAKE} -f "${srctree}/scripts/Makefile.build" obj=init > GCC_PLUGINS_CFLAGS="${GCC_PLUGINS_CFLAGS}" > - > archive_builtin > > #link vmlinux.o > link-vmlinux.sh increments '.version' so it must descend into init/ to update include/generated/compile.h and re-compile init/version.o We do not increment '.version' at the first descend into init/ because we never know whether the kernel is updated or not before the final link stage. -- Best Regards Masahiro Yamada