Index: HelenOS.config
===================================================================
--- HelenOS.config	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ HelenOS.config	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -556,5 +556,5 @@
 
 % Include development files (headers, libraries)
-! [RDFMT=tmpfs|RDFMT=ext2fs] CONFIG_DEVEL_FILES (n/y)
+! CONFIG_DEVEL_FILES (n/y)
 
 % Strip binaries
Index: abi/include/ipc/methods.h
===================================================================
--- abi/include/ipc/methods.h	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ abi/include/ipc/methods.h	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -72,5 +72,5 @@
 #define IPC_M_CONNECTION_CLONE  1
 
-/** Protocol for CONNECT - ME
+/** Protocol for establishing a cloned connection.
  *
  * Through this call, the recipient learns about the new cloned connection.
@@ -81,7 +81,7 @@
  *
  */
-#define IPC_M_CONNECT_ME  2
-
-/** Protocol for CONNECT - TO - ME
+#define IPC_M_CLONE_ESTABLISH  2
+
+/** Protocol for initializing callback connections.
  *
  * Calling process asks the callee to create a callback connection,
@@ -102,5 +102,5 @@
 #define IPC_M_CONNECT_TO_ME  3
 
-/** Protocol for CONNECT - ME - TO
+/** Protocol for initializing new foward connections.
  *
  * Calling process asks the callee to create for him a new connection.
@@ -183,5 +183,5 @@
  * - ARG1 - recipient's phone to the third party task
  */
-#define IPC_M_STATE_CHANGE_AUTHORIZE	9
+#define IPC_M_STATE_CHANGE_AUTHORIZE  9
 
 /** Debug the recipient.
@@ -190,5 +190,5 @@
  *
  */
-#define IPC_M_DEBUG 10
+#define IPC_M_DEBUG  10
 
 /** Last system IPC method */
Index: boot/Makefile.common
===================================================================
--- boot/Makefile.common	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ boot/Makefile.common	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -98,5 +98,5 @@
 	$(USPACE_PATH)/srv/bd/part/guid_part/g_part \
 	$(USPACE_PATH)/srv/bd/part/mbr_part/mbr_part \
-	$(USPACE_PATH)/srv/clip/clip \
+	$(USPACE_PATH)/srv/clipboard/clipboard \
 	$(USPACE_PATH)/srv/fs/tmpfs/tmpfs \
 	$(USPACE_PATH)/srv/fs/fat/fat \
Index: boot/arch/arm32/Makefile.inc
===================================================================
--- boot/arch/arm32/Makefile.inc	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ boot/arch/arm32/Makefile.inc	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -42,6 +42,6 @@
 
 RD_SRVS_ESSENTIAL += \
-	$(USPACE_PATH)/srv/hid/s3c24xx_ts/s3c24ts \
-	$(USPACE_PATH)/srv/hw/char/s3c24xx_uart/s3c24ser
+	$(USPACE_PATH)/srv/hid/s3c24xx_ts/s3c24xx_ts \
+	$(USPACE_PATH)/srv/hw/char/s3c24xx_uart/s3c24xx_uart
 
 RD_SRVS_NON_ESSENTIAL += \
Index: kernel/genarch/src/fb/fb.c
===================================================================
--- kernel/genarch/src/fb/fb.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ kernel/genarch/src/fb/fb.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -390,6 +390,6 @@
 			    instance->position / instance->cols, false);
 			instance->position++;
-		} while ((instance->position % 8)
-		    && (instance->position < instance->cols * instance->rows));
+		} while (((instance->position % instance->cols) % 8 != 0) &&
+		    (instance->position < instance->cols * instance->rows));
 		break;
 	default:
Index: kernel/generic/src/ipc/sysipc.c
===================================================================
--- kernel/generic/src/ipc/sysipc.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ kernel/generic/src/ipc/sysipc.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -111,5 +111,5 @@
 	switch (imethod) {
 	case IPC_M_CONNECTION_CLONE:
-	case IPC_M_CONNECT_ME:
+	case IPC_M_CLONE_ESTABLISH:
 	case IPC_M_PHONE_HUNGUP:
 		/* This message is meant only for the original recipient. */
@@ -160,5 +160,5 @@
 	switch (IPC_GET_IMETHOD(call->data)) {
 	case IPC_M_CONNECTION_CLONE:
-	case IPC_M_CONNECT_ME:
+	case IPC_M_CLONE_ESTABLISH:
 	case IPC_M_CONNECT_TO_ME:
 	case IPC_M_CONNECT_ME_TO:
@@ -225,5 +225,5 @@
 			mutex_unlock(&phone->lock);
 		}
-	} else if (IPC_GET_IMETHOD(*olddata) == IPC_M_CONNECT_ME) {
+	} else if (IPC_GET_IMETHOD(*olddata) == IPC_M_CLONE_ESTABLISH) {
 		phone_t *phone = (phone_t *) IPC_GET_ARG5(*olddata);
 		
@@ -459,5 +459,5 @@
 		break;
 	}
-	case IPC_M_CONNECT_ME:
+	case IPC_M_CLONE_ESTABLISH:
 		IPC_SET_ARG5(call->data, (sysarg_t) phone);
 		break;
Index: uspace/Makefile
===================================================================
--- uspace/Makefile	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/Makefile	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -71,5 +71,5 @@
 	app/sysinfo \
 	app/mkbd \
-	srv/clip \
+	srv/clipboard \
 	srv/loc \
 	srv/devman \
Index: uspace/app/inetcfg/inetcfg.c
===================================================================
--- uspace/app/inetcfg/inetcfg.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/app/inetcfg/inetcfg.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -35,5 +35,4 @@
  */
 
-#include <async.h>
 #include <errno.h>
 #include <inet/inetcfg.h>
Index: uspace/app/init/init.c
===================================================================
--- uspace/app/init/init.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/app/init/init.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -302,6 +302,6 @@
 	spawn("/srv/obio");
 	srv_start("/srv/cuda_adb");
-	srv_start("/srv/s3c24ser");
-	srv_start("/srv/s3c24ts");
+	srv_start("/srv/s3c24xx_uart");
+	srv_start("/srv/s3c24xx_ts");
 	
 	spawn("/srv/loopip");
@@ -315,5 +315,5 @@
 	console("hid/input", "hid/fb0");
 	
-	spawn("/srv/clip");
+	spawn("/srv/clipboard");
 	spawn("/srv/remcons");
 	
