From: Anna Schumaker <Anna.Schumaker@netapp.com>
To: Tom Haynes <thomas.haynes@primarydata.com>
Cc: <Trond.Myklebust@primarydata.com>, <linux-nfs@vger.kernel.org>
Subject: Re: [PATCH] sunrpc: Give parameter names to rpc_count_iostasts_metrics()
Date: Mon, 9 Feb 2015 16:31:50 -0500 [thread overview]
Message-ID: <54D92746.2020700@Netapp.com> (raw)
In-Reply-To: <EB593CD6-EF0C-42FA-A6BD-C3D9C7DD51F9@primarydata.com>
On 02/09/2015 04:30 PM, Tom Haynes wrote:
>
>> On Feb 9, 2015, at 11:07 AM, Anna Schumaker <Anna.Schumaker@netapp.com> wrote:
>>
>> We fall back to an empty function in the case that CONFIG_PROC_FS=n, so
>> give this function named parameters to silence a "parameter name omitted"
>> warning.
>>
>> Reported-by: Jim Davis <jim.epost@gmail.com>
>> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
>> ---
>> include/linux/sunrpc/metrics.h | 4 ++--
>> 1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/include/linux/sunrpc/metrics.h b/include/linux/sunrpc/metrics.h
>> index 7e61a17..b23b8ed 100644
>> --- a/include/linux/sunrpc/metrics.h
>> +++ b/include/linux/sunrpc/metrics.h
>> @@ -89,8 +89,8 @@ void rpc_free_iostats(struct rpc_iostats *);
>> static inline struct rpc_iostats *rpc_alloc_iostats(struct rpc_clnt *clnt) { return NULL; }
>> static inline void rpc_count_iostats(const struct rpc_task *task,
>> struct rpc_iostats *stats) {}
>
> Hi Anna,
>
> Why doesn’t the above also emit the warning?
Because the parameters have names: in rpc_count_iostats you have an rpc_task named "task" and an rpc_iostats named "stats".
Anna
>
> Thanks,
> Tom
>
>
>> -static inline void rpc_count_iostats_metrics(const struct rpc_task *,
>> - struct rpc_iostats *) {}
>> +static inline void rpc_count_iostats_metrics(const struct rpc_task *task,
>> + struct rpc_iostats *op_metrics) {}
>> static inline void rpc_print_iostats(struct seq_file *seq, struct rpc_clnt *clnt) {}
>> static inline void rpc_free_iostats(struct rpc_iostats *stats) {}
>>
>> --
>> 2.3.0
>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
prev parent reply other threads:[~2015-02-09 21:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-09 19:07 [PATCH] sunrpc: Give parameter names to rpc_count_iostasts_metrics() Anna Schumaker
2015-02-09 21:30 ` Tom Haynes
2015-02-09 21:31 ` Anna Schumaker [this message]
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=54D92746.2020700@Netapp.com \
--to=anna.schumaker@netapp.com \
--cc=Trond.Myklebust@primarydata.com \
--cc=linux-nfs@vger.kernel.org \
--cc=thomas.haynes@primarydata.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 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.