2011-12-22 15:19:25 +00:00
|
|
|
/*
|
|
|
|
* \brief NOVA-specific supplements to the IPC framework
|
|
|
|
* \author Norman Feske
|
|
|
|
* \date 2010-01-27
|
|
|
|
*/
|
|
|
|
|
|
|
|
/*
|
2012-01-03 14:35:05 +00:00
|
|
|
* Copyright (C) 2010-2012 Genode Labs GmbH
|
2011-12-22 15:19:25 +00:00
|
|
|
*
|
|
|
|
* This file is part of the Genode OS framework, which is distributed
|
|
|
|
* under the terms of the GNU General Public License version 2.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _INCLUDE__BASE__IPC_H_
|
|
|
|
#define _INCLUDE__BASE__IPC_H_
|
|
|
|
|
|
|
|
#include <base/ipc_generic.h>
|
|
|
|
|
|
|
|
|
|
|
|
inline void Genode::Ipc_ostream::_marshal_capability(Genode::Native_capability const &cap)
|
|
|
|
{
|
2012-03-13 14:44:23 +00:00
|
|
|
if (cap.valid())
|
2012-07-30 08:56:07 +00:00
|
|
|
_snd_msg->snd_append_pt_sel(cap.local_name(),
|
|
|
|
cap.dst().rights());
|
2011-12-22 15:19:25 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
inline void Genode::Ipc_istream::_unmarshal_capability(Genode::Native_capability &cap)
|
|
|
|
{
|
2012-07-12 11:33:51 +00:00
|
|
|
addr_t pt_sel = _rcv_msg->rcv_pt_sel();
|
2012-07-30 08:56:07 +00:00
|
|
|
cap = Native_capability(pt_sel);
|
2011-12-22 15:19:25 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
#endif /* _INCLUDE__BASE__IPC_H_ */
|