From owner-svn-src-all@freebsd.org Mon Mar 12 17:05:55 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 D968DF2C20B; Mon, 12 Mar 2018 17:05:54 +0000 (UTC) (envelope-from tsoome@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 82946864ED; Mon, 12 Mar 2018 17:05:54 +0000 (UTC) (envelope-from tsoome@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 796D46884; Mon, 12 Mar 2018 17:05:54 +0000 (UTC) (envelope-from tsoome@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w2CH5sZq093240; Mon, 12 Mar 2018 17:05:54 GMT (envelope-from tsoome@FreeBSD.org) Received: (from tsoome@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w2CH5r0v093236; Mon, 12 Mar 2018 17:05:53 GMT (envelope-from tsoome@FreeBSD.org) Message-Id: <201803121705.w2CH5r0v093236@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tsoome set sender to tsoome@FreeBSD.org using -f From: Toomas Soome Date: Mon, 12 Mar 2018 17:05:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r330803 - head/sys/dev/e1000 X-SVN-Group: head X-SVN-Commit-Author: tsoome X-SVN-Commit-Paths: head/sys/dev/e1000 X-SVN-Commit-Revision: 330803 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.25 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: Mon, 12 Mar 2018 17:05:55 -0000 Author: tsoome Date: Mon Mar 12 17:05:53 2018 New Revision: 330803 URL: https://svnweb.freebsd.org/changeset/base/330803 Log: e1000g: this statement may fall through The gcc 7 does check for switch statement fall through cases, and if legit, such complaint can besilenced by /* FALLTHROUGH */ comment. Unfortunately such comment is quite limited, but will still notify the reader. This patch is backport from illumos, see https://www.illumos.org/rb/r/941/ Reviewed by: eadler Differential Revision: https://reviews.freebsd.org/D14663 Modified: head/sys/dev/e1000/e1000_82575.c head/sys/dev/e1000/e1000_mbx.c head/sys/dev/e1000/e1000_phy.c head/sys/dev/e1000/e1000_vf.c Modified: head/sys/dev/e1000/e1000_82575.c ============================================================================== --- head/sys/dev/e1000/e1000_82575.c Mon Mar 12 16:31:25 2018 (r330802) +++ head/sys/dev/e1000/e1000_82575.c Mon Mar 12 17:05:53 2018 (r330803) @@ -1679,7 +1679,7 @@ static s32 e1000_setup_serdes_link_82575(struct e1000_ case E1000_CTRL_EXT_LINK_MODE_1000BASE_KX: /* disable PCS autoneg and support parallel detect only */ pcs_autoneg = FALSE; - /* fall through to default case */ + /* FALLTHROUGH */ default: if (hw->mac.type == e1000_82575 || hw->mac.type == e1000_82576) { @@ -1806,6 +1806,7 @@ static s32 e1000_get_media_type_82575(struct e1000_hw break; } /* fall through for I2C based SGMII */ + /* FALLTHROUGH */ case E1000_CTRL_EXT_LINK_MODE_PCIE_SERDES: /* read media type from SFP EEPROM */ ret_val = e1000_set_sfp_media_type_82575(hw); Modified: head/sys/dev/e1000/e1000_mbx.c ============================================================================== --- head/sys/dev/e1000/e1000_mbx.c Mon Mar 12 16:31:25 2018 (r330802) +++ head/sys/dev/e1000/e1000_mbx.c Mon Mar 12 17:05:53 2018 (r330803) @@ -779,6 +779,7 @@ s32 e1000_init_mbx_params_pf(struct e1000_hw *hw) mbx->stats.reqs = 0; mbx->stats.acks = 0; mbx->stats.rsts = 0; + /* FALLTHROUGH */ default: return E1000_SUCCESS; } Modified: head/sys/dev/e1000/e1000_phy.c ============================================================================== --- head/sys/dev/e1000/e1000_phy.c Mon Mar 12 16:31:25 2018 (r330802) +++ head/sys/dev/e1000/e1000_phy.c Mon Mar 12 17:05:53 2018 (r330803) @@ -1298,6 +1298,7 @@ s32 e1000_copper_link_setup_m88_gen2(struct e1000_hw * phy_data |= M88E1000_PSCR_AUTO_X_1000T; break; } + /* FALLTHROUGH */ case 0: default: phy_data |= M88E1000_PSCR_AUTO_X_MODE; Modified: head/sys/dev/e1000/e1000_vf.c ============================================================================== --- head/sys/dev/e1000/e1000_vf.c Mon Mar 12 16:31:25 2018 (r330802) +++ head/sys/dev/e1000/e1000_vf.c Mon Mar 12 17:05:53 2018 (r330803) @@ -488,8 +488,10 @@ s32 e1000_promisc_set_vf(struct e1000_hw *hw, enum e10 break; case e1000_promisc_enabled: msgbuf |= E1000_VF_SET_PROMISC_MULTICAST; + /* FALLTHROUGH */ case e1000_promisc_unicast: msgbuf |= E1000_VF_SET_PROMISC_UNICAST; + /* FALLTHROUGH */ case e1000_promisc_disabled: break; default: