Changeset d8f7362 in mainline for generic/src/ipc/ipc.c
- Timestamp:
- 2006-06-05T22:19:02Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- c74804f
- Parents:
- b65caba1
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
generic/src/ipc/ipc.c
rb65caba1 rd8f7362 238 238 * 239 239 * @param phone Phone to be hung up 240 * @param aggressive If false, the phone is only marked hungup, and all241 * messages are allowed to complete.242 * If true, all messages in all queues are discarded. There243 * may still be some messages that will be 'in-transit' on244 * other CPU.245 240 * 246 241 * @return 0 - phone disconnected, -1 - the phone was already disconnected 247 242 */ 248 int ipc_phone_hangup(phone_t *phone , int aggressive)243 int ipc_phone_hangup(phone_t *phone) 249 244 { 250 245 answerbox_t *box; … … 270 265 _ipc_call(phone, box, call); 271 266 } 272 }273 274 if (aggressive && atomic_get(&phone->active_calls) > 0) {275 /* TODO: Do some stuff be VERY aggressive */276 267 } 277 268 … … 383 374 /* Disconnect all our phones ('ipc_phone_hangup') */ 384 375 for (i=0;i < IPC_MAX_PHONES; i++) 385 ipc_phone_hangup(&TASK->phones[i] , 1);376 ipc_phone_hangup(&TASK->phones[i]); 386 377 387 378 /* Disconnect all connected irqs */ … … 422 413 TASK->phones[i].state = IPC_PHONE_FREE; 423 414 415 /* Just for sure, we might have had some 416 * IPC_PHONE_CONNECTING phones */ 424 417 if (TASK->phones[i].state == IPC_PHONE_CONNECTED) 425 ipc_phone_hangup(&TASK->phones[i], 1); 418 ipc_phone_hangup(&TASK->phones[i]); 419 /* If the hangup succeeded, it has sent a HANGUP 420 * message, the IPC is now in HUNGUP state, we 421 * wait for the reply to come */ 426 422 427 423 if (TASK->phones[i].state != IPC_PHONE_FREE)
Note:
See TracChangeset
for help on using the changeset viewer.