From 703b52c6ef69a54a0f03ef67fa7b64e9c59307bc Mon Sep 17 00:00:00 2001 From: Maher Sanalla Date: Thu, 19 Sep 2024 11:21:16 +0300 Subject: [PATCH] ibdiags: Do not panic on ibstat query failure ibstat relies on umad_get_ca() to retrieve device's statistics. However, in case the latter function fails on a certain device, ibstat panics and exits before processing and displaying other device's statistics which may be obtainable. Thus, warn on failed device query and continue querying the remaining devices instead of an early exit. Signed-off-by: Maher Sanalla Reviewed-by: Leon Romanovsky Signed-off-by: Yishai Hadas --- infiniband-diags/ibstat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/infiniband-diags/ibstat.c b/infiniband-diags/ibstat.c index bdf0f9017..5e918aa57 100644 --- a/infiniband-diags/ibstat.c +++ b/infiniband-diags/ibstat.c @@ -338,7 +338,7 @@ int main(int argc, char *argv[]) if (list_only) printf("%s\n", ca_name); else if (ca_stat(ca_name, dev_port, short_format) < 0) - IBPANIC("stat of IB device '%s' failed", ca_name); + IBWARN("stat of IB device '%s' failed", ca_name); } umad_free_ca_device_list(device_list); return 0;