Commit 9a4139a7 authored by Alexander Aring's avatar Alexander Aring Committed by David Teigland

fs: dlm: move dlm allow conn

This patch checks if possible allowing new connections is allowed before
queueing the listen socket to accept new connections.
Signed-off-by: default avatarAlexander Aring <aahringo@redhat.com>
Signed-off-by: default avatarDavid Teigland <teigland@redhat.com>
parent 6c6a1cc6
......@@ -471,6 +471,9 @@ static void lowcomms_data_ready(struct sock *sk)
static void lowcomms_listen_data_ready(struct sock *sk)
{
if (!dlm_allow_conn)
return;
queue_work(recv_workqueue, &listen_con.rwork);
}
......@@ -969,10 +972,6 @@ static int accept_from_sock(struct listen_connection *con)
struct connection *addcon;
unsigned int mark;
if (!dlm_allow_conn) {
return -1;
}
if (!con->sock)
return -ENOTCONN;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment