Commit 67478857 authored by Namjae Jeon's avatar Namjae Jeon Committed by Steve French
Browse files

ksmbd: add an error print when maximum IP connections limit is reached



This change introduces an error print using pr_info_ratelimited()
to prevent excessive logging. This message will inform the user that
the limit for maximum IP connections has been hit and what that
current count is, which can be useful for debugging and monitoring
connection limits.

Signed-off-by: default avatarNamjae Jeon <linkinjeon@kernel.org>
Signed-off-by: default avatarSteve French <stfrench@microsoft.com>
parent d8b6dc92
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -266,6 +266,8 @@ static int ksmbd_kthread_fn(void *p)
				max_ip_conns++;
#endif
			if (server_conf.max_ip_connections <= max_ip_conns) {
				pr_info_ratelimited("Maximum IP connections exceeded (%u/%u)\n",
						    max_ip_conns, server_conf.max_ip_connections);
				ret = -EAGAIN;
				break;
			}