* Alfred Perlstein <[EMAIL PROTECTED]> [000823 14:29] wrote:
> I have a feeling that this is related to missing spl protection around
> the chgsbsize subsystem, this was probably an issue before I touched it
> but since I touched it last I'll have a look-see.
> Brian, does that makes sense?

So far, here's functions that look like they call chgsbsize without

socreate (called from socket() and socketpair(), on error calls
sofree() which then calls sodealloc() without splnet)

sonewconn3 (called from sonewconn which i'm unsure of the spl at
this point)

I'm sure there's more.

Does it make sense to wrap chgsbsize with spl so callers don't have
to worry about it?

John can you try this patch and let us know if you still experiance

Index: kern_proc.c
RCS file: /home/ncvs/src/sys/kern/kern_proc.c,v
retrieving revision 1.69
diff -u -u -r1.69 kern_proc.c
--- kern_proc.c 2000/07/04 11:25:22     1.69
+++ kern_proc.c 2000/08/23 21:49:49
@@ -196,6 +196,7 @@
        rlim_t  max;
        struct uidinfo *uip;
+       int     s = splnet();
        uip = uifind(uid);
        if (diff < 0)
@@ -205,10 +206,12 @@
        /* don't allow them to exceed max, but allow subtraction */
        if (diff > 0 && uip->ui_sbsize + diff > max) {
+               splx(s);
                return (0);
        uip->ui_sbsize += diff;
+       splx(s);
        return (1);

If this doesn't work then it may be nessesary to spl around examining
the socketbuffer's size.
"I have the heart of a child; I keep it in a jar on my desk."

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to