From: Arnd Bergmann <arnd@arndb.de>
To: Baoyou Xie <baoyou.xie@linaro.org>
Cc: Yuval.Mintz@qlogic.com, Ariel.Elior@qlogic.com,
everest-linux-l2@qlogic.com, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org, xie.baoyou@zte.com.cn,
han.fei@zte.com.cn, tang.qiang007@zte.com.cn
Subject: Re: [PATCH 2/2] qed: remove unused function in qed_cxt.c
Date: Fri, 30 Sep 2016 16:29:03 +0200 [thread overview]
Message-ID: <201609301629.03359.arnd@arndb.de> (raw)
In-Reply-To: <1475222574-19280-1-git-send-email-baoyou.xie@linaro.org>
On Friday 30 September 2016, Baoyou Xie wrote:
> We get 3 warnings when building kernel with W=1:
> drivers/net/ethernet/qlogic/qed/qed_cxt.c:1941:1: warning: no previous prototype for 'qed_cxt_dynamic_ilt_alloc' [-Wmissing-prototypes]
> drivers/net/ethernet/qlogic/qed/qed_cxt.c:2158:5: warning: no previous prototype for 'qed_cxt_free_proto_ilt' [-Wmissing-prototypes]
> drivers/net/ethernet/qlogic/qed/qed_cxt.c:2186:5: warning: no previous prototype for 'qed_cxt_get_task_ctx' [-Wmissing-prototypes]
>
> In fact, these functions are unused in
> drivers/net/ethernet/qlogic/qed/qed_cxt.c, but should be removed.
>
> So this patch removes these unused functions.
>
> Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>
These were only recently added in dbb799c39717 ("qed: Initialize hardware for new protocols"),
so it's likely that the plan is to use them in the future, and your commit message should
at least mention that.
If there is no longer a plan to use them, it would probably better to back out that whole
patch, other alternatives in this case might be to mark them as "static __maybe_unused"
so the compiler can drop the code silently, or to add declarations in a header if the
user would be in another file.
Arnd
prev parent reply other threads:[~2016-09-30 14:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-30 8:02 [PATCH 2/2] qed: remove unused function in qed_cxt.c Baoyou Xie
2016-09-30 14:29 ` Arnd Bergmann [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=201609301629.03359.arnd@arndb.de \
--to=arnd@arndb.de \
--cc=Ariel.Elior@qlogic.com \
--cc=Yuval.Mintz@qlogic.com \
--cc=baoyou.xie@linaro.org \
--cc=everest-linux-l2@qlogic.com \
--cc=han.fei@zte.com.cn \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=tang.qiang007@zte.com.cn \
--cc=xie.baoyou@zte.com.cn \
/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.