/[rtmk]/rtmk/include/rtmk/rtmk.defs
ViewVC logotype

Diff of /rtmk/include/rtmk/rtmk.defs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.16 by jrydberg, Wed Mar 6 00:43:30 2002 UTC revision 1.17 by jrydberg, Wed Mar 27 00:13:46 2002 UTC
# Line 1  Line 1 
1  ; ???   -*-Scheme-*-  ; Interface defintion for rtmk kernel interface.  -*- Scheme -*-
2  ; Copyright 1999, 2000, 2001, 2002 Johan Rydberg, jrydberg@rtmk.org.  ; Copyright 1999-2002 Johan Rydberg, jrydberg@rtmk.org.
3  ;  
4  ; This program is free software; you can redistribute it and/or modify  ; This program is free software; you can redistribute it and/or modify
5  ; it under the terms of the GNU General Public License as published by  ; it under the terms of the GNU General Public License as published by
6  ; the Free Software Foundation; either version 2, or (at your option)  ; the Free Software Foundation; either version 2 of the License, or
7  ; any later version.  ; (at your option) any later version.
8  ;  
9  ; This program is distributed in the hope that it will be useful,  ; This program is distributed in the hope that it will be useful,
10  ; but WITHOUT ANY WARRANTY; without even the implied warranty of  ; but WITHOUT ANY WARRANTY; without even the implied warranty of
11  ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the  ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  ; GNU General Public License for more details.  ; GNU General Public License for more details.
13  ;  
14  ; You should have received a copy of the GNU General Public License  ; You should have received a copy of the GNU General Public License
15  ; along with this program; if not, write to the Free Software  ; along with this program; if not, write to the Free Software
16  ; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  ; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
   
 #include <rtmk/std-types.defs>  
