Subversion Repositories HelenOS

Rev

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

Rev 3397 Rev 3492
Line 845... Line 845...
845
 * @param size      Size for the IPC_M_DATA_READ call. Can be smaller than
845
 * @param size      Size for the IPC_M_DATA_READ call. Can be smaller than
846
 *          the maximum size announced by the sender.
846
 *          the maximum size announced by the sender.
847
 *
847
 *
848
 * @return      Zero on success or a value from @ref errno.h on failure.
848
 * @return      Zero on success or a value from @ref errno.h on failure.
849
 */
849
 */
850
int ipc_data_read_finalize(ipc_callid_t callid, void *src, size_t size)
850
int ipc_data_read_finalize(ipc_callid_t callid, const void *src, size_t size)
851
{
851
{
852
    return ipc_answer_2(callid, EOK, (ipcarg_t) src, (ipcarg_t) size);
852
    return ipc_answer_2(callid, EOK, (ipcarg_t) src, (ipcarg_t) size);
853
}
853
}
854
 
854
 
855
/** Wrapper for making IPC_M_DATA_WRITE calls.
855
/** Wrapper for making IPC_M_DATA_WRITE calls.
Line 858... Line 858...
858
 * @param src       Address of the beginning of the source buffer.
858
 * @param src       Address of the beginning of the source buffer.
859
 * @param size      Size of the source buffer.
859
 * @param size      Size of the source buffer.
860
 *
860
 *
861
 * @return      Zero on success or a negative error code from errno.h.
861
 * @return      Zero on success or a negative error code from errno.h.
862
 */
862
 */
863
int ipc_data_write_start(int phoneid, void *src, size_t size)
863
int ipc_data_write_start(int phoneid, const void *src, size_t size)
864
{
864
{
865
    return async_req_2_0(phoneid, IPC_M_DATA_WRITE, (ipcarg_t) src,
865
    return async_req_2_0(phoneid, IPC_M_DATA_WRITE, (ipcarg_t) src,
866
        (ipcarg_t) size);
866
        (ipcarg_t) size);
867
}
867
}
868
 
868
 
Line 907... Line 907...
907
 */
907
 */
908
int ipc_data_write_finalize(ipc_callid_t callid, void *dst, size_t size)
908
int ipc_data_write_finalize(ipc_callid_t callid, void *dst, size_t size)
909
{
909
{
910
    return ipc_answer_2(callid, EOK, (ipcarg_t) dst, (ipcarg_t) size);
910
    return ipc_answer_2(callid, EOK, (ipcarg_t) dst, (ipcarg_t) size);
911
}
911
}
-
 
912
 
-
 
913
#include <kernel/syscall/sysarg64.h>
-
 
914
/** Connect to a task specified by id.
-
 
915
 */
-
 
916
int ipc_connect_kbox(task_id_t id)
-
 
917
{
-
 
918
    sysarg64_t arg;
-
 
919
 
-
 
920
    arg.value = (unsigned long long) id;
-
 
921
 
-
 
922
    return __SYSCALL1(SYS_IPC_CONNECT_KBOX, (sysarg_t) &arg);
-
 
923
}
912
 
924
 
913
/** @}
925
/** @}
914
 */
926
 */