diff options
-rw-r--r-- | src/atimach64accel.c | 4 | ||||
-rw-r--r-- | src/atiutil.h | 4 |
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 |