--- /dev/null
+Bottom: e9c95ad102b85dd4ad2970df253388b475935d48
+Top: 2e4c0d441a2f3b1ce7007c61679306e6d64bd8b1
+Author: Sean Hefty <sean.hefty@intel.com>
+Date: 2012-12-06 23:34:31 -0800
+
+Refresh of udpong
+
+---
+
+diff --git a/examples/common.c b/examples/common.c
+index 43bfb6b..939f50c 100644
+--- a/examples/common.c
++++ b/examples/common.c
+@@ -45,6 +45,8 @@
+ #include <rdma/rdma_cma.h>
+ #include "common.h"
+
++int use_rs = 1;
++
+ int get_rdma_addr(char *src, char *dst, char *port,
+ struct rdma_addrinfo *hints, struct rdma_addrinfo **rai)
+ {
+diff --git a/examples/common.h b/examples/common.h
+index ef0ea7b..37dc79e 100644
+--- a/examples/common.h
++++ b/examples/common.h
+@@ -35,8 +35,10 @@
+ #include <stdlib.h>
+ #include <sys/types.h>
+ #include <byteswap.h>
++#include <poll.h>
+
+ #include <rdma/rdma_cma.h>
++#include <rdma/rsocket.h>
+
+ #if __BYTE_ORDER == __BIG_ENDIAN
+ static inline uint64_t cpu_to_be64(uint64_t x) { return x; }
+@@ -46,6 +48,28 @@ static inline uint64_t cpu_to_be64(uint64_t x) { return bswap_64(x); }
+ static inline uint32_t cpu_to_be32(uint32_t x) { return bswap_32(x); }
+ #endif
+
++extern int use_rs;
++
++#define rs_socket(f,t,p) use_rs ? rsocket(f,t,p) : socket(f,t,p)
++#define rs_bind(s,a,l) use_rs ? rbind(s,a,l) : bind(s,a,l)
++#define rs_listen(s,b) use_rs ? rlisten(s,b) : listen(s,b)
++#define rs_connect(s,a,l) use_rs ? rconnect(s,a,l) : connect(s,a,l)
++#define rs_accept(s,a,l) use_rs ? raccept(s,a,l) : accept(s,a,l)
++#define rs_shutdown(s,h) use_rs ? rshutdown(s,h) : shutdown(s,h)
++#define rs_close(s) use_rs ? rclose(s) : close(s)
++#define rs_recv(s,b,l,f) use_rs ? rrecv(s,b,l,f) : recv(s,b,l,f)
++#define rs_send(s,b,l,f) use_rs ? rsend(s,b,l,f) : send(s,b,l,f)
++#define rs_recvfrom(s,b,l,f,a,al) \
++ use_rs ? rrecvfrom(s,b,l,f,a,al) : recvfrom(s,b,l,f,a,al)
++#define rs_sendto(s,b,l,f,a,al) \
++ use_rs ? rsendto(s,b,l,f,a,al) : sendto(s,b,l,fa,al)
++#define rs_poll(f,n,t) use_rs ? rpoll(f,n,t) : poll(f,n,t)
++#define rs_fcntl(s,c,p) use_rs ? rfcntl(s,c,p) : fcntl(s,c,p)
++#define rs_setsockopt(s,l,n,v,ol) \
++ use_rs ? rsetsockopt(s,l,n,v,ol) : setsockopt(s,l,n,v,ol)
++#define rs_getsockopt(s,l,n,v,ol) \
++ use_rs ? rgetsockopt(s,l,n,v,ol) : getsockopt(s,l,n,v,ol)
++
+ union socket_addr {
+ struct sockaddr sa;
+ struct sockaddr_in sin;
+diff --git a/examples/rstream.c b/examples/rstream.c
+index fa7491c..617710e 100644
+--- a/examples/rstream.c
++++ b/examples/rstream.c
+@@ -45,7 +45,7 @@
+
+ #include <rdma/rdma_cma.h>
+ #include <rdma/rsocket.h>
+-include "common.h"
++#include "common.h"
+
+ struct test_size_param {
+ int size;
+@@ -80,7 +80,6 @@ enum rs_optimization {
+ };
+
+ static int rs, lrs;
+-static int use_rs = 1;
+ static int use_async;
+ static int verify;
+ static int flags = MSG_DONTWAIT;
+@@ -101,22 +100,6 @@ static char *src_addr;
+ static struct timeval start, end;
+ static void *buf;
+
+-#define rs_socket(f,t,p) use_rs ? rsocket(f,t,p) : socket(f,t,p)
+-#define rs_bind(s,a,l) use_rs ? rbind(s,a,l) : bind(s,a,l)
+-#define rs_listen(s,b) use_rs ? rlisten(s,b) : listen(s,b)
+-#define rs_connect(s,a,l) use_rs ? rconnect(s,a,l) : connect(s,a,l)
+-#define rs_accept(s,a,l) use_rs ? raccept(s,a,l) : accept(s,a,l)
+-#define rs_shutdown(s,h) use_rs ? rshutdown(s,h) : shutdown(s,h)
+-#define rs_close(s) use_rs ? rclose(s) : close(s)
+-#define rs_recv(s,b,l,f) use_rs ? rrecv(s,b,l,f) : recv(s,b,l,f)
+-#define rs_send(s,b,l,f) use_rs ? rsend(s,b,l,f) : send(s,b,l,f)
+-#define rs_poll(f,n,t) use_rs ? rpoll(f,n,t) : poll(f,n,t)
+-#define rs_fcntl(s,c,p) use_rs ? rfcntl(s,c,p) : fcntl(s,c,p)
+-#define rs_setsockopt(s,l,n,v,ol) \
+- use_rs ? rsetsockopt(s,l,n,v,ol) : setsockopt(s,l,n,v,ol)
+-#define rs_getsockopt(s,l,n,v,ol) \
+- use_rs ? rgetsockopt(s,l,n,v,ol) : getsockopt(s,l,n,v,ol)
+-
+ static void show_perf(void)
+ {
+ char str[32];
+diff --git a/examples/udpong.c b/examples/udpong.c
+index d29e584..4adec2f 100644
+--- a/examples/udpong.c
++++ b/examples/udpong.c
+@@ -45,6 +45,7 @@
+
+ #include <rdma/rdma_cma.h>
+ #include <rdma/rsocket.h>
++#include "common.h"
+
+ static int test_size[] = {
+ { 1 << 6 },
+@@ -80,7 +81,6 @@ static struct client clients[256];
+ static int id;
+
+ static int rs;
+-static int use_rs = 1;
+ static int use_async;
+ static int flags = MSG_DONTWAIT;
+ static int poll_timeout;
+@@ -98,21 +98,6 @@ static socklen_t addrlen;
+ static struct timeval start, end;
+ static struct message msg;
+
+-#define rs_socket(f,t,p) use_rs ? rsocket(f,t,p) : socket(f,t,p)
+-#define rs_bind(s,a,l) use_rs ? rbind(s,a,l) : bind(s,a,l)
+-#define rs_connect(s,a,l) use_rs ? rconnect(s,a,l) : connect(s,a,l)
+-#define rs_close(s) use_rs ? rclose(s) : close(s)
+-#define rs_recvfrom(s,b,l,f,a,al) \
+- use_rs ? rrecvfrom(s,b,l,f,a,al) : recvfrom(s,b,l,f,a,al)
+-#define rs_sendto(s,b,l,f,a,al) \
+- use_rs ? rsendto(s,b,l,f,a,al) : sendto(s,b,l,fa,al)
+-#define rs_poll(f,n,t) use_rs ? rpoll(f,n,t) : poll(f,n,t)
+-#define rs_fcntl(s,c,p) use_rs ? rfcntl(s,c,p) : fcntl(s,c,p)
+-#define rs_setsockopt(s,l,n,v,ol) \
+- use_rs ? rsetsockopt(s,l,n,v,ol) : setsockopt(s,l,n,v,ol)
+-#define rs_getsockopt(s,l,n,v,ol) \
+- use_rs ? rgetsockopt(s,l,n,v,ol) : getsockopt(s,l,n,v,ol)
+-
+ static void show_perf(void)
+ {
+ char str[32];