From owner-svn-src-all@freebsd.org Wed Oct 10 21:28:05 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 582B510BCB02; Wed, 10 Oct 2018 21:28:05 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id F3AE772587; Wed, 10 Oct 2018 21:28:04 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id DF3B4267B6; Wed, 10 Oct 2018 21:28:04 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w9ALS4RS088783; Wed, 10 Oct 2018 21:28:04 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w9ALS470088782; Wed, 10 Oct 2018 21:28:04 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201810102128.w9ALS470088782@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Wed, 10 Oct 2018 21:28:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r339293 - stable/11/sys/net X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: stable/11/sys/net X-SVN-Commit-Revision: 339293 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Oct 2018 21:28:05 -0000 Author: jhb Date: Wed Oct 10 21:28:04 2018 New Revision: 339293 URL: https://svnweb.freebsd.org/changeset/base/339293 Log: Disable the KASSERT for curcpu == 0 in netisr for EARLY_AP_STARTUP. In the EARLY_AP_STARTUP case, thread0 can migrate to another CPU before this SYSINIT is run. However, the only part of this SYSINIT that assumes it runs on CPU 0 is in the !EARLY_AP_STARTUP case when it creates the netisr for the boot CPU. In the EARLY_AP_STARTUP case we start up the netisr's for the first N CPUs during the SYSINIT itself and don't depend on running on the boot CPU for correct operation. This is a direct comit to stable/11 as the assertion was removed as part of a different change in r302595. Reported by: rwatson, truckman, jkim, FreeNAS bug 45611 Modified: stable/11/sys/net/netisr.c Modified: stable/11/sys/net/netisr.c ============================================================================== --- stable/11/sys/net/netisr.c Wed Oct 10 20:25:41 2018 (r339292) +++ stable/11/sys/net/netisr.c Wed Oct 10 21:28:04 2018 (r339293) @@ -1272,8 +1272,6 @@ netisr_init(void *arg) struct pcpu *pc; #endif - KASSERT(curcpu == 0, ("%s: not on CPU 0", __func__)); - NETISR_LOCK_INIT(); if (netisr_maxthreads == 0 || netisr_maxthreads < -1 ) netisr_maxthreads = 1; /* default behavior */ @@ -1310,6 +1308,7 @@ netisr_init(void *arg) netisr_start_swi(pc->pc_cpuid, pc); } #else + KASSERT(curcpu == 0, ("%s: not on CPU 0", __func__)); netisr_start_swi(curcpu, pcpu_find(curcpu)); #endif }