We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2e67fa3 commit a6b39abCopy full SHA for a6b39ab
1 file changed
src/nvme/fabrics.c
@@ -1284,6 +1284,17 @@ static void sanitize_discovery_log_entry(struct nvmf_disc_log_entry *e)
1284
{
1285
strchomp(e->trsvcid, sizeof(e->trsvcid));
1286
strchomp(e->traddr, sizeof(e->traddr));
1287
+
1288
+ /*
1289
+ * Report traddr always in 'nn-0x:pn-0x' format, but some discovery logs
1290
+ * provide 'nn-0x,pn-0x'.
1291
+ */
1292
+ if (e->trtype == NVMF_TRTYPE_FC) {
1293
+ char *comma = strchr(e->traddr, ',');
1294
1295
+ if (comma)
1296
+ *comma = ':';
1297
+ }
1298
}
1299
1300
int nvmf_get_discovery_log(nvme_ctrl_t c, struct nvmf_discovery_log **logp,
0 commit comments