From 4dc7c966673bd5e748c7f957ac73005007a94c74 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Sun, 3 May 2009 13:44:06 +0000 Subject: Avoid clobbering error return values with the result from extent_free(), by simply calling iommu_dvma_unload(). Solution suggested by oga@. While there, also unwrap a line that isn't long enough to need wrapping. --- sys/arch/sparc64/dev/iommu.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'sys/arch/sparc64/dev/iommu.c') diff --git a/sys/arch/sparc64/dev/iommu.c b/sys/arch/sparc64/dev/iommu.c index be92ad98c45..97243af304f 100644 --- a/sys/arch/sparc64/dev/iommu.c +++ b/sys/arch/sparc64/dev/iommu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: iommu.c,v 1.58 2009/05/02 18:39:27 kettenis Exp $ */ +/* $OpenBSD: iommu.c,v 1.59 2009/05/03 13:44:05 kettenis Exp $ */ /* $NetBSD: iommu.c,v 1.47 2002/02/08 20:03:45 eeh Exp $ */ /* @@ -1315,8 +1315,7 @@ iommu_dvmamap_unload(bus_dma_tag_t t, bus_dma_tag_t t0, bus_dmamap_t map) map->dm_nsegs = 0; mtx_enter(&is->is_mtx); - error = extent_free(is->is_dvmamap, dvmaddr, - sgsize, EX_NOWAIT); + error = extent_free(is->is_dvmamap, dvmaddr, sgsize, EX_NOWAIT); map->_dm_dvmastart = 0; map->_dm_dvmasize = 0; mtx_leave(&is->is_mtx); -- cgit v1.2.3