From: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
To: YueHaibing <yuehaibing@huawei.com>
Cc: "David S. Miller" <davem@davemloft.net>,
netdev@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH net-next] net: qualcomm: rmnet: Remove set but not used variable 'cmd'
Date: Wed, 28 Nov 2018 19:43:47 -0700 [thread overview]
Message-ID: <4a9a436323e65a2bd1357bf49c687ec8@codeaurora.org> (raw)
In-Reply-To: <1543458992-103568-1-git-send-email-yuehaibing@huawei.com>
On 2018-11-28 19:36, YueHaibing wrote:
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/net/ethernet/qualcomm/rmnet/rmnet_map_command.c: In function
> 'rmnet_map_do_flow_control':
> drivers/net/ethernet/qualcomm/rmnet/rmnet_map_command.c:23:36: warning:
> variable 'cmd' set but not used [-Wunused-but-set-variable]
> struct rmnet_map_control_command *cmd;
>
> 'cmd' not used anymore now, should also be removed.
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> ---
> drivers/net/ethernet/qualcomm/rmnet/rmnet_map_command.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/net/ethernet/qualcomm/rmnet/rmnet_map_command.c
> b/drivers/net/ethernet/qualcomm/rmnet/rmnet_map_command.c
> index 8990307..f6cf59a 100644
> --- a/drivers/net/ethernet/qualcomm/rmnet/rmnet_map_command.c
> +++ b/drivers/net/ethernet/qualcomm/rmnet/rmnet_map_command.c
> @@ -20,14 +20,12 @@ static u8 rmnet_map_do_flow_control(struct sk_buff
> *skb,
> struct rmnet_port *port,
> int enable)
> {
> - struct rmnet_map_control_command *cmd;
> struct rmnet_endpoint *ep;
> struct net_device *vnd;
> u8 mux_id;
> int r;
>
> mux_id = RMNET_MAP_GET_MUX_ID(skb);
> - cmd = RMNET_MAP_GET_CMD_START(skb);
>
> if (mux_id >= RMNET_MAX_LOGICAL_EP) {
> kfree_skb(skb);
Thanks for cleaning these up.
Acked-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project
next prev parent reply other threads:[~2018-11-29 13:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-29 2:36 [PATCH net-next] net: qualcomm: rmnet: Remove set but not used variable 'cmd' YueHaibing
2018-11-29 2:43 ` Subash Abhinov Kasiviswanathan [this message]
2018-12-01 1:24 ` David Miller
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=4a9a436323e65a2bd1357bf49c687ec8@codeaurora.org \
--to=subashab@codeaurora.org \
--cc=davem@davemloft.net \
--cc=kernel-janitors@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=yuehaibing@huawei.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 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).