Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-06 Thread Saeed Mahameed
On Tue, 2019-08-06 at 13:48 -0700, David Miller wrote: > From: Saeed Mahameed > Date: Tue, 6 Aug 2019 20:42:56 + > > > On Sat, 2019-08-03 at 00:48 +0800, Chuhong Yuan wrote: > > > refcount_t is better for reference counters since its > > > implementation can prevent overflows. > > > So conver

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-06 Thread David Miller
From: Saeed Mahameed Date: Tue, 6 Aug 2019 20:42:56 + > On Sat, 2019-08-03 at 00:48 +0800, Chuhong Yuan wrote: >> refcount_t is better for reference counters since its >> implementation can prevent overflows. >> So convert atomic_t ref counters to refcount_t. >> >> Signed-off-by: Chuhong Yua

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-06 Thread Saeed Mahameed
On Sat, 2019-08-03 at 00:48 +0800, Chuhong Yuan wrote: > refcount_t is better for reference counters since its > implementation can prevent overflows. > So convert atomic_t ref counters to refcount_t. > > Signed-off-by: Chuhong Yuan > --- > Changes in v2: > - Add #include. > Acked-by: Saeed M

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-06 Thread Saeed Mahameed
On Tue, 2019-08-06 at 15:38 -0300, Jason Gunthorpe wrote: > On Tue, Aug 06, 2019 at 09:59:58AM +0300, Leon Romanovsky wrote: > > On Mon, Aug 05, 2019 at 08:06:36PM +, Saeed Mahameed wrote: > > > On Mon, 2019-08-05 at 14:55 +0800, Chuhong Yuan wrote: > > > > On Mon, Aug 5, 2019 at 2:13 PM Leon R

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-06 Thread Jason Gunthorpe
On Tue, Aug 06, 2019 at 09:59:58AM +0300, Leon Romanovsky wrote: > On Mon, Aug 05, 2019 at 08:06:36PM +, Saeed Mahameed wrote: > > On Mon, 2019-08-05 at 14:55 +0800, Chuhong Yuan wrote: > > > On Mon, Aug 5, 2019 at 2:13 PM Leon Romanovsky > > > wrote: > > > > On Sun, Aug 04, 2019 at 10:44:47PM

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-06 Thread Leon Romanovsky
On Mon, Aug 05, 2019 at 08:06:36PM +, Saeed Mahameed wrote: > On Mon, 2019-08-05 at 14:55 +0800, Chuhong Yuan wrote: > > On Mon, Aug 5, 2019 at 2:13 PM Leon Romanovsky > > wrote: > > > On Sun, Aug 04, 2019 at 10:44:47PM +0800, Chuhong Yuan wrote: > > > > On Sun, Aug 4, 2019 at 8:59 PM Leon Rom

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-05 Thread Saeed Mahameed
On Mon, 2019-08-05 at 14:55 +0800, Chuhong Yuan wrote: > On Mon, Aug 5, 2019 at 2:13 PM Leon Romanovsky > wrote: > > On Sun, Aug 04, 2019 at 10:44:47PM +0800, Chuhong Yuan wrote: > > > On Sun, Aug 4, 2019 at 8:59 PM Leon Romanovsky > > > wrote: > > > > On Sat, Aug 03, 2019 at 12:48:28AM +0800, Ch

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-04 Thread Chuhong Yuan
On Mon, Aug 5, 2019 at 2:13 PM Leon Romanovsky wrote: > > On Sun, Aug 04, 2019 at 10:44:47PM +0800, Chuhong Yuan wrote: > > On Sun, Aug 4, 2019 at 8:59 PM Leon Romanovsky wrote: > > > > > > On Sat, Aug 03, 2019 at 12:48:28AM +0800, Chuhong Yuan wrote: > > > > refcount_t is better for reference co

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-04 Thread Leon Romanovsky
On Sun, Aug 04, 2019 at 10:44:47PM +0800, Chuhong Yuan wrote: > On Sun, Aug 4, 2019 at 8:59 PM Leon Romanovsky wrote: > > > > On Sat, Aug 03, 2019 at 12:48:28AM +0800, Chuhong Yuan wrote: > > > refcount_t is better for reference counters since its > > > implementation can prevent overflows. > > >

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-04 Thread Chuhong Yuan
On Sun, Aug 4, 2019 at 8:59 PM Leon Romanovsky wrote: > > On Sat, Aug 03, 2019 at 12:48:28AM +0800, Chuhong Yuan wrote: > > refcount_t is better for reference counters since its > > implementation can prevent overflows. > > So convert atomic_t ref counters to refcount_t. > > I'm not thrilled to se

Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-04 Thread Leon Romanovsky
On Sat, Aug 03, 2019 at 12:48:28AM +0800, Chuhong Yuan wrote: > refcount_t is better for reference counters since its > implementation can prevent overflows. > So convert atomic_t ref counters to refcount_t. I'm not thrilled to see those automatic conversion patches, especially for flows which can

[PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-02 Thread Chuhong Yuan
refcount_t is better for reference counters since its implementation can prevent overflows. So convert atomic_t ref counters to refcount_t. Signed-off-by: Chuhong Yuan --- Changes in v2: - Add #include. drivers/net/ethernet/mellanox/mlx5/core/lib/vxlan.c | 9 + 1 file changed, 5 inser