Author: marius
Date: Sat Mar 31 14:03:16 2012
New Revision: 233748
URL: http://svn.freebsd.org/changeset/base/233748

Log:
  Remove checks that are redundant due to tf_type being unsigned.
  
  MFC after:    3 days

Modified:
  head/sys/sparc64/sparc64/trap.c

Modified: head/sys/sparc64/sparc64/trap.c
==============================================================================
--- head/sys/sparc64/sparc64/trap.c     Sat Mar 31 13:56:24 2012        
(r233747)
+++ head/sys/sparc64/sparc64/trap.c     Sat Mar 31 14:03:16 2012        
(r233748)
@@ -301,7 +301,7 @@ trap(struct trapframe *tf)
                        sig = trap_cecc();
                        break;
                default:
-                       if (tf->tf_type < 0 || tf->tf_type > T_MAX)
+                       if (tf->tf_type > T_MAX)
                                panic("trap: bad trap type %#lx (user)",
                                    tf->tf_type);
                        else if (trap_sig[tf->tf_type] == -1)
@@ -405,7 +405,7 @@ trap(struct trapframe *tf)
 
                if (error != 0) {
                        tf->tf_type &= ~T_KERNEL;
-                       if (tf->tf_type < 0 || tf->tf_type > T_MAX)
+                       if (tf->tf_type > T_MAX)
                                panic("trap: bad trap type %#lx (kernel)",
                                    tf->tf_type);
                        panic("trap: %s (kernel)", trap_msg[tf->tf_type]);
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to