Rename tid() to dst() in Native_capability.

As suggested by Norman in the discussion of issue #145, this commit
renames the tid() accessor in Native_capability to dst().
This commit is contained in:
Stefan Kalkowski
2012-03-09 12:25:11 +01:00
committed by Norman Feske
parent 84ca4b25db
commit ae8cf5f44d
43 changed files with 85 additions and 85 deletions

View File

@@ -56,7 +56,7 @@ namespace Genode {
static IF *deref(Capability<IF> cap)
{
/* check if this is a pseudo capability */
if (cap.tid() != 0 || !cap.local_name())
if (cap.dst() != 0 || !cap.local_name())
throw Non_local_capability();
/*

View File

@@ -108,7 +108,7 @@ void Ipc_client::_prepare_next_call()
{
/* prepare next request in buffer */
long local_name = _dst.local_name();
long tid = Native_capability::tid();
long tid = Native_capability::dst();
_write_offset = 0;
_write_to_buf(local_name);
@@ -122,7 +122,7 @@ void Ipc_client::_prepare_next_call()
void Ipc_client::_call()
{
if (_dst.valid()) {
lx_send_to(_rcv_cs, _dst.tid(), "server",
lx_send_to(_rcv_cs, _dst.dst(), "server",
_snd_msg->buf, _write_offset);
lx_recv_from(_rcv_cs, _rcv_msg->buf, _rcv_msg->size());
@@ -183,7 +183,7 @@ void Ipc_server::_wait()
void Ipc_server::_reply()
{
try {
lx_send_to(_rcv_cs, _dst.tid(), "client", _snd_msg->buf, _write_offset);
lx_send_to(_rcv_cs, _dst.dst(), "client", _snd_msg->buf, _write_offset);
} catch (Ipc_error) { }
_prepare_next_reply_wait();
@@ -194,7 +194,7 @@ void Ipc_server::_reply_wait()
{
/* when first called, there was no request yet */
if (_reply_needed)
lx_send_to(_rcv_cs, _dst.tid(), "client", _snd_msg->buf, _write_offset);
lx_send_to(_rcv_cs, _dst.dst(), "client", _snd_msg->buf, _write_offset);
_wait();
}

View File

@@ -116,7 +116,7 @@ const char *Process::_priv_pd_args(Parent_capability parent_cap,
enum { ENV_STR_LEN = 256 };
static char envbuf[5][ENV_STR_LEN];
Genode::snprintf(envbuf[0], ENV_STR_LEN, "parent_tid=%ld",
parent_cap.tid());
parent_cap.dst());
Genode::snprintf(envbuf[1], ENV_STR_LEN, "parent_local_name=%lu",
parent_cap.local_name());
Genode::snprintf(envbuf[2], ENV_STR_LEN, "DISPLAY=%s",

View File

@@ -37,7 +37,7 @@ namespace Genode {
{
Lock::Guard lock_guard(_lock());
return Native_capability(ep.tid(), ++_unique_id_cnt);
return Native_capability(ep.dst(), ++_unique_id_cnt);
}
void free(Native_capability cap) { }