Messages in this thread | | | From | Eric Dumazet <> | Date | Wed, 2 Nov 2022 14:53:42 -0700 | Subject | Re: [PATCH 2/2] net/tcp: Disable TCP-MD5 static key on tcp_md5sig_info destruction |
| |
On Wed, Nov 2, 2022 at 2:49 PM Eric Dumazet <edumazet@google.com> wrote:
> > Are you sure ? > > static_branch_inc() is what we want here, it is a nice wrapper around > the correct internal details, > and ultimately boils to an atomic_inc(). It is safe for all contexts. > > But if/when jump labels get refcount_t one day, we will not have to > change TCP stack because > it made some implementation assumptions.
Oh, I think I understand this better now.
Please provide a helper like
static inline void static_key_fast_inc(struct static_key *key) { atomic_inc(&key->enabled); }
Something like that.
| |