* [PATCH perftest] multicast_resources.h: Guard against duplicated definitions of ntohll/htonll
@ 2013-09-20 23:14 Hal Rosenstock
0 siblings, 0 replies; only message in thread
From: Hal Rosenstock @ 2013-09-20 23:14 UTC (permalink / raw)
To: Ido Shamay
Cc: linux-rdma (linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org)
Signed-off-by: Hal Rosenstock <hal-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
---
diff --git a/src/multicast_resources.h b/src/multicast_resources.h
index bc85bae..1bfa043 100644
--- a/src/multicast_resources.h
+++ b/src/multicast_resources.h
@@ -80,8 +80,12 @@
#define DEF_FLOW_LABLE 0
// Macro for 64 bit variables to switch to from net
+#ifndef ntohll
#define ntohll(x) (((uint64_t)(ntohl((int)((x << 32) >> 32))) << 32) | (unsigned int)ntohl(((int)(x >> 32))))
+#endif
+#ifndef htonll
#define htonll(x) ntohll(x)
+#endif
// generate a bit mask S bits width
#define MASK32(S) ( ((uint32_t) ~0L) >> (32-(S)) )
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2013-09-20 23:14 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-20 23:14 [PATCH perftest] multicast_resources.h: Guard against duplicated definitions of ntohll/htonll Hal Rosenstock
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).