summaryrefslogtreecommitdiff
path: root/lib/util
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2018-11-21 18:24:59 +0100
committerGary Lockyer <gary@samba.org>2018-11-28 23:19:22 +0100
commite7f0b6e41fa3db68f588b91a6a7c25cf58aa815a (patch)
treedbf2c0bce76cbaa8de0ad42bdbba46d5e47235f9 /lib/util
parent80750253032843f919ea8ab48698f54c98968e4d (diff)
downloadsamba-e7f0b6e41fa3db68f588b91a6a7c25cf58aa815a.tar.gz
lib:util: Avoid name confusion with config.h
The HAVE_* is normally used for config.h definitions, so rename it to USE_ASM_BYTEORDER. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
Diffstat (limited to 'lib/util')
-rw-r--r--lib/util/byteorder.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/util/byteorder.h b/lib/util/byteorder.h
index 77afba58cbd..8656035693d 100644
--- a/lib/util/byteorder.h
+++ b/lib/util/byteorder.h
@@ -118,9 +118,9 @@ static __inline__ void st_le32(uint32_t *addr, const uint32_t val)
{
__asm__ ("stwbrx %1,0,%2" : "=m" (*addr) : "r" (val), "r" (addr));
}
-#define HAVE_ASM_BYTEORDER 1
+#define USE_ASM_BYTEORDER 1
#else
-#define HAVE_ASM_BYTEORDER 0
+#define USE_ASM_BYTEORDER 0
#endif
#define CVAL(buf,pos) ((unsigned int)(((const uint8_t *)(buf))[pos]))
@@ -128,7 +128,7 @@ static __inline__ void st_le32(uint32_t *addr, const uint32_t val)
#define PVAL(buf,pos) (CVAL(buf,pos))
#define SCVAL(buf,pos,val) (CVAL_NC(buf,pos) = (val))
-#if HAVE_ASM_BYTEORDER
+#if USE_ASM_BYTEORDER
#define _PTRPOS(buf,pos) (((const uint8_t *)(buf))+(pos))
#define SVAL(buf,pos) ld_le16((const uint16_t *)_PTRPOS(buf,pos))
@@ -140,7 +140,7 @@ static __inline__ void st_le32(uint32_t *addr, const uint32_t val)
#define SSVALS(buf,pos,val) SSVAL((buf),(pos),((int16_t)(val)))
#define SIVALS(buf,pos,val) SIVAL((buf),(pos),((int32_t)(val)))
-#else /* not HAVE_ASM_BYTEORDER */
+#else /* not USE_ASM_BYTEORDER */
#define SVAL(buf,pos) (PVAL(buf,pos)|PVAL(buf,(pos)+1)<<8)
#define IVAL(buf,pos) (SVAL(buf,pos)|SVAL(buf,(pos)+2)<<16)
@@ -153,7 +153,7 @@ static __inline__ void st_le32(uint32_t *addr, const uint32_t val)
#define SSVALS(buf,pos,val) SSVALX((buf),(pos),((int16_t)(val)))
#define SIVALS(buf,pos,val) SIVALX((buf),(pos),((int32_t)(val)))
-#endif /* not HAVE_ASM_BYTEORDER */
+#endif /* not USE_ASM_BYTEORDER */
/* 64 bit macros */
#define BVAL(p, ofs) (IVAL(p,ofs) | (((uint64_t)IVAL(p,(ofs)+4)) << 32))