Module Name:    src
Committed By:   maya
Date:           Wed Mar 14 18:58:32 UTC 2018

Modified Files:
        src/sys/dev/ic: igsfb.c

Log Message:
Don't left shift a negative, use unsigned for bit masks.
Appeases GCC 6 in some build configuration (ALL kernel)

ok uwe


To generate a diff of this commit:
cvs rdiff -u -r1.57 -r1.58 src/sys/dev/ic/igsfb.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/ic/igsfb.c
diff -u src/sys/dev/ic/igsfb.c:1.57 src/sys/dev/ic/igsfb.c:1.58
--- src/sys/dev/ic/igsfb.c:1.57	Wed Jan 24 05:35:58 2018
+++ src/sys/dev/ic/igsfb.c	Wed Mar 14 18:58:32 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: igsfb.c,v 1.57 2018/01/24 05:35:58 riastradh Exp $ */
+/*	$NetBSD: igsfb.c,v 1.58 2018/03/14 18:58:32 maya Exp $ */
 
 /*
  * Copyright (c) 2002, 2003 Valeriy E. Ushakov
@@ -31,7 +31,7 @@
  * Integraphics Systems IGA 168x and CyberPro series.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: igsfb.c,v 1.57 2018/01/24 05:35:58 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: igsfb.c,v 1.58 2018/03/14 18:58:32 maya Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1001,7 +1001,7 @@ igsfb_set_cursor(struct igsfb_devconfig 
 		/* clear trailing bits in the "partial" mask bytes */
 		trailing_bits = p->size.x & 0x07;
 		if (trailing_bits != 0) {
-			const u_int cutmask = ~((~0) << trailing_bits);
+			const u_int cutmask = ~((~0U) << trailing_bits);
 			u_char *mp;
 			u_int i;
 

Reply via email to