>Number:         165444
>Category:       kern
>Synopsis:       [netisr] [patch] incorrect processing of net.isr.bindthreads=0
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Feb 24 11:10:04 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Eugene Grosbein
>Release:        FreeBSD 8.2-STABLE i386
>Organization:
RDTC JSC
>Environment:
System: FreeBSD eg.sd.rdtc.ru 8.2-STABLE FreeBSD 8.2-STABLE #37: Wed Feb 15 
14:22:03 NOVT 2012 [email protected]:/usr/local/obj/usr/local/src/sys/EG i386

>Description:

        I've tried to use loader tunnable 'net.isr.bindthreads=0'
        for 4-core router. Sometimes each of 4 NETISR kernel threads get
        full cpu mask 0,1,2,3 but sometimes some NETISR threads get bound
        to CPU3 only.

        See also:
http://lists.freebsd.org/pipermail/freebsd-hackers/2012-January/037597.html

>How-To-Repeat:

        See above. The effect is random.

>Fix:

        To ensure correct processing of tunnable, small correction is needed,
        something like this:

--- sys/net/netisr.c.orig       2012-02-24 17:45:37.000000000 +0700
+++ sys/net/netisr.c    2012-02-24 17:47:52.000000000 +0700
@@ -980,12 +980,10 @@
        if (error)
                panic("%s: swi_add %d", __func__, error);
        pc->pc_netisr = nwsp->nws_intr_event;
-       if (netisr_bindthreads) {
-               error = intr_event_bind(nwsp->nws_intr_event, cpuid);
+               error = intr_event_bind(nwsp->nws_intr_event, 
netisr_bindthreads ? cpuid : NOCPU);
                if (error != 0)
                        printf("%s: cpu %u: intr_event_bind: %d", __func__,
                            cpuid, error);
-       }
        NETISR_WLOCK();
        nws_array[nws_count] = nwsp->nws_cpu;
        nws_count++;


>Release-Note:
>Audit-Trail:
>Unformatted:
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-bugs
To unsubscribe, send any mail to "[email protected]"

Reply via email to