Index: uspace/app/trace/ipc_desc.c
===================================================================
--- uspace/app/trace/ipc_desc.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/app/trace/ipc_desc.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -39,13 +39,14 @@
 ipc_m_desc_t ipc_methods[] = {
 	/* System methods */
-	{ IPC_M_PHONE_HUNGUP,  "PHONE_HUNGUP" },
-	{ IPC_M_CONNECT_ME,    "CONNECT_ME" },
-	{ IPC_M_CONNECT_ME_TO, "CONNECT_ME_TO" },
-	{ IPC_M_CONNECT_TO_ME, "CONNECT_TO_ME" },
-	{ IPC_M_SHARE_OUT,     "SHARE_OUT" },
-	{ IPC_M_SHARE_IN,      "SHARE_IN" },
-	{ IPC_M_DATA_WRITE,    "DATA_WRITE" },
-	{ IPC_M_DATA_READ,     "DATA_READ" },
-	{ IPC_M_DEBUG,         "DEBUG" },
+	{ IPC_M_PHONE_HUNGUP,     "PHONE_HUNGUP" },
+	{ IPC_M_CONNECTION_CLONE, "CONNECTION_CLONE" },
+	{ IPC_M_CLONE_ESTABLISH,  "CLONE_ESTABLISH" },
+	{ IPC_M_CONNECT_ME_TO,    "CONNECT_ME_TO" },
+	{ IPC_M_CONNECT_TO_ME,    "CONNECT_TO_ME" },
+	{ IPC_M_SHARE_OUT,        "SHARE_OUT" },
+	{ IPC_M_SHARE_IN,         "SHARE_IN" },
+	{ IPC_M_DATA_WRITE,       "DATA_WRITE" },
+	{ IPC_M_DATA_READ,        "DATA_READ" },
+	{ IPC_M_DEBUG,            "DEBUG" },
 	
 	/* Terminating entry */
Index: uspace/drv/bus/usb/vhc/conndev.c
===================================================================
--- uspace/drv/bus/usb/vhc/conndev.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/drv/bus/usb/vhc/conndev.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -69,5 +69,5 @@
 	
 	if (data_request == 0) {
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return;
 	}
Index: uspace/lib/c/Makefile
===================================================================
--- uspace/lib/c/Makefile	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/Makefile	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -122,5 +122,4 @@
 	generic/vfs/canonify.c \
 	generic/net/inet.c \
-	generic/net/modules.c \
 	generic/net/socket_client.c \
 	generic/net/socket_parse.c \
Index: uspace/lib/c/generic/async.c
===================================================================
--- uspace/lib/c/generic/async.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/async.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -946,5 +946,5 @@
 	
 	switch (IPC_GET_IMETHOD(*call)) {
-	case IPC_M_CONNECT_ME:
+	case IPC_M_CLONE_ESTABLISH:
 	case IPC_M_CONNECT_ME_TO:
 		/* Open new connection with fibril, etc. */
@@ -1668,7 +1668,7 @@
 }
 
-/** Wrapper for making IPC_M_CONNECT_ME calls using the async framework.
- *
- * Ask through for a cloned connection to some service.
+/** Wrapper for making IPC_M_CLONE_ESTABLISH calls using the async framework.
+ *
+ * Ask for a cloned connection to some service.
  *
  * @param mgmt Exchange management style.
@@ -1678,5 +1678,5 @@
  *
  */
-async_sess_t *async_connect_me(exch_mgmt_t mgmt, async_exch_t *exch)
+async_sess_t *async_clone_establish(exch_mgmt_t mgmt, async_exch_t *exch)
 {
 	if (exch == NULL) {
@@ -1703,5 +1703,5 @@
 	msg->wdata.active = true;
 	
-	ipc_call_async_0(exch->phone, IPC_M_CONNECT_ME, msg,
+	ipc_call_async_0(exch->phone, IPC_M_CLONE_ESTABLISH, msg,
 	    reply_received, true);
 	
Index: uspace/lib/c/generic/device/nic.c
===================================================================
--- uspace/lib/c/generic/device/nic.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/device/nic.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -65,5 +65,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -94,5 +94,5 @@
 	rc = async_connect_to_me(exch, 0, 0, 0, cfun, carg);
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: uspace/lib/c/generic/devman.c
===================================================================
--- uspace/lib/c/generic/devman.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/devman.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -188,5 +188,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -226,5 +226,5 @@
 	if (retval != EOK) {
 		devman_exchange_end(exch);
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -242,6 +242,6 @@
 		if (retval != EOK) {
 			devman_exchange_end(exch);
-			async_wait_for(req2, NULL);
-			async_wait_for(req, NULL);
+			async_forget(req2);
+			async_forget(req);
 			return retval;
 		}
@@ -250,5 +250,5 @@
 		if (retval != EOK) {
 			devman_exchange_end(exch);
-			async_wait_for(req, NULL);
+			async_forget(req);
 			return retval;
 		}
@@ -283,5 +283,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -386,5 +386,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -423,5 +423,5 @@
 	
 	if (dretval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return dretval;
 	}
@@ -488,5 +488,5 @@
 	
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: uspace/lib/c/generic/inet.c
===================================================================
--- uspace/lib/c/generic/inet.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/inet.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -120,5 +120,5 @@
 
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: uspace/lib/c/generic/inetcfg.c
===================================================================
--- uspace/lib/c/generic/inetcfg.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/inetcfg.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -51,5 +51,5 @@
 
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
@@ -146,5 +146,5 @@
 
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -183,5 +183,5 @@
 
 	if (dretval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return dretval;
 	}
@@ -216,5 +216,5 @@
 
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -261,5 +261,5 @@
 
 	if (dretval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return dretval;
 	}
@@ -294,5 +294,5 @@
 
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -331,5 +331,5 @@
 
 	if (dretval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return dretval;
 	}
@@ -364,5 +364,5 @@
 
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
Index: uspace/lib/c/generic/inetping.c
===================================================================
--- uspace/lib/c/generic/inetping.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/inetping.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -88,5 +88,5 @@
 
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
Index: uspace/lib/c/generic/ipc.c
===================================================================
--- uspace/lib/c/generic/ipc.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/ipc.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -647,9 +647,9 @@
  *
  */
-int ipc_connect_me(int phoneid)
+int ipc_clone_establish(int phoneid)
 {
 	sysarg_t newphid;
-	int res = ipc_call_sync_0_5(phoneid, IPC_M_CONNECT_ME, NULL, NULL,
-	    NULL, NULL, &newphid);
+	int res = ipc_call_sync_0_5(phoneid, IPC_M_CLONE_ESTABLISH, NULL,
+	    NULL, NULL, NULL, &newphid);
 	if (res)
 		return res;
Index: uspace/lib/c/generic/iplink.c
===================================================================
--- uspace/lib/c/generic/iplink.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/iplink.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -94,5 +94,5 @@
 
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: uspace/lib/c/generic/iplink_srv.c
===================================================================
--- uspace/lib/c/generic/iplink_srv.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/iplink_srv.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -178,5 +178,5 @@
 
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: uspace/lib/c/generic/loader.c
===================================================================
--- uspace/lib/c/generic/loader.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/loader.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -101,5 +101,5 @@
 	
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return (int) rc;
 	}
@@ -139,5 +139,5 @@
 	
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return (int) rc;
 	}
@@ -177,5 +177,5 @@
 	
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return (int) rc;
 	}
@@ -236,5 +236,5 @@
 	
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return (int) rc;
 	}
@@ -281,5 +281,5 @@
 
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return (int) rc;
 	}
Index: uspace/lib/c/generic/loc.c
===================================================================
--- uspace/lib/c/generic/loc.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/loc.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -246,5 +246,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -285,5 +285,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -352,5 +352,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -401,5 +401,5 @@
 	
 	if (dretval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return dretval;
 	}
@@ -471,5 +471,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -520,5 +520,5 @@
 	
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -683,5 +683,5 @@
 		
 		if (rc != EOK) {
-			async_wait_for(req, NULL);
+			async_forget(req);
 			free(devs);
 			return 0;
@@ -732,5 +732,5 @@
 		
 		if (rc != EOK) {
-			async_wait_for(req, NULL);
+			async_forget(req);
 			free(devs);
 			return 0;
@@ -760,5 +760,5 @@
 	
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: pace/lib/c/generic/net/modules.c
===================================================================
--- uspace/lib/c/generic/net/modules.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ 	(revision )
@@ -1,201 +1,0 @@
-/*
- * Copyright (c) 2009 Lukas Mejdrech
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup libc
- * @{
- */
-
-/** @file
- * Generic module functions implementation.
- *
- * @todo MAKE IT POSSIBLE TO REMOVE THIS FILE VIA EITHER REPLACING PART OF ITS
- * FUNCTIONALITY OR VIA INTEGRATING ITS FUNCTIONALITY MORE TIGHTLY WITH THE REST
- * OF THE SYSTEM.
- */
-
-#include <async.h>
-#include <malloc.h>
-#include <errno.h>
-#include <sys/time.h>
-#include <ipc/services.h>
-#include <net/modules.h>
-#include <ns.h>
-
-/** Answer a call.
- *
- * @param[in] callid Call identifier.
- * @param[in] result Message processing result.
- * @param[in] answer Message processing answer.
- * @param[in] count  Number of answer parameters.
- *
- */
-void answer_call(ipc_callid_t callid, int result, ipc_call_t *answer,
-    size_t count)
-{
-	/* Choose the most efficient function */
-	if ((answer != NULL) || (count == 0)) {
-		switch (count) {
-		case 0:
-			async_answer_0(callid, (sysarg_t) result);
-			break;
-		case 1:
-			async_answer_1(callid, (sysarg_t) result,
-			    IPC_GET_ARG1(*answer));
-			break;
-		case 2:
-			async_answer_2(callid, (sysarg_t) result,
-			    IPC_GET_ARG1(*answer), IPC_GET_ARG2(*answer));
-			break;
-		case 3:
-			async_answer_3(callid, (sysarg_t) result,
-			    IPC_GET_ARG1(*answer), IPC_GET_ARG2(*answer),
-			    IPC_GET_ARG3(*answer));
-			break;
-		case 4:
-			async_answer_4(callid, (sysarg_t) result,
-			    IPC_GET_ARG1(*answer), IPC_GET_ARG2(*answer),
-			    IPC_GET_ARG3(*answer), IPC_GET_ARG4(*answer));
-			break;
-		case 5:
-		default:
-			async_answer_5(callid, (sysarg_t) result,
-			    IPC_GET_ARG1(*answer), IPC_GET_ARG2(*answer),
-			    IPC_GET_ARG3(*answer), IPC_GET_ARG4(*answer),
-			    IPC_GET_ARG5(*answer));
-			break;
-		}
-	}
-}
-
-/** Create bidirectional connection with the needed module service and register
- * the message receiver.
- *
- * @param[in] need            Needed module service.
- * @param[in] arg1            First parameter.
- * @param[in] arg2            Second parameter.
- * @param[in] arg3            Third parameter.
- * @param[in] client_receiver Message receiver.
- *
- * @return Session to the needed service.
- * @return Other error codes as defined for the async_connect_to_me()
- *         function.
- *
- */
-async_sess_t *bind_service(services_t need, sysarg_t arg1, sysarg_t arg2,
-    sysarg_t arg3, async_client_conn_t client_receiver)
-{
-	/* Connect to the needed service */
-	async_sess_t *sess = connect_to_service(need);
-	if (sess != NULL) {
-		/* Request the bidirectional connection */
-		async_exch_t *exch = async_exchange_begin(sess);
-		int rc = async_connect_to_me(exch, arg1, arg2, arg3,
-		    client_receiver, NULL);
-		async_exchange_end(exch);
-		
-		if (rc != EOK) {
-			async_hangup(sess);
-			errno = rc;
-			return NULL;
-		}
-	}
-	
-	return sess;
-}
-
-/** Connect to the needed module.
- *
- * @param[in] need Needed module service.
- *
- * @return Session to the needed service.
- * @return NULL if the connection timeouted.
- *
- */
-async_sess_t *connect_to_service(services_t need)
-{
-	return service_connect_blocking(EXCHANGE_SERIALIZE, need, 0, 0);
-}
-
-/** Reply the data to the other party.
- *
- * @param[in] data        The data buffer to be sent.
- * @param[in] data_length The buffer length.
- *
- * @return EOK on success.
- * @return EINVAL if the client does not expect the data.
- * @return EOVERFLOW if the client does not expect all the data.
- *         Only partial data are transfered.
- * @return Other error codes as defined for the
- *         async_data_read_finalize() function.
- *
- */
-int data_reply(void *data, size_t data_length)
-{
-	size_t length;
-	ipc_callid_t callid;
-	
-	/* Fetch the request */
-	if (!async_data_read_receive(&callid, &length))
-		return EINVAL;
-	
-	/* Check the requested data size */
-	if (length < data_length) {
-		async_data_read_finalize(callid, data, length);
-		return EOVERFLOW;
-	}
-	
-	/* Send the data */
-	return async_data_read_finalize(callid, data, data_length);
-}
-
-/** Refresh answer structure and argument count.
- *
- * Erase all arguments.
- *
- * @param[in,out] answer Message processing answer structure.
- * @param[in,out] count  Number of answer arguments.
- *
- */
-void refresh_answer(ipc_call_t *answer, size_t *count)
-{
-	if (count != NULL)
-		*count = 0;
-	
-	if (answer != NULL) {
-		IPC_SET_RETVAL(*answer, 0);
-		IPC_SET_IMETHOD(*answer, 0);
-		IPC_SET_ARG1(*answer, 0);
-		IPC_SET_ARG2(*answer, 0);
-		IPC_SET_ARG3(*answer, 0);
-		IPC_SET_ARG4(*answer, 0);
-		IPC_SET_ARG5(*answer, 0);
-	}
-}
-
-/** @}
- */
Index: uspace/lib/c/generic/net/socket_client.c
===================================================================
--- uspace/lib/c/generic/net/socket_client.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/net/socket_client.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -44,7 +44,7 @@
 #include <errno.h>
 #include <task.h>
+#include <ns.h>
 #include <ipc/services.h>
 #include <ipc/socket.h>
-#include <net/modules.h>
 #include <net/in.h>
 #include <net/socket.h>
@@ -284,5 +284,5 @@
 {
 	if (socket_globals.tcp_sess == NULL) {
-		socket_globals.tcp_sess = bind_service(SERVICE_TCP,
+		socket_globals.tcp_sess = service_bind(SERVICE_TCP,
 		    0, 0, SERVICE_TCP, socket_connection);
 	}
@@ -301,5 +301,5 @@
 {
 	if (socket_globals.udp_sess == NULL) {
-		socket_globals.udp_sess = bind_service(SERVICE_UDP,
+		socket_globals.udp_sess = service_bind(SERVICE_UDP,
 		    0, 0, SERVICE_UDP, socket_connection);
 	}
@@ -378,5 +378,5 @@
  * @return		Other error codes as defined for the NET_SOCKET message.
  * @return		Other error codes as defined for the
- *			bind_service() function.
+ *			service_bind() function.
  */
 int socket(int domain, int type, int protocol)
Index: uspace/lib/c/generic/ns.c
===================================================================
--- uspace/lib/c/generic/ns.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/generic/ns.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -37,4 +37,5 @@
 #include <async.h>
 #include <macros.h>
+#include <errno.h>
 #include "private/ns.h"
 
@@ -48,5 +49,5 @@
 }
 
-async_sess_t *service_connect(exch_mgmt_t mgmt, sysarg_t service, sysarg_t arg2,
+async_sess_t *service_connect(exch_mgmt_t mgmt, services_t service, sysarg_t arg2,
     sysarg_t arg3)
 {
@@ -72,5 +73,5 @@
 }
 
-async_sess_t *service_connect_blocking(exch_mgmt_t mgmt, sysarg_t service,
+async_sess_t *service_connect_blocking(exch_mgmt_t mgmt, services_t service,
     sysarg_t arg2, sysarg_t arg3)
 {
@@ -81,5 +82,5 @@
 	    async_connect_me_to_blocking(mgmt, exch, service, arg2, arg3);
 	async_exchange_end(exch);
-
+	
 	if (!sess)
 		return NULL;
@@ -91,4 +92,39 @@
 	 */
 	async_sess_args_set(sess, arg2, arg3, 0);
+	
+	return sess;
+}
+
+/** Create bidirectional connection with a service
+ *
+ * @param[in] service         Service.
+ * @param[in] arg1            First parameter.
+ * @param[in] arg2            Second parameter.
+ * @param[in] arg3            Third parameter.
+ * @param[in] client_receiver Message receiver.
+ *
+ * @return Session to the service.
+ * @return Other error codes as defined by async_connect_to_me().
+ *
+ */
+async_sess_t *service_bind(services_t service, sysarg_t arg1, sysarg_t arg2,
+    sysarg_t arg3, async_client_conn_t client_receiver)
+{
+	/* Connect to the needed service */
+	async_sess_t *sess =
+	    service_connect_blocking(EXCHANGE_SERIALIZE, service, 0, 0);
+	if (sess != NULL) {
+		/* Request callback connection */
+		async_exch_t *exch = async_exchange_begin(sess);
+		int rc = async_connect_to_me(exch, arg1, arg2, arg3,
+		    client_receiver, NULL);
+		async_exchange_end(exch);
+		
+		if (rc != EOK) {
+			async_hangup(sess);
+			errno = rc;
+			return NULL;
+		}
+	}
 	
 	return sess;
Index: uspace/lib/c/include/async.h
===================================================================
--- uspace/lib/c/include/async.h	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/include/async.h	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -321,5 +321,5 @@
     sysarg_t *, sysarg_t *);
 
-extern async_sess_t *async_connect_me(exch_mgmt_t, async_exch_t *);
+extern async_sess_t *async_clone_establish(exch_mgmt_t, async_exch_t *);
 extern async_sess_t *async_connect_me_to(exch_mgmt_t, async_exch_t *, sysarg_t,
     sysarg_t, sysarg_t);
Index: uspace/lib/c/include/ipc/ipc.h
===================================================================
--- uspace/lib/c/include/ipc/ipc.h	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/include/ipc/ipc.h	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -254,7 +254,7 @@
     sysarg_t, sysarg_t, void *, ipc_async_callback_t, bool);
 
+extern int ipc_clone_establish(int);
 extern int ipc_connect_to_me(int, sysarg_t, sysarg_t, sysarg_t, task_id_t *,
     sysarg_t *);
-extern int ipc_connect_me(int);
 extern int ipc_connect_me_to(int, sysarg_t, sysarg_t, sysarg_t);
 extern int ipc_connect_me_to_blocking(int, sysarg_t, sysarg_t, sysarg_t);
Index: pace/lib/c/include/net/modules.h
===================================================================
--- uspace/lib/c/include/net/modules.h	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ 	(revision )
@@ -1,65 +1,0 @@
-/*
- * Copyright (c) 2009 Lukas Mejdrech
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/** @addtogroup libc
- * @{
- */
-
-/** @file
- * Generic module functions.
- *
- * @todo MAKE IT POSSIBLE TO REMOVE THIS FILE VIA EITHER REPLACING PART OF ITS
- * FUNCTIONALITY OR VIA INTEGRATING ITS FUNCTIONALITY MORE TIGHTLY WITH THE REST
- * OF THE SYSTEM.
- */
-
-#ifndef LIBC_MODULES_H_
-#define LIBC_MODULES_H_
-
-#include <async.h>
-#include <ipc/services.h>
-#include <sys/time.h>
-
-/** Connect to module function type definition.
- *
- * @return Session to the service.
- *
- */
-typedef async_sess_t *connect_module_t(services_t);
-
-extern void answer_call(ipc_callid_t, int, ipc_call_t *, size_t);
-extern async_sess_t *bind_service(services_t, sysarg_t, sysarg_t, sysarg_t,
-    async_client_conn_t);
-extern async_sess_t *connect_to_service(services_t);
-extern int data_reply(void *, size_t);
-extern void refresh_answer(ipc_call_t *, size_t *);
-
-#endif
-
-/** @}
- */
Index: uspace/lib/c/include/ns.h
===================================================================
--- uspace/lib/c/include/ns.h	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/c/include/ns.h	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -37,11 +37,14 @@
 
 #include <sys/types.h>
+#include <ipc/services.h>
 #include <task.h>
 #include <async.h>
 
 extern int service_register(sysarg_t);
-extern async_sess_t *service_connect(exch_mgmt_t, sysarg_t, sysarg_t, sysarg_t);
-extern async_sess_t *service_connect_blocking(exch_mgmt_t, sysarg_t, sysarg_t,
+extern async_sess_t *service_connect(exch_mgmt_t, services_t, sysarg_t, sysarg_t);
+extern async_sess_t *service_connect_blocking(exch_mgmt_t, services_t, sysarg_t,
     sysarg_t);
+extern async_sess_t *service_bind(services_t, sysarg_t, sysarg_t, sysarg_t,
+    async_client_conn_t);
 
 extern int ns_ping(void);
Index: uspace/lib/drv/generic/remote_usbhc.c
===================================================================
--- uspace/lib/drv/generic/remote_usbhc.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/drv/generic/remote_usbhc.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -259,5 +259,5 @@
 	if (data_request == 0) {
 		// FIXME: How to let the other side know that we want to abort?
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return ENOMEM;
 	}
@@ -308,5 +308,5 @@
 		const int ret = async_data_write_start(exch, data, size);
 		if (ret != EOK) {
-			async_wait_for(opening_request, NULL);
+			async_forget(opening_request);
 			return ret;
 		}
Index: uspace/lib/fs/libfs.c
===================================================================
--- uspace/lib/fs/libfs.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/fs/libfs.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -320,5 +320,5 @@
 	if (rc != EOK) {
 		async_exchange_end(exch);
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
@@ -341,5 +341,5 @@
 	if (reg.plb_ro == (void *) -1) {
 		async_exchange_end(exch);
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return ENOMEM;
 	}
@@ -348,5 +348,5 @@
 	
 	if (rc) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
@@ -404,5 +404,5 @@
 	
 	async_exch_t *exch = async_exchange_begin(mountee_sess);
-	async_sess_t *sess = async_connect_me(EXCHANGE_PARALLEL, exch);
+	async_sess_t *sess = async_clone_establish(EXCHANGE_PARALLEL, exch);
 	
 	if (!sess) {
Index: uspace/lib/net/tl/socket_core.c
===================================================================
--- uspace/lib/net/tl/socket_core.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/net/tl/socket_core.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -39,5 +39,4 @@
 #include <net/in.h>
 #include <net/inet.h>
-#include <net/modules.h>
 #include <stdint.h>
 #include <stdlib.h>
Index: uspace/lib/nic/include/nic.h
===================================================================
--- uspace/lib/nic/include/nic.h	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/nic/include/nic.h	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -232,5 +232,4 @@
 extern int nic_report_poll_mode(nic_t *, nic_poll_mode_t, struct timeval *);
 extern void nic_query_address(nic_t *, nic_address_t *);
-extern void nic_received_noneth_frame(nic_t *, void *, size_t);
 extern void nic_received_frame(nic_t *, nic_frame_t *);
 extern void nic_received_frame_list(nic_t *, nic_frame_list_t *);
Index: uspace/lib/nic/src/nic_driver.c
===================================================================
--- uspace/lib/nic/src/nic_driver.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/nic/src/nic_driver.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -624,23 +624,4 @@
 
 /**
- * This function is to be used only in the loopback driver. It's workaround
- * for the situation when the frame does not contain ethernet address.
- * The filtering is therefore not applied here.
- *
- * @param nic_data
- * @param data		Frame data
- * @param size		Frame size in bytes
- */
-void nic_received_noneth_frame(nic_t *nic_data, void *data, size_t size)
-{
-	fibril_rwlock_write_lock(&nic_data->stats_lock);
-	nic_data->stats.receive_packets++;
-	nic_data->stats.receive_bytes += size;
-	fibril_rwlock_write_unlock(&nic_data->stats_lock);
-	
-	nic_ev_received(nic_data->client_session, data, size);
-}
-
-/**
  * Some NICs can receive multiple frames during single interrupt. These can
  * send them in whole list of frames (actually nic_frame_t structures), then
Index: uspace/lib/nic/src/nic_ev.c
===================================================================
--- uspace/lib/nic/src/nic_ev.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/nic/src/nic_ev.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -54,5 +54,5 @@
 
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
@@ -86,5 +86,5 @@
 
 	if (retval != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return retval;
 	}
Index: uspace/lib/usbhid/src/hidiface.c
===================================================================
--- uspace/lib/usbhid/src/hidiface.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/usbhid/src/hidiface.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -120,5 +120,5 @@
 	
 	if (data_request == 0) {
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		free(buffer);
 		return ENOMEM;
@@ -206,5 +206,5 @@
 	
 	if (data_request == 0) {
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return ENOMEM;
 	}
Index: uspace/lib/usbvirt/src/ipc_hc.c
===================================================================
--- uspace/lib/usbvirt/src/ipc_hc.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/lib/usbvirt/src/ipc_hc.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -80,5 +80,5 @@
 	if (rc != EOK) {
 		async_exchange_end(exch);
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return rc;
 	}
@@ -91,5 +91,5 @@
 	
 	if (data_request == 0) {
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return ENOMEM;
 	}
@@ -153,5 +153,5 @@
 	if (rc != EOK) {
 		async_exchange_end(exch);
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return rc;
 	}
@@ -161,5 +161,5 @@
 		if (rc != EOK) {
 			async_exchange_end(exch);
-			async_wait_for(opening_request, NULL);
+			async_forget(opening_request);
 			return rc;
 		}
@@ -226,5 +226,5 @@
 	
 	if (data_request == 0) {
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return ENOMEM;
 	}
@@ -301,5 +301,5 @@
 	
 	if (rc != EOK) {
-		async_wait_for(opening_request, NULL);
+		async_forget(opening_request);
 		return rc;
 	}
Index: pace/srv/clip/Makefile
===================================================================
--- uspace/srv/clip/Makefile	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ 	(revision )
@@ -1,36 +1,0 @@
-#
-# Copyright (c) 2005 Martin Decky
-# Copyright (c) 2007 Jakub Jermar
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-#
-# - Redistributions of source code must retain the above copyright
-#   notice, this list of conditions and the following disclaimer.
-# - Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in the
-#   documentation and/or other materials provided with the distribution.
-# - The name of the author may not be used to endorse or promote products
-#   derived from this software without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
-# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
-# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
-# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
-# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
-# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
-# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-#
-
-USPACE_PREFIX = ../..
-BINARY = clip
-
-SOURCES = \
-	clip.c
-
-include $(USPACE_PREFIX)/Makefile.common
Index: pace/srv/clip/clip.c
===================================================================
--- uspace/srv/clip/clip.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ 	(revision )
@@ -1,193 +1,0 @@
-/*
- * Copyright (c) 2009 Martin Decky
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include <stdio.h>
-#include <bool.h>
-#include <async.h>
-#include <ns.h>
-#include <ipc/services.h>
-#include <ipc/clipboard.h>
-#include <malloc.h>
-#include <fibril_synch.h>
-#include <errno.h>
-
-#define NAME  "clip"
-
-static char *clip_data = NULL;
-static size_t clip_size = 0;
-static clipboard_tag_t clip_tag = CLIPBOARD_TAG_NONE;
-static FIBRIL_MUTEX_INITIALIZE(clip_mtx);
-
-static void clip_put_data(ipc_callid_t rid, ipc_call_t *request)
-{
-	char *data;
-	int rc;
-	size_t size;
-	
-	switch (IPC_GET_ARG1(*request)) {
-	case CLIPBOARD_TAG_NONE:
-		fibril_mutex_lock(&clip_mtx);
-		
-		if (clip_data)
-			free(clip_data);
-		
-		clip_data = NULL;
-		clip_size = 0;
-		clip_tag = CLIPBOARD_TAG_NONE;
-		
-		fibril_mutex_unlock(&clip_mtx);
-		async_answer_0(rid, EOK);
-		break;
-	case CLIPBOARD_TAG_DATA:
-		rc = async_data_write_accept((void **) &data, false, 0, 0, 0, &size);
-		if (rc != EOK) {
-			async_answer_0(rid, rc);
-			break;
-		}
-		
-		fibril_mutex_lock(&clip_mtx);
-		
-		if (clip_data)
-			free(clip_data);
-		
-		clip_data = data;
-		clip_size = size;
-		clip_tag = CLIPBOARD_TAG_DATA;
-		
-		fibril_mutex_unlock(&clip_mtx);
-		async_answer_0(rid, EOK);
-		break;
-	default:
-		async_answer_0(rid, EINVAL);
-	}
-}
-
-static void clip_get_data(ipc_callid_t rid, ipc_call_t *request)
-{
-	fibril_mutex_lock(&clip_mtx);
-	
-	ipc_callid_t callid;
-	size_t size;
-	
-	/* Check for clipboard data tag compatibility */
-	switch (IPC_GET_ARG1(*request)) {
-	case CLIPBOARD_TAG_DATA:
-		if (!async_data_read_receive(&callid, &size)) {
-			async_answer_0(callid, EINVAL);
-			async_answer_0(rid, EINVAL);
-			break;
-		}
-		
-		if (clip_tag != CLIPBOARD_TAG_DATA) {
-			/* So far we only understand binary data */
-			async_answer_0(callid, EOVERFLOW);
-			async_answer_0(rid, EOVERFLOW);
-			break;
-		}
-		
-		if (clip_size != size) {
-			/* The client expects different size of data */
-			async_answer_0(callid, EOVERFLOW);
-			async_answer_0(rid, EOVERFLOW);
-			break;
-		}
-		
-		sysarg_t retval = async_data_read_finalize(callid, clip_data, size);
-		if (retval != EOK) {
-			async_answer_0(rid, retval);
-			break;
-		}
-		
-		async_answer_0(rid, EOK);
-	default:
-		/*
-		 * Sorry, we don't know how to get unknown or NONE
-		 * data from the clipbard
-		 */
-		async_answer_0(rid, EINVAL);
-		break;
-	}
-	
-	fibril_mutex_unlock(&clip_mtx);
-}
-
-static void clip_content(ipc_callid_t rid, ipc_call_t *request)
-{
-	fibril_mutex_lock(&clip_mtx);
-	
-	size_t size = clip_size;
-	clipboard_tag_t tag = clip_tag;
-	
-	fibril_mutex_unlock(&clip_mtx);
-	async_answer_2(rid, EOK, (sysarg_t) size, (sysarg_t) tag);
-}
-
-static void clip_connection(ipc_callid_t iid, ipc_call_t *icall, void *arg)
-{
-	/* Accept connection */
-	async_answer_0(iid, EOK);
-	
-	while (true) {
-		ipc_call_t call;
-		ipc_callid_t callid = async_get_call(&call);
-		
-		if (!IPC_GET_IMETHOD(call))
-			break;
-		
-		switch (IPC_GET_IMETHOD(call)) {
-		case CLIPBOARD_PUT_DATA:
-			clip_put_data(callid, &call);
-			break;
-		case CLIPBOARD_GET_DATA:
-			clip_get_data(callid, &call);
-			break;
-		case CLIPBOARD_CONTENT:
-			clip_content(callid, &call);
-			break;
-		default:
-			async_answer_0(callid, ENOENT);
-		}
-	}
-}
-
-int main(int argc, char *argv[])
-{
-	printf("%s: HelenOS clipboard service\n", NAME);
-	
-	async_set_client_connection(clip_connection);
-	
-	if (service_register(SERVICE_CLIPBOARD) != EOK)
-		return -1;
-	
-	printf("%s: Accepting connections\n", NAME);
-	task_retval(0);
-	async_manager();
-	
-	/* Never reached */
-	return 0;
-}
Index: pace/srv/clip/clip.h
===================================================================
--- uspace/srv/clip/clip.h	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ 	(revision )
@@ -1,32 +1,0 @@
-/*
- * Copyright (c) 2009 Martin Decky
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef CLIP_MAIN_H_
-#define CLIP_MAIN_H_
-
-#endif
Index: uspace/srv/clipboard/Makefile
===================================================================
--- uspace/srv/clipboard/Makefile	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
+++ uspace/srv/clipboard/Makefile	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -0,0 +1,36 @@
+#
+# Copyright (c) 2005 Martin Decky
+# Copyright (c) 2007 Jakub Jermar
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# - Redistributions of source code must retain the above copyright
+#   notice, this list of conditions and the following disclaimer.
+# - Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in the
+#   documentation and/or other materials provided with the distribution.
+# - The name of the author may not be used to endorse or promote products
+#   derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#
+
+USPACE_PREFIX = ../..
+BINARY = clipboard
+
+SOURCES = \
+	clipboard.c
+
+include $(USPACE_PREFIX)/Makefile.common
Index: uspace/srv/clipboard/clip.h
===================================================================
--- uspace/srv/clipboard/clip.h	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
+++ uspace/srv/clipboard/clip.h	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -0,0 +1,32 @@
+/*
+ * Copyright (c) 2009 Martin Decky
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ *   notice, this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright
+ *   notice, this list of conditions and the following disclaimer in the
+ *   documentation and/or other materials provided with the distribution.
+ * - The name of the author may not be used to endorse or promote products
+ *   derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef CLIP_MAIN_H_
+#define CLIP_MAIN_H_
+
+#endif
Index: uspace/srv/clipboard/clipboard.c
===================================================================
--- uspace/srv/clipboard/clipboard.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
+++ uspace/srv/clipboard/clipboard.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -0,0 +1,193 @@
+/*
+ * Copyright (c) 2009 Martin Decky
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ *   notice, this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright
+ *   notice, this list of conditions and the following disclaimer in the
+ *   documentation and/or other materials provided with the distribution.
+ * - The name of the author may not be used to endorse or promote products
+ *   derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include <stdio.h>
+#include <bool.h>
+#include <async.h>
+#include <ns.h>
+#include <ipc/services.h>
+#include <ipc/clipboard.h>
+#include <malloc.h>
+#include <fibril_synch.h>
+#include <errno.h>
+
+#define NAME  "clipboard"
+
+static char *clip_data = NULL;
+static size_t clip_size = 0;
+static clipboard_tag_t clip_tag = CLIPBOARD_TAG_NONE;
+static FIBRIL_MUTEX_INITIALIZE(clip_mtx);
+
+static void clip_put_data(ipc_callid_t rid, ipc_call_t *request)
+{
+	char *data;
+	int rc;
+	size_t size;
+	
+	switch (IPC_GET_ARG1(*request)) {
+	case CLIPBOARD_TAG_NONE:
+		fibril_mutex_lock(&clip_mtx);
+		
+		if (clip_data)
+			free(clip_data);
+		
+		clip_data = NULL;
+		clip_size = 0;
+		clip_tag = CLIPBOARD_TAG_NONE;
+		
+		fibril_mutex_unlock(&clip_mtx);
+		async_answer_0(rid, EOK);
+		break;
+	case CLIPBOARD_TAG_DATA:
+		rc = async_data_write_accept((void **) &data, false, 0, 0, 0, &size);
+		if (rc != EOK) {
+			async_answer_0(rid, rc);
+			break;
+		}
+		
+		fibril_mutex_lock(&clip_mtx);
+		
+		if (clip_data)
+			free(clip_data);
+		
+		clip_data = data;
+		clip_size = size;
+		clip_tag = CLIPBOARD_TAG_DATA;
+		
+		fibril_mutex_unlock(&clip_mtx);
+		async_answer_0(rid, EOK);
+		break;
+	default:
+		async_answer_0(rid, EINVAL);
+	}
+}
+
+static void clip_get_data(ipc_callid_t rid, ipc_call_t *request)
+{
+	fibril_mutex_lock(&clip_mtx);
+	
+	ipc_callid_t callid;
+	size_t size;
+	
+	/* Check for clipboard data tag compatibility */
+	switch (IPC_GET_ARG1(*request)) {
+	case CLIPBOARD_TAG_DATA:
+		if (!async_data_read_receive(&callid, &size)) {
+			async_answer_0(callid, EINVAL);
+			async_answer_0(rid, EINVAL);
+			break;
+		}
+		
+		if (clip_tag != CLIPBOARD_TAG_DATA) {
+			/* So far we only understand binary data */
+			async_answer_0(callid, EOVERFLOW);
+			async_answer_0(rid, EOVERFLOW);
+			break;
+		}
+		
+		if (clip_size != size) {
+			/* The client expects different size of data */
+			async_answer_0(callid, EOVERFLOW);
+			async_answer_0(rid, EOVERFLOW);
+			break;
+		}
+		
+		sysarg_t retval = async_data_read_finalize(callid, clip_data, size);
+		if (retval != EOK) {
+			async_answer_0(rid, retval);
+			break;
+		}
+		
+		async_answer_0(rid, EOK);
+	default:
+		/*
+		 * Sorry, we don't know how to get unknown or NONE
+		 * data from the clipbard
+		 */
+		async_answer_0(rid, EINVAL);
+		break;
+	}
+	
+	fibril_mutex_unlock(&clip_mtx);
+}
+
+static void clip_content(ipc_callid_t rid, ipc_call_t *request)
+{
+	fibril_mutex_lock(&clip_mtx);
+	
+	size_t size = clip_size;
+	clipboard_tag_t tag = clip_tag;
+	
+	fibril_mutex_unlock(&clip_mtx);
+	async_answer_2(rid, EOK, (sysarg_t) size, (sysarg_t) tag);
+}
+
+static void clip_connection(ipc_callid_t iid, ipc_call_t *icall, void *arg)
+{
+	/* Accept connection */
+	async_answer_0(iid, EOK);
+	
+	while (true) {
+		ipc_call_t call;
+		ipc_callid_t callid = async_get_call(&call);
+		
+		if (!IPC_GET_IMETHOD(call))
+			break;
+		
+		switch (IPC_GET_IMETHOD(call)) {
+		case CLIPBOARD_PUT_DATA:
+			clip_put_data(callid, &call);
+			break;
+		case CLIPBOARD_GET_DATA:
+			clip_get_data(callid, &call);
+			break;
+		case CLIPBOARD_CONTENT:
+			clip_content(callid, &call);
+			break;
+		default:
+			async_answer_0(callid, ENOENT);
+		}
+	}
+}
+
+int main(int argc, char *argv[])
+{
+	printf("%s: HelenOS clipboard service\n", NAME);
+	
+	async_set_client_connection(clip_connection);
+	
+	if (service_register(SERVICE_CLIPBOARD) != EOK)
+		return -1;
+	
+	printf("%s: Accepting connections\n", NAME);
+	task_retval(0);
+	async_manager();
+	
+	/* Never reached */
+	return 0;
+}
Index: uspace/srv/hid/input/port/chardev.c
===================================================================
--- uspace/srv/hid/input/port/chardev.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/hid/input/port/chardev.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -63,5 +63,5 @@
 /** List of devices to try connecting to. */
 static const char *in_devs[] = {
-	"char/s3c24ser"
+	"char/s3c24xx_uart"
 };
 
Index: uspace/srv/hid/s3c24xx_ts/Makefile
===================================================================
--- uspace/srv/hid/s3c24xx_ts/Makefile	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/hid/s3c24xx_ts/Makefile	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -29,6 +29,5 @@
 USPACE_PREFIX = ../../..
 
-# Need to use short name because of FAT 8+3 limit
-BINARY = s3c24ts
+BINARY = s3c24xx_ts
 
 SOURCES = \
Index: uspace/srv/hid/s3c24xx_ts/s3c24xx_ts.c
===================================================================
--- uspace/srv/hid/s3c24xx_ts/s3c24xx_ts.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/hid/s3c24xx_ts/s3c24xx_ts.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -52,5 +52,5 @@
 #include "s3c24xx_ts.h"
 
-#define NAME       "s3c24ser"
+#define NAME       "s3c24xx_ts"
 #define NAMESPACE  "hid"
 
Index: uspace/srv/net/inet/inet.c
===================================================================
--- uspace/srv/net/inet/inet.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/net/inet/inet.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -364,5 +364,5 @@
 
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: uspace/srv/net/inet/inetping.c
===================================================================
--- uspace/srv/net/inet/inetping.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/net/inet/inetping.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -88,5 +88,5 @@
 
 	if (rc != EOK) {
-		async_wait_for(req, NULL);
+		async_forget(req);
 		return rc;
 	}
Index: uspace/srv/net/tcp/sock.c
===================================================================
--- uspace/srv/net/tcp/sock.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/net/tcp/sock.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -42,5 +42,4 @@
 #include <ipc/services.h>
 #include <ipc/socket.h>
-#include <net/modules.h>
 #include <net/socket.h>
 #include <ns.h>
@@ -89,4 +88,6 @@
 	socket = (tcp_sockdata_t *)sock_core->specific_data;
 	(void)socket;
+
+	/* XXX We need to initiate connection cleanup here */
 }
 
@@ -142,10 +143,11 @@
 	sock->sock_core = sock_core;
 
-	refresh_answer(&answer, NULL);
 	SOCKET_SET_SOCKET_ID(answer, sock_id);
 
 	SOCKET_SET_DATA_FRAGMENT_SIZE(answer, FRAGMENT_SIZE);
 	SOCKET_SET_HEADER_SIZE(answer, sizeof(tcp_header_t));
-	answer_call(callid, EOK, &answer, 3);
+	
+	async_answer_3(callid, EOK, IPC_GET_ARG1(answer),
+	    IPC_GET_ARG2(answer), IPC_GET_ARG3(answer));
 }
 
@@ -466,12 +468,12 @@
 	assert(asock_core != NULL);
 
-	refresh_answer(&answer, NULL);
-
 	SOCKET_SET_DATA_FRAGMENT_SIZE(answer, FRAGMENT_SIZE);
 	SOCKET_SET_SOCKET_ID(answer, asock_id);
 	SOCKET_SET_ADDRESS_LENGTH(answer, sizeof(struct sockaddr_in));
-
-	answer_call(callid, asock_core->socket_id, &answer, 3);
-
+	
+	async_answer_3(callid, asock_core->socket_id,
+	    IPC_GET_ARG1(answer), IPC_GET_ARG2(answer),
+	    IPC_GET_ARG3(answer));
+	
 	/* Push one fragment notification to client's queue */
 	log_msg(LVL_DEBUG, "tcp_sock_accept(): notify data\n");
@@ -557,7 +559,8 @@
 	}
 
-	refresh_answer(&answer, NULL);
+	IPC_SET_ARG1(answer, 0);
 	SOCKET_SET_DATA_FRAGMENT_SIZE(answer, FRAGMENT_SIZE);
-	answer_call(callid, EOK, &answer, 2);
+	async_answer_2(callid, EOK, IPC_GET_ARG1(answer),
+	    IPC_GET_ARG2(answer));
 	fibril_mutex_unlock(&socket->lock);
 }
@@ -677,6 +680,6 @@
 
 	SOCKET_SET_READ_DATA_LENGTH(answer, length);
-	answer_call(callid, EOK, &answer, 1);
-
+	async_answer_1(callid, EOK, IPC_GET_ARG1(answer));
+	
 	/* Push one fragment notification to client's queue */
 	tcp_sock_notify_data(sock_core);
@@ -835,4 +838,9 @@
 		}
 	}
+
+	/* Clean up */
+	log_msg(LVL_DEBUG, "tcp_sock_connection: Clean up");
+	async_hangup(client.sess);
+	socket_cores_release(NULL, &client.sockets, &gsock, tcp_free_sock_data);
 }
 
Index: uspace/srv/net/udp/sock.c
===================================================================
--- uspace/srv/net/udp/sock.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/net/udp/sock.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -43,5 +43,4 @@
 #include <ipc/services.h>
 #include <ipc/socket.h>
-#include <net/modules.h>
 #include <net/socket.h>
 #include <ns.h>
@@ -85,5 +84,6 @@
 
 	socket = (udp_sockdata_t *)sock_core->specific_data;
-	(void)socket;
+	assert(socket->assoc != NULL);
+	udp_uc_destroy(socket->assoc);
 }
 
