Skip to contentSkip to conversation

mm-shmem-remove-duplicate-error-validation.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Mar 17, 2025

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: mm: shmem: remove duplicate error validation
has been removed from the -mm tree. Its filename was
mm-shmem-remove-duplicate-error-validation.patch

This patch was dropped because it was merged into the mm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Baolin Wang <[email protected]>
Subject: mm: shmem: remove duplicate error validation
Date: Fri, 7 Feb 2025 17:44:19 +0800

Remove duplicate error code checks for 'start' and 'end', as the get_order_from_str() will only return -EINVAL if the cmdline string is configured incorrectly.

---

 mm/shmem.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
mm/shmem.c renamed from mm/shmem.c~mm-shmem-remove-duplicate-error-validation +3 -3
@@ -5664,19 +5664,19 @@ static int __init setup_thp_shmem(char *
 								 THP_ORDERS_ALL_FILE_DEFAULT);
 			}
 
-			if (start == -EINVAL) {
+			if (start < 0) {
 				pr_err("invalid size %s in thp_shmem boot parameter\n",
 				       start_size);
 				goto err;
 			}
 
-			if (end == -EINVAL) {
+			if (end < 0) {
 				pr_err("invalid size %s in thp_shmem boot parameter\n",
 				       end_size);
 				goto err;
 			}
 
-			if (start < 0 || end < 0 || start > end)
+			if (start > end)
 				goto err;
 
 			nr = end - start + 1;

_

Patches currently in -mm which might be from [email protected] are