lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080905034415.GB2789@x200.localdomain>
Date:	Fri, 5 Sep 2008 07:44:15 +0400
From:	Alexey Dobriyan <adobriyan@...il.com>
To:	Patrick McHardy <kaber@...sh.net>
Cc:	netfilter-devel@...r.kernel.org, netdev@...r.kernel.org,
	containers@...ts.linux-foundation.org
Subject: Re: [PATCH 21/25] netns ct: per-netns event cache

On Thu, Sep 04, 2008 at 06:58:38PM +0200, Patrick McHardy wrote:
> adobriyan@...il.com wrote:
>>  static inline void
>> -nf_conntrack_event_cache(enum ip_conntrack_events event,
>> +nf_conntrack_event_cache(struct net *net, enum ip_conntrack_events event,
>>  			 const struct sk_buff *skb)
>>  {
>
> Passing the conntrack instead of the struct net and the skb
> would probably keep the callers cleaner.

Dunno, passing netns explicitly like saying conntrack event happened in
netns A, which is reasonable. OTOH, s/skb/ct/ is indeed nicer.

I'll change it as you suggest and see what happens.

BTW, I asked earlier if untracked conntracks are ever supposed to drop into
event cache. If they're, trimming nf_conntrack_untracked is out of question.

>>  	struct nf_conn *ct = (struct nf_conn *)skb->nfct;
>>  	struct nf_conntrack_ecache *ecache;
>>   	local_bh_disable();
>> -	ecache = &__get_cpu_var(nf_conntrack_ecache);
>> +	ecache = per_cpu_ptr(net->ct.ecache, raw_smp_processor_id());
>>  	if (ct != ecache->ct)
>>  		__nf_ct_event_cache_init(ct);
>>  	ecache->events |= event;
>> @@ -60,16 +58,29 @@ nf_ct_expect_event(enum ip_conntrack_expect_events event,
>>  	atomic_notifier_call_chain(&nf_ct_expect_chain, event, exp);
>>  }
>>  

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