[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <m24ommhks5.fsf@ssh.synack.fr>
Date: Sat, 16 Jan 2010 02:59:38 +0100
From: Samir Bellabes <sam@...ack.fr>
To: Patrick McHardy <kaber@...sh.net>
Cc: linux-security-module@...r.kernel.org, jamal <hadi@...erus.ca>,
Evgeniy Polyakov <zbr@...emap.net>,
Neil Horman <nhorman@...driver.com>, netdev@...r.kernel.org,
netfilter-devel@...r.kernel.org
Subject: Re: [RFC 7/9] snet: introduce snet_netlink.c and snet_netlink.h
Patrick McHardy <kaber@...sh.net> writes:
>> +atomic_t snet_num_listeners = ATOMIC_INIT(0);
>
> The num_listeners seem to be redundant as you only support a
> single listener anyways, whose presence is indicated by
> snet_nl_pid != 0.
I simplified the code, by removing the variable snet_num_listeners and
use the value of snet_nl_pid
* if snet_nl_pid == 0, then there is no userspace listening application
* if snet_nl_pid > 0, then its value is the PID of the listening
application
In the same time, I deleted the check on a listener for this operations
on verdict : snet_nl_version, snet_nl_insert, snet_nl_remove,
snet_nl_flush, snet_nl_verdict_delay.
In this way, it's possible to execute this operations and get events in
the same time (which means have a listeners)
Patrick, thanks again for reviewing
sam
--
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