From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755292AbdCPQoU (ORCPT ); Thu, 16 Mar 2017 12:44:20 -0400 Received: from mx1.redhat.com ([209.132.183.28]:40546 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753287AbdCPQoR (ORCPT ); Thu, 16 Mar 2017 12:44:17 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com C38A864D8A Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=jolsa@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com C38A864D8A Date: Thu, 16 Mar 2017 17:44:13 +0100 From: Jiri Olsa To: Arnd Bergmann Cc: Arnaldo Carvalho de Melo , Jiri Olsa , Josh Poimboeuf , gregkh , "kernelci.org bot" , kernel-build-reports@lists.linaro.org, linux-mips@linux-mips.org, Linux Kernel Mailing List , stable@vger.kernel.org, Ralf Baechle , James Hogan , Ingo Molnar , Stephen Rothwell Subject: Re: stable build: 203 builds: 4 failed, 199 passed, 5 errors, 41 warnings (v4.10.1) Message-ID: <20170316164413.GC20999@krava> References: <58b2dc6f.cf4d2e0a.f521.74b3@mx.google.com> <20170315072204.GB26837@kroah.com> <20170316122907.GS12825@kernel.org> <20170316124958.GA3620@krava> <20170316135959.GC3620@krava> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.8.0 (2017-02-23) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Thu, 16 Mar 2017 16:44:18 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 16, 2017 at 03:39:36PM +0100, Arnd Bergmann wrote: > On Thu, Mar 16, 2017 at 2:59 PM, Jiri Olsa wrote: > > On Thu, Mar 16, 2017 at 02:44:45PM +0100, Arnd Bergmann wrote: > >> On Thu, Mar 16, 2017 at 1:49 PM, Jiri Olsa wrote: > >> > On Thu, Mar 16, 2017 at 09:29:07AM -0300, Arnaldo Carvalho de Melo wrote: > >> >> Em Wed, Mar 15, 2017 at 02:15:22PM +0100, Arnd Bergmann escreveu: > >> >> > On Wed, Mar 15, 2017 at 8:22 AM, gregkh wrote: > >> >> > > > >> >> > > All now queued up in the stable trees, thanks. > >> >> > > >> >> > Like 4.9.y it builds clean except for a couple of stack frame size warnings > >> >> > and this one that continues to puzzle me. > >> >> > > >> >> > /bin/sh: 1: /home/buildslave/workspace/kernel-builder/arch/x86/defconfig/allmodconfig+CONFIG_OF=n/label/builder/next/build-x86/tools/objtool//fixdep: > >> >> > Permission denied > >> >> > >> >> Jiri? Josh? > >> > > >> > hum, looks like it imight be related to this fix we did for perf: > >> > abb26210a395 perf tools: Force fixdep compilation at the start of the build > >> > > >> > it's forcing fixdep to be build as first.. having it as a simple dependency > >> > (which AFAICS is objtool case), the make -jX occasionaly raced on high cpu > >> > servers, and executed unfinished binary, hence the permission fail > >> > >> It's probably another variation of this bug, but the commit you cite got merged > >> into 4.10-rc1, while the problem still persists in mainline (4.11-rc2+). > > > > the problem is in objtool build right? the fix was for perf build > > Ah, got it. Yes, that must be it then. I supposed we coul duplicate what you > did for perf in objtool, but a cleaner way would be to generalize it for all of > tools/, right? > > Arnd i came up quickly with attached change.. not too much tested, but basically it's the idea applied to objtool looks like we could generalize some of those pieces, I'll try to look at it next week if nobody beats me to it ;-) thanks, jirka --- diff --git a/tools/lib/subcmd/Makefile b/tools/lib/subcmd/Makefile index 3d1c3b5b5150..a00942fbe43b 100644 --- a/tools/lib/subcmd/Makefile +++ b/tools/lib/subcmd/Makefile @@ -1,6 +1,18 @@ include ../../scripts/Makefile.include include ../../scripts/utilities.mak # QUIET_CLEAN +all: + +config := 1 + +NON_CONFIG_TARGETS := clean + +ifdef MAKECMDGOALS +ifeq ($(filter-out $(NON_CONFIG_TARGETS),$(MAKECMDGOALS)),) + config := 0 +endif +endif + ifeq ($(srctree),) srctree := $(patsubst %/,%,$(dir $(CURDIR))) srctree := $(patsubst %/,%,$(dir $(srctree))) @@ -45,7 +57,24 @@ all: export srctree OUTPUT CC LD CFLAGS V include $(srctree)/tools/build/Makefile.include -all: fixdep $(LIBFILE) +ifdef FIXDEP + force_fixdep := 0 +else + force_fixdep := $(config) +endif + +ifeq ($(force_fixdep),1) +goals := $(filter-out all sub-make, $(MAKECMDGOALS)) + +$(goals) all: sub-make + +sub-make: fixdep + $(Q)$(MAKE) FIXDEP=1 -f Makefile $(goals) + +else # force_fixdep + + +all: $(LIBFILE) $(SUBCMD_IN): FORCE @$(MAKE) $(build)=libsubcmd @@ -59,4 +88,6 @@ clean: FORCE: -.PHONY: clean FORCE +endif # force_fixdep + +.PHONY: clean FORCE sub-make diff --git a/tools/objtool/Makefile b/tools/objtool/Makefile index 27e019c09bd2..8c78a9114ab5 100644 --- a/tools/objtool/Makefile +++ b/tools/objtool/Makefile @@ -1,6 +1,18 @@ include ../scripts/Makefile.include include ../scripts/Makefile.arch +all: + +config := 1 + +NON_CONFIG_TARGETS := clean + +ifdef MAKECMDGOALS +ifeq ($(filter-out $(NON_CONFIG_TARGETS),$(MAKECMDGOALS)),) + config := 0 +endif +endif + ifeq ($(ARCH),x86_64) ARCH := x86 endif @@ -22,8 +34,6 @@ LIBSUBCMD = $(LIBSUBCMD_OUTPUT)libsubcmd.a OBJTOOL := $(OUTPUT)objtool OBJTOOL_IN := $(OBJTOOL)-in.o -all: $(OBJTOOL) - INCLUDES := -I$(srctree)/tools/include -I$(srctree)/tools/arch/$(HOSTARCH)/include/uapi CFLAGS += -Wall -Werror $(EXTRA_WARNINGS) -fomit-frame-pointer -O2 -g $(INCLUDES) LDFLAGS += -lelf $(LIBSUBCMD) @@ -36,7 +46,25 @@ AWK = awk export srctree OUTPUT CFLAGS SRCARCH AWK include $(srctree)/tools/build/Makefile.include -$(OBJTOOL_IN): fixdep FORCE +ifdef FIXDEP + force_fixdep := 0 +else + force_fixdep := $(config) +endif + +ifeq ($(force_fixdep),1) +goals := $(filter-out all sub-make, $(MAKECMDGOALS)) + +$(goals) all: sub-make + +sub-make: fixdep + $(Q)$(MAKE) FIXDEP=1 -f Makefile $(goals) + +else # force_fixdep + +all: $(OBJTOOL) + +$(OBJTOOL_IN): FORCE @$(MAKE) $(build)=objtool # Busybox's diff doesn't have -I, avoid warning in that case @@ -55,7 +83,7 @@ $(OBJTOOL): $(LIBSUBCMD) $(OBJTOOL_IN) $(QUIET_LINK)$(CC) $(OBJTOOL_IN) $(LDFLAGS) -o $@ -$(LIBSUBCMD): fixdep FORCE +$(LIBSUBCMD): FORCE $(Q)$(MAKE) -C $(SUBCMD_SRCDIR) OUTPUT=$(LIBSUBCMD_OUTPUT) clean: @@ -65,4 +93,6 @@ clean: FORCE: -.PHONY: clean FORCE +endif # force_fixdep + +.PHONY: clean FORCE sub-make