mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH -next] x86/cpu: Drop pointless static qualifier in punit_dev_state_show()
@ 2018-10-12 10:40 YueHaibing
  2018-10-12 10:51 ` [tip:perf/core] " tip-bot for YueHaibing
  0 siblings, 1 reply; 2+ messages in thread
From: YueHaibing @ 2018-10-12 10:40 UTC (permalink / raw)
  To: Thomas Gleixner, Ingo Molnar, Borislav Petkov, H. Peter Anvin,
	Peter Zijlstra, Andy Shevchenko
  Cc: YueHaibing, x86, linux-kernel, kernel-janitors

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

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 arch/x86/platform/atom/punit_atom_debug.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/platform/atom/punit_atom_debug.c b/arch/x86/platform/atom/punit_atom_debug.c
index 41dae0f..6cb6076 100644
--- a/arch/x86/platform/atom/punit_atom_debug.c
+++ b/arch/x86/platform/atom/punit_atom_debug.c
@@ -115,7 +115,7 @@ static int punit_dev_state_show(struct seq_file *seq_file, void *unused)
 
 static int punit_dbgfs_register(struct punit_device *punit_device)
 {
-	static struct dentry *dev_state;
+	struct dentry *dev_state;
 
 	punit_dbg_file = debugfs_create_dir("punit_atom", NULL);
 	if (!punit_dbg_file)




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

* [tip:perf/core] x86/cpu: Drop pointless static qualifier in punit_dev_state_show()
  2018-10-12 10:40 [PATCH -next] x86/cpu: Drop pointless static qualifier in punit_dev_state_show() YueHaibing
@ 2018-10-12 10:51 ` tip-bot for YueHaibing
  0 siblings, 0 replies; 2+ messages in thread
From: tip-bot for YueHaibing @ 2018-10-12 10:51 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: tglx, bp, yuehaibing, hpa, torvalds, peterz, linux-kernel, mingo,
	andriy.shevchenko

Commit-ID:  f703fd374ef8fb06e46713b326d255e20d6278ad
Gitweb:     https://git.kernel.org/tip/f703fd374ef8fb06e46713b326d255e20d6278ad
Author:     YueHaibing <yuehaibing@huawei.com>
AuthorDate: Fri, 12 Oct 2018 10:40:22 +0000
Committer:  Ingo Molnar <mingo@kernel.org>
CommitDate: Fri, 12 Oct 2018 12:48:44 +0200

x86/cpu: Drop pointless static qualifier in punit_dev_state_show()

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

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: kernel-janitors@vger.kernel.org
Link: http://lkml.kernel.org/r/1539340822-117563-1-git-send-email-yuehaibing@huawei.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 arch/x86/platform/atom/punit_atom_debug.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/platform/atom/punit_atom_debug.c b/arch/x86/platform/atom/punit_atom_debug.c
index 41dae0f0d898..6cb6076223ba 100644
--- a/arch/x86/platform/atom/punit_atom_debug.c
+++ b/arch/x86/platform/atom/punit_atom_debug.c
@@ -115,7 +115,7 @@ static struct dentry *punit_dbg_file;
 
 static int punit_dbgfs_register(struct punit_device *punit_device)
 {
-	static struct dentry *dev_state;
+	struct dentry *dev_state;
 
 	punit_dbg_file = debugfs_create_dir("punit_atom", NULL);
 	if (!punit_dbg_file)

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

end of thread, other threads:[~2018-10-12 10:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-12 10:40 [PATCH -next] x86/cpu: Drop pointless static qualifier in punit_dev_state_show() YueHaibing
2018-10-12 10:51 ` [tip:perf/core] " tip-bot for YueHaibing

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®