zdestroy() patch

Matthew Dillon dillon at apollo.backplane.com
Sun Jan 20 18:22:42 PST 2008


:Hello,
:
:I know that zalloc() is deprecated but here is anyway a patch that
:implements zdestroy() as suggested in:
:
:http://leaf.dragonflybsd.org/mailarchive/bugs/2008-01/msg00032.html
:
:This patch is not thread-safe and assumes that the mp lock is held
:while zalloc() and friends are called as stated in:
:
:http://leaf.dragonflybsd.org/mailarchive/kernel/2008-01/msg00045.html
:
:I'll commit it in a few days if there are no objections.
:
:Regarding zalloc() lack of thread safety, I see two options:

    Looks good.

    We shouldn't worry too much about thread safety.  Only the PV entry
    subsystem actually needs to use zalloc() these days.  All the other
    subsystems could easily be converted to using our OBJCACHE subsystem.

    I'm in no rush... it can be done as the SMP work dives into those
    subsystems.

						-Matt






More information about the Bugs mailing list