:The vn structure appears to NOT be corrupt.  Seems like a race if
:vn->sc_cred goes from NULL to non-NULL between frame 6 and 5.  Could
:this be related to my recent link_elf change (setting p to proc0 if p
:is NULL)?
:
:Joe

    Hmm.  If devfs is racing access to that field then try changing the
    vnsetcred() code around a bit to this:

        struct ucred *ocred
        ...


        /*
         * Set credits in our softc
         */
        ocred = vn->sc_cred;
        vn->sc_cred = crdup(cred);
        if (ocred)
                crfree(ocred);

    If the race is more involved then that (assuming it is a race), we
    may have to call crhold() and friends whenever we use vn->sc_cred.

                                        -Matt
                                        Matthew Dillon 
                                        <[email protected]>

Reply via email to