RDMA/nes: silence compiler warning
Subsystems (2)
PATCH 1/1 RDMA/nes: silence compiler warning
drivers/infiniband/hw/nes/nes_cm.c:3190:2: warning: format ‘%zu’
expects argument of type ‘size_t’, but argument 11 has type ‘int’ [-Wformat]
The warning says the type is "int" but actually it's unsigned short.
drivers/infiniband/hw/nes/nes_cm.c +1 -1
@@ -3189,7 +3189,7 @@ int nes_accept(struct iw_cm_id *cm_id, struct iw_cm_conn_param *conn_param) nes_debug(NES_DBG_CM, "QP%u, Destination IP = 0x%08X:0x%04X, local = " "0x%08X:0x%04X, rcv_nxt=0x%08X, snd_nxt=0x%08X, mpa + " - "private data length=%zu.\n", nesqp->hwqp.qp_id, + "private data length=%d.\n", nesqp->hwqp.qp_id, ntohl(cm_id->remote_addr.sin_addr.s_addr), ntohs(cm_id->remote_addr.sin_port), ntohl(cm_id->local_addr.sin_addr.s_addr),
RGFuIENhcnBlbnRlciBXcm90ZToNCg0KPiBTaWduZWQtb2ZmLWJ5OiBEYW4gQ2FycGVudGVyIDxk YW4uY2FycGVudGVyQG9yYWNsZS5jb20+DQo+IA0KPiBkaWZmIC0tZ2l0IGEvZHJpdmVycy9pbmZp bmliYW5kL2h3L25lcy9uZXNfY20uYw0KPiBiL2RyaXZlcnMvaW5maW5pYmFuZC9ody9uZXMvbmVz X2NtLmMNCj4gaW5kZXggMTY2NjdjNy4uYjk2ZWM0MyAxMDA2NDQNCj4gLS0tIGEvZHJpdmVycy9p bmZpbmliYW5kL2h3L25lcy9uZXNfY20uYw0KPiArKysgYi9kcml2ZXJzL2luZmluaWJhbmQvaHcv bmVzL25lc19jbS5jDQo+IEBAIC0zMTg5LDcgKzMxODksNyBAQCBpbnQgbmVzX2FjY2VwdChzdHJ1 Y3QgaXdfY21faWQgKmNtX2lkLCBzdHJ1Y3QNCj4gaXdfY21fY29ubl9wYXJhbSAqY29ubl9wYXJh bSkNCj4gDQo+ICAJbmVzX2RlYnVnKE5FU19EQkdfQ00sICJRUCV1LCBEZXN0aW5hdGlvbiBJUCA9 IDB4JTA4WDoweCUwNFgsDQo+IGxvY2FsID0gIg0KPiAgCQkgICIweCUwOFg6MHglMDRYLCByY3Zf bnh0PTB4JTA4WCwgc25kX254dD0weCUwOFgsIG1wYSArICINCj4gLQkJICAicHJpdmF0ZSBkYXRh IGxlbmd0aD0lenUuXG4iLCBuZXNxcC0+aHdxcC5xcF9pZCwNCj4gKwkJICAicHJpdmF0ZSBkYXRh IGxlbmd0aD0lZC5cbiIsIG5lc3FwLT5od3FwLnFwX2lkLA0KPiAgCQkgIG50b2hsKGNtX2lkLT5y ZW1vdGVfYWRkci5zaW5fYWRkci5zX2FkZHIpLA0KPiAgCQkgIG50b2hzKGNtX2lkLT5yZW1vdGVf YWRkci5zaW5fcG9ydCksDQo+ICAJCSAgbnRvaGwoY21faWQtPmxvY2FsX2FkZHIuc2luX2FkZHIu c19hZGRyKSwNCg0KQWNrZWQtYnk6IEZhaXNhbCBMYXRpZiA8ZmFpc2FsLmxhdGlmQGludGVsLmNv bT4NCg0K
Thanks, I rolled this into the patch (which was still pending) that introduced this into my tree.
Quoted 7 lines · Dan Carpenter
nes_debug(NES_DBG_CM, "QP%u, Destination IP = 0x%08X:0x%04X, local = " "0x%08X:0x%04X, rcv_nxt=0x%08X, snd_nxt=0x%08X, mpa + "
- "private data length=%zu.\n",nesqp->hwqp.qp_id,
+ "private data length=%d.\n",nesqp->hwqp.qp_id,ntohl(cm_id->remote_addr.sin_addr.s_addr),ntohs(cm_id->remote_addr.sin_port),ntohl(cm_id->local_addr.sin_addr.s_addr),
By the way, could this debug message be using %pI4 instead of %08X to print IP addresses?
- R.
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 23 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Roland Dreier
Sent: Monday, October 17, 2011 1:15 PM
To: Dan Carpenter
Cc: Latif, Faisal; Hefty, Sean; Hal Rosenstock; linux- [email protected]; [email protected]
Subject: Re: [patch] RDMA/nes: silence compiler warningQuoted 1 line · Dan Carpenter
nes_debug(NES_DBG_CM, "QP%u, Destination IP = 0x%08X:0x%04X,
local = "
Quoted 1 line
"0x%08X:0x%04X, rcv_nxt=0x%08X, snd_nxt=0x%08X, mpa
+ "
Quoted 5 lines
- "private data length=%zu.\n",
nesqp->hwqp.qp_id,
+ "private data length=%d.\n",nesqp->hwqp.qp_id,ntohl(cm_id->remote_addr.sin_addr.s_addr),ntohs(cm_id->remote_addr.sin_port),ntohl(cm_id->local_addr.sin_addr.s_addr),
Quoted 4 lines
By the way, could this debug message be using %pI4 instead of %08X to print IP addresses?
- R.
Yes, We should have used %pI4 for this also.
Thanks
Faisal
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 1 line · Faisal
Yes, We should have used %pI4 for this also.
Any chance of you guys going through and converting IP printing to %pI4 in the whole driver?
- R.
Quoted 11 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Roland Dreier
Sent: Tuesday, October 18, 2011 12:11 PM
To: Latif, Faisal
Cc: Dan Carpenter; Hefty, Sean; Hal Rosenstock; linux- [email protected]; [email protected]
Subject: Re: [patch] RDMA/nes: silence compiler warning
Quoted 8 lines
Quoted 1 line · Faisal
Yes, We should have used %pI4 for this also.
Any chance of you guys going through and converting IP printing to %pI4 in the whole driver?
- R.
I will get patch out to you to convert the IP printing. Thanks for pointing it out.
Faisal