diff mbox

[TRIVIAL,infiniband-diags] ibaddr.c: Fix LID printfs to be unsigned rather than signed

Message ID b0f11628-e2ef-15d9-5a9e-68edbc81ca77@dev.mellanox.co.il (mailing list archive)
State Accepted, archived
Delegated to: Ira Weiny
Headers show

Commit Message

Hal Rosenstock Sept. 26, 2016, 11:38 a.m. UTC
%u is what's used in other places for unicast LIDs

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 Oct. 18, 2016, 4:27 p.m. UTC | #1
On Mon, Sep 26, 2016 at 07:38:46AM -0400, Hal Rosenstock wrote:
> 
> %u is what's used in other places for unicast LIDs
> 
> Signed-off-by: Hal Rosenstock <hal@mellanox.com>

Thanks applied,
Ira

> ---
> diff --git a/src/ibaddr.c b/src/ibaddr.c
> index 5845b4e..1a721d0 100644
> --- a/src/ibaddr.c
> +++ b/src/ibaddr.c
> @@ -83,7 +83,7 @@ static int ib_resolve_addr(ib_portid_t * portid, int portnum, int show_lid,
>  		printf("LID start 0x%x end 0x%x", portid->lid,
>  		       portid->lid + (1 << lmc) - 1);
>  	else if (show_lid < 0)
> -		printf("LID start %d end %d", portid->lid,
> +		printf("LID start %u end %u", portid->lid,
>  		       portid->lid + (1 << lmc) - 1);
>  	printf("\n");
>  	return 0;
--
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/ibaddr.c b/src/ibaddr.c
index 5845b4e..1a721d0 100644
--- a/src/ibaddr.c
+++ b/src/ibaddr.c
@@ -83,7 +83,7 @@  static int ib_resolve_addr(ib_portid_t * portid, int portnum, int show_lid,
 		printf("LID start 0x%x end 0x%x", portid->lid,
 		       portid->lid + (1 << lmc) - 1);
 	else if (show_lid < 0)
-		printf("LID start %d end %d", portid->lid,
+		printf("LID start %u end %u", portid->lid,
 		       portid->lid + (1 << lmc) - 1);
 	printf("\n");
 	return 0;