Author: neel
Date: Sat Mar 16 22:53:05 2013
New Revision: 248392
URL: http://svnweb.freebsd.org/changeset/base/248392

Log:
  Fix the '-Wtautological-compare' warning emitted by clang for comparing the
  unsigned enum type with a negative value.
  
  Obtained from:        NetApp

Modified:
  head/sys/amd64/vmm/vmm.c

Modified: head/sys/amd64/vmm/vmm.c
==============================================================================
--- head/sys/amd64/vmm/vmm.c    Sat Mar 16 22:44:14 2013        (r248391)
+++ head/sys/amd64/vmm/vmm.c    Sat Mar 16 22:53:05 2013        (r248392)
@@ -937,7 +937,7 @@ vm_set_x2apic_state(struct vm *vm, int v
        if (vcpuid < 0 || vcpuid >= VM_MAXCPU)
                return (EINVAL);
 
-       if (state < 0 || state >= X2APIC_STATE_LAST)
+       if (state >= X2APIC_STATE_LAST)
                return (EINVAL);
 
        vm->vcpu[vcpuid].x2apic_state = state;
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "[email protected]"

Reply via email to