Skip to content

Commit

Permalink
[v1.22.x] util: Add fabric argument to pingpong test
Browse files Browse the repository at this point in the history
Signed-off-by: Sai Sunku <sunkusa@amazon.com>
(cherry picked from commit 6793260)
  • Loading branch information
sunkuamzn authored and shijin-aws committed Feb 6, 2025
1 parent bd99935 commit 9c7aa79
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion util/pingpong.c
Original file line number Diff line number Diff line change
Expand Up @@ -2002,6 +2002,7 @@ static void pp_pingpong_usage(struct ct_pingpong *ct, char *name, char *desc)
"destination control port number (client: 47592)");

fprintf(stderr, " %-20s %s\n", "-d <domain>", "domain name");
fprintf(stderr, " %-20s %s\n", "-f <fabric>", "fabric name");
fprintf(stderr, " %-20s %s\n", "-s <source address>",
"source address associated with domain name");
fprintf(stderr, " %-20s %s\n", "-p <provider>",
Expand Down Expand Up @@ -2041,6 +2042,11 @@ static void pp_parse_opts(struct ct_pingpong *ct, int op, char *optarg)
ct->hints->fabric_attr->prov_name = strdup(optarg);
break;

/* Fabric */
case 'f':
ct->hints->fabric_attr->name = strdup(optarg);
break;

/* Endpoint */
case 'e':
if (!strncasecmp("msg", optarg, 3) && (strlen(optarg) == 3)) {
Expand Down Expand Up @@ -2327,7 +2333,7 @@ int main(int argc, char **argv)

ofi_osd_init();

while ((op = getopt(argc, argv, "hvd:p:e:I:S:s:B:P:cm:6")) != -1) {
while ((op = getopt(argc, argv, "hvd:p:f:e:I:S:s:B:P:cm:6")) != -1) {
switch (op) {
default:
pp_parse_opts(&ct, op, optarg);
Expand Down

0 comments on commit 9c7aa79

Please sign in to comment.