[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <da09fbe5-17e6-bea4-80dd-be4a0394541e@intel.com>
Date: Tue, 11 Jul 2023 10:35:45 +0200
From: Przemek Kitszel <przemyslaw.kitszel@...el.com>
To: Su Hui <suhui@...china.com>, <jesse.brandeburg@...el.com>,
<anthony.l.nguyen@...el.com>, <davem@...emloft.net>, <edumazet@...gle.com>,
<kuba@...nel.org>, <pabeni@...hat.com>
CC: <netdev@...r.kernel.org>, <kernel-janitors@...r.kernel.org>,
<intel-wired-lan@...ts.osuosl.org>, <linux-kernel@...r.kernel.org>, wuych
<yunchuan@...china.com>
Subject: Re: [Intel-wired-lan] [PATCH net-next v2 06/10] ice: remove
unnecessary (void*) conversions
On 7/10/23 08:41, Su Hui wrote:
> From: wuych <yunchuan@...china.com>
>
> Pointer variables of void * type do not require type cast.
You should rather tell what are you doing here, perhaps:
Drop casts on dim->priv access, which is "void *".
>
> Signed-off-by: wuych <yunchuan@...china.com>
You have to provide your own Sign-off when sending patches of other devs.
Also, preferable format is "Name Surname <email>", not a nickname/corpo-id.
> ---
> drivers/net/ethernet/intel/ice/ice_main.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/net/ethernet/intel/ice/ice_main.c b/drivers/net/ethernet/intel/ice/ice_main.c
> index 93979ab18bc1..52af3bd80868 100644
> --- a/drivers/net/ethernet/intel/ice/ice_main.c
> +++ b/drivers/net/ethernet/intel/ice/ice_main.c
> @@ -6242,7 +6242,7 @@ static void ice_tx_dim_work(struct work_struct *work)
> u16 itr;
>
> dim = container_of(work, struct dim, work);
> - rc = (struct ice_ring_container *)dim->priv;
> + rc = dim->priv;
>
> WARN_ON(dim->profile_ix >= ARRAY_SIZE(tx_profile));
>
> @@ -6262,7 +6262,7 @@ static void ice_rx_dim_work(struct work_struct *work)
> u16 itr;
>
> dim = container_of(work, struct dim, work);
> - rc = (struct ice_ring_container *)dim->priv;
> + rc = dim->priv;
>
> WARN_ON(dim->profile_ix >= ARRAY_SIZE(rx_profile));
>
Code per-se looks ok
Powered by blists - more mailing lists