This patch fixes Logically dead code reported by
coverity run. This uncovers the missing call
to lustre_lnet_list_peer() to list peer under
old API.
CoverityID: 404746 ("Logically dead code")
Test-Parameters: trivial testlist=sanity-lnet
Fixes:
f0be00678c ("LU-9680 lnet: collect data about peer_ni by using Netlink")
Signed-off-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
Change-Id: I0659ce403110118697fb8c88ade70f1695509382
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/52921
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Chris Horn <chris.horn@hpe.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
static int jt_list_peer(int argc, char **argv)
{
- int rc;
struct cYAML *err_rc = NULL, *list_rc = NULL;
+ int rc;
rc = check_cmd(peer_cmds, "peer", "list", 0, argc, argv);
if (rc)
goto old_api;
return rc;
}
+
old_api:
+ rc = lustre_lnet_list_peer(-1, &list_rc, &err_rc);
if (rc != LUSTRE_CFG_RC_NO_ERR)
cYAML_print_tree2file(stderr, err_rc);
else if (list_rc)