diff mbox

[TRIVIAL,infiniband-diags] ibportstate.c: When not switch, port can be router port

Message ID f44f2a4f-15f7-6ae5-d1fb-7af0a77aeaee@dev.mellanox.co.il (mailing list archive)
State Accepted, archived
Delegated to: Ira Weiny
Headers show

Commit Message

Hal Rosenstock Sept. 23, 2016, 1:17 p.m. UTC
Indicate PortInfo is on CA/RT port rather than just CA port when not
on Switch port. RT is what's used by ibnetdiscover for router nodes.

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
---
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Ira Weiny Sept. 26, 2016, 5:47 a.m. UTC | #1
On Fri, Sep 23, 2016 at 09:17:10AM -0400, Hal Rosenstock wrote:
> 
> Indicate PortInfo is on CA/RT port rather than just CA port when not
> on Switch port. RT is what's used by ibnetdiscover for router nodes.
> 
> Signed-off-by: Hal Rosenstock <hal@mellanox.com>

Thanks Applied,
Ira

> ---
> diff --git a/src/ibportstate.c b/src/ibportstate.c
> index cb47aa9..cfb8be7 100644
> --- a/src/ibportstate.c
> +++ b/src/ibportstate.c
> @@ -522,9 +522,9 @@ int main(int argc, char **argv)
>  		IBEXIT("Can't set M_Key fields on switch port != 0");
>  
>  	if (port_op != QUERY || changed)
> -		printf("Initial %s PortInfo:\n", is_switch ? "Switch" : "CA");
> +		printf("Initial %s PortInfo:\n", is_switch ? "Switch" : "CA/RT");
>  	else
> -		printf("%s PortInfo:\n", is_switch ? "Switch" : "CA");
> +		printf("%s PortInfo:\n", is_switch ? "Switch" : "CA/RT");
>  	espeed_cap = get_port_info(&portid, data, portnum, is_switch);
>  	show_port_info(&portid, data, portnum, espeed_cap, is_switch);
>  	if (is_mlnx_ext_port_info_supported(devid)) {
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Ira Weiny Oct. 18, 2016, 4:25 p.m. UTC | #2
On Fri, Sep 23, 2016 at 09:17:10AM -0400, Hal Rosenstock wrote:
> 
> Indicate PortInfo is on CA/RT port rather than just CA port when not
> on Switch port. RT is what's used by ibnetdiscover for router nodes.
> 
> Signed-off-by: Hal Rosenstock <hal@mellanox.com>
>

Thanks applied,
Ira

> ---
> diff --git a/src/ibportstate.c b/src/ibportstate.c
> index cb47aa9..cfb8be7 100644
> --- a/src/ibportstate.c
> +++ b/src/ibportstate.c
> @@ -522,9 +522,9 @@ int main(int argc, char **argv)
>  		IBEXIT("Can't set M_Key fields on switch port != 0");
>  
>  	if (port_op != QUERY || changed)
> -		printf("Initial %s PortInfo:\n", is_switch ? "Switch" : "CA");
> +		printf("Initial %s PortInfo:\n", is_switch ? "Switch" : "CA/RT");
>  	else
> -		printf("%s PortInfo:\n", is_switch ? "Switch" : "CA");
> +		printf("%s PortInfo:\n", is_switch ? "Switch" : "CA/RT");
>  	espeed_cap = get_port_info(&portid, data, portnum, is_switch);
>  	show_port_info(&portid, data, portnum, espeed_cap, is_switch);
>  	if (is_mlnx_ext_port_info_supported(devid)) {
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/src/ibportstate.c b/src/ibportstate.c
index cb47aa9..cfb8be7 100644
--- a/src/ibportstate.c
+++ b/src/ibportstate.c
@@ -522,9 +522,9 @@  int main(int argc, char **argv)
 		IBEXIT("Can't set M_Key fields on switch port != 0");
 
 	if (port_op != QUERY || changed)
-		printf("Initial %s PortInfo:\n", is_switch ? "Switch" : "CA");
+		printf("Initial %s PortInfo:\n", is_switch ? "Switch" : "CA/RT");
 	else
-		printf("%s PortInfo:\n", is_switch ? "Switch" : "CA");
+		printf("%s PortInfo:\n", is_switch ? "Switch" : "CA/RT");
 	espeed_cap = get_port_info(&portid, data, portnum, is_switch);
 	show_port_info(&portid, data, portnum, espeed_cap, is_switch);
 	if (is_mlnx_ext_port_info_supported(devid)) {