DragonFly commits List (threaded) for 2008-04
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
Re: HEADS UP on HEAD - PF ABI changes - Re: cvs commit: src/usr.sbin/pfctl parse.y pf.conf.5 pfctl_parser.c src/sys/net/pf pf.c pfvar.h
:Wait ... you might want to consider to store the hash in the state instead
:of calculating it over and over again:
:
:i.e.
: if (s) {
: m->m_pkthdr.fw_flags |= ALTQ_MBUF_STATE_HASHED;
:- m->m_pkthdr.altq_state_hash = pf_state_hash(s);
:+ m->m_pkthdr.altq_state_hash = s->hash;
: }
:
:and calculate the hash on state creation.
:
:The hash operation is not exactly expensive, but still. I think this
:would be space well spent. Unless there is some padding in your pf state
:this will result in another ABI change. OpenBSD recently separated the
:in-kernel state entry from the information used for pfsync and userland
:copys, this is a good idea.
:
:--
:/"\ Best regards, | mlaier@freebsd.org
:\ / Max Laier | ICQ #67774661
You are absolutely correct. I will make that change.
-Matt
Matthew Dillon
<dillon@backplane.com>
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]