mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] rtmutex: Drop pointless static qualifier in rt_mutex_adjust_prio_chain()
@ 2018-08-07  8:56 Mao Wenan
  2018-08-07  8:59 ` Julia Lawall
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Mao Wenan @ 2018-08-07  8:56 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar, Will Deacon
  Cc: Mao Wenan, linux-kernel, kernel-janitors

There is no need to have the 'T *v' variable static
since new value always be assigned before use it.

Signed-off-by: Mao Wenan <maowenan@huawei.com>
---
 kernel/locking/rtmutex.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/locking/rtmutex.c b/kernel/locking/rtmutex.c
index 2823d41..ba70db8 100644
--- a/kernel/locking/rtmutex.c
+++ b/kernel/locking/rtmutex.c
@@ -472,7 +472,7 @@ static int rt_mutex_adjust_prio_chain(struct task_struct *task,
 	 * We limit the lock chain length for each invocation.
 	 */
 	if (++depth > max_lock_depth) {
-		static int prev_max;
+		int prev_max;
 
 		/*
 		 * Print this only once. If the admin changes the limit,




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-08-07 18:34 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-07  8:56 [PATCH] rtmutex: Drop pointless static qualifier in rt_mutex_adjust_prio_chain() Mao Wenan
2018-08-07  8:59 ` Julia Lawall
2018-08-07  9:29 ` Dan Carpenter
2018-08-07 18:34 ` kbuild test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®