Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 214468
b: refs/heads/master
c: ffcec0e
h: refs/heads/master
v: v3
  • Loading branch information
Zach Brown authored and Andy Grover committed Sep 9, 2010
1 parent 4ef6c39 commit daf0293
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5adb5bc65f93e52341c3fc9d03d4030dd375e256
refs/heads/master: ffcec0e110c198717eb0f6ac000c1e5397db9451
9 changes: 7 additions & 2 deletions trunk/net/rds/connection.c
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,10 @@ void rds_conn_shutdown(struct rds_connection *conn)

/*
* Stop and free a connection.
*
* This can only be used in very limited circumstances. It assumes that once
* the conn has been shutdown that no one else is referencing the connection.
* We can only ensure this in the rmmod path in the current code.
*/
void rds_conn_destroy(struct rds_connection *conn)
{
Expand All @@ -326,10 +330,11 @@ void rds_conn_destroy(struct rds_connection *conn)
spin_lock_irq(&rds_conn_lock);
hlist_del_init_rcu(&conn->c_hash_node);
spin_unlock_irq(&rds_conn_lock);

synchronize_rcu();

rds_conn_shutdown(conn);
/* shut the connection down */
rds_conn_drop(conn);
flush_work(&conn->c_down_w);

/* tear down queued messages */
list_for_each_entry_safe(rm, rtmp,
Expand Down

0 comments on commit daf0293

Please sign in to comment.