home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / BC_DICE2.DMS / in.adf / INCLUDE / exec / semaphores.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-01-10  |  886 b   |  63 lines

  1. #ifndef EXEC_SEMAPHORES_H
  2. #define EXEC_SEMAPHORES_H
  3. /*
  4. ** $Filename: exec/semaphores.h $
  5. ** $Release: 2.04 Includes, V37.4 $
  6. ** $Revision: 36.6 $
  7. ** $Date: 90/05/10 $
  8. **
  9. ** Definitions for locking functions.
  10. **
  11. ** (C) Copyright 1986-1991 Commodore-Amiga, Inc.
  12. ** All Rights Reserved
  13. */
  14.  
  15. #ifndef EXEC_NODES_H
  16. #include "exec/nodes.h"
  17. #endif 
  18.  
  19. #ifndef EXEC_LISTS_H
  20. #include "exec/lists.h"
  21. #endif 
  22.  
  23. #ifndef EXEC_PORTS_H
  24. #include "exec/ports.h"
  25. #endif 
  26.  
  27. #ifndef EXEC_TASKS_H
  28. #include "exec/tasks.h"
  29. #endif 
  30.  
  31.  
  32.  
  33.  
  34.  
  35. struct SemaphoreRequest {
  36.  struct MinNode sr_Link;
  37.  struct Task *sr_Waiter;
  38. };
  39.  
  40.  
  41. struct SignalSemaphore {
  42.  struct Node ss_Link;
  43.  WORD ss_NestCount;
  44.  struct MinList ss_WaitQueue;
  45.  struct SemaphoreRequest ss_MultipleLink;
  46.  struct Task *ss_Owner;
  47.  WORD ss_QueueCount;
  48. };
  49.  
  50.  
  51.  
  52.  
  53.  
  54. struct Semaphore {
  55.  struct MsgPort sm_MsgPort;
  56.  WORD sm_Bids;
  57. };
  58.  
  59. #define sm_LockMsg mp_SigTask
  60.  
  61.  
  62. #endif 
  63.