Skip to contentSkip to conversation

mm-damon-use-struct-damon_target-instead-of-void-in-target_valid.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Oct 3, 2022

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: mm/damon: use 'struct damon_target *' instead of 'void *' in target_valid()
has been removed from the -mm tree. Its filename was
mm-damon-use-struct-damon_target-instead-of-void-in-target_valid.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: Kaixu Xia <[email protected]>
Subject: mm/damon: use 'struct damon_target *' instead of 'void *' in target_valid()
Date: Thu, 15 Sep 2022 19:33:41 +0800

We could use 'struct damon_target *' directly instead of 'void *' in target_valid() operation to make code simple.

---

 include/linux/damon.h |    2 +-
 mm/damon/vaddr.c      |    3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)
include/linux/damon.h renamed from include/linux/damon.h~mm-damon-use-struct-damon_target-instead-of-void-in-target_valid +1 -1
@@ -346,7 +346,7 @@ struct damon_operations {
 	unsigned long (*apply_scheme)(struct damon_ctx *context,
 			struct damon_target *t, struct damon_region *r,
 			struct damos *scheme);
-	bool (*target_valid)(void *target);
+	bool (*target_valid)(struct damon_target *t);
 	void (*cleanup)(struct damon_ctx *context);
 };
 
mm/damon/vaddr.c renamed from mm/damon/vaddr.c~mm-damon-use-struct-damon_target-instead-of-void-in-target_valid +1 -2
@@ -593,9 +593,8 @@ static unsigned int damon_va_check_acces
  * Functions for the target validity check and cleanup
  */
 
-static bool damon_va_target_valid(void *target)
+static bool damon_va_target_valid(struct damon_target *t)
 {
-	struct damon_target *t = target;
 	struct task_struct *task;
 
 	task = damon_get_task_struct(t);

_

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