@@ -133,12 +133,11 @@
 	assert(sock_core != NULL);
 	sock->sock_core = sock_core;
-
-
-	refresh_answer(&answer, NULL);
+	
 	SOCKET_SET_SOCKET_ID(answer, sock_id);
 
 	SOCKET_SET_DATA_FRAGMENT_SIZE(answer, FRAGMENT_SIZE);
 	SOCKET_SET_HEADER_SIZE(answer, sizeof(udp_header_t));
-	answer_call(callid, EOK, &answer, 3);
+	async_answer_3(callid, EOK, IPC_GET_ARG1(answer),
+	    IPC_GET_ARG2(answer), IPC_GET_ARG3(answer));
 }
 
@@ -368,9 +367,11 @@
 		}
 	}
-
-	refresh_answer(&answer, NULL);
+	
+	IPC_SET_ARG1(answer, 0);
 	SOCKET_SET_DATA_FRAGMENT_SIZE(answer, FRAGMENT_SIZE);
-	answer_call(callid, EOK, &answer, 2);
+	async_answer_2(callid, EOK, IPC_GET_ARG1(answer),
+	    IPC_GET_ARG2(answer));
 	fibril_mutex_unlock(&socket->lock);
+	
 out:
 	if (addr != NULL)
@@ -485,8 +486,10 @@
 
 	log_msg(LVL_DEBUG, "read_data_length <- %zu", length);
