Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/arm/xscale Remove tautologies.



details:   https://anonhg.NetBSD.org/src/rev/ca8f6f8330c7
branches:  trunk
changeset: 331575:ca8f6f8330c7
user:      joerg <joerg%NetBSD.org@localhost>
date:      Thu Aug 14 16:55:02 2014 +0000

description:
Remove tautologies.

diffstat:

 sys/arch/arm/xscale/ixp425_npe.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (34 lines):

diff -r 6a04a856e6fc -r ca8f6f8330c7 sys/arch/arm/xscale/ixp425_npe.c
--- a/sys/arch/arm/xscale/ixp425_npe.c  Thu Aug 14 16:50:22 2014 +0000
+++ b/sys/arch/arm/xscale/ixp425_npe.c  Thu Aug 14 16:55:02 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ixp425_npe.c,v 1.10 2014/03/20 06:48:54 skrll Exp $    */
+/*     $NetBSD: ixp425_npe.c,v 1.11 2014/08/14 16:55:02 joerg Exp $    */
 
 /*-
  * Copyright (c) 2006 Sam Leffler, Errno Consulting
@@ -62,7 +62,7 @@
 #if 0
 __FBSDID("$FreeBSD: src/sys/arm/xscale/ixp425/ixp425_npe.c,v 1.1 2006/11/19 23:55:23 sam Exp $");
 #endif
-__KERNEL_RCSID(0, "$NetBSD: ixp425_npe.c,v 1.10 2014/03/20 06:48:54 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ixp425_npe.c,v 1.11 2014/08/14 16:55:02 joerg Exp $");
 
 /*
  * Intel XScale Network Processing Engine (NPE) support.
@@ -594,13 +594,13 @@
            IX_NPEDL_OFFSET_STATE_ADDR_CTXT_NUM;
        
        /* error-check Context Register No. and Context Number values  */
-       if (!(0 <= reg && reg < IX_NPEDL_CTXT_REG_MAX)) {
+       if (reg >= IX_NPEDL_CTXT_REG_MAX) {
            printf("%s: invalid Context Register %u\n", device_xname(sc->sc_dev),
                reg);
            error = EINVAL;
            break;
        }    
-       if (!(0 <= cNum && cNum < IX_NPEDL_CTXT_NUM_MAX)) {
+       if (cNum >= IX_NPEDL_CTXT_NUM_MAX) {
            printf("%s: invalid Context Number %u\n", device_xname(sc->sc_dev),
                cNum);
            error = EINVAL;



Home | Main Index | Thread Index | Old Index