Re: [PATCH nf] x_tables: Properly close read section with read_seqcount_retry

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> > > +struct xt_table_info
> > > +*xt_table_get_private_protected(const struct xt_table *table)
> > > +{
> > > +	return rcu_dereference_protected(table->private,
> > > +					 mutex_is_locked(&xt[table->af].mutex));
> > > +}
> > > +EXPORT_SYMBOL(xt_table_get_private_protected);
> >
> > In all debug builds this function compiles to a single memory
>
> ! went missing... :/

? Not sure about "!".

!debug gets you a single deref, for debug builds do we get extra code.

Can you elaborate on this. I am not able to get the context here.
Are you referring to the definition of RCU_LOCKDEP_WARN.
RCU_LOCKDEP_WARN is a NOOP if CONFIG_PROVE_RCU is false.

#ifdef CONFIG_PROVE_RCU
#define RCU_LOCKDEP_WARN(c, s)						\
	do {								\
		static bool __section(.data.unlikely) __warned;		\
		if (debug_lockdep_rcu_enabled() && !__warned && (c)) {	\
			__warned = true;				\
			lockdep_rcu_suspicious(__FILE__, __LINE__, s);	\
		}							\
	} while (0)
...
#else /* #ifdef CONFIG_PROVE_RCU */

#define RCU_LOCKDEP_WARN(c, s) do { } while (0)



[Index of Archives]     [Netfitler Users]     [Berkeley Packet Filter]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux