[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20210905153553.nmmgv7w3t3oeqtca@mobilestation>
Date: Sun, 5 Sep 2021 18:35:53 +0300
From: Serge Semin <fancer.lancer@...il.com>
To: Colin King <colin.king@...onical.com>
Cc: Serge Semin <Sergey.Semin@...kalelectronics.ru>,
Jon Mason <jdmason@...zu.us>,
Dave Jiang <dave.jiang@...el.com>, linux-ntb@...glegroups.com,
kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ntb: ntb_pingpong: remove redundant initialization of
variables msg_data and spad_data
On Wed, Jun 09, 2021 at 12:21:28PM +0100, Colin King wrote:
> From: Colin Ian King <colin.king@...onical.com>
>
> The variables msg_data and spad_data are being initialized with values
> that are never read, they are being updated later on. The initializations
> are redundant and can be removed.
>
> Addresses-Coverity: ("Unused value")
> Signed-off-by: Colin Ian King <colin.king@...onical.com>
> ---
> drivers/ntb/test/ntb_pingpong.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Wow, missed this in my emails log. Thanks for the cleanup.
Acked-by: Serge Semin <fancer.lancer@...il.com>
>
> diff --git a/drivers/ntb/test/ntb_pingpong.c b/drivers/ntb/test/ntb_pingpong.c
> index 2164e8492772..8aeca7914050 100644
> --- a/drivers/ntb/test/ntb_pingpong.c
> +++ b/drivers/ntb/test/ntb_pingpong.c
> @@ -187,7 +187,7 @@ static void pp_ping(struct pp_ctx *pp)
>
> static void pp_pong(struct pp_ctx *pp)
> {
> - u32 msg_data = -1, spad_data = -1;
> + u32 msg_data, spad_data;
> int pidx = 0;
>
> /* Read pong data */
> --
> 2.31.1
>
> --
> You received this message because you are subscribed to the Google Groups "linux-ntb" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to linux-ntb+unsubscribe@...glegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/linux-ntb/20210609112128.184667-1-colin.king%40canonical.com.
Powered by blists - more mailing lists