Subversion Repositories HelenOS

Rev

Rev 4002 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4002 Rev 4481
Line 28... Line 28...
28
 
28
 
29
/** @addtogroup libcipc
29
/** @addtogroup libcipc
30
 * @{
30
 * @{
31
 */
31
 */
32
/** @file
32
/** @file
33
 */
33
 */
34
 
34
 
35
#ifndef LIBIPC_IPC_H_
35
#ifndef LIBIPC_IPC_H_
36
#define LIBIPC_IPC_H_
36
#define LIBIPC_IPC_H_
37
 
37
 
-
 
38
#include <task.h>
38
#include <kernel/ipc/ipc.h>
39
#include <kernel/ipc/ipc.h>
39
#include <kernel/ddi/irq.h>
40
#include <kernel/ddi/irq.h>
40
#include <sys/types.h>
41
#include <sys/types.h>
41
#include <kernel/synch/synch.h>
42
#include <kernel/synch/synch.h>
42
 
43
 
-
 
44
#define IPC_FLAG_BLOCKING  0x01
-
 
45
 
43
typedef sysarg_t ipcarg_t;
46
typedef sysarg_t ipcarg_t;
-
 
47
 
44
typedef struct {
48
typedef struct {
45
    ipcarg_t args[IPC_CALL_LEN];
49
    ipcarg_t args[IPC_CALL_LEN];
46
    ipcarg_t in_phone_hash;
50
    ipcarg_t in_phone_hash;
47
} ipc_call_t;
51
} ipc_call_t;
-
 
52
 
48
typedef sysarg_t ipc_callid_t;
53
typedef sysarg_t ipc_callid_t;
49
 
54
 
50
typedef void (* ipc_async_callback_t)(void *, int, ipc_call_t *);
55
typedef void (* ipc_async_callback_t)(void *, int, ipc_call_t *);
51
 
56
 
52
/*
57
/*
Line 54... Line 59...
54
 * They are in the form ipc_call_sync_m_n(), where m denotes the number of
59
 * They are in the form ipc_call_sync_m_n(), where m denotes the number of
55
 * arguments of payload and n denotes number of return values. Whenever
60
 * arguments of payload and n denotes number of return values. Whenever
56
 * possible, the fast version is used.
61
 * possible, the fast version is used.
57
 */
62
 */
58
#define ipc_call_sync_0_0(phoneid, method) \
63
#define ipc_call_sync_0_0(phoneid, method) \
59
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, 0, 0, 0, 0, 0)
64
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, 0, 0, 0, 0, 0)
60
#define ipc_call_sync_0_1(phoneid, method, res1) \
65
#define ipc_call_sync_0_1(phoneid, method, res1) \
61
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), 0, 0, 0, 0)
66
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), 0, 0, 0, 0)
62
#define ipc_call_sync_0_2(phoneid, method, res1, res2) \
67
#define ipc_call_sync_0_2(phoneid, method, res1, res2) \
63
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), 0, 0, 0)
68
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), 0, 0, 0)
64
#define ipc_call_sync_0_3(phoneid, method, res1, res2, res3) \
69
#define ipc_call_sync_0_3(phoneid, method, res1, res2, res3) \
65
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), (res3), \
70
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), (res3), \
66
        0, 0)
71
        0, 0)
67
#define ipc_call_sync_0_4(phoneid, method, res1, res2, res3, res4) \
72
#define ipc_call_sync_0_4(phoneid, method, res1, res2, res3, res4) \
68
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), (res3), \
73
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), (res3), \
69
        (res4), 0)
74
        (res4), 0)
70
#define ipc_call_sync_0_5(phoneid, method, res1, res2, res3, res4, res5) \
75
#define ipc_call_sync_0_5(phoneid, method, res1, res2, res3, res4, res5) \
71
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), (res3), \
76
    ipc_call_sync_fast((phoneid), (method), 0, 0, 0, (res1), (res2), (res3), \
72
        (res4), (res5))
77
        (res4), (res5))
-
 
78
 
