Skip to content

Commit f0dd975

Browse files
martin-gpyigaw
authored andcommitted
fabrics: add additional debug messages for --tls and --concat
Add additional debug messages when --tls and --concat is set respectively based on the treq and sectype fields for a given record in the discovery log page data during a nvme connect-all. This makes it easier to debug, otherwise can be quite confusing to the end user. Signed-off-by: Martin George <[email protected]>
1 parent 5fd3e9b commit f0dd975

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

libnvme/src/nvme/fabrics.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1209,10 +1209,15 @@ static int nvmf_connect_disc_entry(nvme_host_t h,
12091209

12101210
if (e->trtype == NVMF_TRTYPE_TCP &&
12111211
e->tsas.tcp.sectype != NVMF_TCP_SECTYPE_NONE) {
1212-
if (e->treq & NVMF_TREQ_REQUIRED)
1212+
if (e->treq & NVMF_TREQ_REQUIRED) {
1213+
nvme_msg(h->ctx, LOG_DEBUG, "setting --tls due to treq %s and sectype %s\n",
1214+
nvmf_treq_str(e->treq), nvmf_sectype_str(e->tsas.tcp.sectype));
12131215
c->cfg.tls = true;
1214-
else if (e->treq & NVMF_TREQ_NOT_REQUIRED)
1216+
} else if (e->treq & NVMF_TREQ_NOT_REQUIRED) {
1217+
nvme_msg(h->ctx, LOG_DEBUG, "setting --concat due to treq %s and sectype %s\n",
1218+
nvmf_treq_str(e->treq), nvmf_sectype_str(e->tsas.tcp.sectype));
12151219
c->cfg.concat = true;
1220+
}
12161221
}
12171222

12181223
ret = nvmf_add_ctrl(h, c, cfg);

0 commit comments

Comments
 (0)