Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 6 Apr 2022 23:45:54 GMT
From:      John Baldwin <jhb@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 89abc0fbbd47 - main - x86 bounce_bus_dma_tag_destroy: Silence set but unused warning.
Message-ID:  <202204062345.236Njsuk008539@gitrepo.freebsd.org>

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

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

commit 89abc0fbbd47ef41b693c8bf89c27120c3d05d79
Author:     John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2022-04-06 23:45:27 +0000
Commit:     John Baldwin <jhb@FreeBSD.org>
CommitDate: 2022-04-06 23:45:27 +0000

    x86 bounce_bus_dma_tag_destroy: Silence set but unused warning.
---
 sys/x86/x86/busdma_bounce.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/sys/x86/x86/busdma_bounce.c b/sys/x86/x86/busdma_bounce.c
index 258441cf2070..abbf64fd3965 100644
--- a/sys/x86/x86/busdma_bounce.c
+++ b/sys/x86/x86/busdma_bounce.c
@@ -230,12 +230,13 @@ bounce_bus_dma_tag_set_domain(bus_dma_tag_t dmat)
 static int
 bounce_bus_dma_tag_destroy(bus_dma_tag_t dmat)
 {
-	bus_dma_tag_t dmat_copy __diagused;
+#ifdef KTR
+	bus_dma_tag_t dmat_copy = dmat;
+#endif
 	bus_dma_tag_t parent;
 	int error;
 
 	error = 0;
-	dmat_copy = dmat;
 
 	if (dmat != NULL) {
 		if (dmat->map_count != 0) {



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