DPDK patches and discussions
 help / color / mirror / Atom feed
From: wangyunjian <wangyunjian@huawei.com>
To: Suanming Mou <suanmingm@nvidia.com>, "dev@dpdk.org" <dev@dpdk.org>
Cc: "matan@mellanox.com" <matan@mellanox.com>,
	"shahafs@mellanox.com" <shahafs@mellanox.com>,
	"viacheslavo@mellanox.com" <viacheslavo@mellanox.com>,
	"Lilijun (Jerry)" <jerry.lilijun@huawei.com>,
	xudingke <xudingke@huawei.com>
Subject: Re: [dpdk-dev] [PATCH] net/mlx5: remove unnecessary NULL check
Date: Wed, 18 Nov 2020 02:41:37 +0000	[thread overview]
Message-ID: <34EFBCA9F01B0748BEB6B629CE643AE60DB1CC3B@dggemm513-mbx.china.huawei.com> (raw)
In-Reply-To: <2b575415-7f73-d1d9-6b47-3008651b8c77@nvidia.com>

OK, please reject this patch.

Thanks,
Yunjian

> -----Original Message-----
> From: Suanming Mou [mailto:suanmingm@nvidia.com]
> Sent: Wednesday, November 18, 2020 10:16 AM
> To: wangyunjian <wangyunjian@huawei.com>; dev@dpdk.org
> Cc: matan@mellanox.com; shahafs@mellanox.com;
> viacheslavo@mellanox.com; Lilijun (Jerry) <jerry.lilijun@huawei.com>; xudingke
> <xudingke@huawei.com>
> Subject: Re: [dpdk-dev] [PATCH] net/mlx5: remove unnecessary NULL check
> 
> Hi Yunjian,
> 
> As the code changed, I think this patch is not needed anymore.
> 
> Thanks,
> SuanmingMou
> 
> On 3/31/2020 6:24 PM, wangyunjian wrote:
> > From: Yunjian Wang <wangyunjian@huawei.com>
> >
> > This NULL check is unnecessary, container_of is never NULL.
> >
> > Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
> > ---
> >   drivers/net/mlx5/mlx5.c | 3 ---
> >   1 file changed, 3 deletions(-)
> >
> > diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c index
> > 94aaa6057..2e4edb123 100644
> > --- a/drivers/net/mlx5/mlx5.c
> > +++ b/drivers/net/mlx5/mlx5.c
> > @@ -747,7 +747,6 @@ mlx5_free_table_hash_list(struct mlx5_priv *priv)
> >   	if (pos) {
> >   		tbl_data = container_of(pos, struct mlx5_flow_tbl_data_entry,
> >   					entry);
> > -		MLX5_ASSERT(tbl_data);
> >   		mlx5_hlist_remove(sh->flow_tbls, pos);
> >   		rte_free(tbl_data);
> >   	}
> > @@ -756,7 +755,6 @@ mlx5_free_table_hash_list(struct mlx5_priv *priv)
> >   	if (pos) {
> >   		tbl_data = container_of(pos, struct mlx5_flow_tbl_data_entry,
> >   					entry);
> > -		MLX5_ASSERT(tbl_data);
> >   		mlx5_hlist_remove(sh->flow_tbls, pos);
> >   		rte_free(tbl_data);
> >   	}
> > @@ -766,7 +764,6 @@ mlx5_free_table_hash_list(struct mlx5_priv *priv)
> >   	if (pos) {
> >   		tbl_data = container_of(pos, struct mlx5_flow_tbl_data_entry,
> >   					entry);
> > -		MLX5_ASSERT(tbl_data);
> >   		mlx5_hlist_remove(sh->flow_tbls, pos);
> >   		rte_free(tbl_data);
> >   	}
> 


      reply	other threads:[~2020-11-18  2:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-31 10:24 wangyunjian
2020-03-31 10:53 ` Matan Azrad
2020-04-01 11:13   ` wangyunjian
2020-11-18  2:15 ` Suanming Mou
2020-11-18  2:41   ` wangyunjian [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=34EFBCA9F01B0748BEB6B629CE643AE60DB1CC3B@dggemm513-mbx.china.huawei.com \
    --to=wangyunjian@huawei.com \
    --cc=dev@dpdk.org \
    --cc=jerry.lilijun@huawei.com \
    --cc=matan@mellanox.com \
    --cc=shahafs@mellanox.com \
    --cc=suanmingm@nvidia.com \
    --cc=viacheslavo@mellanox.com \
    --cc=xudingke@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).