73
#define ipc_call_sync_1_0(phoneid, method, arg1) \
79
#define ipc_call_sync_1_0(phoneid, method, arg1) \
74
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, 0, 0, 0, 0, 0)
80
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, 0, 0, 0, 0, 0)
75
#define ipc_call_sync_1_1(phoneid, method, arg1, res1) \
81
#define ipc_call_sync_1_1(phoneid, method, arg1, res1) \
76
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), 0, 0, 0, 0)
82
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), 0, 0, 0, 0)
77
#define ipc_call_sync_1_2(phoneid, method, arg1, res1, res2) \
83
#define ipc_call_sync_1_2(phoneid, method, arg1, res1, res2) \
78
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), 0, \
84
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), 0, \
79
    0, 0)
85
        0, 0)
80
#define ipc_call_sync_1_3(phoneid, method, arg1, res1, res2, res3) \
86
#define ipc_call_sync_1_3(phoneid, method, arg1, res1, res2, res3) \
81
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), \
87
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), \
82
    (res3), 0, 0)
88
        (res3), 0, 0)
83
#define ipc_call_sync_1_4(phoneid, method, arg1, res1, res2, res3, res4) \
89
#define ipc_call_sync_1_4(phoneid, method, arg1, res1, res2, res3, res4) \
84
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), \
90
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), \
85
    (res3), (res4), 0)
91
        (res3), (res4), 0)
86
#define ipc_call_sync_1_5(phoneid, method, arg1, res1, res2, res3, res4, \
92
#define ipc_call_sync_1_5(phoneid, method, arg1, res1, res2, res3, res4, \
87
    res5) \
93
    res5) \
88
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), \
94
    ipc_call_sync_fast((phoneid), (method), (arg1), 0, 0, (res1), (res2), \
89
        (res3), (res4), (res5))
95
        (res3), (res4), (res5))
-
 
96
 
90
#define ipc_call_sync_2_0(phoneid, method, arg1, arg2) \
97
#define ipc_call_sync_2_0(phoneid, method, arg1, arg2) \
91
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, 0, 0, 0, \
98
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, 0, 0, 0, \
92
    0, 0)
99
        0, 0)
93
#define ipc_call_sync_2_1(phoneid, method, arg1, arg2, res1) \
100
#define ipc_call_sync_2_1(phoneid, method, arg1, arg2, res1) \
94
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), 0, 0, \
101
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), 0, 0, \
95
    0, 0)
102
        0, 0)
96
#define ipc_call_sync_2_2(phoneid, method, arg1, arg2, res1, res2) \
103
#define ipc_call_sync_2_2(phoneid, method, arg1, arg2, res1, res2) \
97
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
104
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
98
    (res2), 0, 0, 0)
105
        (res2), 0, 0, 0)
99
#define ipc_call_sync_2_3(phoneid, method, arg1, arg2, res1, res2, res3) \
106
#define ipc_call_sync_2_3(phoneid, method, arg1, arg2, res1, res2, res3) \
100
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
107
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
101
    (res2), (res3), 0, 0)
108
        (res2), (res3), 0, 0)
102
#define ipc_call_sync_2_4(phoneid, method, arg1, arg2, res1, res2, res3, \
109
#define ipc_call_sync_2_4(phoneid, method, arg1, arg2, res1, res2, res3, \
103
    res4) \
110
    res4) \
104
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
111
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
105
        (res2), (res3), (res4), 0)
112
        (res2), (res3), (res4), 0)
106
#define ipc_call_sync_2_5(phoneid, method, arg1, arg2, res1, res2, res3, \
113
#define ipc_call_sync_2_5(phoneid, method, arg1, arg2, res1, res2, res3, \
107
    res4, res5)\
114
    res4, res5)\
108
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
115
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), 0, (res1), \
109
        (res2), (res3), (res4), (res5))
116
        (res2), (res3), (res4), (res5))
-
 
117
 
110
#define ipc_call_sync_3_0(phoneid, method, arg1, arg2, arg3) \
118
#define ipc_call_sync_3_0(phoneid, method, arg1, arg2, arg3) \
111
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), 0, 0, 0, \
119
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), 0, 0, 0, \
112
    0, 0)
120
        0, 0)
