From owner-freebsd-net@FreeBSD.ORG Sun Dec 7 22:53:57 2014 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9AECD714 for ; Sun, 7 Dec 2014 22:53:57 +0000 (UTC) Received: from phabric-backend.isc.freebsd.org (phabric-backend.isc.freebsd.org [IPv6:2001:4f8:3:ffe0:406a:0:50:2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7A64EEC2 for ; Sun, 7 Dec 2014 22:53:57 +0000 (UTC) Received: from phabric-backend.isc.freebsd.org (phabric-backend.isc.freebsd.org [127.0.1.5]) by phabric-backend.isc.freebsd.org (8.14.9/8.14.9) with ESMTP id sB7Mruwd064416 for ; Sun, 7 Dec 2014 22:53:56 GMT (envelope-from root@phabric-backend.isc.freebsd.org) Received: (from root@localhost) by phabric-backend.isc.freebsd.org (8.14.9/8.14.9/Submit) id sB7MruJR064415; Sun, 7 Dec 2014 22:53:56 GMT (envelope-from root) Date: Sun, 7 Dec 2014 22:53:56 +0000 To: freebsd-net@freebsd.org From: "rodrigc (Craig Rodrigues)" Subject: [Differential] [Request, 4 lines] D1279: Fix crash when VIMAGE + Infiniband is compiled into the kernel Message-ID: X-Priority: 3 Thread-Topic: D1279: Fix crash when VIMAGE + Infiniband is compiled into the kernel X-Herald-Rules: none X-Phabricator-To: X-Phabricator-To: X-Phabricator-To: X-Phabricator-Cc: Thread-Index: NjUzMWY2ZDIwNmE4N2FiMTY0YWRjYTIxMjI3 X-Phabricator-Sent-This-Message: Yes X-Mail-Transport-Agent: MetaMTA X-Auto-Response-Suppress: All X-Phabricator-Mail-Tags: , , , MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="utf-8" X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Dec 2014 22:53:57 -0000 rodrigc created this revision. rodrigc added reviewers: bz, hselasky. rodrigc added a subscriber: freebsd-net. REVISION SUMMARY PR: 191468 Use CURVNET macros inside inet_get_local_port_range() function. Without this fix, a kernel with VIMAGE + Infiniband will panic on bootup. Certain necessary #include statements require LIST_HEAD. Add these includes to ofed/include/linux/list.h, because LIST_HEAD is specifically overridden in this file. TEST PLAN # Compile a kernel with the following kernel config: include GENERIC ident VIMAGE options VIMAGE options VNET_DEBUG # InfiniBand support options OFED # InfiniBand support options SDP # SDP protocol options IPOIB # IPoIB options IPOIB_CM # IPoIB connected mode # InfiniBand Adapters device mlx4ib device mlxen device mthca # bhyve kernel debug device bvmdebug # Boot it REVISION DETAIL https://reviews.freebsd.org/D1279 AFFECTED FILES sys/ofed/include/linux/list.h sys/ofed/include/net/ip.h To: rodrigc, bz, hselasky Cc: freebsd-net