diff mbox series

[15/30] x86/xen: Add missing annotation for xen_pte_unlock()

Message ID 20200214204741.94112-16-jbi.octave@gmail.com (mailing list archive)
State New, archived
Headers show
Series None | expand

Commit Message

Jules Irenge Feb. 14, 2020, 8:47 p.m. UTC
Sparse reports warning at xen_pte_unlock()

warning: context imbalance in xen_pte_unlock() - unexpected unlock

The root cause is the missing annotation at xen_pte_unlock()
Add the missing __releases(ptl) annotation

Signed-off-by: Jules Irenge <jbi.octave@gmail.com>
---
 arch/x86/xen/mmu_pv.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/arch/x86/xen/mmu_pv.c b/arch/x86/xen/mmu_pv.c
index 352f0c80cfcf..777008f8c668 100644
--- a/arch/x86/xen/mmu_pv.c
+++ b/arch/x86/xen/mmu_pv.c
@@ -707,7 +707,7 @@  static spinlock_t *xen_pte_lock(struct page *page, struct mm_struct *mm)
 	return ptl;
 }
 
-static void xen_pte_unlock(void *v)
+static void xen_pte_unlock(void *v) __releases(ptl)
 {
 	spinlock_t *ptl = v;
 	spin_unlock(ptl);