Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 06 Dec 2012 15:56:02 +0400
From:      "Alexander V. Chernikov" <melifaro@FreeBSD.org>
To:        =?ISO-8859-1?Q?Ermal_Lu=E7i?= <eri@freebsd.org>
Cc:        freebsd-net <freebsd-net@freebsd.org>, freebsd-ipfw@freebsd.org
Subject:   Re: ipfw(4) dynamic states/rules and its callout
Message-ID:  <50C087D2.6020607@FreeBSD.org>
In-Reply-To: <CAPBZQG3T=Mvp80-mhFJJ5QRcv5+3SLwV__2bVgvP1YO=UFVOUA@mail.gmail.com>
References:  <CAPBZQG3T=Mvp80-mhFJJ5QRcv5+3SLwV__2bVgvP1YO=UFVOUA@mail.gmail.com>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On 06.12.2012 13:13, Ermal Luši wrote:
> Hello,
>
> i was looking at ipfw dynamic code for dynamic states/rules and see that it
> unconditionally schedules a callout even if there is not work to do.
>
> Wouldn't it be best to reschedule it when there is something to do to avoid
> having a useless
> callout/event run every time on the system?
>
> Is there any complication i am missing on it!
I thought about the same (and possibly not allocating dynamic hash at 
all if we have no dynamic rules) while rewriting dynamic code.
The main "problem" is to reliably determine if we have dynamic rules in 
our ruleset.

Rule checking probably can be done via adding additional argument to 
check_ipfw_struct(), however the rest can be a bit more complicated 
since we can delete more that one rule (or set with bunch of rules) at once.

>
> Regards,
> Ermal
> _______________________________________________
> freebsd-net@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"
>




Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?50C087D2.6020607>