* [PATCH v2] libceph: Fix sparse warning
@ 2012-08-23 12:14 Iulius Curt
2012-08-27 12:20 ` Iulius Curt
0 siblings, 1 reply; 3+ messages in thread
From: Iulius Curt @ 2012-08-23 12:14 UTC (permalink / raw)
To: sage; +Cc: davem, ceph-devel, netdev, dbaluta, Iulius Curt, Iulius Curt
From: Iulius Curt <iulius.curt@gmail.com>
Make ceph_monc_do_poolop() static to remove the following sparse warning:
* net/ceph/mon_client.c:616:5: warning: symbol 'ceph_monc_do_poolop' was not
declared. Should it be static?
Also drops the 'ceph_monc_' prefix, now being a private function.
Signed-off-by: Iulius Curt <icurt@ixiacom.com>
---
v1 ---> v2
* drop the 'ceph_monc_' prefix
---
net/ceph/mon_client.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/net/ceph/mon_client.c b/net/ceph/mon_client.c
index 105d533..84ce495 100644
--- a/net/ceph/mon_client.c
+++ b/net/ceph/mon_client.c
@@ -613,7 +613,7 @@ bad:
/*
* Do a synchronous pool op.
*/
-int ceph_monc_do_poolop(struct ceph_mon_client *monc, u32 op,
+static int do_poolop(struct ceph_mon_client *monc, u32 op,
u32 pool, u64 snapid,
char *buf, int len)
{
@@ -663,7 +663,7 @@ out:
int ceph_monc_create_snapid(struct ceph_mon_client *monc,
u32 pool, u64 *snapid)
{
- return ceph_monc_do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
+ return do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
pool, 0, (char *)snapid, sizeof(*snapid));
}
@@ -672,7 +672,7 @@ EXPORT_SYMBOL(ceph_monc_create_snapid);
int ceph_monc_delete_snapid(struct ceph_mon_client *monc,
u32 pool, u64 snapid)
{
- return ceph_monc_do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
+ return do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
pool, snapid, 0, 0);
}
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH v2] libceph: Fix sparse warning
2012-08-23 12:14 [PATCH v2] libceph: Fix sparse warning Iulius Curt
@ 2012-08-27 12:20 ` Iulius Curt
2012-08-27 16:04 ` Sage Weil
0 siblings, 1 reply; 3+ messages in thread
From: Iulius Curt @ 2012-08-27 12:20 UTC (permalink / raw)
To: sage; +Cc: Iulius Curt, davem, ceph-devel, netdev, dbaluta
On 08/23/2012 03:14 PM, Iulius Curt wrote:
> From: Iulius Curt<iulius.curt@gmail.com>
>
> Make ceph_monc_do_poolop() static to remove the following sparse warning:
> * net/ceph/mon_client.c:616:5: warning: symbol 'ceph_monc_do_poolop' was not
> declared. Should it be static?
> Also drops the 'ceph_monc_' prefix, now being a private function.
>
> Signed-off-by: Iulius Curt<icurt@ixiacom.com>
> ---
> v1 ---> v2
> * drop the 'ceph_monc_' prefix
> ---
> net/ceph/mon_client.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/net/ceph/mon_client.c b/net/ceph/mon_client.c
> index 105d533..84ce495 100644
> --- a/net/ceph/mon_client.c
> +++ b/net/ceph/mon_client.c
> @@ -613,7 +613,7 @@ bad:
> /*
> * Do a synchronous pool op.
> */
> -int ceph_monc_do_poolop(struct ceph_mon_client *monc, u32 op,
> +static int do_poolop(struct ceph_mon_client *monc, u32 op,
> u32 pool, u64 snapid,
> char *buf, int len)
> {
> @@ -663,7 +663,7 @@ out:
> int ceph_monc_create_snapid(struct ceph_mon_client *monc,
> u32 pool, u64 *snapid)
> {
> - return ceph_monc_do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> + return do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> pool, 0, (char *)snapid, sizeof(*snapid));
>
> }
> @@ -672,7 +672,7 @@ EXPORT_SYMBOL(ceph_monc_create_snapid);
> int ceph_monc_delete_snapid(struct ceph_mon_client *monc,
> u32 pool, u64 snapid)
> {
> - return ceph_monc_do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> + return do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> pool, snapid, 0, 0);
>
> }
> --
> 1.7.9.5
>
>
Hi Sage,
Can you, please, have a look.
Thanks,
Iulius
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v2] libceph: Fix sparse warning
2012-08-27 12:20 ` Iulius Curt
@ 2012-08-27 16:04 ` Sage Weil
0 siblings, 0 replies; 3+ messages in thread
From: Sage Weil @ 2012-08-27 16:04 UTC (permalink / raw)
To: Iulius Curt; +Cc: Iulius Curt, davem, ceph-devel, netdev, dbaluta
Hi Iulius,
On Mon, 27 Aug 2012, Iulius Curt wrote:
> On 08/23/2012 03:14 PM, Iulius Curt wrote:
> > From: Iulius Curt<iulius.curt@gmail.com>
> >
> > Make ceph_monc_do_poolop() static to remove the following sparse warning:
> > * net/ceph/mon_client.c:616:5: warning: symbol 'ceph_monc_do_poolop' was
> > not
> > declared. Should it be static?
> > Also drops the 'ceph_monc_' prefix, now being a private function.
> >
> > Signed-off-by: Iulius Curt<icurt@ixiacom.com>
> > ---
> > v1 ---> v2
> > * drop the 'ceph_monc_' prefix
> > ---
> > net/ceph/mon_client.c | 6 +++---
> > 1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/net/ceph/mon_client.c b/net/ceph/mon_client.c
> > index 105d533..84ce495 100644
> > --- a/net/ceph/mon_client.c
> > +++ b/net/ceph/mon_client.c
> > @@ -613,7 +613,7 @@ bad:
> > /*
> > * Do a synchronous pool op.
> > */
> > -int ceph_monc_do_poolop(struct ceph_mon_client *monc, u32 op,
> > +static int do_poolop(struct ceph_mon_client *monc, u32 op,
> > u32 pool, u64 snapid,
> > char *buf, int len)
> > {
> > @@ -663,7 +663,7 @@ out:
> > int ceph_monc_create_snapid(struct ceph_mon_client *monc,
> > u32 pool, u64 *snapid)
> > {
> > - return ceph_monc_do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> > + return do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> > pool, 0, (char *)snapid, sizeof(*snapid));
> >
> > }
> > @@ -672,7 +672,7 @@ EXPORT_SYMBOL(ceph_monc_create_snapid);
> > int ceph_monc_delete_snapid(struct ceph_mon_client *monc,
> > u32 pool, u64 snapid)
> > {
> > - return ceph_monc_do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> > + return do_poolop(monc, POOL_OP_CREATE_UNMANAGED_SNAP,
> > pool, snapid, 0, 0);
> >
> > }
> > --
> > 1.7.9.5
> >
> >
> Hi Sage,
>
> Can you, please, have a look.
Looks great--sorry I forgot to reply before. This is applied to the
ceph tree's testing branch and will go upstream for 3.7.
Thanks!
sage
>
> Thanks,
> Iulius
>
> --
> To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-08-27 16:04 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-23 12:14 [PATCH v2] libceph: Fix sparse warning Iulius Curt
2012-08-27 12:20 ` Iulius Curt
2012-08-27 16:04 ` Sage Weil
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).