Changeset a1dc7fe in mainline for uspace/lib/c/generic/async_sess.c
- Timestamp:
- 2010-12-26T17:43:23Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 8cd21d16
- Parents:
- d1c041a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/async_sess.c
rd1c041a ra1dc7fe 114 114 115 115 /** 116 * Mutex protecting the inactive_conn_head list and the session _hash hash table.116 * Mutex protecting the inactive_conn_head list and the session list. 117 117 */ 118 118 static fibril_mutex_t async_sess_mutex; … … 124 124 125 125 /** 126 * List of all existingsessions.127 */ 128 //static LIST_INITIALIZE(session_list);126 * List of all open sessions. 127 */ 128 static LIST_INITIALIZE(session_list_head); 129 129 130 130 /** Initialize the async_sess subsystem. … … 136 136 fibril_mutex_initialize(&async_sess_mutex); 137 137 list_initialize(&inactive_conn_head); 138 list_initialize(&session_list_head); 138 139 } 139 140 … … 142 143 sess->sess_phone = phone; 143 144 list_initialize(&sess->conn_head); 145 146 /* Add to list of sessions. */ 147 fibril_mutex_lock(&async_sess_mutex); 148 list_append(&sess->sess_link, &session_list_head); 149 fibril_mutex_unlock(&async_sess_mutex); 144 150 } 145 151 … … 147 153 { 148 154 conn_node_t *conn; 155 156 /* Remove from list of sessions. */ 157 fibril_mutex_lock(&async_sess_mutex); 158 list_remove(&sess->sess_link); 159 fibril_mutex_unlock(&async_sess_mutex); 149 160 150 161 /* We did not connect the phone so we do not hang it up either. */
Note:
See TracChangeset
for help on using the changeset viewer.