113
#define ipc_call_sync_3_1(phoneid, method, arg1, arg2, arg3, res1) \
121
#define ipc_call_sync_3_1(phoneid, method, arg1, arg2, arg3, res1) \
114
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), (res1), \
122
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), (res1), \
115
    0, 0, 0, 0)
123
        0, 0, 0, 0)
116
#define ipc_call_sync_3_2(phoneid, method, arg1, arg2, arg3, res1, res2) \
124
#define ipc_call_sync_3_2(phoneid, method, arg1, arg2, arg3, res1, res2) \
117
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), (res1), \
125
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), (res1), \
118
    (res2), 0, 0, 0)
126
        (res2), 0, 0, 0)
119
#define ipc_call_sync_3_3(phoneid, method, arg1, arg2, arg3, res1, res2, \
127
#define ipc_call_sync_3_3(phoneid, method, arg1, arg2, arg3, res1, res2, \
120
    res3) \
128
    res3) \
121
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), \
129
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), \
122
        (res1), (res2), (res3), 0, 0)
130
        (res1), (res2), (res3), 0, 0)
123
#define ipc_call_sync_3_4(phoneid, method, arg1, arg2, arg3, res1, res2, \
131
#define ipc_call_sync_3_4(phoneid, method, arg1, arg2, arg3, res1, res2, \
Line 126... Line 134...
126
        (res1), (res2), (res3), (res4), 0)
134
        (res1), (res2), (res3), (res4), 0)
127
#define ipc_call_sync_3_5(phoneid, method, arg1, arg2, arg3, res1, res2, \
135
#define ipc_call_sync_3_5(phoneid, method, arg1, arg2, arg3, res1, res2, \
128
    res3, res4, res5) \
136
    res3, res4, res5) \
129
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), \
137
    ipc_call_sync_fast((phoneid), (method), (arg1), (arg2), (arg3), \
130
        (res1), (res2), (res3), (res4), (res5))
138
        (res1), (res2), (res3), (res4), (res5))
-
 
139
 
131
#define ipc_call_sync_4_0(phoneid, method, arg1, arg2, arg3, arg4) \
140
#define ipc_call_sync_4_0(phoneid, method, arg1, arg2, arg3, arg4) \
132
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), 0, \
141
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), 0, \
133
    0, 0, 0, 0, 0)
142
        0, 0, 0, 0, 0)
134
#define ipc_call_sync_4_1(phoneid, method, arg1, arg2, arg3, arg4, res1) \
143
#define ipc_call_sync_4_1(phoneid, method, arg1, arg2, arg3, arg4, res1) \
135
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), 0, \
144
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), 0, \
136
    (res1), 0, 0, 0, 0)
145
        (res1), 0, 0, 0, 0)
137
#define ipc_call_sync_4_2(phoneid, method, arg1, arg2, arg3, arg4, res1, res2) \
146
#define ipc_call_sync_4_2(phoneid, method, arg1, arg2, arg3, arg4, res1, res2) \
138
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), 0, \
147
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), 0, \
139
    (res1), (res2), 0, 0, 0)
148
        (res1), (res2), 0, 0, 0)
140
#define ipc_call_sync_4_3(phoneid, method, arg1, arg2, arg3, arg4, res1, res2, \
149
#define ipc_call_sync_4_3(phoneid, method, arg1, arg2, arg3, arg4, res1, res2, \
141
    res3) \
150
    res3) \
142
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), \
151
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), \
143
        (arg4), 0, (res1), (res2), (res3), 0, 0)
152
        (arg4), 0, (res1), (res2), (res3), 0, 0)
144
#define ipc_call_sync_4_4(phoneid, method, arg1, arg2, arg3, arg4, res1, res2, \
153
#define ipc_call_sync_4_4(phoneid, method, arg1, arg2, arg3, arg4, res1, res2, \
Line 147... Line 156...
147
        (arg4), 0, (res1), (res2), (res3), (res4), 0)
156
        (arg4), 0, (res1), (res2), (res3), (res4), 0)
148
#define ipc_call_sync_4_5(phoneid, method, arg1, arg2, arg3, arg4, res1, res2, \
157
#define ipc_call_sync_4_5(phoneid, method, arg1, arg2, arg3, arg4, res1, res2, \
149
    res3, res4, res5) \
