summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2023-04-09 12:06:56 -0700
committerAlan Coopersmith <alan.coopersmith@oracle.com>2023-04-09 12:09:10 -0700
commitadda00c31ae77da0d86b3e5dbd168cbf2917a3f0 (patch)
tree5d3e82486a0436e7f7799d3ffe6ba1ccb24f260a
parent36024e0d3d16ec926d631a016b4d361646b8785b (diff)
Handle -Wextra-semi-stmt warnings from clang
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--src/atimach64accel.c4
-rw-r--r--src/atiutil.h4
2 files changed, 5 insertions, 3 deletions
diff --git a/src/atimach64accel.c b/src/atimach64accel.c
index f35af53..0453f22 100644
--- a/src/atimach64accel.c
+++ b/src/atimach64accel.c
@@ -67,13 +67,15 @@
/* Used to test MMIO cache integrity in ATIMach64Sync() */
#define TestRegisterCaching(_Register) \
+ do { \
if (RegisterIsCached(_Register) && \
(CacheSlot(_Register) != inm(_Register))) \
{ \
UncacheRegister(_Register); \
xf86DrvMsg(pScreenInfo->scrnIndex, X_WARNING, \
#_Register " MMIO write cache disabled!\n"); \
- }
+ } \
+ } while (0)
/*
* X-to-Mach64 mix translation table.
diff --git a/src/atiutil.h b/src/atiutil.h
index caa4b70..e807125 100644
--- a/src/atiutil.h
+++ b/src/atiutil.h
@@ -33,12 +33,12 @@
#define __ONE_MICROSECOND__ 100 /* This'll need calibration */
#define ATIDelay(_microseconds) \
- { \
+ do { \
unsigned int _i, _j; \
for (_i = 0; _i < _microseconds; _i++) \
for (_j = 0; _j < __ONE_MICROSECOND__; _j++) \
/* Nothing */; \
- }
+ } while (0)
/*
* Macros to get/set a contiguous bit field. Arguments should not be