+	IPC_SET_ARG2(answer, 0);
 	SOCKET_SET_READ_DATA_LENGTH(answer, length);
 	SOCKET_SET_ADDRESS_LENGTH(answer, sizeof(addr));
-	answer_call(callid, EOK, &answer, 3);
-
+	async_answer_3(callid, EOK, IPC_GET_ARG1(answer),
+	    IPC_GET_ARG2(answer), IPC_GET_ARG3(answer));
+	
 	/* Push one fragment notification to client's queue */
 	udp_sock_notify_data(sock_core);
@@ -512,7 +515,4 @@
 	socket = (udp_sockdata_t *)sock_core->specific_data;
 	fibril_mutex_lock(&socket->lock);
-
-	assert(socket->assoc != NULL);
-	udp_uc_destroy(socket->assoc);
 
 	rc = socket_destroy(NULL, socket_id, &client->sockets, &gsock,
@@ -599,4 +599,9 @@
 		}
 	}
+
+	/* Clean up */
+	log_msg(LVL_DEBUG, "udp_sock_connection: Clean up");
+	async_hangup(client.sess);
+	socket_cores_release(NULL, &client.sockets, &gsock, udp_free_sock_data);
 }
 
Index: uspace/srv/vfs/vfs_ops.c
===================================================================
--- uspace/srv/vfs/vfs_ops.c	(revision 6efb4d2ae69379d91c4fccc34083faf72518fd07)
+++ uspace/srv/vfs/vfs_ops.c	(revision 1a23f6ec4a86a9f9b2d79272d9b134a9e00875f8)
@@ -137,5 +137,5 @@
 			
 			if (rc != EOK) {
-				async_wait_for(msg, NULL);
+				async_forget(msg);
 				fibril_rwlock_write_unlock(&namespace_rwlock);
 				async_answer_0(rid, rc);
@@ -204,5 +204,5 @@
 	if (rc != EOK) {
 		vfs_exchange_release(exch);
-		async_wait_for(msg, NULL);
+		async_forget(msg);
 		
 		/* Mount failed, drop reference to mp_node. */
@@ -219,5 +219,5 @@
 	if (rc != EOK) {
 		vfs_exchange_release(exch);
-		async_wait_for(msg, NULL);
+		async_forget(msg);
 		
 		/* Mount failed, drop reference to mp_node. */
