Skip to contentSkip to conversation

mm-swap_slotsc-remove-always-zero-and-unused-return-value-of-enable_swap_slots_cache.patch removed from -mm tree

merged [email protected] 1 participant 1 message Oct 14, 2020

lore
Share & tools
lore

[email protected]

author tree notice Applied
#0 lore raw

The patch titled
Subject: mm/swap_slots.c: remove always zero and unused return value of enable_swap_slots_cache()
has been removed from the -mm tree. Its filename was
mm-swap_slotsc-remove-always-zero-and-unused-return-value-of-enable_swap_slots_cache.patch

This patch was dropped because it was merged into mainline or a subsystem tree

------------------------------------------------------
From: Miaohe Lin <[email protected]>
Subject: mm/swap_slots.c: remove always zero and unused return value of enable_swap_slots_cache()

enable_swap_slots_cache() always return zero and its return value is just ignored by the caller. So make enable_swap_slots_cache() void.

---

 include/linux/swap_slots.h |    2 +-
 mm/swap_slots.c            |    3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)
include/linux/swap_slots.h renamed from include/linux/swap_slots.h~mm-swap_slotsc-remove-always-zero-and-unused-return-value-of-enable_swap_slots_cache +1 -1
@@ -23,7 +23,7 @@ struct swap_slots_cache {
 
 void disable_swap_slots_cache_lock(void);
 void reenable_swap_slots_cache_unlock(void);
-int enable_swap_slots_cache(void);
+void enable_swap_slots_cache(void);
 int free_swap_slot(swp_entry_t entry);
 
 extern bool swap_slot_cache_enabled;
mm/swap_slots.c renamed from mm/swap_slots.c~mm-swap_slotsc-remove-always-zero-and-unused-return-value-of-enable_swap_slots_cache +1 -2
@@ -237,7 +237,7 @@ static int free_slot_cache(unsigned int
 	return 0;
 }
 
-int enable_swap_slots_cache(void)
+void enable_swap_slots_cache(void)
 {
 	mutex_lock(&swap_slots_cache_enable_mutex);
 	if (!swap_slot_cache_initialized) {
@@ -255,7 +255,6 @@ int enable_swap_slots_cache(void)
 	__reenable_swap_slots_cache();
 out_unlock:
 	mutex_unlock(&swap_slots_cache_enable_mutex);
-	return 0;
 }
 
 /* called with swap slot cache's alloc lock held */

_

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

mm-vmstat-use-helper-macro-abs.patch
mm-fix-some-broken-comments.patch mm-use-helper-function-put_write_access.patch percpu_counter-use-helper-macro-abs.patch mm-migrate-avoid-possible-unnecessary-process-right-check-in-kernel_move_pages.patch