Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/powerpc/powerpc Only call unmapiodev if va is non-z...



details:   https://anonhg.NetBSD.org/src/rev/b5b649d04948
branches:  trunk
changeset: 762909:b5b649d04948
user:      matt <matt%NetBSD.org@localhost>
date:      Sat Mar 05 15:25:52 2011 +0000

description:
Only call unmapiodev if va is non-zero.

diffstat:

 sys/arch/powerpc/powerpc/bus_space.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (28 lines):

diff -r a354acffa77d -r b5b649d04948 sys/arch/powerpc/powerpc/bus_space.c
--- a/sys/arch/powerpc/powerpc/bus_space.c      Sat Mar 05 15:19:44 2011 +0000
+++ b/sys/arch/powerpc/powerpc/bus_space.c      Sat Mar 05 15:25:52 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: bus_space.c,v 1.25 2011/02/15 19:39:12 macallan Exp $  */
+/*     $NetBSD: bus_space.c,v 1.26 2011/03/05 15:25:52 matt Exp $      */
 
 /*-
  * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bus_space.c,v 1.25 2011/02/15 19:39:12 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bus_space.c,v 1.26 2011/03/05 15:25:52 matt Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -684,7 +684,8 @@
                printf("memio_unmap: can't free region\n");
        }
 
-       unmapiodev(va, size);
+       if (va)
+               unmapiodev(va, size);
 }
 
 int



Home | Main Index | Thread Index | Old Index