[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210107190707.6279d0ed@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date: Thu, 7 Jan 2021 19:07:07 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Saeed Mahameed <saeed@...nel.org>
Cc: "David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
Oz Shlomo <ozsh@...dia.com>,
Marcelo Ricardo Leitner <marcelo.leitner@...il.com>,
Roi Dayan <roid@...dia.com>, Paul Blakey <paulb@...dia.com>,
Saeed Mahameed <saeedm@...dia.com>
Subject: Re: [net 04/11] net/mlx5e: CT: Use per flow counter when CT flow
accounting is enabled
On Thu, 7 Jan 2021 12:28:38 -0800 Saeed Mahameed wrote:
> + int ret;
> +
> + counter = kzalloc(sizeof(*counter), GFP_KERNEL);
> + if (!counter)
> + return ERR_PTR(-ENOMEM);
> +
> + counter->is_shared = false;
> + counter->counter = mlx5_fc_create(ct_priv->dev, true);
> + if (IS_ERR(counter->counter)) {
> + ct_dbg("Failed to create counter for ct entry");
> + ret = PTR_ERR(counter->counter);
> + kfree(counter);
> + return ERR_PTR(ret);
The err ptr -> ret -> err ptr conversion seems entirely pointless, no?
Powered by blists - more mailing lists