Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 Dec 2021 04:54:02 GMT
From:      Jessica Clarke <jrtc27@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: d90c3b51cc3a - main - xdma: Fix -Wunused-but-set-variable warnings
Message-ID:  <202112100454.1BA4s2p6049283@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by jrtc27:

URL: https://cgit.FreeBSD.org/src/commit/?id=d90c3b51cc3a15235054a5823928e8b654697768

commit d90c3b51cc3a15235054a5823928e8b654697768
Author:     Jessica Clarke <jrtc27@FreeBSD.org>
AuthorDate: 2021-12-10 04:48:51 +0000
Commit:     Jessica Clarke <jrtc27@FreeBSD.org>
CommitDate: 2021-12-10 04:48:51 +0000

    xdma: Fix -Wunused-but-set-variable warnings
    
    MFC after:      1 week
---
 sys/dev/xdma/xdma_mbuf.c |  3 ---
 sys/dev/xdma/xdma_sg.c   | 11 -----------
 2 files changed, 14 deletions(-)

diff --git a/sys/dev/xdma/xdma_mbuf.c b/sys/dev/xdma/xdma_mbuf.c
index 58fab199803b..c6c9a8f48ba9 100644
--- a/sys/dev/xdma/xdma_mbuf.c
+++ b/sys/dev/xdma/xdma_mbuf.c
@@ -82,9 +82,6 @@ xdma_enqueue_mbuf(xdma_channel_t *xchan, struct mbuf **mp,
     enum xdma_direction dir)
 {
 	struct xdma_request *xr;
-	xdma_controller_t *xdma;
-
-	xdma = xchan->xdma;
 
 	xr = xchan_bank_get(xchan);
 	if (xr == NULL)
diff --git a/sys/dev/xdma/xdma_sg.c b/sys/dev/xdma/xdma_sg.c
index add034ae846d..f27b410a4a32 100644
--- a/sys/dev/xdma/xdma_sg.c
+++ b/sys/dev/xdma/xdma_sg.c
@@ -324,12 +324,9 @@ xchan_seg_done(xdma_channel_t *xchan,
     struct xdma_transfer_status *st)
 {
 	struct xdma_request *xr;
-	xdma_controller_t *xdma;
 	struct xchan_buf *b;
 	bus_addr_t addr;
 
-	xdma = xchan->xdma;
-
 	xr = TAILQ_FIRST(&xchan->processing);
 	if (xr == NULL)
 		panic("request not found\n");
@@ -487,15 +484,12 @@ static int
 _xdma_load_data(xdma_channel_t *xchan, struct xdma_request *xr,
     struct bus_dma_segment *seg)
 {
-	xdma_controller_t *xdma;
 	struct mbuf *m;
 	uint32_t nsegs;
 	vm_offset_t va, addr;
 	bus_addr_t pa;
 	vm_prot_t prot;
 
-	xdma = xchan->xdma;
-
 	m = xr->m;
 
 	KASSERT(xchan->caps & (XCHAN_CAP_NOSEG | XCHAN_CAP_BOUNCE),
@@ -548,13 +542,8 @@ static int
 xdma_load_data(xdma_channel_t *xchan,
     struct xdma_request *xr, struct bus_dma_segment *seg)
 {
-	xdma_controller_t *xdma;
-	int error;
 	int nsegs;
 
-	xdma = xchan->xdma;
-
-	error = 0;
 	nsegs = 0;
 
 	if (xchan->caps & XCHAN_CAP_BUSDMA)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202112100454.1BA4s2p6049283>