17    
18  ; ??? we use base offset 100 instead of 0.  Offset 0 should be reserved  ; Note that:
19  ;     for future extentions.  ; You always see the interface from the client side.  This mean
20  (dni "rtmk" "rtmk kernel interface" 100)  ; that arguments marked as "out" is output from the client context
21    ; into the server context.  Arguments marked as "in" is input into
22  #if KERNEL_SERVER  ; the client context (imported from server context).
23  (import "mutations.h")  
24  #else  (define-interface rtmk 100
25  (import "<rtmk/rtmk.h>")    ; Create a new task, returning it in NEW_TASKP.  If INHERIT_P is
26  #endif    ; true, fork TASKs address space.
27      (define-method task_create (returns RTMK_MSG_TYPE_INTEGER32)
28  ; FIXME      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
29  ; (import "<rtmk/thread.h>")                 (out inherit_p   RTMK_MSG_TYPE_INTEGER32)
30                   (in  new_taskp   RTMK_MSG_TYPE_MAKE_SEND))
31      )
32    
33      ; Terminate TASK and release all resources held by it.
34      (define-method task_terminate (returns RTMK_MSG_TYPE_INTEGER32)
35        (arguments (out task        RTMK_MSG_TYPE_COPY_SEND))
36      )
37    
38      ; Set special port in TASK to PORT at SLOT in special port array.  
39      (define-method task_special_port_set (returns RTMK_MSG_TYPE_INTEGER32)
40        (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
41                   (out slot        RTMK_MSG_TYPE_INTEGER32)
42                   (out port        RTMK_MSG_TYPE_COPY_SEND))
43      )
44    
45      ; Get send rights to port SLOT in TASKs special port set.
46      ; Right is returned in PORTP.
47      (define-method task_special_port_get (returns RTMK_MSG_TYPE_INTEGER32)
48        (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
49                   (out slot        RTMK_MSG_TYPE_INTEGER32)
50                   (in  portp       RTMK_MSG_TYPE_COPY_SEND))
51      )
52    
53      ; Return send rights to threads that belong to TASK.
54      (define-method task_threads (returns RTMK_MSG_TYPE_INTEGER32)
55        (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
56                   (in  threadp     ^RTMK_MSG_TYPE_COPY_SEND[]))
57      )
58    
59    
60  ; Thread related functions    ; Create a new thread, return it in NEW_THREADP.  TASK is the
61      ; task that the new thread will live in.
62  ; Create a new task, returning it in NEW-TASKP.  If INHERIT-P is    (define-method thread_create (returns RTMK_MSG_TYPE_INTEGER32)
63  ; true, fork TASK-PORTs address space.      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
64  (define-routine task-create                 (in  new_threadp RTMK_MSG_TYPE_MAKE_SEND))
65    (c-name "task_create")    )
66    (comment "create new task task")  
67    ()                                    ; no attrs    ; Terminate THREAD and release all resources held by it.
68    (return-type kern-return-t)    (define-method thread_terminate (returns RTMK_MSG_TYPE_INTEGER32)
69    (arguments ((task-port    "task"      task-t)      (arguments (out thread      RTMK_MSG_TYPE_COPY_SEND))
70                (inherit-p    "inherit_p" bool)    )
71                (new-taskp    "new_task"  task-t AD_IN)))  
72  )      ; Suspend THREAD.  When this method returns, the thread is
73      ; suspended.
74  ; Terminate TASK-PORT and release all resources held by it.    (define-method thread_suspend (returns RTMK_MSG_TYPE_INTEGER32)
75  (define-routine task-terminate      (arguments (out thread      RTMK_MSG_TYPE_COPY_SEND))
76    (c-name "task_terminate")    )
77    (comment "terminate task")  
78    ()                                    ; no attrs    ; Resume execution of THREAD.
79    (return-type kern-return-t)    (define-method thread_resume (returns RTMK_MSG_TYPE_INTEGER32)
80    (arguments ((task-port    "task"      task-t)))      (arguments (out thread      RTMK_MSG_TYPE_COPY_SEND))
81  )      )
82    
83  ; Set special port in TASK to PORT at SLOT in special port array.      ; Get state for THREAD.  FLAVOR specifies what type of state.
84  (define-routine task-special-port-set    ; State is returned in BUF.
85    (c-name "task_special_port_set")    (define-method thread_state_get (returns RTMK_MSG_TYPE_INTEGER32)
86    (comment "????")      (arguments (out   thread    RTMK_MSG_TYPE_COPY_SEND)
87    ()                 (out   flavor    RTMK_MSG_TYPE_INTEGER32)
88    (return-type kern-return-t)                 (in    buf       RTMK_MSG_TYPE_INTEGER8[])
89    (arguments ((task-port  "task"        task-t)                 (inout count     RTMK_MSG_TYPE_INTEGER32))
90                (slot       "slot"        int)    )
91                (port       "port"        rtmk-port-t)))  
92  )    ; Set state for THREAD.  FLAVOR specifies what type of state.
93      ; State is located in BUF.
94  ; Get send rights to port SLOT in TASKs special port set.    (define-method thread_state_set (returns RTMK_MSG_TYPE_INTEGER32)
95  ; Right is returned in PORTP.      (arguments (out thread      RTMK_MSG_TYPE_COPY_SEND)
96  (define-routine task-special-port-get                 (out flavor      RTMK_MSG_TYPE_INTEGER32)
97    (c-name "task_special_port_get")                 (out buf         RTMK_MSG_TYPE_INTEGER8[]))
98    (comment "???")    )
   ()  
   (return-type kern-return-t)  
   (arguments ((task-port  "task"        task-t)  
               (slot       "slot"        int)  
               (namep      "namep"       rtmk-port-t AD_IN)))  
 )  
   
 ; Return send rights to threads that belong to TASK.  
 (define-routine task-threads  
   (c-name "task_threads")  
   (comment "????")  
   ()  
   (return-type kern-return-t)  
   (arguments ((task-port  "task"        task-t)  
               (threads    "threads"     port-array-t AD_IN)))  
 )  