158
    res3, res4, res5) \
150
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), \
159
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), \
151
        (arg4), 0, (res1), (res2), (res3), (res4), (res5))
160
        (arg4), 0, (res1), (res2), (res3), (res4), (res5))
-
 
161
 
152
#define ipc_call_sync_5_0(phoneid, method, arg1, arg2, arg3, arg4, arg5) \
162
#define ipc_call_sync_5_0(phoneid, method, arg1, arg2, arg3, arg4, arg5) \
153
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), \
163
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), \
154
        (arg5), 0, 0, 0, 0, 0)
164
        (arg5), 0, 0, 0, 0, 0)
155
#define ipc_call_sync_5_1(phoneid, method, arg1, arg2, arg3, arg4, arg5, res1) \
165
#define ipc_call_sync_5_1(phoneid, method, arg1, arg2, arg3, arg4, arg5, res1) \
156
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), \
166
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), (arg4), \
157
        (arg5), (res1), 0, 0, 0, 0)
167
        (arg5), (res1), 0, 0, 0, 0)
158
#define ipc_call_sync_5_2(phoneid, method, arg1, arg2, arg3, arg4, arg5, res1, \
168
#define ipc_call_sync_5_2(phoneid, method, arg1, arg2, arg3, arg4, arg5, res1, \
159
    res2) \
169
    res2) \
160
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), \
170
    ipc_call_sync_slow((phoneid), (method), (arg1), (arg2), (arg3), \
161
        (arg4), (arg5), (res1), (res2), 0, 0, 0)
171
        (arg4), (arg5), (res1), (res2), 0, 0, 0)
162
#define ipc_call_sync_5_3(phoneid, method, arg1, arg2, arg3, arg4, arg5, res1, \
172
#define ipc_call_sync_5_3(phoneid, method, arg1, arg2, arg3, arg4, arg5, res1, \
Line 179... Line 189...
179
    ipcarg_t, ipcarg_t, ipcarg_t *, ipcarg_t *, ipcarg_t *, ipcarg_t *,
189
    ipcarg_t, ipcarg_t, ipcarg_t *, ipcarg_t *, ipcarg_t *, ipcarg_t *,
180
    ipcarg_t *);
190
    ipcarg_t *);
181
 
191
 
182
extern ipc_callid_t ipc_wait_cycle(ipc_call_t *, uint32_t, int);
192
extern ipc_callid_t ipc_wait_cycle(ipc_call_t *, uint32_t, int);
183
extern ipc_callid_t ipc_wait_for_call_timeout(ipc_call_t *, uint32_t);
193
extern ipc_callid_t ipc_wait_for_call_timeout(ipc_call_t *, uint32_t);
-
 
194
 
184
static inline ipc_callid_t ipc_wait_for_call(ipc_call_t *data)
195
static inline ipc_callid_t ipc_wait_for_call(ipc_call_t *data)
185
{
196
{
186
    return ipc_wait_for_call_timeout(data, SYNCH_NO_TIMEOUT);
197
    return ipc_wait_for_call_timeout(data, SYNCH_NO_TIMEOUT);
187
}
198
}
-
 
199
 
188
extern ipc_callid_t ipc_trywait_for_call(ipc_call_t *);
200
extern ipc_callid_t ipc_trywait_for_call(ipc_call_t *);
189
 
201
 
190
/*
202
/*
191
 * User-friendly wrappers for ipc_answer_fast() and ipc_answer_slow().
203
 * User-friendly wrappers for ipc_answer_fast() and ipc_answer_slow().
192
 * They are in the form of ipc_answer_m(), where m is the number of return
204
 * They are in the form of ipc_answer_m(), where m is the number of return
193
 * arguments. The macros decide between the fast and the slow version according
205
 * arguments. The macros decide between the fast and the slow version according
194
 * to m.
206
 * to m.
195
 */
207
 */
196
#define ipc_answer_0(callid, retval) \
208
#define ipc_answer_0(callid, retval) \
197
    ipc_answer_fast((callid), (retval), 0, 0, 0, 0)
