From: Josh Triplett <josh@joshtriplett.org>
To: David Miller <davem@davemloft.net>
Cc: rashika.kheria@gmail.com, linux-kernel@vger.kernel.org,
sebastian@breakpoint.cc, sachin.kamat@linaro.org,
netdev@vger.kernel.org
Subject: Re: [PATCH v2 5/9] drivers: net: Put prototype declaration for function sbni_probe() in sbni.c
Date: Sat, 14 Dec 2013 19:41:49 -0800 [thread overview]
Message-ID: <20131215034148.GA1573@leaf> (raw)
In-Reply-To: <20131214.222658.766340465002992773.davem@davemloft.net>
On Sat, Dec 14, 2013 at 10:26:58PM -0500, David Miller wrote:
> From: Rashika Kheria <rashika.kheria@gmail.com>
> Date: Sat, 14 Dec 2013 17:55:42 +0530
>
> > This patch declares the prototype for the function sbni_probe() in file sbni.c.
> >
> > Thus, it also removes the following warning in wan/sbni.c:
> > drivers/net/wan/sbni.c:224:12: warning: no previous prototype for ‘sbni_probe’ [-Wmissing-prototypes]
> >
> > Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
> > ---
> >
> > This revision fixes the following issues of the previous revision:
> > Incorrect fix
> >
> > drivers/net/wan/sbni.c | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/drivers/net/wan/sbni.c b/drivers/net/wan/sbni.c
> > index 388ddf6..5061ffd 100644
> > --- a/drivers/net/wan/sbni.c
> > +++ b/drivers/net/wan/sbni.c
> > @@ -221,6 +221,7 @@ static void __init sbni_devsetup(struct net_device *dev)
> > dev->netdev_ops = &sbni_netdev_ops;
> > }
> >
> > +int __init sbni_probe(int unit);
> > int __init sbni_probe(int unit)
>
> This is not the correct way to fix this kind of warning, an exported
> function needs to appear in a header file so that both the definition
> and any callers of this function will see the same declaration in that
> header file.
It should, yes; however, in this case, the function is one of several
dozen that are directly prototyped and used by drivers/net/Space.c, and
there's no header file prototyping any of those functions.
Do you have a suggestion for what header file should contain a prototype
for this probe function?
- Josh Triplett
next prev parent reply other threads:[~2013-12-15 3:42 UTC|newest]
Thread overview: 67+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-14 12:14 [PATCH v2 1/9] drivers: net: Remove unused function igb_get_eee_status_i354() in e1000_82575.c Rashika Kheria
2013-12-14 12:14 ` Rashika Kheria
2013-12-14 12:17 ` [PATCH v2 2/9] drivers: net: Mark functions as static in qlcnic_io.c Rashika Kheria
2013-12-19 8:47 ` [PATCH v3 1/8] " Rashika Kheria
2013-12-19 8:48 ` [PATCH v3 2/8] drivers: net: Mark functions as static in qlcnic_83xx_hw.c Rashika Kheria
2013-12-19 11:51 ` Shahed Shaikh
2013-12-19 11:51 ` Shahed Shaikh
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 8:49 ` [PATCH v3 3/8] drivers: net: Mark functions as static in stmmac_platform.c Rashika Kheria
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 8:52 ` [PATCH v3 4/8] drivers: net: Include new header file in sbni.c Rashika Kheria
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 8:53 ` [PATCH v3 5/8] drivers: net: Mark functions as static in 3945-debug.c Rashika Kheria
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 8:54 ` [PATCH v3 6/8] drivers: net: Mark functions as static in 4965-debug.c Rashika Kheria
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 8:55 ` [PATCH v3 7/8] drivers: net: Mark functions as static in debug.c Rashika Kheria
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-19 8:56 ` [PATCH v3 8/8] drivers: net: Mark function xenvif_count_frag_slots() as static in netback.c Rashika Kheria
2013-12-19 11:48 ` Wei Liu
2013-12-19 11:48 ` Wei Liu
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-20 9:38 ` Paul Durrant
2013-12-20 9:38 ` Paul Durrant
2013-12-20 9:38 ` Paul Durrant
2013-12-19 23:52 ` David Miller
2013-12-19 8:56 ` Rashika Kheria
2013-12-19 11:49 ` [PATCH v3 1/8] drivers: net: Mark functions as static in qlcnic_io.c Shahed Shaikh
2013-12-19 11:49 ` Shahed Shaikh
2013-12-19 23:52 ` David Miller
2013-12-19 23:52 ` David Miller
2013-12-14 12:19 ` [PATCH v2 3/9] drivers: net: Mark functions as static in qlcnic_83xx_hw.c Rashika Kheria
2013-12-14 12:21 ` [PATCH v2 4/9] drivers: net: Mark functions as static in stmmac_platform.c Rashika Kheria
2013-12-14 12:25 ` [PATCH v2 5/9] drivers: net: Put prototype declaration for function sbni_probe() in sbni.c Rashika Kheria
2013-12-14 20:31 ` Josh Triplett
2013-12-15 3:26 ` David Miller
2013-12-15 3:26 ` David Miller
2013-12-15 3:41 ` Josh Triplett [this message]
2013-12-15 4:01 ` David Miller
2013-12-15 4:01 ` David Miller
2013-12-14 12:27 ` [PATCH v2 6/9] drivers: net: Mark functions as static in 3945-debug.c Rashika Kheria
2013-12-14 12:28 ` [PATCH v2 7/9] drivers: net: Mark functions as static in 4965-debug.c Rashika Kheria
2013-12-14 12:29 ` [PATCH v2 1/9] drivers: net: Remove unused function igb_get_eee_status_i354() in e1000_82575.c Jeff Kirsher
2013-12-14 12:30 ` [PATCH v2 8/9] drivers: net: Mark functions as static in debug.c Rashika Kheria
2013-12-14 12:32 ` [PATCH v2 9/9] drivers: net: Mark function xenvif_count_frag_slots() as static in netback.c Rashika Kheria
2013-12-14 12:32 ` Rashika Kheria
2013-12-16 10:50 ` Ian Campbell
2013-12-16 10:50 ` Ian Campbell
2013-12-16 17:11 ` [PATCH v2 1/9] drivers: net: Remove unused function igb_get_eee_status_i354() in e1000_82575.c Wyborny, Carolyn
2013-12-16 17:11 ` Wyborny, Carolyn
2013-12-16 17:43 ` Josh Triplett
2013-12-16 17:43 ` Josh Triplett
2013-12-16 18:17 ` Wyborny, Carolyn
2013-12-16 18:17 ` Wyborny, Carolyn
2013-12-16 18:22 ` Josh Triplett
2013-12-16 18:51 ` Wyborny, Carolyn
2013-12-16 18:51 ` Wyborny, Carolyn
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=20131215034148.GA1573@leaf \
--to=josh@joshtriplett.org \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=rashika.kheria@gmail.com \
--cc=sachin.kamat@linaro.org \
--cc=sebastian@breakpoint.cc \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.