99    
100    
101  ; Thread related functions    ; Allocate new port with recieve rights in TASK.  The name of
102      ; the port will be received in NAMEP.
103  ; Create a new thread, return it in NEW-THREAD.  TASK-PORT is the    (define-method port_allocate (returns RTMK_MSG_TYPE_INTEGER32)
104  ; task that the new thread will live in.      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
105  (define-routine thread-create                 (in  namep       RTMK_MSG_TYPE_MOVE_RECEIVE))
106    (c-name "thread_create")    )
107    (comment "create a new thread")  
108    ()                                    ; no taros    ; Allocate new port with receive rights in TASK. The name of
109    (return-type kern-return-t)    ; the new port right is supplied in PORT_NAME.  If a previous
110    (arguments ((task-port    "task"      task-t)    ; right exists with that name, KERN_NAME_EXISTS is returned.
111                (new-thread   "new_thead" thread-t AD_IN)))    (define-method port_allocate_name (returns RTMK_MSG_TYPE_INTEGER32)
112  )        (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
113                   (out port_name   RTMK_MSG_TYPE_PORT_NAME))
114  ; Suspend THREAD-PORT.  When the function returns, the thread is    )
115  ; suspended.  
116  (define-routine thread-suspend    ; Deallocate PORT_NAME.
117    (c-name "thread_suspend")    (define-method port_deallocate (returns RTMK_MSG_TYPE_INTEGER32)
118    (comment "suspend THREAD-PORT")      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
119    ()                                    ; no attrs                 (out port_name   RTMK_MSG_TYPE_PORT_NAME))
120    (return-type kern-return-t)    )
121    (arguments ((thread-port  "thread"    thread-t)))  
122  )    ; Destroy PORT_NAME.
123      (define-method port_destroy (returns RTMK_MSG_TYPE_INTEGER32)
124  ; Resume execution of THREAD.      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
125  (define-routine thread-resume                 (out port_name   RTMK_MSG_TYPE_PORT_NAME))
126    (c-name "thread_resume")    )
127    (comment "resume THREAD-PORT")  
128    ()                                    ; no attrs    ; Allocate a new port set.  When created the port set does not
129    (return-type kern-return-t)    ; contain any members.  Return receive rights in PSETP.  
130    (arguments ((thread-port  "thread"    thread-t)))    (define-method port_set_allocate (returns RTMK_MSG_TYPE_INTEGER32)
131  )      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
132                   (in  psetp       RTMK_MSG_TYPE_MOVE_RECEIVE))
133  ; Set status for THREAD-PORT.  FLAVOR specifies what status    )
134  ; we should set.  Status data is located in STATE.  
135  (define-routine thread-state-set    ; Insert PORT into PORT_SET.  If PORT_SET is NULL, we remove
136    (c-name "thread_state_set")    ; PORT from the port set it currently belongs to.
137    (comment "FIXME")    (define-method port_move_member (returns RTMK_MSG_TYPE_INTEGER32)
138    ()      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
139    (return-type kern-return-t)                 (out port        RTMK_MSG_TYPE_PORT_NAME)
140    (arguments ((thread-port "thread"     thread-t)                 (out port_set    RTMK_MSG_TYPE_PORT_NAME))
141                (flavor      "flavor"     int)    )
142                (state       "state"      thread-state-t)))  
143  )    ; Insert rights for PORT into TASK-PORT using RIGHT_NAME.
144      (define-method port_insert_right (returns RTMK_MSG_TYPE_INTEGER32)
145  ; Get status for THREAD-PORT.  FLAVOR specifies what status      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
146  ; we should get.  Status data will be put in STATE.                 (out right_name  RTMK_MSG_TYPE_PORT_NAME)
147  (define-routine thread-state-get                 (out port        RTMK_MSG_TYPE_ANY))
148    (c-name "thread_state_get")    )
   (comment "FIXME")  
   ()  
   (return-type kern-return-t)  
   (arguments ((thread-port "thread"     thread-t)  
               (flavor      "flavor"     int)  
               (state       "state"      thread-state-t AD_INOUT)))  
 )  
149    
150    
151  ; Allocate new port with recieve rights in TASK-PORT.  The name of    ; Map SIZE bytes of memory object [OBJECT+OFFSET] into
152  ; the port will be received in NAMEP.    ; TASKs address space.  
153  (define-routine port-allocate    (define-method vm_map (returns RTMK_MSG_TYPE_INTEGER32)
154    (c-name "port_allocate")      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
155    (comment "allocate new port with recieve rights in TASK-PORT")                 (inout address   RTMK_MSG_TYPE_INTEGER32)
156    ()                 (out size        RTMK_MSG_TYPE_INTEGER32)
157    (return-type kern-return-t)                 (out anywhere    RTMK_MSG_TYPE_INTEGER32)
158    (arguments ((task-port  "task"        task-t)                 (out object      RTMK_MSG_TYPE_COPY_SEND)
159                (namep      "namep"       rtmk-port-receive-t AD_IN)))                 (out offset      RTMK_MSG_TYPE_INTEGER32)
160  )                 (out copy        RTMK_MSG_TYPE_INTEGER32)
161                   (out prot        RTMK_MSG_TYPE_INTEGER32)
162  ; Allocate w new port with receive rights in TASK-PORT. The name of                 (out max_prot    RTMK_MSG_TYPE_INTEGER32)
163  ; the new port is supplied in PORT_NAME.  If a previous port exists                 (out inherit     RTMK_MSG_TYPE_INTEGER32))
164  ; with that name, KERN_NAME_EXISTS is returned.    )
165  (define-routine port-allocate-name  
166    (c-name "port_allocate_name")    ; Tries to allocate SIZE number of bytes in TASK address
167    (comment "FIXME")    ; space.  If ANYWHERE is false, we tries to do this at a fixed address.  
168    ()    (define-method vm_allocate (returns RTMK_MSG_TYPE_INTEGER32)
169    (return-type kern-return-t)      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
170    (arguments ((task-port  "task"        task-t)                 (inout address   RTMK_MSG_TYPE_INTEGER32)
171                (port-name  "name"        rtmk-port-name-t)))                 (out size        RTMK_MSG_TYPE_INTEGER32)
172  )                 (out anywhere    RTMK_MSG_TYPE_INTEGER32))
173      )
174  ; Allocate a new port set.  When created the port set does not  
175  ; contain any members.  Return receive rights in PSETP.      ; Deallocate region [ADDRESS, ADDRESS+SIZE) in TASKs address space.
176  (define-routine port-set-allocate    (define-method vm_deallocate (returns RTMK_MSG_TYPE_INTEGER32)
177    (c-name "port_set_allocate")      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
178    (comment "FIXME")                 (out address     RTMK_MSG_TYPE_INTEGER32)
179    ()                 (out size        RTMK_MSG_TYPE_INTEGER32))
180    (return-type kern-return-t)    )
181    (arguments ((task-port  "task"        task-t)  
182                (psetp      "psetp"       rtmk-port-receive-t AD_IN)))    ; Set the protection for address region [ADDRESS, ADDRESS+SIZE)
183  )    ; in TASK to PROTECTION. If SETMAX is specified, the maximum
184      ; protection is to be set; otherwise, only the current protection
185  ; Insert PORT into PORT_SET.  If PORT_SET is NULL, we remove    ; is affected.  
186  ; PORT from the port set it currently belongs to.    (define-method vm_protect (returns RTMK_MSG_TYPE_INTEGER32)
187  (define-routine port-move-member      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
188    (c-name "port_move_member")                 (out address     RTMK_MSG_TYPE_INTEGER32)
189    (comment "FIXME")                 (out size        RTMK_MSG_TYPE_INTEGER32)
190    ()                 (out protection  RTMK_MSG_TYPE_INTEGER32)
191    (return-type kern-return-t)                 (out setmax      RTMK_MSG_TYPE_INTEGER32))
192    (arguments ((task-port  "task"        task-t)    )
193                (port       "port"        rtmk-port-t)  
194                (port-set   "port_set"    rtmk-port-t)))    ; Write into TASKs address space at offset DST_OFFSET, from current
195  )    ; tasks address space at SRC_OFFSET.  Copy LENGTH bytes.  
196      (define-method vm_write (returns RTMK_MSG_TYPE_INTEGER32)
197  ; Insert rights for PORT into TASK-PORT using RIGHT_NAME.      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
198  ; RIGHT_TYPE specifies what type should be inserted.                 (out dst_offset  RTMK_MSG_TYPE_INTEGER32)
199  (define-routine port-insert-right                 (out src_offset  RTMK_MSG_TYPE_INTEGER32)
200    (c-name "port_insert_right")                 (out length      RTMK_MSG_TYPE_INTEGER32))
201    (comment "???")    )
   ()  
   (return-type kern-return-t)  
   (arguments ((task-port  "task"        task-t)  
               (port       "port"        rtmk-port-t)  
               (right-name "right_name"  rtmk-port-name-t)  
               (right-type "right_type"  rtmk-port-type-t)))  
 )  
202    
203    
204  ; Map SIZE bytes of OBJECT at OFFSET-X in TASKs address space.      ; Reboot host.  HOST must be priveledged host port.
205  (define-routine vm-map    (define-method host_reboot (returns RTMK_MSG_TYPE_INTEGER32)
206    (c-name "vm_map")      (arguments (out host        RTMK_MSG_TYPE_COPY_SEND))
207    (comment "map memory")    )
208    ()  
209    (return-type kern-return-t)    ; Attach event counter to interrupt INTR_NO.  When interrupt
210    (arguments ((task       "task"        task-t)    ; occurs it will signal on the event counter.
211                (address    "address"     vm-offset-t AD_INOUT)    (define-method host_attach_interrupt (returns RTMK_MSG_TYPE_INTEGER32)
212                (size       "size"        vm-size-t)      (arguments (out host        RTMK_MSG_TYPE_COPY_SEND)
213                (anywhere   "anywhere"    int)                 (out intr_no     RTMK_MSG_TYPE_INTEGER32)
214                (object     "object"      rtmk-port-t)                 (out evc         RTMK_MSG_TYPE_COPY_SEND))
215                (offset-x   "offset"      vm-offset-t)    )
216                (copy-p     "copy_p"      int)  
217                (prot       "prot"        vm-prot-t)    ; Get information about host.  FLAVOR specifies what info.
218                (max-prot   "max_prot"    vm-prot-t)    (define-method host_info (returns RTMK_MSG_TYPE_INTEGER32)
219                (inherit    "inherit"     vm-inherit-t)))      (arguments (out   host      RTMK_MSG_TYPE_COPY_SEND)
220  )                 (out   flavor    RTMK_MSG_TYPE_INTEGER32)
221                   (in    buf       RTMK_MSG_TYPE_INTEGER8[])
222  ; Tries to allocate SIZE number of bytes in TASK-PORT address                 (inout count     RTMK_MSG_TYPE_INTEGER32))
223  ; space.  If ANYWHERE is false, we tries to do this at a fixed address.      )
224  (define-routine vm-allocate  
225    (c-name "vm_allocate")    ; Allocate new event counter. Returned in EVCP.  
226    (comment "allocate SIZE bytes in TASK-PORT")    (define-method eventcnt_allocate (returns RTMK_MSG_TYPE_INTEGER32)
227    ()      (arguments (out task        RTMK_MSG_TYPE_COPY_SEND)
228    (return-type kern-return-t)                 (in  evcp        RTMK_MSG_TYPE_COPY_SEND))
229    (arguments ((task-port  "task"        task-t)    )
230                (size       "size"        vm-size-t)    
               (offset-x   "offset"      vm-offset-t AD_INOUT)  
               (anywhere   "anywhere"    int)))  
 )  
   
 ; Deallocate region [OFFSET, OFFSET+SIZE) in TASKs address space.  
 (define-routine vm-deallocate  
   (c-name "vm_deallocate")  
   (comment "deallocate SIZE bytes in TASK-PORT at OFFSET")  
   ()  
   (return-type kern-return-t)  
   (arguments ((task-port  "task"        task-t)  
               (offset-x   "offset"      vm-offset-t)  
               (size       "size"        vm-size-t)))  
 )  
   
 ; Set the protection for address region [OFFSET, OFFSET+SIZE)  
 ; in TASK to PROTECTION. If SETMAX_P is specified, the maximum  
 ; protection is to be set; otherwise, only the current protection  
 ; is affected.    
 (define-routine vm-protect  
   (c-name "vm_protect")  
   (comment "change protection to PROTECTION")  
   ()  
   (return-type kern-return-t)  
   (arguments ((task-port  "task"        task-t)  
               (offset-x   "offset"      vm-offset-t)  
               (size       "size"        vm-size-t)  
               (protection "protection"  vm-prot-t)  
               (setmax-p   "setmax_p"    int)))  
 )  
   
 ; Write into TASKs address space at offset DST_OFFSET, from current  
 ; tasks address space at SRC_OFFSET.  Copy LENGTH bytes.    
 (define-routine vm-write  
   (c-name "vm_write")  
   (comment "copy LENGTH bytes into TASKs address space")  
   ()  
   (return-type kern-return-t)  
   (arguments ((task-port  "task"        task-t)  
               (dst-off    "dst_off"     vm-offset-t)  
               (src-off    "src_off"     vm-offset-t)  
               (length     "length"      vm-size-t)))  
 )  
   
 ; Reboot host.  HOST_PORT must be priveledged port.  
 (define-routine host-reboot  
   (c-name "host_reboot")  
   (comment "reboot host")  
   ()  
   (return-type kern-return-t)  
   (arguments ((host-port  "host"        rtmk-port-t)))  
 )  
   
 ; Create a new host memory object.  OFFSET is offset into physical  
 ; memory. SIZE should be page aligned.  Right to object is returned  
 ; in OBJECTP.  
 (define-routine host-memory-object-create  
   (c-name "host_memory_object_create")  
   (comment "???")  
   ()  
   (return-type kern-return-t)  
   (arguments ((host-port  "host"        rtmk-port-t)  
               (x-offset   "object"      vm-offset-t)  
               (size       "size"        vm-size-t)  
               (objectp    "objectp"     memory-object-t AD_IN)))  
 )  
   
 ; Attach event counter to interrupt INTR_NO.  When interrupt  
 ; occurs it will signal on the event counter.  
 (define-routine host-attach-interrupt  
   (c-name "host_attach_interrupt")  
   (comment "???")  
   ()  
   (return-type kern-return-t)  
   (arguments ((host-port  "host"        rtmk-port-t)  
               (intr-no    "intr_no"     int)  
               (evc        "evc"         eventcnt-t)))  
 )  
   
 ; Get information about host.  FLAVOR specifies what info.  
 (define-routine host-info  
   (c-name "host_info")  
   (comment "???")  
   ()  
   (return-type kern-return-t)  
   (arguments ((host-port  "host"        rtmk-port-t)  
               (flavor     "flavor"      int)  
               (buf        "buf"         host-status-t AD_IN)))  
 )  
   
 ; Allocate new event counter.  
 (define-routine eventcnt-allocate  
   (c-name "eventcnt_allocate")  
   (comment "????")  
   ()  
   (return-type kern-return-t)  
   (arguments ((task-port  "task"        task-t)  
               (evcp       "evcp"        eventcnt-t AD_IN)))  
 )  
   
