* [PATCH] net/rds: remove variable total_copied
@ 2022-10-24 13:50 Colin Ian King
2022-10-27 3:20 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: Colin Ian King @ 2022-10-24 13:50 UTC (permalink / raw)
To: Santosh Shilimkar, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, netdev, linux-rdma, rds-devel
Cc: kernel-janitors, linux-kernel
Variable total_copied is just being incremented and it's never used
anywhere else. The variable and the increment are redundant so
remove it.
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
net/rds/message.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/net/rds/message.c b/net/rds/message.c
index 44dbc612ef54..b47e4f0a1639 100644
--- a/net/rds/message.c
+++ b/net/rds/message.c
@@ -366,7 +366,6 @@ static int rds_message_zcopy_from_user(struct rds_message *rm, struct iov_iter *
struct scatterlist *sg;
int ret = 0;
int length = iov_iter_count(from);
- int total_copied = 0;
struct rds_msg_zcopy_info *info;
rm->m_inc.i_hdr.h_len = cpu_to_be32(iov_iter_count(from));
@@ -404,7 +403,6 @@ static int rds_message_zcopy_from_user(struct rds_message *rm, struct iov_iter *
ret = -EFAULT;
goto err;
}
- total_copied += copied;
length -= copied;
sg_set_page(sg, pages, copied, start);
rm->data.op_nents++;
--
2.37.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] net/rds: remove variable total_copied
2022-10-24 13:50 [PATCH] net/rds: remove variable total_copied Colin Ian King
@ 2022-10-27 3:20 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-10-27 3:20 UTC (permalink / raw)
To: Colin Ian King
Cc: santosh.shilimkar, davem, edumazet, kuba, pabeni, netdev,
linux-rdma, rds-devel, kernel-janitors, linux-kernel
Hello:
This patch was applied to netdev/net-next.git (master)
by Jakub Kicinski <kuba@kernel.org>:
On Mon, 24 Oct 2022 14:50:46 +0100 you wrote:
> Variable total_copied is just being incremented and it's never used
> anywhere else. The variable and the increment are redundant so
> remove it.
>
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
> ---
> net/rds/message.c | 2 --
> 1 file changed, 2 deletions(-)
Here is the summary with links:
- net/rds: remove variable total_copied
https://git.kernel.org/netdev/net-next/c/b65ef50e0647
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-10-27 3:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-24 13:50 [PATCH] net/rds: remove variable total_copied Colin Ian King
2022-10-27 3:20 ` patchwork-bot+netdevbpf
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).