209
    ipc_answer_fast((callid), (retval), 0, 0, 0, 0)
198
#define ipc_answer_1(callid, retval, arg1) \
210
#define ipc_answer_1(callid, retval, arg1) \
199
    ipc_answer_fast((callid), (retval), (arg1), 0, 0, 0)
211
    ipc_answer_fast((callid), (retval), (arg1), 0, 0, 0)
200
#define ipc_answer_2(callid, retval, arg1, arg2) \
212
#define ipc_answer_2(callid, retval, arg1, arg2) \
201
    ipc_answer_fast((callid), (retval), (arg1), (arg2), 0, 0)
213
    ipc_answer_fast((callid), (retval), (arg1), (arg2), 0, 0)
202
#define ipc_answer_3(callid, retval, arg1, arg2, arg3) \
214
#define ipc_answer_3(callid, retval, arg1, arg2, arg3) \
203
    ipc_answer_fast((callid), (retval), (arg1), (arg2), (arg3), 0)
215
    ipc_answer_fast((callid), (retval), (arg1), (arg2), (arg3), 0)
204
#define ipc_answer_4(callid, retval, arg1, arg2, arg3, arg4) \
216
#define ipc_answer_4(callid, retval, arg1, arg2, arg3, arg4) \
205
    ipc_answer_fast((callid), (retval), (arg1), (arg2), (arg3), (arg4))
217
    ipc_answer_fast((callid), (retval), (arg1), (arg2), (arg3), (arg4))
206
#define ipc_answer_5(callid, retval, arg1, arg2, arg3, arg4, arg5) \
218
#define ipc_answer_5(callid, retval, arg1, arg2, arg3, arg4, arg5) \
207
    ipc_answer_slow((callid), (retval), (arg1), (arg2), (arg3), (arg4), (arg5))
219
    ipc_answer_slow((callid), (retval), (arg1), (arg2), (arg3), (arg4), (arg5))
208
 
220
 
209
extern ipcarg_t ipc_answer_fast(ipc_callid_t, ipcarg_t, ipcarg_t, ipcarg_t,
221
extern ipcarg_t ipc_answer_fast(ipc_callid_t, ipcarg_t, ipcarg_t, ipcarg_t,
210
    ipcarg_t, ipcarg_t);
222
    ipcarg_t, ipcarg_t);
211
extern ipcarg_t ipc_answer_slow(ipc_callid_t, ipcarg_t, ipcarg_t, ipcarg_t,
223
extern ipcarg_t ipc_answer_slow(ipc_callid_t, ipcarg_t, ipcarg_t, ipcarg_t,
212
    ipcarg_t, ipcarg_t, ipcarg_t);
224
    ipcarg_t, ipcarg_t, ipcarg_t);
Line 244... Line 256...
244
extern void ipc_call_async_fast(int, ipcarg_t, ipcarg_t, ipcarg_t, ipcarg_t,
256
extern void ipc_call_async_fast(int, ipcarg_t, ipcarg_t, ipcarg_t, ipcarg_t,
245
    ipcarg_t, void *, ipc_async_callback_t, int);
257
    ipcarg_t, void *, ipc_async_callback_t, int);
246
extern void ipc_call_async_slow(int, ipcarg_t, ipcarg_t, ipcarg_t, ipcarg_t,
258
extern void ipc_call_async_slow(int, ipcarg_t, ipcarg_t, ipcarg_t, ipcarg_t,
247
    ipcarg_t, ipcarg_t, void *, ipc_async_callback_t, int);
259
    ipcarg_t, ipcarg_t, void *, ipc_async_callback_t, int);
248
 
260
 
249
#define IPC_FLAG_BLOCKING  0x01
-
 
250
 
-
 
