RE: [PATCH] net: convert sk_filter.refcnt from atomic_t to refcount_t

2017-03-21 Thread Reshetova, Elena
> On 03/20/2017 10:37 AM, Elena Reshetova wrote: > [...] > > diff --git a/net/core/filter.c b/net/core/filter.c > > index ebaeaf2..389cb8d 100644 > > --- a/net/core/filter.c > > +++ b/net/core/filter.c > > @@ -928,7 +928,7 @@ static void sk_filter_release_rcu(struct rcu_head *rcu) > >*/ > >

Re: [PATCH] net: convert sk_filter.refcnt from atomic_t to refcount_t

2017-03-20 Thread Daniel Borkmann
On 03/20/2017 10:37 AM, Elena Reshetova wrote: [...] diff --git a/net/core/filter.c b/net/core/filter.c index ebaeaf2..389cb8d 100644 --- a/net/core/filter.c +++ b/net/core/filter.c @@ -928,7 +928,7 @@ static void sk_filter_release_rcu(struct rcu_head *rcu) */ static void

RE: [PATCH] net: convert sk_filter.refcnt from atomic_t to refcount_t

2017-03-20 Thread Reshetova, Elena
> Hello! > > On 3/18/2017 3:58 PM, Elena Reshetova wrote: > > > refcount_t type and corresponding API should be > > used instead of atomic_t when the variable is used as > > a reference counter. This allows to avoid accidental > > refcounter overflows that might lead to use-after-free > >

[PATCH] net: convert sk_filter.refcnt from atomic_t to refcount_t

2017-03-20 Thread Elena Reshetova
refcount_t type and corresponding API should be used instead of atomic_t when the variable is used as a reference counter. This allows to avoid accidental refcounter overflows that might lead to use-after-free situations. Signed-off-by: Elena Reshetova Signed-off-by:

Re: [PATCH] net: convert sk_filter.refcnt from atomic_t to refcount_t

2017-03-18 Thread Sergei Shtylyov
Hello! On 3/18/2017 3:58 PM, Elena Reshetova wrote: refcount_t type and corresponding API should be used instead of atomic_t when the variable is used as a reference counter. This allows to avoid accidental refcounter overflows that might lead to use-after-free situations. Signed-off-by:

[PATCH] net: convert sk_filter.refcnt from atomic_t to refcount_t

2017-03-18 Thread Elena Reshetova
refcount_t type and corresponding API should be used instead of atomic_t when the variable is used as a reference counter. This allows to avoid accidental refcounter overflows that might lead to use-after-free situations. Signed-off-by: Elena Reshetova Signed-off-by: