home *** CD-ROM | disk | FTP | other *** search
/ RISC DISC 1 / RISC_DISC_1.iso / pd_share / code / oslib / Hdr / OSModule < prev    next >
Encoding:
Text File  |  1994-09-14  |  7.5 KB  |  308 lines

  1. ;AAsm header file for OSModule
  2. ;written by DefMod (Aug  8 1994) on Wed Sep 14 13:20:15 1994
  3.  
  4.         [       :LNOT: :DEF: Get_Types
  5.         GBLS    Get_Types
  6. Get_Types                       SETS    "GET OS:Hdr.Types"
  7.         |
  8. Get_Types                       SETS    ""
  9.         ]
  10.         $Get_Types
  11.  
  12.         [       :LNOT: :DEF: Get_OS
  13.         GBLS    Get_OS
  14. Get_OS                          SETS    "GET OS:Hdr.OS"
  15.         |
  16. Get_OS                          SETS    ""
  17.         ]
  18.         $Get_OS
  19.  
  20.         [       :LNOT: :DEF: OSModule_Hdr
  21.         GBLS    OSModule_Hdr
  22.  
  23. ;Symbols for constants
  24. OSModule_EntryStart             *       0
  25. OSModule_EntryInit              *       4
  26. OSModule_EntryDie               *       8
  27. OSModule_EntryService           *       12
  28. OSModule_EntryTitle             *       16
  29. OSModule_EntryHelp              *       20
  30. OSModule_EntryTable             *       24
  31. OSModule_EntrySWIChunk          *       28
  32. OSModule_EntrySWIEntry          *       32
  33. OSModule_EntryNameTable         *       36
  34. OSModule_EntryNameCode          *       40
  35. OSModule_SWIChunkSize           *       64
  36. OSModule_SWISystemBase          *       262144
  37. OSModule_SWIApplicationBase     *       524288
  38. OSModule_SWIUserBase            *       786432
  39. OSModule_SectionSystem          *       -1
  40. OSModule_SectionCard0           *       0
  41. OSModule_SectionCard1           *       1
  42. OSModule_SectionCard2           *       2
  43. OSModule_SectionCard3           *       3
  44. OSModule_SectionROM1            *       -2
  45. OSModule_SectionROM2            *       -3
  46. OSModule_SectionROM3            *       -4
  47. OSModule_SectionROM4            *       -5
  48. OSModule_StatusUnplugged        *       -1
  49. OSModule_StatusDormant          *       0
  50. OSModule_StatusActive           *       1
  51. OSModule_StatusRunning          *       2
  52. Error_ModuleNotMod              *       &100
  53. Error_ModuleMHNoRoom            *       &101
  54. Error_ModuleRMNotFound          *       &102
  55. Error_ModuleCantKill            *       &103
  56. Error_ModuleCantKill2           *       &103
  57. Error_ModuleWimpCantKill        *       &103
  58. Error_ModuleBadModuleReason     *       &104
  59. Error_ModuleBadDynamicArea      *       &104
  60. Error_ModuleRMNotFoundInROM     *       &105
  61. Error_ModuleModulePostfix       *       &106
  62. Error_ModuleNoMoreModules       *       &107
  63. Error_ModuleNoMoreIncarnations  *       &108
  64. Error_ModulePostfixNeeded       *       &109
  65. Error_ModuleIncarnationExists   *       &10A
  66. Error_ModuleIncarnationNotFound *       &10B
  67. Error_ModuleChunkNotRM          *       &10C
  68. Error_ModuleBadRMHeaderField    *       &10D
  69. Error_ModuleModuleTooOld        *       &10E
  70. Error_ModuleModuleBadSWI        *       &10F
  71. Error_ModuleModuleInUse         *       &110
  72. Error_ModuleBadFilingSystemOperation *       &111
  73. Error_ModuleFilingSystemReadOnly *       &112
  74. Error_ModuleNotADir             *       &113
  75.  
  76. ;Symbols for SWI's and SWI reason codes
  77. XOS_Module                      *       &2001E
  78. OS_Module                       *       &1E
  79.  
  80. OSModule_Run                    *       &0
  81.    ;Entry
  82.    ;  R0 = &0
  83.    ;  R1 -> tail (String)
  84.  
  85. OSModule_Load                   *       &1
  86.    ;Entry
  87.    ;  R0 = &1
  88.    ;  R1 -> tail (String)
  89.  
  90. OSModule_Enter                  *       &2
  91.    ;Entry
  92.    ;  R0 = &2
  93.    ;  R1 -> module_name (String)
  94.    ;  R2 -> args (String)
  95.  
  96. OSModule_Reinit                 *       &3
  97.    ;Entry
  98.    ;  R0 = &3
  99.    ;  R1 -> tail (String)
  100.  
  101. OSModule_Kill                   *       &4
  102.    ;Entry
  103.    ;  R0 = &4
  104.    ;  R1 -> module_name (String)
  105.  
  106. OSModule_Info                   *       &5
  107.    ;Entry
  108.    ;  R0 = &5
  109.    ;Exit
  110.    ;  R2 = max (Int)
  111.    ;  R3 = free (Int)
  112.  
  113. OSModule_Alloc                  *       &6
  114.    ;Entry
  115.    ;  R0 = &6
  116.    ;  R3 = size (Int)
  117.    ;Exit
  118.    ;  R2 = blk (pointer to Void)
  119.  
  120. OSModule_Free                   *       &7
  121.    ;Entry
  122.    ;  R0 = &7
  123.    ;  R2 = blk (pointer to Void)
  124.  
  125. OSModule_Tidy                   *       &8
  126.    ;Entry
  127.    ;  R0 = &8
  128.  
  129. OSModule_Clear                  *       &9
  130.    ;Entry
  131.    ;  R0 = &9
  132.  
  133. OSModule_AddArea                *       &A
  134.    ;Entry
  135.    ;  R0 = &A
  136.    ;  R1 -> module (data)
  137.  
  138. OSModule_CopyArea               *       &B
  139.    ;Entry
  140.    ;  R0 = &B
  141.    ;  R1 -> module (data)
  142.    ;  R2 = size (Int)
  143.  
  144. OSModule_Enumerate              *       &C
  145.    ;Entry
  146.    ;  R0 = &C
  147.    ;  R1 = module_no (Int)
  148.    ;  R2 = instance_no (Int)
  149.    ;Exit
  150.    ;  R1 = module_no_out (Int)
  151.    ;  R2 = instance_no_out (Int)
  152.    ;  R3 -> module (data)
  153.    ;  R4 = workspace (pointer to Void)
  154.    ;  R5 -> postfix (String)
  155.  
  156. OSModule_Realloc                *       &D
  157.    ;Entry
  158.    ;  R0 = &D
  159.    ;  R2 = blk (pointer to Void)
  160.    ;  R3 = size_increase (Int)
  161.    ;Exit
  162.    ;  R2 = blk_out (pointer to Void)
  163.  
  164. OSModule_Instantiate            *       &E
  165.    ;Entry
  166.    ;  R0 = &E
  167.    ;  R1 -> instance_name (String)
  168.  
  169. OSModule_Rename                 *       &F
  170.    ;Entry
  171.    ;  R0 = &F
  172.    ;  R1 -> old_name (String)
  173.    ;  R2 -> new_postfix (String)
  174.  
  175. OSModule_Prefer                 *       &10
  176.    ;Entry
  177.    ;  R0 = &10
  178.    ;  R1 -> instance_name (String)
  179.  
  180. OSModule_AddPoduleArea          *       &11
  181.    ;Entry
  182.    ;  R0 = &11
  183.    ;  R1 -> environment (String)
  184.    ;  R2 = chunk (Int)
  185.    ;  R3 = rom_section (Int)
  186.  
  187. OSModule_Lookup                 *       &12
  188.    ;Entry
  189.    ;  R0 = &12
  190.    ;  R1 -> module_name (String)
  191.    ;Exit
  192.    ;  R1 = module_no (Int)
  193.    ;  R2 = instance_no (Int)
  194.    ;  R3 -> module (data)
  195.    ;  R4 = workspace (pointer to Void)
  196.    ;  R5 -> postfix (String)
  197.  
  198. OSModule_EnumerateROM           *       &13
  199.    ;Entry
  200.    ;  R0 = &13
  201.    ;  R1 = module_no (Int)
  202.    ;  R2 = section (Int)
  203.    ;Exit
  204.    ;  R1 = module_no_out (Int)
  205.    ;  R2 = section_out (Int)
  206.    ;  R3 -> module_name (String)
  207.    ;  R4 = status (Int)
  208.    ;  R5 = chunk_no (Int)
  209.  
  210. OSModule_EnumerateROMWithInfo   *       &14
  211.    ;Entry
  212.    ;  R0 = &14
  213.    ;  R1 = module_no (Int)
  214.    ;  R2 = section (Int)
  215.    ;Exit
  216.    ;  R1 = module_no_out (Int)
  217.    ;  R2 = section_out (Int)
  218.    ;  R3 -> module_name (String)
  219.    ;  R4 = status (Int)
  220.    ;  R5 = chunk_no (Int)
  221.    ;  R6 = bcd_version (Int)
  222.  
  223. Service_UKCommand               *       &4
  224.    ;Entry
  225.    ;  R0 -> command (String)
  226.    ;  R1 = &4
  227.    ;Exit
  228.    ;  R0 -> error (OS_Error)
  229.    ;  R1 = unclaimed (Bool)
  230.  
  231. Service_Error                   *       &6
  232.    ;Entry
  233.    ;  R0 -> error (OS_Error)
  234.    ;  R1 = &6
  235.  
  236. Service_UKByte                  *       &7
  237.    ;Entry
  238.    ;  R1 = &7
  239.    ;  R2 = byte (Int)
  240.    ;  R3 = arg0 (Int)
  241.    ;  R4 = arg1 (Int)
  242.    ;Exit
  243.    ;  R1 = unclaimed (Bool)
  244.    ;  R2 = res0 (Int)
  245.    ;  R3 = res1 (Int)
  246.  
  247. Service_UKWord                  *       &8
  248.    ;Entry
  249.    ;  R1 = &8
  250.    ;  R2 = word (Int)
  251.    ;  R3 -> block (data)
  252.    ;Exit
  253.    ;  R1 = unclaimed (Bool)
  254.  
  255. Service_Help                    *       &9
  256.    ;Entry
  257.    ;  R0 -> command (String)
  258.    ;  R1 = &9
  259.    ;Exit
  260.    ;  R1 = unclaimed (Bool)
  261.  
  262. Service_UKConfig                *       &28
  263.    ;Entry
  264.    ;  R0 -> tail (String)
  265.    ;  R1 = &28
  266.    ;Exit
  267.    ;  R0 -> error (OS_Error)
  268.    ;  R1 = unclaimed (Bool)
  269.  
  270. Service_UKStatus                *       &29
  271.    ;Entry
  272.    ;  R0 -> tail (String)
  273.    ;  R1 = &29
  274.    ;Exit
  275.    ;  R1 = unclaimed (Bool)
  276.  
  277. Service_NewApplication          *       &2A
  278.    ;Entry
  279.    ;  R1 = &2A
  280.    ;Exit
  281.    ;  R1 = unclaimed (Bool)
  282.  
  283. Service_LookupFileType          *       &42
  284.    ;Entry
  285.    ;  R1 = &42
  286.    ;  R2 = file_type (Bits)
  287.    ;Exit
  288.    ;  R1 = unclaimed (Bool)
  289.    ;  R2 = name1 (Bits)
  290.    ;  R3 = name2 (Bits)
  291.  
  292. Service_PostInit                *       &73
  293.    ;Entry
  294.    ;  R1 = &73
  295.  
  296. Service_SyntaxError             *       &8C
  297.    ;Entry
  298.    ;  R1 = &8C
  299.    ;  R2 -> offset (Int)
  300.    ;  R3 = base (pointer to data)
  301.    ;  R4 -> command (String)
  302.    ;Exit
  303.    ;  R0 -> error (OS_Error)
  304.    ;  R1 = unclaimed (Bool)
  305.  
  306.         ]
  307.         END
  308.