[Devel] [PATCH vz9] fs/fuse kio: ignore rpc errors with uninitialized addrs

Yuriy Vasilev yuriy.vasilev at virtuozzo.com
Fri Aug 11 14:09:09 MSK 2023


Pass addr with PCS_ADDRTYPE_NONE to netaddr_cmp will lead to BUG. Let's
skip these errors.

Affects: #VSTOR-73400

Signed-off-by: Yuriy Vasilev <yuriy.vasilev at virtuozzo.com>
---
 fs/fuse/kio/pcs/pcs_fuse_kdirect.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/fs/fuse/kio/pcs/pcs_fuse_kdirect.c b/fs/fuse/kio/pcs/pcs_fuse_kdirect.c
index 706da8e536c9..e122a6d1f6cb 100644
--- a/fs/fuse/kio/pcs/pcs_fuse_kdirect.c
+++ b/fs/fuse/kio/pcs/pcs_fuse_kdirect.c
@@ -1386,6 +1386,9 @@ void fuse_rpc_error_account(struct fuse_error_metrics *metrics,
 		return;
 	}
 
+	if (addr->type == PCS_ADDRTYPE_NONE)
+		return;
+
 	metric = NULL;
 	mutex_lock(&metrics->mutex);
 	list_for_each_entry(entry, &metrics->fuse_rpc_error_metric_list, list) {
-- 
2.34.1



More information about the Devel mailing list