231    
232  ; Data range [OFFSET, OFFSET+SIZE) is unavailable in OBJECT.    ; Data range [OFFSET, OFFSET+SIZE) is unavailable in OBJECT.
233  ; Region will be zero filled.    ; Region will be zero filled.
234  (define-routine memory-object-data-unavail    (define-method memory_object_data_unavail (returns)
235    (c-name "memory_object_data_unavail")      (arguments (out mem_obj     RTMK_MSG_TYPE_COPY_SEND)
236    (comment "????")                 (out offset      RTMK_MSG_TYPE_INTEGER32)
237    ()                 (out size        RTMK_MSG_TYPE_INTEGER32))
238    (return-type void)    )
239    (arguments ((mem-obj    "object"      rtmk-port-t)  
240                (offset-x   "offset"      vm-offset-t)    ; Supply data for region [OFFSET, OFFSET+SIZE) in
241                (size       "size"        vm-size-t)))    ; OBJECT.  ADDRESS points at location in pagers address
242  )    ; space.
243      ; ??? use out of line memory!
244  ; Supply data for region [OFFSET, OFFSET+SIZE) in    (define-method memory_object_data_supply (returns)
245  ; OBJECT.  ADDRESS points at location in pagers address      (arguments (out mem_obj     RTMK_MSG_TYPE_COPY_SEND)
246  ; space.                 (out offset      RTMK_MSG_TYPE_INTEGER32)
247  (define-routine memory-object-data-supply                 (out address     RTMK_MSG_TYPE_INTEGER32)
248    (c-name "memory_object_data_supply")                 (out size        RTMK_MSG_TYPE_INTEGER32)
249    (comment "supply SIZE bytes of data to MEM-OBJ")                 (out dealloc     RTMK_MSG_TYPE_INTEGER32)
250    ()                 (out prot_lock   RTMK_MSG_TYPE_INTEGER32)
251    (return-type void)                 (out precious    RTMK_MSG_TYPE_INTEGER32))
252    (arguments ((mem-obj    "object"      rtmk-port-t)    )
253                (offset-x   "offset"      vm-offset-t)  
254                (address    "address"     vm-offset-t)    ; Set attributes for OBJECT.
255                (size       "size"        vm-size-t)    (define-method memory_object_set_attributes (returns RTMK_MSG_TYPE_INTEGER32)
256                (dealloc    "dealloc"     int)      (arguments (out mem_obj     RTMK_MSG_TYPE_COPY_SEND)
257                (lock-value "lock_value"  vm-prot-t)                 (out ready       RTMK_MSG_TYPE_INTEGER32)
258                (precious   "precious"    int)))                 (out cache       RTMK_MSG_TYPE_INTEGER32)
259  )                 (out strategy    RTMK_MSG_TYPE_INTEGER32))
260      )
261  ; Set attributes for OBJECT.  
262  (define-routine memory-object-set-attributes    ; Change attributes for OBJECT.
263    (c-name "memory_object_set_attributes")    (define-method memory_object_change_attributes (returns RTMK_MSG_TYPE_INTEGER32)
264    (comment "set attributes for MEM-OBJ")      (arguments (out mem_obj     RTMK_MSG_TYPE_COPY_SEND)
265    ()                 (out ready       RTMK_MSG_TYPE_INTEGER32)
266    (return-type kern-return-t)                 (out strategy    RTMK_MSG_TYPE_INTEGER32))
267    (arguments ((mem-obj    "object"      rtmk-port-t)    )
               (ready-p    "ready_p"     int)  
               (cache-p    "cache_p"     int)  
               (copy-strat "copy_strat"  int)))  
 )  
   
 ; Change attributes for OBJECT.  
 (define-routine memory-object-change-attributes  
   (c-name "memory_object_change_attributes")  
   (comment "change attributes for MEM-OBJ")  
   ()  
   (return-type kern-return-t)  
   (arguments ((mem-obj    "object"      rtmk-port-t)  
               (ready-p    "ready_p"     int)  
               (copy-strat "copy_strat"  int)))  
268  )  )

Legend:
Removed from v.1.16  
changed lines
  Added in v.1.17

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26