LinuxPPC-Dev Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] windfarm: make symbol 'wf_thread' static
@ 2021-04-07 12:57 Yu Kuai
  2021-04-19  3:59 ` Michael Ellerman
  0 siblings, 1 reply; 2+ messages in thread
From: Yu Kuai @ 2021-04-07 12:57 UTC (permalink / raw)
  To: benh; +Cc: yukuai3, linuxppc-dev, linux-kernel, zhangxiaoxu5, yi.zhang

The sparse tool complains as follows:

drivers/macintosh/windfarm_core.c:59:20: warning:
 symbol 'wf_thread' was not declared. Should it be static?

This symbol is not used outside of windfarm_core.c, so this
commit marks it static.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
---
 drivers/macintosh/windfarm_core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/macintosh/windfarm_core.c b/drivers/macintosh/windfarm_core.c
index 77612303841e..07f91ec1f960 100644
--- a/drivers/macintosh/windfarm_core.c
+++ b/drivers/macintosh/windfarm_core.c
@@ -56,7 +56,7 @@ static BLOCKING_NOTIFIER_HEAD(wf_client_list);
 static int wf_client_count;
 static unsigned int wf_overtemp;
 static unsigned int wf_overtemp_counter;
-struct task_struct *wf_thread;
+static struct task_struct *wf_thread;
 
 static struct platform_device wf_platform_device = {
 	.name	= "windfarm",
-- 
2.25.4


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

* Re: [PATCH] windfarm: make symbol 'wf_thread' static
  2021-04-07 12:57 [PATCH] windfarm: make symbol 'wf_thread' static Yu Kuai
@ 2021-04-19  3:59 ` Michael Ellerman
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Ellerman @ 2021-04-19  3:59 UTC (permalink / raw)
  To: Yu Kuai, benh; +Cc: linuxppc-dev, zhangxiaoxu5, linux-kernel, yi.zhang

On Wed, 7 Apr 2021 20:57:38 +0800, Yu Kuai wrote:
> The sparse tool complains as follows:
> 
> drivers/macintosh/windfarm_core.c:59:20: warning:
>  symbol 'wf_thread' was not declared. Should it be static?
> 
> This symbol is not used outside of windfarm_core.c, so this
> commit marks it static.

Applied to powerpc/next.

[1/1] windfarm: make symbol 'wf_thread' static
      https://git.kernel.org/powerpc/c/4204ecd598cb0a044e6fcfd48e569080955347f4

cheers

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

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-07 12:57 [PATCH] windfarm: make symbol 'wf_thread' static Yu Kuai
2021-04-19  3:59 ` Michael Ellerman

LinuxPPC-Dev Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linuxppc-dev/0 linuxppc-dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linuxppc-dev linuxppc-dev/ https://lore.kernel.org/linuxppc-dev \
		linuxppc-dev@lists.ozlabs.org linuxppc-dev@ozlabs.org
	public-inbox-index linuxppc-dev

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.ozlabs.lists.linuxppc-dev


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git