lkml.org 
[lkml]   [2020]   [Feb]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 20/30] mm/zsmalloc: Add missing annotation for migrate_write_unlock()
Date
Sparse reports a warning at migrate_write_unlock()
warning: context imbalance in migrate_write_unlock() - unexpected unlock
The root cause is the missing annotation at migrate_write_unlock()
Add the missing __releases(&zspage->lock)

Signed-off-by: Jules Irenge <jbi.octave@gmail.com>
---
mm/zsmalloc.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/mm/zsmalloc.c b/mm/zsmalloc.c
index 7ec69a1140cf..cb5541d06823 100644
--- a/mm/zsmalloc.c
+++ b/mm/zsmalloc.c
@@ -1852,6 +1852,7 @@ static void migrate_write_lock(struct zspage *zspage)
}

static void migrate_write_unlock(struct zspage *zspage)
+ __releases(&zspage->lock)
{
write_unlock(&zspage->lock);
}
--
2.24.1
\
 
 \ /
  Last update: 2020-02-24 00:18    [W:0.127 / U:1.704 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site