From patchwork Wed Mar 15 13:54:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Masami Hiramatsu (Google)" X-Patchwork-Id: 70255 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp2365951wrd; Wed, 15 Mar 2023 07:36:24 -0700 (PDT) X-Google-Smtp-Source: AK7set+q5lt1FnZC04gv2yuJahQXrPs1FU9dvip06UWyn/Hr/lVTEjVWefDU1R2HSsRrgwj8sSPb X-Received: by 2002:a05:6a20:1e4d:b0:bc:a257:5b2a with SMTP id cy13-20020a056a201e4d00b000bca2575b2amr11177pzb.31.1678890983846; Wed, 15 Mar 2023 07:36:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1678890983; cv=none; d=google.com; s=arc-20160816; b=JdmKJEaOLfNTN3BJOaFGPuhOByyb38giSSfdVgTvjPKrcA86ZBB6ne/qQNfHBWzkSQ NGIKtndiZbJMR6F+Dy+96oQJEf10pqQ8/nAPIe8VwMaASv14ejE9i4nxpq7qKH6Mg0hi i774RXhg5gMrSILBmPrpp2XstzNqIXJKS586f/bTXohrzYcTai0Z2u+G7lyPa+uZ/xPy G4N0qjupZp4PEkCgOev8isclIfqnVMnCskUxRndsNId43ThwUEQo2nYTszwh7tsV70Nx 40u2KD/jm0rI+RtzBK3g9B6wkUCts0NYy2EAwzHyoP1lzfFyom3BCDQKkcfD37CGx2tO Ph9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:message-id:date:subject:cc:to:from:dkim-signature; bh=ZL6W+c0VcJOTR5HqQGSQ02QVmQT7UKDWGA/QiiULz/M=; b=dn32IxFgrnDNnlvGdu1K0HwmyGTM+sQnIcC4jFpFf5jvc61M9V4e8a3M+Fjil1DJo8 tJ//UPkivtBINY147kyo4hXYehiiHz65PBaJMPHBv2GBQ7IXAp4peqs2/vyV7Aejp/Am iKoV+LLtvJT6HNoMRs0fOmW+L9RyZob4gVCo4trdj+aPtOkC2nRMWRM+h2/GzN7NFf8h 9GiKqd38NxgfYWpDxsr8xBbgrvT5GhyEBeV9NIMJpe2ECPx7Fk0Dz5EGpDTiod7VkwZK j298b3KZ3X40RIs74lMD3fij3db51P0rzsn+kahK1xqamu7DSni8NIeX3RmjVqI9EdEE 6UmQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=kOqVUhOr; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k5-20020a63ff05000000b005097eda2632si4931067pgi.740.2023.03.15.07.36.11; Wed, 15 Mar 2023 07:36:23 -0700 (PDT) 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=pass header.i=@kernel.org header.s=k20201202 header.b=kOqVUhOr; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232518AbjCONyW (ORCPT + 99 others); Wed, 15 Mar 2023 09:54:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52076 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232628AbjCONyQ (ORCPT ); Wed, 15 Mar 2023 09:54:16 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3BEC615164; Wed, 15 Mar 2023 06:54:14 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C6B4961D5F; Wed, 15 Mar 2023 13:54:13 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id CABAEC433EF; Wed, 15 Mar 2023 13:54:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1678888453; bh=MeUXDq1IdFKnPC0Emxz8eivaGaiRcMqUYA0SAkpvH7M=; h=From:To:Cc:Subject:Date:From; b=kOqVUhOrBsS97XPXEH4mPaXOnze6wk6DENj5/ciEAbQqRH43FTcfX25SKJ1lVt9nE AvepeV56Se7O/Z1Yhq0tG6FVTzYhqrLC50gddTLerWCxOHsFLTmUJy+zU5gS0FBlpo QFjF8PCngkxGMN5grwRPfiFLmBOthskskDJb1UisHOGl/nSXClKcQNhI6ano0AGHOE KncDHxhRgX+HcghinIfdHFLxifvsdPLnCPBKJMgxvkDvcRR6n6ZpgH9DOCE1S8S3pX pc0P+2wmBB7kFSvT7PRWazkmLYwFC0jN/z4F0HfA3QXN/hHc+xsoWPWEDnyX2AIQEy AF5jUAKa8d/3Q== From: "Masami Hiramatsu (Google)" To: linux-trace-kernel@vger.kernel.org Cc: Heinz Wiesinger , andersson@kernel.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, mhiramat@kernel.org, quic_rjendra@quicinc.com, quic_saipraka@quicinc.com, quic_sibis@quicinc.com Subject: [PATCH v2] bootconfig: Fix testcase to increase max node Date: Wed, 15 Mar 2023 22:54:08 +0900 Message-Id: <167888844790.791176.670805252426835131.stgit@devnote2> X-Mailer: git-send-email 2.25.1 User-Agent: StGit/0.19 MIME-Version: 1.0 X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1760261545131761204?= X-GMAIL-MSGID: =?utf-8?q?1760444792287923226?= From: Masami Hiramatsu (Google) Since commit 6c40624930c5 ("bootconfig: Increase max nodes of bootconfig from 1024 to 8192 for DCC support") increased the max number of bootconfig node to 8192, the bootconfig testcase of the max number of nodes fails. To fix this issue, we can not simply increase the number in the test script because the test bootconfig file becomes too big (>32KB). To fix that, we can use a combination of three alphabets (26^3 = 17576). But with that, we can not express the 8193 (just one exceed from the limitation) because it also exceeds the max size of bootconfig. So, the first 26 nodes will just use one alphabet. With this fix, test-bootconfig.sh passes all tests. Reported-by: Heinz Wiesinger Link: https://lore.kernel.org/all/2463802.XAFRqVoOGU@amaterasu.liwjatan.org Fixes: 6c40624930c5 ("bootconfig: Increase max nodes of bootconfig from 1024 to 8192 for DCC support") Signed-off-by: Masami Hiramatsu (Google) Reviewed-by: Steven Rostedt (Google) --- tools/bootconfig/test-bootconfig.sh | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tools/bootconfig/test-bootconfig.sh b/tools/bootconfig/test-bootconfig.sh index f68e2e9eef8b..a2c484c243f5 100755 --- a/tools/bootconfig/test-bootconfig.sh +++ b/tools/bootconfig/test-bootconfig.sh @@ -87,10 +87,14 @@ xfail grep -i "error" $OUTFILE echo "Max node number check" -echo -n > $TEMPCONF -for i in `seq 1 1024` ; do - echo "node$i" >> $TEMPCONF -done +awk ' +BEGIN { + for (i = 0; i < 26; i += 1) + printf("%c\n", 65 + i % 26) + for (i = 26; i < 8192; i += 1) + printf("%c%c%c\n", 65 + i % 26, 65 + (i / 26) % 26, 65 + (i / 26 / 26)) +} +' > $TEMPCONF xpass $BOOTCONF -a $TEMPCONF $INITRD echo "badnode" >> $TEMPCONF