summaryrefslogtreecommitdiff
path: root/sys/dev/ic
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2010-08-02 20:55:50 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2010-08-02 20:55:50 +0000
commitb74a056a5cd9c84b02ff6d4ae92f895bbdbfbd51 (patch)
tree60baef09fa84a596edbfef26821d58b11df3d682 /sys/dev/ic
parenta625e136b7a7dffe00dec15e6a7e483df3fd33be (diff)
Make MHZ_TO_PLL safer to use by adding parenthesis. Fixes a potential issue
in agten(4) uncovered by gcc4. ok miod@, deraadt@
Diffstat (limited to 'sys/dev/ic')
-rw-r--r--sys/dev/ic/ibm525reg.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/ic/ibm525reg.h b/sys/dev/ic/ibm525reg.h
index a602128093a..fca2fff436a 100644
--- a/sys/dev/ic/ibm525reg.h
+++ b/sys/dev/ic/ibm525reg.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ibm525reg.h,v 1.1 2005/07/19 09:34:14 miod Exp $ */
+/* $OpenBSD: ibm525reg.h,v 1.2 2010/08/02 20:55:49 kettenis Exp $ */
/*
* Copyright (c) 2005, Miodrag Vallat.
*
@@ -176,7 +176,7 @@
* Pixel clock encoding
*/
#define MHZ_TO_PLL(m) \
- (m) < 32 ? 0x00 | (4 * (m) - 65) : \
- (m) < 64 ? 0x40 | (2 * (m) - 65) : \
- (m) < 128 ? 0x80 | ((m) - 65) : \
- 0xc0 | ((m) / 2 - 65)
+ ((m) < 32 ? 0x00 | (4 * (m) - 65) : \
+ (m) < 64 ? 0x40 | (2 * (m) - 65) : \
+ (m) < 128 ? 0x80 | ((m) - 65) : \
+ 0xc0 | ((m) / 2 - 65))