components/open-fabrics/perftest/patches/base.patch
branchs11u3-sru
changeset 4996 739983ef315c
parent 3679 c058dce9610f
equal deleted inserted replaced
4993:efe17d59c020 4996:739983ef315c
  1439 +    int	temp_reads = 0;
  1439 +    int	temp_reads = 0;
  1440 +
  1440 +
  1441      // Client.
  1441      // Client.
  1442      if (params->machine == CLIENT) {
  1442      if (params->machine == CLIENT) {
  1443  		if (ctx_write_keys(my_dest,params)) {
  1443  		if (ctx_write_keys(my_dest,params)) {
  1444 @@ -904,6 +921,18 @@
  1444 @@ -904,6 +921,21 @@
  1445  			return -1;
  1445  			return -1;
  1446  		}
  1446  		}
  1447      }
  1447      }
  1448 +    // We could have tavor at one end and hermon at the other.
  1448 +
  1449 +    // To avoid a modify QP error set max_rd_atomic to lowest
  1449 +    /*
  1450 +    // on either side of connection.
  1450 +     * If we have different HCA's at either end of the connection with
       
  1451 +     * different RDMA attributes, then to avoid a modify QP error set
       
  1452 +     * max_rd_atomic to lowest on either side of connection.
       
  1453 +     */
  1451 +    if (rem_dest->out_reads > my_dest->out_reads)
  1454 +    if (rem_dest->out_reads > my_dest->out_reads)
  1452 +	temp_reads =  my_dest->out_reads;
  1455 +	temp_reads =  my_dest->out_reads;
  1453 +
  1456 +
  1454 +    if (my_dest->out_reads > rem_dest->out_reads)
  1457 +    if (my_dest->out_reads > rem_dest->out_reads)
  1455 +	my_dest->out_reads = rem_dest->out_reads;
  1458 +	my_dest->out_reads = rem_dest->out_reads;
  1602  	}
  1605  	}
  1603  
  1606  
  1604 diff -r -u /tmp/perftest-1.3.0/send_bw.c perftest-1.3.0/send_bw.c
  1607 diff -r -u /tmp/perftest-1.3.0/send_bw.c perftest-1.3.0/send_bw.c
  1605 --- /tmp/perftest-1.3.0/send_bw.c	Thu Jan 20 07:37:18 2011
  1608 --- /tmp/perftest-1.3.0/send_bw.c	Thu Jan 20 07:37:18 2011
  1606 +++ perftest-1.3.0/send_bw.c	Fri Feb 11 04:12:47 2011
  1609 +++ perftest-1.3.0/send_bw.c	Fri Feb 11 04:12:47 2011
  1607 @@ -320,7 +320,7 @@
  1610 @@ -320,9 +320,6 @@
  1608  		user_parm->size = MTU_SIZE(user_parm->curr_mtu);
  1611  		user_parm->size = MTU_SIZE(user_parm->curr_mtu);
  1609  	}
  1612  	}
  1610  
  1613  
  1611 -	if (is_dev_hermon(ctx->context) != NOT_HERMON && user_parm->inline_size != 0)
  1614 -	if (is_dev_hermon(ctx->context) != NOT_HERMON && user_parm->inline_size != 0)
  1612 +	if (is_dev_hermon(ctx->context) == NOT_HERMON && user_parm->inline_size != 0)
  1615 -		user_parm->inline_size = 0;
  1613  		user_parm->inline_size = 0;
  1616 -
  1614  
       
  1615  	printf(" Inline data is used up to %d bytes message\n", user_parm->inline_size);
  1617  	printf(" Inline data is used up to %d bytes message\n", user_parm->inline_size);
  1616 @@ -649,7 +649,11 @@
  1618  
       
  1619  	ctx->size = user_parm->size;
       
  1620 @@ -649,7 +646,11 @@
  1617  			}
  1621  			}
  1618  	}
  1622  	}
  1619  
  1623  
  1620 +#if !(defined(__sparc))
  1624 +#if !(defined(__sparc))
  1621  	cycles_to_units = get_cpu_mhz(user_param->cpu_freq_f) * 1000000;
  1625  	cycles_to_units = get_cpu_mhz(user_param->cpu_freq_f) * 1000000;
  1766  #include <getopt.h>
  1770  #include <getopt.h>
  1767 +#include <inttypes.h>
  1771 +#include <inttypes.h>
  1768  #include <time.h>
  1772  #include <time.h>
  1769  #include <infiniband/verbs.h>
  1773  #include <infiniband/verbs.h>
  1770  
  1774  
  1771 @@ -224,7 +225,7 @@
  1775 @@ -224,9 +225,6 @@
  1772  		return NULL;
  1776  		return NULL;
  1773  	}
  1777  	}
  1774  
  1778  
  1775 -	if (is_dev_hermon(ctx->context) != NOT_HERMON && user_parm->inline_size != 0)
  1779 -	if (is_dev_hermon(ctx->context) != NOT_HERMON && user_parm->inline_size != 0)
  1776 +	if (is_dev_hermon(ctx->context) == NOT_HERMON && user_parm->inline_size != 0)
  1780 -		user_parm->inline_size = 0;
  1777  		user_parm->inline_size = 0;
  1781 -
  1778  
       
  1779  	printf(" Inline data is used up to %d bytes message\n", user_parm->inline_size);
  1782  	printf(" Inline data is used up to %d bytes message\n", user_parm->inline_size);
  1780 @@ -368,7 +369,6 @@
  1783  
       
  1784  	ctx->pd = ibv_alloc_pd(ctx->context);
       
  1785 @@ -368,7 +366,6 @@
  1781  	cycles_t t;
  1786  	cycles_t t;
  1782  	int iters = user_param->iters;
  1787  	int iters = user_param->iters;
  1783  
  1788  
  1784 -
  1789 -
  1785  	opt_delta = tcompleted[opt_posted] - tposted[opt_completed];
  1790  	opt_delta = tcompleted[opt_posted] - tposted[opt_completed];
  1786  
  1791  
  1787  	if (user_param->noPeak == OFF) {
  1792  	if (user_param->noPeak == OFF) {
  1788 @@ -384,7 +384,11 @@
  1793 @@ -384,7 +381,11 @@
  1789  		  }
  1794  		  }
  1790  	}
  1795  	}
  1791  	
  1796  	
  1792 +#if !(defined(__sparc))
  1797 +#if !(defined(__sparc))
  1793  	cycles_to_units = get_cpu_mhz(user_param->cpu_freq_f) * 1000000;
  1798  	cycles_to_units = get_cpu_mhz(user_param->cpu_freq_f) * 1000000;