251
extern int ipc_connect_to_me(int, int, int, int, ipcarg_t *);
261
extern int ipc_connect_to_me(int, int, int, int, ipcarg_t *);
252
extern int ipc_connect_me_to(int, int, int, int);
262
extern int ipc_connect_me_to(int, int, int, int);
253
extern int ipc_connect_me_to_blocking(int, int, int, int);
263
extern int ipc_connect_me_to_blocking(int, int, int, int);
254
extern int ipc_hangup(int);
264
extern int ipc_hangup(int);
255
extern int ipc_register_irq(int, int, int, irq_code_t *);
265
extern int ipc_register_irq(int, int, int, irq_code_t *);
256
extern int ipc_unregister_irq(int, int);
266
extern int ipc_unregister_irq(int, int);
257
extern int ipc_forward_fast(ipc_callid_t, int, int, ipcarg_t, ipcarg_t, int);
267
extern int ipc_forward_fast(ipc_callid_t, int, int, ipcarg_t, ipcarg_t, int);
258
extern int ipc_forward_slow(ipc_callid_t, int, int, ipcarg_t, ipcarg_t,
268
extern int ipc_forward_slow(ipc_callid_t, int, int, ipcarg_t, ipcarg_t,
259
    ipcarg_t, ipcarg_t, ipcarg_t, int);
269
    ipcarg_t, ipcarg_t, ipcarg_t, int);
260
 
-
 
261
 
270
 
262
/*
271
/*
263
 * User-friendly wrappers for ipc_share_in_start().
272
 * User-friendly wrappers for ipc_share_in_start().
264
 */
273
 */
265
#define ipc_share_in_start_0_0(phoneid, dst, size) \
274
#define ipc_share_in_start_0_0(phoneid, dst, size) \
266
    ipc_share_in_start((phoneid), (dst), (size), 0, NULL)
275
    ipc_share_in_start((phoneid), (dst), (size), 0, NULL)
267
#define ipc_share_in_start_0_1(phoneid, dst, size, flags) \
276
#define ipc_share_in_start_0_1(phoneid, dst, size, flags) \
268
    ipc_share_in_start((phoneid), (dst), (size), 0, (flags))
277
    ipc_share_in_start((phoneid), (dst), (size), 0, (flags))
269
#define ipc_share_in_start_1_0(phoneid, dst, size, arg) \
278
#define ipc_share_in_start_1_0(phoneid, dst, size, arg) \
270
    ipc_share_in_start((phoneid), (dst), (size), (arg), NULL)
279
    ipc_share_in_start((phoneid), (dst), (size), (arg), NULL)
271
#define ipc_share_in_start_1_1(phoneid, dst, size, arg, flags) \
280
#define ipc_share_in_start_1_1(phoneid, dst, size, arg, flags) \
272
    ipc_share_in_start((phoneid), (dst), (size), (arg), (flags))
281
    ipc_share_in_start((phoneid), (dst), (size), (arg), (flags))
273
 
282
 
274
extern int ipc_share_in_start(int, void *, size_t, ipcarg_t, int *);
283
extern int ipc_share_in_start(int, void *, size_t, ipcarg_t, int *);
275
extern int ipc_share_in_receive(ipc_callid_t *, size_t *);
284
extern int ipc_share_in_receive(ipc_callid_t *, size_t *);
276
extern int ipc_share_in_finalize(ipc_callid_t, void *, int );
285
extern int ipc_share_in_finalize(ipc_callid_t, void *, int );
277
extern int ipc_share_out_start(int, void *, int);
286
extern int ipc_share_out_start(int, void *, int);
Line 282... Line 291...
282
extern int ipc_data_read_finalize(ipc_callid_t, const void *, size_t);
291
extern int ipc_data_read_finalize(ipc_callid_t, const void *, size_t);
283
extern int ipc_data_write_start(int, const void *, size_t);
292
extern int ipc_data_write_start(int, const void *, size_t);
284
extern int ipc_data_write_receive(ipc_callid_t *, size_t *);
293
extern int ipc_data_write_receive(ipc_callid_t *, size_t *);
285
extern int ipc_data_write_finalize(ipc_callid_t, void *, size_t);
294
extern int ipc_data_write_finalize(ipc_callid_t, void *, size_t);
286
 
295
 
287
#include <task.h>
-
 
288
 
-
 
289
extern int ipc_connect_kbox(task_id_t);
296
extern int ipc_connect_kbox(task_id_t);
290
 
297
 
291
#endif
298
#endif
292
 
299
 
293
/** @}
300
/** @}