public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Subrata Modak <subrata@linux.vnet.ibm.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Sachin P Sant <sachinp@linux.vnet.ibm.com>,
	Subrata Modak <subrata@linux.vnet.ibm.com>,
	Balbir Singh <balbir@linux.vnet.ibm.com>,
	LKML <linux-kernel@vger.kernel.org>
Subject: [PATCH] Address Sparse Static Warning inside kernel/fork.c
Date: Thu, 06 Aug 2009 22:36:00 +0530	[thread overview]
Message-ID: <20090806170600.32631.77680.sendpatchset@subratamodak.linux.ibm.com> (raw)

Hi Ingo,

The patch below fixes the following SPARSE warning:
kernel/fork.c:81:5: warning: symbol 'max_threads' was not declared. Should it be static?
kernel/fork.c:171:13: warning: symbol 'fork_init' was not declared. Should it be static?

Signed-off-by: Subrata Modak<subrata@linux.vnet.ibm.com>

To: Ingo Molnar <mingo@elte.hu>,
Cc: LKML <linux-kernel@vger.kernel.org>,
Cc: Balbir Singh <balbir@linux.vnet.ibm.com>,
Cc: Sachin P Sant <sachinp@linux.vnet.ibm.com>,
---

--- a/kernel/fork.c	2009-08-05 12:00:51.000000000 +0530
+++ b/kernel/fork.c	2009-08-06 22:26:30.000000000 +0530
@@ -78,7 +78,7 @@
 unsigned long total_forks;	/* Handle normal Linux uptimes. */
 int nr_threads; 		/* The idle threads do not count.. */
 
-int max_threads;		/* tunable limit on nr_threads */
+static int max_threads;		/* tunable limit on nr_threads */
 
 DEFINE_PER_CPU(unsigned long, process_counts) = 0;
 
@@ -168,7 +168,7 @@ void __put_task_struct(struct task_struc
 #define arch_task_cache_init()
 #endif
 
-void __init fork_init(unsigned long mempages)
+static void __init fork_init(unsigned long mempages)
 {
 #ifndef __HAVE_ARCH_TASK_STRUCT_ALLOCATOR
 #ifndef ARCH_MIN_TASKALIGN

Regards--
Subrata


             reply	other threads:[~2009-08-06 17:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-06 17:06 Subrata Modak [this message]
2009-08-06 17:22 ` [PATCH] Address Sparse Static Warning inside kernel/fork.c Arnd Bergmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090806170600.32631.77680.sendpatchset@subratamodak.linux.ibm.com \
    --to=subrata@linux.vnet.ibm.com \
    --cc=balbir@linux.vnet.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=sachinp@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox