From nobody Wed Dec 15 13:46:21 2021 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 3543518E2DCA; Wed, 15 Dec 2021 13:46:22 +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 4JDc3K60KQz3nbF; Wed, 15 Dec 2021 13:46:21 +0000 (UTC) (envelope-from git@FreeBSD.org) 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 AEA651D3A9; Wed, 15 Dec 2021 13:46:21 +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 1BFDkLea083642; Wed, 15 Dec 2021 13:46:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1BFDkLGf083641; Wed, 15 Dec 2021 13:46:21 GMT (envelope-from git) Date: Wed, 15 Dec 2021 13:46:21 GMT Message-Id: <202112151346.1BFDkLGf083641@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mateusz Guzik Subject: git: e7236a7ddf37 - main - xen: plug some of set-but-not-used vars 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: mjg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e7236a7ddf37ffe330d323c7b6037230d10afee4 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1639575981; 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=T3GLLvMljmeVhxAoSeRdUxUnWHm/uuuMAV4D3f453yM=; b=Z18/HLo2qDRM9n5cC8HMj1b1SfcZUYDUIltT7cXQrD5e1EX9f7i4Nhalt8H6osA306q5OY jtvH71ml2MDJP4sc4IKiCuESWYVf+W5dmhuY1CVFbal8mrxmdt/ky4bAZEevxTohdoOkfg 8NODmG5BZ+kyZ4jGqnX+xRV6aqIrCRdZ5nR5GcM/6IJbF/3sJJNJq4zoZw0Ip7uF299s0w YteUAwvFM8GsC9+WXCJBnE0+q2jgxcoQe1i+f9c+eubDZYYlUKEP+xWmOMWKsCymxLrMiA WzfNgNPGiDvjMsmOW+HuKoDgDXkcRYEjBthKL1QL9I3ZYwLEjdLCSmqUwHoWow== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1639575981; a=rsa-sha256; cv=none; b=wwUD1+YjFYmFsZ5R2kZ2qegfrX5sR7f0cBP9cnENnd+Kg3CrhzgNx13kPotDTNw8lQPXjq qHWcH71SPb70j0LAn6cvLg7nrZkGRc658UnVLNpqlkAbyZJ/E4N8h/wEyVry70/mpduzbG j/GEXSclunW/TcL2OFIGdGaGSFFQi35F+W1KJrqGWhUKlDZTmn++3AzHdfCqlg9ZrTkkzc kpgFIJD04RjpKoXqksnB9juBYTyAz2Ymwybkt0NV2FYrTLneOrrfHOsFTww0NnUeC1jFoE C4QzA8taTbqkJRNr6w9DRiXegeqitMfmSkiggiqJJEwNJNpK53cWgVPzEaIn2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=e7236a7ddf37ffe330d323c7b6037230d10afee4 commit e7236a7ddf37ffe330d323c7b6037230d10afee4 Author: Mateusz Guzik AuthorDate: 2021-12-15 13:45:04 +0000 Commit: Mateusz Guzik CommitDate: 2021-12-15 13:46:17 +0000 xen: plug some of set-but-not-used vars Sponsored by: Rubicon Communications, LLC ("Netgate") --- sys/dev/xen/balloon/balloon.c | 4 ++-- sys/dev/xen/blkback/blkback.c | 4 +--- sys/dev/xen/console/xen_console.c | 2 +- sys/dev/xen/netback/netback.c | 2 +- sys/dev/xen/netfront/netfront.c | 4 +--- sys/dev/xen/privcmd/privcmd.c | 2 +- sys/dev/xen/xenstore/xenstore.c | 3 --- sys/x86/xen/pv.c | 3 --- sys/x86/xen/xen_intr.c | 2 +- 9 files changed, 8 insertions(+), 18 deletions(-) diff --git a/sys/dev/xen/balloon/balloon.c b/sys/dev/xen/balloon/balloon.c index 007fada24259..7e97fa144485 100644 --- a/sys/dev/xen/balloon/balloon.c +++ b/sys/dev/xen/balloon/balloon.c @@ -177,7 +177,7 @@ increase_reservation(unsigned long nr_pages) XENMEM_populate_physmap, &reservation); if (rc < nr_pages) { if (rc > 0) { - int ret; + int ret __diagused; /* We hit the Xen hard limit: reprobe. */ reservation.nr_extents = rc; @@ -215,7 +215,7 @@ decrease_reservation(unsigned long nr_pages) unsigned long i; vm_page_t page; int need_sleep = 0; - int ret; + int ret __diagused; struct xen_memory_reservation reservation = { .address_bits = 0, .extent_order = 0, diff --git a/sys/dev/xen/blkback/blkback.c b/sys/dev/xen/blkback/blkback.c index 6a4e8007f6b9..4470cc59a29a 100644 --- a/sys/dev/xen/blkback/blkback.c +++ b/sys/dev/xen/blkback/blkback.c @@ -1087,7 +1087,7 @@ xbb_unmap_reqlist(struct xbb_xen_reqlist *reqlist) struct gnttab_unmap_grant_ref unmap[XBB_MAX_SEGMENTS_PER_REQLIST]; u_int i; u_int invcount; - int error; + int error __diagused; invcount = 0; for (i = 0; i < reqlist->nr_segments; i++) { @@ -1645,11 +1645,9 @@ 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; nr_sects = 0; nseg = ring_req->nr_segments; nreq->nr_pages = nseg; diff --git a/sys/dev/xen/console/xen_console.c b/sys/dev/xen/console/xen_console.c index 8ad755dbf214..c26b741c37fe 100644 --- a/sys/dev/xen/console/xen_console.c +++ b/sys/dev/xen/console/xen_console.c @@ -701,7 +701,7 @@ static struct ttydevsw xencons_ttydevsw = { static void xencons_identify(driver_t *driver, device_t parent) { - device_t child; + device_t child __unused; if (main_cons.ops == NULL) return; diff --git a/sys/dev/xen/netback/netback.c b/sys/dev/xen/netback/netback.c index 06d92093d903..8de4e11c61d9 100644 --- a/sys/dev/xen/netback/netback.c +++ b/sys/dev/xen/netback/netback.c @@ -639,7 +639,7 @@ static int xnb_disconnect(struct xnb_softc *xnb) { struct gnttab_unmap_grant_ref gnts[XNB_NUM_RING_TYPES]; - int error; + int error __diagused; int i; if (xnb->xen_intr_handle != NULL) diff --git a/sys/dev/xen/netfront/netfront.c b/sys/dev/xen/netfront/netfront.c index fd2d97a7c70c..8dba5a8dc6d5 100644 --- a/sys/dev/xen/netfront/netfront.c +++ b/sys/dev/xen/netfront/netfront.c @@ -1409,10 +1409,9 @@ xn_get_responses(struct netfront_rxq *rxq, struct netif_extra_info *extras = rinfo->extras; struct mbuf *m, *m0, *m_prev; grant_ref_t ref = xn_get_rx_ref(rxq, *cons); - RING_IDX ref_cons = *cons; int frags = 1; int err = 0; - u_long ret; + u_long ret __diagused; m0 = m = m_prev = xn_get_rx_mbuf(rxq, *cons); @@ -1500,7 +1499,6 @@ next_skip_queue: m0 = m; m->m_next = NULL; ref = xn_get_rx_ref(rxq, *cons + frags); - ref_cons = *cons + frags; frags++; } *list = m0; diff --git a/sys/dev/xen/privcmd/privcmd.c b/sys/dev/xen/privcmd/privcmd.c index 763c2f471c4f..f8da2e2d9a35 100644 --- a/sys/dev/xen/privcmd/privcmd.c +++ b/sys/dev/xen/privcmd/privcmd.c @@ -121,7 +121,7 @@ privcmd_pg_dtor(void *handle) { struct xen_remove_from_physmap rm = { .domid = DOMID_SELF }; struct privcmd_map *map = handle; - int error; + int error __diagused; vm_size_t i; vm_page_t m; diff --git a/sys/dev/xen/xenstore/xenstore.c b/sys/dev/xen/xenstore/xenstore.c index dc00ed0d50b8..d09fd22f4eb1 100644 --- a/sys/dev/xen/xenstore/xenstore.c +++ b/sys/dev/xen/xenstore/xenstore.c @@ -787,11 +787,8 @@ xs_read_reply(enum xsd_sockmsg_type *type, u_int *len, void **result) int xs_dev_request_and_reply(struct xsd_sockmsg *msg, void **result) { - uint32_t request_type; int error; - request_type = msg->type; - sx_xlock(&xs.request_mutex); if ((error = xs_write_store(msg, sizeof(*msg) + msg->len)) == 0) error = xs_read_reply(&msg->type, &msg->len, result); diff --git a/sys/x86/xen/pv.c b/sys/x86/xen/pv.c index a316d4ee8857..e0c88992390e 100644 --- a/sys/x86/xen/pv.c +++ b/sys/x86/xen/pv.c @@ -255,11 +255,8 @@ xen_pvh_parse_symtab(void) { Elf_Ehdr *ehdr; Elf_Shdr *shdr; - uint32_t size; int i, j; - size = end; - ehdr = (Elf_Ehdr *)(&end + 1); if (memcmp(ehdr->e_ident, ELFMAG, SELFMAG) || ehdr->e_ident[EI_CLASS] != ELF_TARG_CLASS || diff --git a/sys/x86/xen/xen_intr.c b/sys/x86/xen/xen_intr.c index a3d84965f0f2..08e3ac6b1f52 100644 --- a/sys/x86/xen/xen_intr.c +++ b/sys/x86/xen/xen_intr.c @@ -491,7 +491,7 @@ xen_intr_active_ports(struct xen_intr_pcpu_data *pcpu, shared_info_t *sh, void xen_intr_handle_upcall(struct trapframe *trap_frame) { - u_int l1i, l2i, port, cpu; + u_int l1i, l2i, port, cpu __diagused; u_long masked_l1, masked_l2; struct xenisrc *isrc; shared_info_t *s;