Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/sparc/sparc Don't check unsigned values for negativ...



details:   https://anonhg.NetBSD.org/src/rev/cbec5730f223
branches:  trunk
changeset: 810970:cbec5730f223
user:      joerg <joerg%NetBSD.org@localhost>
date:      Sun Oct 04 08:17:43 2015 +0000

description:
Don't check unsigned values for negativity.

diffstat:

 sys/arch/sparc/sparc/msiiep.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r a3a018777b37 -r cbec5730f223 sys/arch/sparc/sparc/msiiep.c
--- a/sys/arch/sparc/sparc/msiiep.c     Sun Oct 04 08:17:03 2015 +0000
+++ b/sys/arch/sparc/sparc/msiiep.c     Sun Oct 04 08:17:43 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: msiiep.c,v 1.45 2013/11/16 23:54:01 mrg Exp $ */
+/*     $NetBSD: msiiep.c,v 1.46 2015/10/04 08:17:43 joerg Exp $ */
 
 /*
  * Copyright (c) 2001 Valeriy E. Ushakov
@@ -27,7 +27,7 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: msiiep.c,v 1.45 2013/11/16 23:54:01 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: msiiep.c,v 1.46 2015/10/04 08:17:43 joerg Exp $");
 
 #include <sys/param.h>
 #include <sys/malloc.h>
@@ -507,7 +507,7 @@
 
        for (i = 0; i < nmaps; ++i, ++m) {
                offset = pciaddr - m->pcibase;
-               if (offset >= 0 && offset + size <= m->size)
+               if (offset + size <= m->size)
                        return (m->sysbase + offset);
        }
        return (0);



Home | Main Index | Thread Index | Old Index