:Please nuke the old patch I sent to you on IRC and test following one: :http://leaf.dragonflybsd.org/~sephe/sendfile.diff1 : :Best Regards, :sephe
FreeBSD has a cute atomic_fetchadd_int() function that can also be
used. It is in /archive/FreeBSD-current/src/sys/i386/include/atomic.h.
Instead of:
serialize_enter
subtract_int...
serialize_exit
You would do:
if (atomic_fetchadd_int(&sfm->mref_count, -1) == 1) {
... last ref went away ...
}
-Matt
Matthew Dillon
<[EMAIL PROTECTED]>
