Skip to contentSkip to conversation

mm: remove unused anon_vma_trylock_write()

PATCH Applied Hao Li 4 participants 4 messages Aug 27 – Aug 28

Subsystems (2)
lore
Share & tools
lore

Hao Li

author
#0 lore raw

PATCH 1/1 mm: remove unused anon_vma_trylock_write()

The last user of anon_vma_trylock_write() was removed by cc22b9978509, leaving the helper unused. Remove it.

---
 mm/internal.h | 5 -----
 1 file changed, 5 deletions(-)
mm/internal.h +0 -5
index 68db5abd0a4c..9069013d191f 100644
@@ -298,11 +298,6 @@ static inline void anon_vma_lock_write(struct anon_vma *anon_vma)
 	down_write(&anon_vma->root->rwsem);
 }
 
-static inline int anon_vma_trylock_write(struct anon_vma *anon_vma)
-{
-	return down_write_trylock(&anon_vma->root->rwsem);
-}
-
 static inline void anon_vma_unlock_write(struct anon_vma *anon_vma)
 {
 	up_write(&anon_vma->root->rwsem);
Signature · 1 line
2.54.0
reviewer Reviewed-by on v1 1/1
#1 lore raw
Quoted 4 lines · Hao Li

The last user of anon_vma_trylock_write() was removed by cc22b9978509, leaving the helper unused. Remove it.

LGTM so:

Quoted 21 lines
---
 mm/internal.h | 5 -----
 1 file changed, 5 deletions(-)
mm/internal.h +0 -6
index 68db5abd0a4c..9069013d191f 100644
@@ -298,11 +298,6 @@ static inline void anon_vma_lock_write(struct anon_vma *anon_vma)
 	down_write(&anon_vma->root->rwsem);
 }
 
-static inline int anon_vma_trylock_write(struct anon_vma *anon_vma)
-{
-	return down_write_trylock(&anon_vma->root->rwsem);
-}
-
 static inline void anon_vma_unlock_write(struct anon_vma *anon_vma)
 {
 	up_write(&anon_vma->root->rwsem);
--
Quoted 2 lines

2.54.0

--
Cheers, Lorenzo