[ofa-general] Re: Fwd: [PATCH] infiniband-diags/ibnetdiscover: Apply --node-name-map remapping to names printed by --ports option

Ira Weiny weiny2 at llnl.gov
Mon Mar 9 14:26:08 PDT 2009


Sasha, David sent this to me to put the node names in the output of the ports
option.  It did not apply; I guess because of mailer issues.

So I applied by hand and created the attached patch with David's signed off by
line.  The first chunk did not seem to be more than a format change so I left
it out.  Was there something there David?

Ira


On Sat, 7 Mar 2009 21:31:38 -0600
David McMillen <davem at systemfabricworks.com> wrote:

> I sent a patch to the general mailing list, but my "message to general
> awaits moderator approval"
> 
> Since you seem to be working the tree a lot, I thought I'd pass it on to you
> as a heads-up.
> 
> I hope this mailer didn't mess up the tabs/spaces...  I know the one sent to
> the list was done right.
> 
> Dave
> 
> 
> ---------- Forwarded message ----------
> From: <davem at systemfabricworks.com>
> Date: Sat, Mar 7, 2009 at 8:17 PM
> Subject: [PATCH] infiniband-diags/ibnetdiscover: Apply --node-name-map
> remapping to names printed by --ports option
> To: general at lists.openfabrics.org, sashak at voltaire.com
> 
> 
> 
>    Apply --node-name-map remapping to names printed by --ports option.
> 
> Signed-off-by: David A. McMillen <davem at systemfabricworks.com>
> ---
>  infiniband-diags/src/ibnetdiscover.c |   17 +++++++++++++----
>  1 files changed, 13 insertions(+), 4 deletions(-)
> 
> diff --git a/infiniband-diags/src/ibnetdiscover.c
> b/infiniband-diags/src/ibnetdiscover.c
> index 948a79d..3ace235 100644
> --- a/infiniband-diags/src/ibnetdiscover.c
> +++ b/infiniband-diags/src/ibnetdiscover.c
> @@ -903,15 +903,24 @@ void dump_ports_report ()
>                                        fprintf(stdout,
>                                                " - %2s %5d %2d 0x%016"
> PRIx64
>                                                " ( '%s' - '%s' )\n",
> -
> node_type_str2(port->remoteport->node),
> +                                               node_type_str2(port->
> +                                                       remoteport->node),
>                                                port->remoteport->lid,
>                                                port->remoteport->portnum,
>                                                port->remoteport->portguid,
> -                                               port->node->nodedesc,
> -
> port->remoteport->node->nodedesc);
> +
> remap_node_name(node_name_map,
> +                                                   port->node->nodeguid,
> +                                                   port->node->nodedesc),
> +
> remap_node_name(node_name_map,
> +                                                   port->remoteport->node->
> +                                                       nodeguid,
> +                                                   port->remoteport->node->
> +                                                       nodedesc));
>                                else
>                                        fprintf(stdout, "%36s'%s'\n", "",
> -                                               port->node->nodedesc);
> +
> remap_node_name(node_name_map,
> +                                                   port->node->nodeguid,
> +                                                   port->node->nodedesc));
>                        }
>                        n++;
>                }
> 


-- 
Ira Weiny
Math Programer/Computer Scientist
Larence Livermore National Lab
weiny2 at llnl.gov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-infiniband-diags-ibnetdiscover-Apply-node-name-ma.patch
Type: application/octet-stream
Size: 1342 bytes
Desc: not available
URL: <http://lists.openfabrics.org/pipermail/general/attachments/20090309/e1eb0f5e/attachment.obj>


More information about the general mailing list