From nobody Fri Jul 29 18:47:20 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 4Lvc2K6VCwz4Y1X1; Fri, 29 Jul 2022 18:47:21 +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 4Lvc2J5Cdlz3nx4; Fri, 29 Jul 2022 18:47:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659120440; 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=MSI9kxNOpjit6aZTgGrpw0o3UXOW6aYuOiOQT/psQUE=; b=R15GzzVKFf0xtYKKwh0ez06tBMBwKsVFvb8ot9GrngaE40roqSX3tMLFl470PVUs3hOp1z 7HG1DaRFgKZvCDpPSqNqKQLiMmd/Bx10m0SK7mmvv804OZNgdvc0ZAUGyUNNVpPHYnuAT8 iBdvOvRucH3VFPUYOOamnyAkSk4CLWSgNK3sz4IZz5jwFzA58909NqbpPdEosd0M8olgYz hm4MKfYFISDXVgylivvKvcSEJ2qzkkH1E8FX/9bzXmBmUA0e4Wk+pJoPi8NyjYBcdOfhw/ MGZW2t8hhK5cYpK0+gMvkBK6ZnBJRgmY9gzzAcnFHvZ7nehkoyEGB7CEGfEPwg== 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 4Lvc2J42sYzm9y; Fri, 29 Jul 2022 18:47:20 +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 26TIlK8a023965; Fri, 29 Jul 2022 18:47:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 26TIlKaZ023964; Fri, 29 Jul 2022 18:47:20 GMT (envelope-from git) Date: Fri, 29 Jul 2022 18:47:20 GMT Message-Id: <202207291847.26TIlKaZ023964@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: 4263f9186b4b - stable/13 - Fix unused variable warning in xen's blkback.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/13 X-Git-Reftype: branch X-Git-Commit: 4263f9186b4b1095000507418c82a13375f913cc Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659120440; 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=MSI9kxNOpjit6aZTgGrpw0o3UXOW6aYuOiOQT/psQUE=; b=DEOADvxjWvDOot1yPqkCRTKplOd3Cw8CYXX183iKRGZsk0myACZ2oS2+avr92qw8opJgvk iB57hATgznczPg8u9ub4lWEvy1pn7wrVvXXBrmYxfby+GI120LBJwF8+QxgimBdhzEHubO jJHNm4YKIsKyqL6/ZM6/FB+pgQCqxoi3NXWysnxxc/r3oWnXJ1/sNDX/iXE0LJY5YGefIY cgwEdpuSbvgx+cYS7xs+zPah9tqqpF+9VRJ1qPQex+ZCljojU4Ik1i3HLBQ3jlY4LKAF9y AfzfHLnPUTsalDQzh0TB3QSQRVTpVhjvsW/Eu9P71pTqjeeKMDYypljixA+epQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1659120440; a=rsa-sha256; cv=none; b=lx02pEEzP3mgb/ZoLx4FTQubvgXoyituWDX3zEyrXSUbuyQ9rvxFtjxTV8TMBBoXSzehse mySEWljFTUiHp9K9ECrXGR4tjmLOPvV2omD5vFRPg855hM6P7Wym1jYXagbhnq6Mwv5DBL vxsmuulO4Bn7LkHlgzHrYhEr1D+C/iszs333LDUQqF77MBgN4lu/QTE80/rR3s1AChWDrX Ym4KMR6qC4xl/+eKDGxjp2y62YiNUbrO09AKwhsVTysbGRiTcyAhcw0jZ3/38BLssSzKP0 okwqCl77OHh2P3gfEEo40ydfN5fXzPCqlluoIq95fimwHWpIsAx0U96r3pAPsA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=4263f9186b4b1095000507418c82a13375f913cc commit 4263f9186b4b1095000507418c82a13375f913cc Author: Dimitry Andric AuthorDate: 2022-07-26 12:02:36 +0000 Commit: Dimitry Andric CommitDate: 2022-07-29 18:29:03 +0000 Fix unused variable warning in xen's blkback.c With clang 15, the following -Werror warning is produced: sys/dev/xen/blkback/blkback.c:1561:12: error: variable 'req_seg_idx' set but not used [-Werror,-Wunused-but-set-variable] u_int req_seg_idx; ^ The 'req_seg_idx' variable was used in the for loop later in the xbb_dispatch_io() function, but refactoring in 112cacaee408 got rid of it. Remove the variable since it no longer serves any purpose. MFC after: 3 days (cherry picked from commit 39e12a7591bf2ed4b2fae48e19f3af3a3cdcb196) --- sys/dev/xen/blkback/blkback.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/sys/dev/xen/blkback/blkback.c b/sys/dev/xen/blkback/blkback.c index 010e737740b8..ca6670be0516 100644 --- a/sys/dev/xen/blkback/blkback.c +++ b/sys/dev/xen/blkback/blkback.c @@ -1646,7 +1646,6 @@ xbb_dispatch_io(struct xbb_softc *xbb, struct xbb_xen_reqlist *reqlist) STAILQ_FOREACH(nreq, &reqlist->contig_req_list, links) { blkif_request_t *ring_req; RING_IDX req_ring_idx; - u_int req_seg_idx; ring_req = nreq->ring_req; req_ring_idx = nreq->req_ring_idx; @@ -1654,7 +1653,6 @@ xbb_dispatch_io(struct xbb_softc *xbb, struct xbb_xen_reqlist *reqlist) nseg = ring_req->nr_segments; nreq->nr_pages = nseg; nreq->nr_512b_sectors = 0; - req_seg_idx = 0; sg = NULL; /* Check that number of segments is sane. */ @@ -1708,7 +1706,6 @@ xbb_dispatch_io(struct xbb_softc *xbb, struct xbb_xen_reqlist *reqlist) map++; xbb_sg++; seg_idx++; - req_seg_idx++; } /* Convert to the disk's sector size */