Patch "bootconfig: Fix testcase to increase max node" has been added to the 5.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    bootconfig: Fix testcase to increase max node

to the 5.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     bootconfig-fix-testcase-to-increase-max-node.patch
and it can be found in the queue-5.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit bad755146c5b09e05cd0e50e3ea1cfec6a675446
Author: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>
Date:   Wed Mar 15 22:54:08 2023 +0900

    bootconfig: Fix testcase to increase max node
    
    [ Upstream commit b69245126a48e50882021180fa5d264dc7149ccc ]
    
    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.
    
    Link: https://lore.kernel.org/all/167888844790.791176.670805252426835131.stgit@devnote2/
    
    Reported-by: Heinz Wiesinger <pprkut@xxxxxxxxxxxxx>
    Link: https://lore.kernel.org/all/2463802.XAFRqVoOGU@xxxxxxxxxxxxxxxxxxxxxx
    Fixes: 6c40624930c5 ("bootconfig: Increase max nodes of bootconfig from 1024 to 8192 for DCC support")
    Signed-off-by: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>
    Reviewed-by: Steven Rostedt (Google) <rostedt@xxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/tools/bootconfig/test-bootconfig.sh b/tools/bootconfig/test-bootconfig.sh
index baed891d0ba49..e36f178f7dcbf 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



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux