public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 4/9] mISDN: fix sparse warnings
@ 2008-12-10 15:13 Hannes Eder
  2008-12-10 22:01 ` Jiri Slaby
  0 siblings, 1 reply; 3+ messages in thread
From: Hannes Eder @ 2008-12-10 15:13 UTC (permalink / raw)
  To: Karsten Keil; +Cc: linux-kernel, kernel-janitors

Impact: make an exported symbol non static

Fix this warning:

  drivers/isdn/hardware/mISDN/hfcmulti.c:176:1: warning: symbol 'plx_lock' shadows an earlier one
  drivers/isdn/hardware/mISDN/hfcmulti.c:175:19: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---

Note that patch introduces this new warning:

  drivers/isdn/hardware/mISDN/hfcmulti.c:175:12: warning: symbol 'plx_lock' was not declared. Should it be static?

Should 'plx_lock' be declared in a header file?  Or is it really
neccessart to export it?


 drivers/isdn/hardware/mISDN/hfcmulti.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/isdn/hardware/mISDN/hfcmulti.c b/drivers/isdn/hardware/mISDN/hfcmulti.c
index 599d832..b4595f7 100644
--- a/drivers/isdn/hardware/mISDN/hfcmulti.c
+++ b/drivers/isdn/hardware/mISDN/hfcmulti.c
@@ -172,7 +172,7 @@ static int interrupt_registered;
 
 static struct hfc_multi *syncmaster;
 static int plxsd_master; /* if we have a master card (yet) */
-static spinlock_t plx_lock; /* may not acquire other lock inside */
+spinlock_t plx_lock; /* may not acquire other lock inside */
 EXPORT_SYMBOL(plx_lock);
 
 #define	TYP_E1		1
-- 
1.5.6.3


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

* Re: [PATCHv2 4/9] mISDN: fix sparse warning
  2008-12-10 22:01 ` Jiri Slaby
@ 2008-12-10 19:41   ` Hannes Eder
  0 siblings, 0 replies; 3+ messages in thread
From: Hannes Eder @ 2008-12-10 19:41 UTC (permalink / raw)
  To: Jiri Slaby; +Cc: Karsten Keil, linux-kernel, kernel-janitors

Impact: un-export symbol 'plx_lock'

Fix this warning:

  drivers/isdn/hardware/mISDN/hfcmulti.c:176:1: warning: symbol 'plx_lock' shadows an earlier one
  drivers/isdn/hardware/mISDN/hfcmulti.c:175:19: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---

On Wed, Dec 10, 2008 at 11:01 PM, Jiri Slaby <jirislaby@gmail.com> wrote:
> On 12/10/2008 04:13 PM, Hannes Eder wrote:
>> Should 'plx_lock' be declared in a header file?  Or is it really
>> neccessart to export it?
>
> As there is no other user, I vote for unexporting it.

In that case patch number 4 looks like this:

 drivers/isdn/hardware/mISDN/hfcmulti.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/isdn/hardware/mISDN/hfcmulti.c b/drivers/isdn/hardware/mISDN/hfcmulti.c
index 599d832..970201d 100644
--- a/drivers/isdn/hardware/mISDN/hfcmulti.c
+++ b/drivers/isdn/hardware/mISDN/hfcmulti.c
@@ -173,7 +173,6 @@ static int interrupt_registered;
 static struct hfc_multi *syncmaster;
 static int plxsd_master; /* if we have a master card (yet) */
 static spinlock_t plx_lock; /* may not acquire other lock inside */
-EXPORT_SYMBOL(plx_lock);
 
 #define	TYP_E1		1
 #define	TYP_4S		4
-- 
1.5.6.3


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

* Re: [PATCH 4/9] mISDN: fix sparse warnings
  2008-12-10 15:13 [PATCH 4/9] mISDN: fix sparse warnings Hannes Eder
@ 2008-12-10 22:01 ` Jiri Slaby
  2008-12-10 19:41   ` [PATCHv2 4/9] mISDN: fix sparse warning Hannes Eder
  0 siblings, 1 reply; 3+ messages in thread
From: Jiri Slaby @ 2008-12-10 22:01 UTC (permalink / raw)
  To: Hannes Eder; +Cc: Karsten Keil, linux-kernel, kernel-janitors

On 12/10/2008 04:13 PM, Hannes Eder wrote:
> Should 'plx_lock' be declared in a header file?  Or is it really
> neccessart to export it?

As there is no other user, I vote for unexporting it.

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

end of thread, other threads:[~2008-12-11 20:05 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-10 15:13 [PATCH 4/9] mISDN: fix sparse warnings Hannes Eder
2008-12-10 22:01 ` Jiri Slaby
2008-12-10 19:41   ` [PATCHv2 4/9] mISDN: fix sparse warning Hannes Eder

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