Message ID | 20230118-kbuild-alignment-v1-1-eb5e9fd55c92@weissschuh.net |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp2127609wrn; Tue, 17 Jan 2023 19:53:32 -0800 (PST) X-Google-Smtp-Source: AMrXdXt+0PEkgippmEMyuicyhwzGg/ARWMqCTFX4Dit1wVnleAkOQ3BWq5lL21fuqwstkE1dW7nN X-Received: by 2002:a17:903:2014:b0:194:a7b2:4329 with SMTP id s20-20020a170903201400b00194a7b24329mr4260281pla.28.1674014011978; Tue, 17 Jan 2023 19:53:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1674014011; cv=none; d=google.com; s=arc-20160816; b=Rr7i9mrf8dyTnLeqCWG9Sh4///qHFcA/VhRT6AF2+NbrSEnyeZpjXgnVNxXW/l81Wp ZYjHqtiYHz2FTDZjGrEwj+LvePMbCGkD4UPgv09vRJyqsBsdzCMOZCsffOxzo2vrKLuO mQEbnQW6dXzdIqs9kbcswSzFCpS0kk3SpUWZ7yHYDSdX4SmSxTbZ6A8bg6JOpQFpFhDf D/voogAxi2CycbjkM7O/Lb/ScuKTVUPje11TRnaI49BzC9U0UvUnZlZ4mQgIxt+CF2X1 qi4qLYvZo3l/l/9rljbw3B9cA1pzH+OiBjKNiVTXlImSokdYt2emMxK7WiywCQh+LhKO nWSA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:dkim-signature :from; bh=DfKCJVfrJ0XczitVxj9z6Ra1b70nI1LmEcJRyzlsHIA=; b=gaujcsxVZTyUcwwKG+uIDkm9Udid+XKMFNlLJVOFkRcNHsRf6DjpCO1fU3sL0wyxPq oQnsAonQhRhDjWev2RaLUexF4QvXU+Nt6JWXDPBjXOK1BZ7eg/PtXmLGFNxra2mXkkOb epBM21qUnHry+JBDtKHCoCendcjQRTDWiveJs4l71rW8TmkUBClwZnA/TF2dZvHKc7qh 5psvsVvXcybpD8xPJGTUIeMUwPHvik8v51CtsPsNmoYIp+bg6PXsu72CGUUESezflXH0 GTP32zNeiJmRE/xArst5eRnF9MOGly58WxrtX6HBJ32IWqZVhocEag4NOfUmi7lm/XK4 TSmQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@weissschuh.net header.s=mail header.b="aumQF/Tc"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k11-20020a170902ba8b00b00194974e28a9si7227902pls.518.2023.01.17.19.53.19; Tue, 17 Jan 2023 19:53:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@weissschuh.net header.s=mail header.b="aumQF/Tc"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229684AbjARDw7 (ORCPT <rfc822;pfffrao@gmail.com> + 99 others); Tue, 17 Jan 2023 22:52:59 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34492 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229483AbjARDw4 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 17 Jan 2023 22:52:56 -0500 Received: from todd.t-8ch.de (todd.t-8ch.de [159.69.126.157]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3655353B11; Tue, 17 Jan 2023 19:52:54 -0800 (PST) From: Thomas =?utf-8?q?Wei=C3=9Fschuh?= <linux@weissschuh.net> DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=weissschuh.net; s=mail; t=1674013973; bh=LeJ7gI3yR8MhBw3LdfOaYZv4aNx3sO+fd4js1DkSvTk=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=aumQF/TcOjSY7DpoHL3bnZxTpOw/p54FeLWG97HAHPjnEQg+txWdK/gPtO0W6i45g ttGko7iGFV+IRqIv/PWxgpsZFqZQVDNc4k2SWr8vmNOvUmmXwOINTXMuRB6Uib9wS+ +vs31as6Dd2UkdP8QgBGnOGSI94HSa1ddvleySLE= Date: Wed, 18 Jan 2023 03:52:18 +0000 Subject: [PATCH 1/3] selftests/bpf: align kbuild messages to standard MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Message-Id: <20230118-kbuild-alignment-v1-1-eb5e9fd55c92@weissschuh.net> References: <20230118-kbuild-alignment-v1-0-eb5e9fd55c92@weissschuh.net> In-Reply-To: <20230118-kbuild-alignment-v1-0-eb5e9fd55c92@weissschuh.net> To: Alexei Starovoitov <ast@kernel.org>, Daniel Borkmann <daniel@iogearbox.net>, Andrii Nakryiko <andrii@kernel.org>, Martin KaFai Lau <martin.lau@linux.dev>, Song Liu <song@kernel.org>, Yonghong Song <yhs@fb.com>, John Fastabend <john.fastabend@gmail.com>, KP Singh <kpsingh@kernel.org>, Stanislav Fomichev <sdf@google.com>, Hao Luo <haoluo@google.com>, Jiri Olsa <jolsa@kernel.org>, Mykola Lysenko <mykolal@fb.com>, Shuah Khan <shuah@kernel.org>, Masahiro Yamada <masahiroy@kernel.org> Cc: bpf@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, Thomas =?utf-8?q?Wei=C3=9Fschuh?= <linux@weissschuh.net> X-Mailer: b4 0.11.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1674013966; l=1017; i=linux@weissschuh.net; s=20221212; h=from:subject:message-id; bh=LeJ7gI3yR8MhBw3LdfOaYZv4aNx3sO+fd4js1DkSvTk=; b=tBkx8uRJ5OT383z4h0Cc9/q/mtXjwWDwrQNqqqE2xzO28njGH8YjaQGfK9uXkZWjeYduZGVCJKh+ gjzRUk+FDKlW2QIxzV1YJHjlJpynKpzqgtgWZbeHfRXVfDgDKrQT X-Developer-Key: i=linux@weissschuh.net; a=ed25519; pk=KcycQgFPX2wGR5azS7RhpBqedglOZVgRPfdFSPB1LNw= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1755330916645946140?= X-GMAIL-MSGID: =?utf-8?q?1755330916645946140?= |
Series |
align custom kbuild messages to standard layout
|
|
Commit Message
Thomas Weißschuh
Jan. 18, 2023, 3:52 a.m. UTC
The common layout for kbuild messages is as follows:
- 2 spaces
- 7 or more characters for the action
- 1 space
- name of the file being built/generated
The custom message formatting included an additional space in the action
part, which leads to misalignments with the rest of kbuild.
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
---
tools/testing/selftests/bpf/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
On 1/17/23 7:52 PM, Thomas Weißschuh wrote: > The common layout for kbuild messages is as follows: > > - 2 spaces > - 7 or more characters for the action > - 1 space > - name of the file being built/generated > > The custom message formatting included an additional space in the action > part, which leads to misalignments with the rest of kbuild. Could you give an example to show the output before/after the patch, and how it leads to mis-alignment and why it is a problem? > > Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> > --- > tools/testing/selftests/bpf/Makefile | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tools/testing/selftests/bpf/Makefile b/tools/testing/selftests/bpf/Makefile > index c22c43bbee19..5190c19295d4 100644 > --- a/tools/testing/selftests/bpf/Makefile > +++ b/tools/testing/selftests/bpf/Makefile > @@ -98,7 +98,7 @@ Q = > msg = > else > Q = @ > -msg = @printf ' %-8s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; > +msg = @printf ' %-7s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; > MAKEFLAGS += --no-print-directory > submake_extras := feature_display=0 > endif >
On Tue, Jan 17, 2023 at 09:02:20PM -0800, Yonghong Song wrote: > > > On 1/17/23 7:52 PM, Thomas Weißschuh wrote: > > The common layout for kbuild messages is as follows: > > > > - 2 spaces > > - 7 or more characters for the action > > - 1 space > > - name of the file being built/generated > > > > The custom message formatting included an additional space in the action > > part, which leads to misalignments with the rest of kbuild. > > Could you give an example to show the output before/after the patch, and > how it leads to mis-alignment and why it is a problem? Before: LD .../linux/tools/bpf/resolve_btfids/resolve_btfids-in.o LINK resolve_btfids CHK kernel/kheaders_data.tar.xz After: LD .../linux/tools/bpf/resolve_btfids/resolve_btfids-in.o LINK resolve_btfids CHK kernel/kheaders_data.tar.xz The line starting with "LINK" has the filename "resolve_btfids" one space character more to the right than the other lines. It's slightly confusing when scanning the build logs. > > Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> > > --- > > tools/testing/selftests/bpf/Makefile | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/tools/testing/selftests/bpf/Makefile b/tools/testing/selftests/bpf/Makefile > > index c22c43bbee19..5190c19295d4 100644 > > --- a/tools/testing/selftests/bpf/Makefile > > +++ b/tools/testing/selftests/bpf/Makefile > > @@ -98,7 +98,7 @@ Q = > > msg = > > else > > Q = @ > > -msg = @printf ' %-8s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; > > +msg = @printf ' %-7s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; > > MAKEFLAGS += --no-print-directory > > submake_extras := feature_display=0 > > endif > >
On 1/17/23 9:15 PM, Thomas Weißschuh wrote: > On Tue, Jan 17, 2023 at 09:02:20PM -0800, Yonghong Song wrote: >> >> >> On 1/17/23 7:52 PM, Thomas Weißschuh wrote: >>> The common layout for kbuild messages is as follows: >>> >>> - 2 spaces >>> - 7 or more characters for the action >>> - 1 space >>> - name of the file being built/generated >>> >>> The custom message formatting included an additional space in the action >>> part, which leads to misalignments with the rest of kbuild. >> >> Could you give an example to show the output before/after the patch, and >> how it leads to mis-alignment and why it is a problem? > > Before: > > LD .../linux/tools/bpf/resolve_btfids/resolve_btfids-in.o > LINK resolve_btfids > CHK kernel/kheaders_data.tar.xz > > After: > > LD .../linux/tools/bpf/resolve_btfids/resolve_btfids-in.o > LINK resolve_btfids > CHK kernel/kheaders_data.tar.xz > > The line starting with "LINK" has the filename "resolve_btfids" one > space character more to the right than the other lines. Thanks! I would be great if you can put the details about (1) what are the command line to reproduce the issue, and (2) what the output differences, to the commit message in all three patches. > > It's slightly confusing when scanning the build logs. > >>> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> >>> --- >>> tools/testing/selftests/bpf/Makefile | 2 +- >>> 1 file changed, 1 insertion(+), 1 deletion(-) >>> >>> diff --git a/tools/testing/selftests/bpf/Makefile b/tools/testing/selftests/bpf/Makefile >>> index c22c43bbee19..5190c19295d4 100644 >>> --- a/tools/testing/selftests/bpf/Makefile >>> +++ b/tools/testing/selftests/bpf/Makefile >>> @@ -98,7 +98,7 @@ Q = >>> msg = >>> else >>> Q = @ >>> -msg = @printf ' %-8s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; >>> +msg = @printf ' %-7s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; >>> MAKEFLAGS += --no-print-directory >>> submake_extras := feature_display=0 >>> endif >>>
diff --git a/tools/testing/selftests/bpf/Makefile b/tools/testing/selftests/bpf/Makefile index c22c43bbee19..5190c19295d4 100644 --- a/tools/testing/selftests/bpf/Makefile +++ b/tools/testing/selftests/bpf/Makefile @@ -98,7 +98,7 @@ Q = msg = else Q = @ -msg = @printf ' %-8s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; +msg = @printf ' %-7s%s %s%s\n' "$(1)" "$(if $(2), [$(2)])" "$(notdir $(3))" "$(if $(4), $(4))"; MAKEFLAGS += --no-print-directory submake_extras := feature_display=0 endif