Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 591929 Details for
Bug 824964
dlm: deadlock between dlm_send and dlm_controld
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
possible patch, untested
lowcomms.patch (text/plain), 2.16 KB, created by
David Teigland
on 2012-06-14 21:17:24 UTC
(
hide
)
Description:
possible patch, untested
Filename:
MIME Type:
Creator:
David Teigland
Created:
2012-06-14 21:17:24 UTC
Size:
2.16 KB
patch
obsolete
>diff --git a/fs/dlm/lowcomms.c b/fs/dlm/lowcomms.c >index 5c1b0e3..36fed2f 100644 >--- a/fs/dlm/lowcomms.c >+++ b/fs/dlm/lowcomms.c >@@ -933,6 +933,7 @@ static void tcp_connect_to_sock(struct connection *con) > int addr_len; > struct socket *sock = NULL; > int one = 1; >+ int rv; > > if (con->nodeid == 0) { > log_print("attempt to connect sock 0 foiled"); >@@ -956,8 +957,19 @@ static void tcp_connect_to_sock(struct connection *con) > goto out_err; > > memset(&saddr, 0, sizeof(saddr)); >- if (dlm_nodeid_to_addr(con->nodeid, &saddr)) >+ >+ mutex_lock(&connections_lock); >+ if (test_bit(CF_CLOSE, &con->flags)) { >+ mutex_unlock(&connections_lock); > goto out_err; >+ } >+ >+ rv = dlm_nodeid_to_addr(con->nodeid, &saddr); >+ if (rv) { >+ mutex_unlock(&connections_lock); >+ goto out_err; >+ } >+ mutex_unlock(&connections_lock); > > sock->sk->sk_user_data = con; > con->rx_action = receive_from_sock; >@@ -983,9 +995,8 @@ static void tcp_connect_to_sock(struct connection *con) > kernel_setsockopt(sock, SOL_TCP, TCP_NODELAY, (char *)&one, > sizeof(one)); > >- result = >- sock->ops->connect(sock, (struct sockaddr *)&saddr, addr_len, >- O_NONBLOCK); >+ result = sock->ops->connect(sock, (struct sockaddr *)&saddr, addr_len, >+ O_NONBLOCK); > if (result == -EINPROGRESS) > result = 0; > if (result == 0) >@@ -1416,11 +1427,17 @@ int dlm_lowcomms_close(int nodeid) > struct connection *con; > > log_print("closing connection to node %d", nodeid); >- con = nodeid2con(nodeid, 0); >+ >+ mutex_lock(&connections_lock); >+ con = __nodeid2con(nodeid, 0); > if (con) { > clear_bit(CF_CONNECT_PENDING, &con->flags); > clear_bit(CF_WRITE_PENDING, &con->flags); > set_bit(CF_CLOSE, &con->flags); >+ } >+ mutex_unlock(&connections_lock); >+ >+ if (con) { > if (cancel_work_sync(&con->swork)) > log_print("canceled swork for node %d", nodeid); > if (cancel_work_sync(&con->rwork)) >@@ -1448,6 +1465,9 @@ static void process_send_sockets(struct work_struct *work) > { > struct connection *con = container_of(work, struct connection, swork); > >+ if (test_bit(CF_CLOSE, &con->flags)) >+ return; >+ > if (test_and_clear_bit(CF_CONNECT_PENDING, &con->flags)) { > con->connect_action(con); > set_bit(CF_WRITE_PENDING, &con->flags);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 824964
:
591929
|
600809