+ list-test-check-the-size-of-every-lists-for-list_cut_position.patch added to mm-nonmm-unstable branch

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

 



The patch titled
     Subject: list: test: check the size of every lists for list_cut_position*()
has been added to the -mm mm-nonmm-unstable branch.  Its filename is
     list-test-check-the-size-of-every-lists-for-list_cut_position.patch

This patch will shortly appear at
     https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/list-test-check-the-size-of-every-lists-for-list_cut_position.patch

This patch will later appear in the mm-nonmm-unstable branch at
    git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next via the mm-everything
branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
and is updated there every 2-3 working days

------------------------------------------------------
From: I Hsin Cheng <richard120310@xxxxxxxxx>
Subject: list: test: check the size of every lists for list_cut_position*()
Date: Tue, 8 Oct 2024 14:52:53 +0800

Check the total number of elements in both resultant lists are correct
within list_cut_position*().  Previously, only the first list's size was
checked.  so additional elements in the second list would not have been
caught.

Link: https://lkml.kernel.org/r/20241008065253.26673-1-richard120310@xxxxxxxxx
Signed-off-by: I Hsin Cheng <richard120310@xxxxxxxxx>
Cc: David Gow <davidgow@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 lib/list-test.c |    4 ++++
 1 file changed, 4 insertions(+)

--- a/lib/list-test.c~list-test-check-the-size-of-every-lists-for-list_cut_position
+++ a/lib/list-test.c
@@ -412,6 +412,8 @@ static void list_test_list_cut_position(
 		KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]);
 		i++;
 	}
+
+	KUNIT_EXPECT_EQ(test, i, 3);
 }
 
 static void list_test_list_cut_before(struct kunit *test)
@@ -440,6 +442,8 @@ static void list_test_list_cut_before(st
 		KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]);
 		i++;
 	}
+
+	KUNIT_EXPECT_EQ(test, i, 3);
 }
 
 static void list_test_list_splice(struct kunit *test)
_

Patches currently in -mm which might be from richard120310@xxxxxxxxx are

list-test-check-the-size-of-every-lists-for-list_cut_position.patch





[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux