lkml.org 
[lkml]   [2020]   [Feb]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 01/30] x86/apic/vector: Add missing annotation to lock_vector_lock(void)
Date
Sparse reports a warning at lock_vector_lock(void)

warning: context imbalance in lock_vector_lock() - wrong count at exit

The root cause is the missing annotation at lock_vector_lock(void)
Add the missing __acquires(&vector_lock) annotation

Signed-off-by: Jules Irenge <jbi.octave@gmail.com>
---
arch/x86/kernel/apic/vector.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/apic/vector.c b/arch/x86/kernel/apic/vector.c
index 2c5676b0a6e7..d7556939c6cf 100644
--- a/arch/x86/kernel/apic/vector.c
+++ b/arch/x86/kernel/apic/vector.c
@@ -47,7 +47,7 @@ static struct irq_matrix *vector_matrix;
static DEFINE_PER_CPU(struct hlist_head, cleanup_list);
#endif

-void lock_vector_lock(void)
+void lock_vector_lock(void) __acquires(&vector_lock)
{
/* Used to the online set of cpus does not change
* during assign_irq_vector.
--
2.24.1
\
 
 \ /
  Last update: 2020-02-14 21:49    [W:0.140 / U:3.920 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site