From nobody Sun Jul 24 11:02:28 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4LrKyF0Prvz4XXQ8; Sun, 24 Jul 2022 11:02:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4LrKyD6nGNz3dcB; Sun, 24 Jul 2022 11:02:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658660549; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=X9Mmk17i4DMKHELzTnQkn28aSy3v69ZOeiy3MYNAgBY=; b=CMivWb3Mkc7NA3Z+V37KZz7erSrSlYOiaUIa2L8u+a1aC2e5kkINyGADhDu8wuENKvRLAh 4AiN0kEQ1n1/Kh2p496l8vgTgEi33/T62FqZpe07eZwo390PRtLWqfrkE4NIYSyTHd0Eva LYHnTx0PPDnRnzbLWyJXIkaj+ZESTIzU+n3m2ukMudu4b5vbs+JPY9o1gOnF/OBTjGUtpm tAiUcFz1SJqk0Qb31IDGZN6x529H2g9ZT4EazWmMTHTBp5H0LwOKaaPOKhuSJPhxW1Cd9A RcD71cmu7WyU30Q9dpfgiDin686Oni6AFiNGG9K72tlMfFkgbxcyH1KabfvRRg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4LrKyD5pBNzGqy; Sun, 24 Jul 2022 11:02:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 26OB2Srr041591; Sun, 24 Jul 2022 11:02:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 26OB2Stk041589; Sun, 24 Jul 2022 11:02:28 GMT (envelope-from git) Date: Sun, 24 Jul 2022 11:02:28 GMT Message-Id: <202207241102.26OB2Stk041589@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dimitry Andric Subject: git: 459bc065e29b - stable/12 - Fix unused variable warning in if_lagg.c List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dim X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 459bc065e29bed81bb2e8454252aaeb5792e49d2 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658660549; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=X9Mmk17i4DMKHELzTnQkn28aSy3v69ZOeiy3MYNAgBY=; b=pSPVq/SyI9QwgIderNrtKomKx3P7JRUCD+enQMKYkejF4i7i4vlTOAhJK6fSHH8AYQFG8a 0Sgd8KtG50No0JuiOB2KW0+GPOSG4aLuy9EWSINvdN0aKgv7aSpMF/6ASQR3Qj7oowMAUZ jTmQ8YgTMbEWxpqbxdtfj00Kkv3qGH/YC7O4B9y5NLf+QqFKSF+uFnh1rZfKzNRVg/Bsk/ JaZvTh6sraFNYKYDxeliQB3ZgUBq5RjFTyQ+44uejoi2lHFoTwzS712QB/1yORDr1G/5xG F2IelDGiXiy9DDe+XPh3haJwtjVNqvLjjyOJYW8dlH4YrvPd36JxPXzaLwdp6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1658660549; a=rsa-sha256; cv=none; b=LbBWxmfiqTAvT7OkQC7AKSFZGKtBhfLf0bb87lOaAiGMIMDNjumYeg2TnMy+HHgKDUV2z+ c/2zOdnW9iTg98hB4svpWwiRdUmB7jcw6tNx+u6k6b95oa0AkXK7xxycFfEoPfhBlZNF23 iyPYEytQGXo3VUSfKaxslbpweWfMD4vhOfOBzGfQGwZY94z8hPrggQSjATWtb7Bn16R02H m4Hyc4AUXrnsqLroinWvH9S4662jHRdIxoRmy4spOrhC9Avg4CVZL9nq/jOkkuoeC3adbf agICayn3n3ozQb/pyUcCLBjfrFKQpzhh2VzQVh0do3eJnkVY6LHKt3dum1JiHA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/12 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=459bc065e29bed81bb2e8454252aaeb5792e49d2 commit 459bc065e29bed81bb2e8454252aaeb5792e49d2 Author: Dimitry Andric AuthorDate: 2022-07-21 18:51:23 +0000 Commit: Dimitry Andric CommitDate: 2022-07-24 11:01:21 +0000 Fix unused variable warning in if_lagg.c With clang 15, the following -Werror warning is produced: sys/net/if_lagg.c:2413:6: error: variable 'active_ports' set but not used [-Werror,-Wunused-but-set-variable] int active_ports = 0; ^ The 'active_ports' variable appears to have been a debugging aid that has never been used for anything (ref https://reviews.freebsd.org/D549), so remove it. MFC after: 3 days (cherry picked from commit fa267a329ffa3d0e02c3c3a52dd5df5231d92cba) --- sys/net/if_lagg.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/sys/net/if_lagg.c b/sys/net/if_lagg.c index 57c56604e65e..6b342167e8e1 100644 --- a/sys/net/if_lagg.c +++ b/sys/net/if_lagg.c @@ -2189,7 +2189,6 @@ lagg_rr_input(struct lagg_softc *sc, struct lagg_port *lp, struct mbuf *m) static int lagg_bcast_start(struct lagg_softc *sc, struct mbuf *m) { - int active_ports = 0; int errors = 0; int ret; struct lagg_port *lp, *last = NULL; @@ -2200,8 +2199,6 @@ lagg_bcast_start(struct lagg_softc *sc, struct mbuf *m) if (!LAGG_PORTACTIVE(lp)) continue; - active_ports++; - if (last != NULL) { m0 = m_copym(m, 0, M_COPYALL, M_NOWAIT); if (m0 == NULL) {