Index: uspace/lib/hound/include/hound/client.h
===================================================================
--- uspace/lib/hound/include/hound/client.h	(revision eb0ef5148d4b4fe77108a5a24002b26178b294a7)
+++ uspace/lib/hound/include/hound/client.h	(revision 876f55613e8dd6d15775798211c6f619f0c533dc)
@@ -54,6 +54,6 @@
 void hound_context_destroy(hound_context_t *hound);
 
-int hound_context_set_main_stream_format(hound_context_t *hound,
-    unsigned channels, unsigned rate, pcm_sample_format_t format);
+int hound_context_set_main_stream_params(hound_context_t *hound,
+    pcm_format_t format, size_t bsize);
 
 int hound_context_get_available_targets(hound_context_t *hound,
Index: uspace/lib/hound/include/hound/protocol.h
===================================================================
--- uspace/lib/hound/include/hound/protocol.h	(revision eb0ef5148d4b4fe77108a5a24002b26178b294a7)
+++ uspace/lib/hound/include/hound/protocol.h	(revision 876f55613e8dd6d15775798211c6f619f0c533dc)
@@ -41,7 +41,7 @@
 #include <pcm/format.h>
 
-const char *HOUND_SERVICE;
+extern const char *HOUND_SERVICE;
 
-enum {
+typedef enum {
 	HOUND_SINK_APPS = 0x1,
 	HOUND_SINK_DEVS = 0x2,
@@ -53,9 +53,14 @@
 	HOUND_STREAM_IGNORE_UNDERFLOW = 0x2,
 	HOUND_STREAM_IGNORE_OVERFLOW = 0x4,
-};
+} hound_flags_t;
 
 typedef async_sess_t hound_sess_t;
 typedef intptr_t hound_context_id_t;
 
+/**
+ * Check context id for errors.
+ * @param id Context id
+ * @return Error code.
+ */
 static inline int hound_context_id_err(hound_context_id_t id)
 {
@@ -72,4 +77,13 @@
 int hound_service_get_list(hound_sess_t *sess, const char ***ids, size_t *count,
     int flags, const char *connection);
+
+/**
+ * Wrapper for list queries with no connection parameter.
+ * @param[in] sess hound daemon session.
+ * @param[out] ids list of string identifiers
+ * @param[out] count Number of elements in @p ids
+ * @param[in] flags Flags limiting the query.
+ * @return Error code.
+ */
 static inline int hound_service_get_list_all(hound_sess_t *sess,
     const char ***ids, size_t *count, int flags)
@@ -92,16 +106,29 @@
 
 /* Server */
+
+/** Hound server interace structure */
 typedef struct hound_server_iface {
+	/** Create new context */
 	int (*add_context)(void *, hound_context_id_t *, const char *, bool);
+	/** Destroy existing context */
 	int (*rem_context)(void *, hound_context_id_t);
+	/** Query context direction */
 	bool (*is_record_context)(void *, hound_context_id_t);
+	/** Get string identifiers of specified objects */
 	int (*get_list)(void *, const char ***, size_t *, const char *, int);
+	/** Create connection between source and sink */
 	int (*connect)(void *, const char *, const char *);
+	/** Destroy connection between source and sink */
 	int (*disconnect)(void *, const char *, const char *);
+	/** Create new stream tied to the context */
 	int (*add_stream)(void *, hound_context_id_t, int, pcm_format_t, size_t,
 	    void **);
+	/** Destroy existing stream */
 	int (*rem_stream)(void *, void *);
+	/** Block until the stream buffer is empty */
 	int (*drain_stream)(void *);
+	/** Write new data to the stream */
 	int (*stream_data_write)(void *, const void *, size_t);
+	/** Read data from the stream */
 	int (*stream_data_read)(void *, void *, size_t);
 	void *server;
Index: uspace/lib/hound/src/client.c
===================================================================
--- uspace/lib/hound/src/client.c	(revision eb0ef5148d4b4fe77108a5a24002b26178b294a7)
+++ uspace/lib/hound/src/client.c	(revision 876f55613e8dd6d15775798211c6f619f0c533dc)
@@ -45,16 +45,23 @@
 #include "client.h"
 
-/***
- * CLIENT SIDE
- ***/
-
+/** Stream structure */
 typedef struct hound_stream {
+	/** link in context's list */
 	link_t link;
+	/** audio data format fo the stream */
 	pcm_format_t format;
+	/** IPC exchange representing the stream (in STREAM MODE) */
 	async_exch_t *exch;
+	/** parent context */
 	hound_context_t *context;
+	/** Stream flags */
 	int flags;
 } hound_stream_t;
 
+/**
+ * Linked list isntacen helper function.
+ * @param l link
+ * @return hound stream isntance.
+ */
 static inline hound_stream_t * hound_stream_from_link(link_t *l)
 {
@@ -62,9 +69,15 @@
 }
 
+/** Hound client context structure */
 typedef struct hound_context {
+	/** Audio session */
 	hound_sess_t *session;
+	/** context name, reported to the daemon */
 	const char *name;
+	/** True if the instance is record context */
 	bool record;
+	/** List of associated streams */
 	list_t stream_list;
+	/** Main stream helper structure */
 	struct {
 		hound_stream_t *stream;
@@ -72,8 +85,16 @@
 		size_t bsize;
 	} main;
+	/** Assigned context id */
 	hound_context_id_t id;
 } hound_context_t;
 
-
+/**
+ * Alloc and initialize context structure.
+ * @param name Base for the real context name, will add task id.
+ * @param record True if the new context should capture audio data.
+ * @param format PCM format of the main pipe.
+ * @param bsize Server size buffer size of the main stream.
+ * @return valid pointer to initialized structure on success, NULL on failure
+ */
 static hound_context_t *hound_context_create(const char *name, bool record,
     pcm_format_t format, size_t bsize)
@@ -111,4 +132,11 @@
 }
 
+/**
+ * Playback context helper function.
+ * @param name Base for the real context name, will add task id.
+ * @param format PCM format of the main pipe.
+ * @param bsize Server size buffer size of the main stream.
+ * @return valid pointer to initialized structure on success, NULL on failure
+ */
 hound_context_t * hound_context_create_playback(const char *name,
     pcm_format_t format, size_t bsize)
@@ -117,4 +145,11 @@
 }
 
+/**
+ * Record context helper function.
+ * @param name Base for the real context name, will add task id.
+ * @param format PCM format of the main pipe.
+ * @param bsize Server size buffer size of the main stream.
+ * @return valid pointer to initialized structure on success, NULL on failure
+ */
 hound_context_t * hound_context_create_capture(const char *name,
     pcm_format_t format, size_t bsize)
@@ -123,4 +158,12 @@
 }
 
+/**
+ * Correctly dispose of the hound context structure.
+ * @param hound context to remove.
+ *
+ * The function will destroy all associated streams first. Pointers
+ * to these structures will become invalid and the function will block
+ * if any of these stream needs to be drained first.
+ */
 void hound_context_destroy(hound_context_t *hound)
 {
@@ -139,4 +182,13 @@
 }
 
+/**
+ * Get a list of possible connection targets.
+ * @param[in] hound Hound context.
+ * @param[out] names list of target string ids.
+ * @param[out] count Number of elements in @p names list
+ * @return Error code.
+ *
+ * The function will return deice sinks or source based on the context type.
+ */
 int hound_context_get_available_targets(hound_context_t *hound,
     const char ***names, size_t *count)
@@ -149,4 +201,11 @@
 }
 
+/**
+ * Get a list of targets connected to the context.
+ * @param[in] hound Hound context.
+ * @param[out] names list of target string ids.
+ * @param[out] count Number of elements in @p names list
+ * @return Error code.
+ */
 int hound_context_get_connected_targets(hound_context_t *hound,
     const char ***names, size_t *count)
@@ -160,4 +219,13 @@
 }
 
+/**
+ * Create a new connection to the target.
+ * @param hound Hound context.
+ * @param target String identifier of the desired target.
+ * @return Error code.
+ *
+ * The function recognizes special 'HOUND_DEFAULT_TARGET' and will
+ * connect to the first possible target if it is passed this value.
+ */
 int hound_context_connect_target(hound_context_t *hound, const char* target)
 {
@@ -189,4 +257,10 @@
 }
 
+/**
+ * Destroy a connection to the target.
+ * @param hound Hound context.
+ * @param target String identifier of the desired target.
+ * @return Error code.
+ */
 int hound_context_disconnect_target(hound_context_t *hound, const char* target)
 {
@@ -203,4 +277,12 @@
 }
 
+/**
+ * Create a new stream associated with the context.
+ * @param hound Hound context.
+ * @param flags new stream flags.
+ * @param format new stream PCM format.
+ * @param bzise new stream server side buffer size (in bytes)
+ * @return Valid pointer to a stream instance, NULL on failure.
+ */
 hound_stream_t *hound_stream_create(hound_context_t *hound, unsigned flags,
     pcm_format_t format, size_t bsize)
@@ -229,4 +311,11 @@
 }
 
+/**
+ * Destroy existing stream
+ * @param stream The stream to destroy.
+ *
+ * Function will wait until the server side buffer is empty if the
+ * HOUND_STREAM_DRAIN_ON_EXIT flag was set on creation.
+ */
 void hound_stream_destroy(hound_stream_t *stream)
 {
@@ -241,4 +330,11 @@
 }
 
+/**
+ * Send new data to a stream.
+ * @param stream The target stream
+ * @param data data buffer
+ * @param size size of the @p data buffer.
+ * @return error code.
+ */
 int hound_stream_write(hound_stream_t *stream, const void *data, size_t size)
 {
@@ -249,4 +345,11 @@
 }
 
+/**
+ * Get data from a stream.
+ * @param stream The target stream.
+ * @param data data buffer.
+ * @param size size of the @p data buffer.
+ * @return error code.
+ */
 int hound_stream_read(hound_stream_t *stream, void *data, size_t size)
 {
@@ -257,4 +360,12 @@
 }
 
+/**
+ * Main stream getter function.
+ * @param hound Houndcontext.
+ * @return Valid stream pointer, NULL on failure.
+ *
+ * The function will create new stream, or return a pointer to the exiting one
+ * if it exists.
+ */
 static hound_stream_t * hound_get_main_stream(hound_context_t *hound)
 {
@@ -267,8 +378,18 @@
 }
 
+/**
+ * Send new data to the main stream.
+ * @param stream The target stream
+ * @param data data buffer
+ * @param size size of the @p data buffer.
+ * @return error code.
+ */
 int hound_write_main_stream(hound_context_t *hound,
     const void *data, size_t size)
 {
 	assert(hound);
+	if (hound->record)
+		return EINVAL;
+
 	hound_stream_t *mstream = hound_get_main_stream(hound);
 	if (!mstream)
@@ -277,7 +398,16 @@
 }
 
+/**
+ * Get data from the main stream.
+ * @param stream The target stream
+ * @param data data buffer
+ * @param size size of the @p data buffer.
+ * @return error code.
+ */
 int hound_read_main_stream(hound_context_t *hound, void *data, size_t size)
 {
 	assert(hound);
+	if (!hound->record)
+		return EINVAL;
 	hound_stream_t *mstream = hound_get_main_stream(hound);
 	if (!mstream)
@@ -286,4 +416,13 @@
 }
 
+/**
+ * Destroy the old main stream and replace it with a new one with fresh data.
+ * @param hound Hound context.
+ * @param data data buffer.
+ * @param size size of the @p data buffer.
+ * @return error code.
+ *
+ * NOT IMPLEMENTED
+ */
 int hound_write_replace_main_stream(hound_context_t *hound,
     const void *data, size_t size)
@@ -296,6 +435,14 @@
 }
 
-int hound_context_set_main_stream_format(hound_context_t *hound,
-    unsigned channels, unsigned rate, pcm_sample_format_t format)
+/**
+ * Destroy the old main stream and replace it with a new one using new params.
+ * @param hound Hound context.
+ * @param channels
+ * @return error code.
+ *
+ * NOT IMPLEMENTED
+ */
+int hound_context_set_main_stream_params(hound_context_t *hound,
+    pcm_format_t format, size_t bsize)
 {
 	assert(hound);
@@ -304,8 +451,21 @@
 }
 
+/**
+ * Write data immediately to a new stream, and wait for it to drain.
+ * @param hound Hound context.
+ * @param format pcm data format.
+ * @param data data buffer
+ * @param size @p data buffer size
+ * @return Error code.
+ *
+ * This functnion creates a new stream writes the data, ti waits for the stream
+ * to drain and destroys it before returning.
+ */
 int hound_write_immediate(hound_context_t *hound, pcm_format_t format,
     const void *data, size_t size)
 {
 	assert(hound);
+	if (hound->record)
+		return EINVAL;
 	hound_stream_t *tmpstream = hound_stream_create(hound, 0, format, size);
 	if (!tmpstream)
@@ -319,6 +479,4 @@
 	return ret;
 }
-
-
 /**
  * @}
Index: uspace/lib/hound/src/protocol.c
===================================================================
--- uspace/lib/hound/src/protocol.c	(revision eb0ef5148d4b4fe77108a5a24002b26178b294a7)
+++ uspace/lib/hound/src/protocol.c	(revision 876f55613e8dd6d15775798211c6f619f0c533dc)
@@ -48,14 +48,24 @@
 
 enum ipc_methods {
+	/** Create new context representation on the server side */
 	IPC_M_HOUND_CONTEXT_REGISTER = IPC_FIRST_USER_METHOD,
+	/** Release existing context representation on the server side */
 	IPC_M_HOUND_CONTEXT_UNREGISTER,
+	/** Request list of objects */
 	IPC_M_HOUND_GET_LIST,
+	/** Create new connection */
 	IPC_M_HOUND_CONNECT,
+	/** Destroy connection */
 	IPC_M_HOUND_DISCONNECT,
+	/** Switch IPC pipe to stream mode */
 	IPC_M_HOUND_STREAM_ENTER,
+	/** Switch IPC pipe back to general mode */
 	IPC_M_HOUND_STREAM_EXIT,
+	/** Wait until there is no data in the stream */
 	IPC_M_HOUND_STREAM_DRAIN,
 };
 
+
+/** PCM format conversion helper structure */
 typedef union {
 	struct {
@@ -72,6 +82,12 @@
  ****/
 
+/** Well defined service name */
 const char *HOUND_SERVICE = "audio/hound";
 
+/**
+ * Start a new audio session.
+ * @param service Named service typically 'HOUND_SERVICE' constant.
+ * @return Valid session on success, NULL on failure.
+ */
 hound_sess_t *hound_service_connect(const char *service)
 {
@@ -84,4 +100,8 @@
 }
 
+/**
+ * End an existing audio session.
+ * @param sess The session.
+ */
 void hound_service_disconnect(hound_sess_t *sess)
 {
@@ -90,4 +110,11 @@
 }
 
+/**
+ * Register a named application context to the audio server.
+ * @param sess Valid audio session.
+ * @param name Valid string identifier
+ * @param record True if the application context wishes to receive data.
+ * @return Valid ID on success, Error code on failure.
+ */
 hound_context_id_t hound_service_register_context(hound_sess_t *sess,
     const char *name, bool record)
@@ -113,4 +140,10 @@
 }
 
+/**
+ * Remove application context from the server's list.
+ * @param sess Valid audio session.
+ * @param id Valid context id.
+ * @return Error code.
+ */
 int hound_service_unregister_context(hound_sess_t *sess, hound_context_id_t id)
 {
@@ -123,4 +156,14 @@
 }
 
+/**
+ * Retrieve a list of server side actors.
+ * @param[in] sess Valid audio session.
+ * @param[out] ids list of string identifiers.
+ * @param[out] count Number of elements int the @p ids list.
+ * @param[in] flags list requirements.
+ * @param[in] connection name of target actor. Used only if the list should
+ *            contain connected actors.
+ * @retval Error code.
+ */
 int hound_service_get_list(hound_sess_t *sess, const char ***ids, size_t *count,
     int flags, const char *connection)
@@ -190,4 +233,11 @@
 }
 
+/**
+ * Create a new connection between a source and a sink.
+ * @param sess Valid audio session.
+ * @param source Source name, valid string.
+ * @param sink Sink name, valid string.
+ * @return Error code.
+ */
 int hound_service_connect_source_sink(hound_sess_t *sess, const char *source,
     const char *sink)
@@ -212,4 +262,11 @@
 }
 
+/**
+ * Destroy an existing connection between a source and a sink.
+ * @param sess Valid audio session.
+ * @param source Source name, valid string.
+ * @param sink Sink name, valid string.
+ * @return Error code.
+ */
 int hound_service_disconnect_source_sink(hound_sess_t *sess, const char *source,
     const char *sink)
@@ -231,4 +288,13 @@
 }
 
+/**
+ * Switch IPC exchange to a STREAM mode.
+ * @param exch IPC exchange.
+ * @param id context id this stream should be associated with
+ * @param flags set stream properties
+ * @param format format of the new stream.
+ * @param bsize size of the server side buffer.
+ * @return Error code.
+ */
 int hound_service_stream_enter(async_exch_t *exch, hound_context_id_t id,
     int flags, pcm_format_t format, size_t bsize)
@@ -243,4 +309,9 @@
 }
 
+/**
+ * Destroy existing stream and return IPC exchange to general mode.
+ * @param exch IPC exchange.
+ * @return Error code.
+ */
 int hound_service_stream_exit(async_exch_t *exch)
 {
@@ -248,4 +319,9 @@
 }
 
+/**
+ * Wait until the server side buffer is empty.
+ * @param exch IPC exchange.
+ * @return Error code.
+ */
 int hound_service_stream_drain(async_exch_t *exch)
 {
@@ -253,4 +329,11 @@
 }
 
+/**
+ * Write audio data to a stream.
+ * @param exch IPC exchange in STREAM MODE.
+ * @param data Audio data buffer.
+ * @size size of the buffer
+ * @return Error code.
+ */
 int hound_service_stream_write(async_exch_t *exch, const void *data, size_t size)
 {
@@ -258,4 +341,11 @@
 }
 
+/**
+ * Read data from a stream.
+ * @param exch IPC exchange in STREAM MODE.
+ * @param data Audio data buffer.
+ * @size size of the buffer
+ * @return Error code.
+ */
 int hound_service_stream_read(async_exch_t *exch, void *data, size_t size)
 {
@@ -271,4 +361,8 @@
 static const hound_server_iface_t *server_iface;
 
+/**
+ * Set hound server interface implementation.
+ * @param iface Initialized Hound server interface.
+ */
 void hound_service_set_server_iface(const hound_server_iface_t *iface)
 {
@@ -276,4 +370,10 @@
 }
 
+/**
+ * Server side implementation of the hound protocol. IPC connection handler.
+ * @param iid initial call id
+ * @param icall pointer to initial call structure.
+ * @param arg (unused)
+ */
 void hound_connection_handler(ipc_callid_t iid, ipc_call_t *icall, void *arg)
 {
@@ -291,4 +391,5 @@
 		switch (IPC_GET_IMETHOD(call)) {
 		case IPC_M_HOUND_CONTEXT_REGISTER: {
+			/* check interface functions */
 			if (!server_iface || !server_iface->add_context) {
 				async_answer_0(callid, ENOTSUP);
@@ -297,4 +398,6 @@
 			bool record = IPC_GET_ARG1(call);
 			void *name;
+
+			/* Get context name */
 			int ret =
 			    async_data_write_accept(&name, true, 0, 0, 0, 0);
@@ -306,6 +409,7 @@
 			ret = server_iface->add_context(server_iface->server,
 			    &id, name, record);
+			/** new context should create a copy */
+			free(name);
 			if (ret != EOK) {
-				free(name);
 				async_answer_0(callid, ret);
 			} else {
@@ -315,8 +419,11 @@
 		}
 		case IPC_M_HOUND_CONTEXT_UNREGISTER: {
+			/* check interface functions */
 			if (!server_iface || !server_iface->rem_context) {
 				async_answer_0(callid, ENOTSUP);
 				break;
 			}
+
+			/* get id, 1st param */
 			hound_context_id_t id = IPC_GET_ARG1(call);
 			const int ret =
@@ -326,8 +433,10 @@
 		}
 		case IPC_M_HOUND_GET_LIST: {
+			/* check interface functions */
 			if (!server_iface || !server_iface->get_list) {
 				async_answer_0(callid, ENOTSUP);
 				break;
 			}
+
 			const char **list = NULL;
 			const int flags = IPC_GET_ARG1(call);
@@ -336,4 +445,6 @@
 			char *conn_name = NULL;
 			int ret = EOK;
+
+			/* get connected actor name if provided */
 			if (conn)
 				ret = async_data_write_accept(
@@ -345,4 +456,6 @@
 				    conn_name, flags);
 			free(conn_name);
+
+			/* Alloc string sizes array */
 			size_t *sizes = NULL;
 			if (count)
@@ -383,12 +496,43 @@
 		}
 		case IPC_M_HOUND_CONNECT: {
+			/* check interface functions */
 			if (!server_iface || !server_iface->connect) {
 				async_answer_0(callid, ENOTSUP);
 				break;
 			}
+
 			void *source = NULL;
 			void *sink = NULL;
+
+			/* read source name */
 			int ret =
 			    async_data_write_accept(&source, true, 0, 0, 0, 0);
+			/* read sink name */
+			if (ret == EOK)
+				ret = async_data_write_accept(&sink,
+				    true, 0, 0, 0, 0);
+
+			if (ret == EOK)
+				ret = server_iface->connect(
+				    server_iface->server, source, sink);
+			free(source);
+			free(sink);
+			async_answer_0(callid, ret);
+			break;
+		}
+		case IPC_M_HOUND_DISCONNECT: {
+			/* check interface functions */
+			if (!server_iface || !server_iface->disconnect) {
+				async_answer_0(callid, ENOTSUP);
+				break;
+			}
+
+			void *source = NULL;
+			void *sink = NULL;
+
+			/* read source name */
+			int ret =
+			    async_data_write_accept(&source, true, 0, 0, 0, 0);
+			/*read sink name */
 			if (ret == EOK)
 				ret = async_data_write_accept(&sink,
@@ -402,25 +546,6 @@
 			break;
 		}
-		case IPC_M_HOUND_DISCONNECT: {
-			if (!server_iface || !server_iface->disconnect) {
-				async_answer_0(callid, ENOTSUP);
-				break;
-			}
-			void *source = NULL;
-			void *sink = NULL;
-			int ret =
-			    async_data_write_accept(&source, true, 0, 0, 0, 0);
-			if (ret == EOK)
-				ret = async_data_write_accept(&sink,
-				    true, 0, 0, 0, 0);
-			if (ret == EOK)
-				ret = server_iface->connect(
-				    server_iface->server, source, sink);
-			free(source);
-			free(sink);
-			async_answer_0(callid, ret);
-			break;
-		}
 		case IPC_M_HOUND_STREAM_ENTER: {
+			/* check interface functions */
 			if (!server_iface || !server_iface->is_record_context
 			    || !server_iface->add_stream
@@ -430,4 +555,5 @@
 			}
 
+			/* get parameters */
 			hound_context_id_t id = IPC_GET_ARG1(call);
 			const int flags = IPC_GET_ARG2(call);
@@ -439,4 +565,5 @@
 			};
 			size_t bsize = IPC_GET_ARG4(call);
+
 			void *stream;
 			int ret = server_iface->add_stream(server_iface->server,
@@ -451,4 +578,5 @@
 				if(server_iface->stream_data_read) {
 					async_answer_0(callid, EOK);
+					/* start answering read calls */
 					hound_server_write_data(stream);
 					server_iface->rem_stream(
@@ -460,4 +588,5 @@
 				if (server_iface->stream_data_write) {
 					async_answer_0(callid, EOK);
+					/* accept write calls */
 					hound_server_read_data(stream);
 					server_iface->rem_stream(
@@ -481,4 +610,8 @@
 }
 
+/**
+ * Read data and push it to the stream.
+ * @param stream target stream, will push data there.
+ */
 static void hound_server_read_data(void *stream)
 {
@@ -487,6 +620,8 @@
 	size_t size = 0;
 	int ret_answer = EOK;
+	/* accept data write or drain */
 	while (async_data_write_receive_call(&callid, &call, &size)
 	    || (IPC_GET_IMETHOD(call) == IPC_M_HOUND_STREAM_DRAIN)) {
+		/* check drain first */
 		if (IPC_GET_IMETHOD(call) == IPC_M_HOUND_STREAM_DRAIN) {
 			int ret = ENOTSUP;
@@ -496,8 +631,11 @@
 			continue;
 		}
+
+		/* there was an error last time */
 		if (ret_answer != EOK) {
 			async_answer_0(callid, ret_answer);
 			continue;
 		}
+
 		char *buffer = malloc(size);
 		if (!buffer) {
@@ -507,4 +645,5 @@
 		const int ret = async_data_write_finalize(callid, buffer, size);
 		if (ret == EOK) {
+			/* push data to stream */
 			ret_answer = server_iface->stream_data_write(
 			    stream, buffer, size);
@@ -517,4 +656,8 @@
 }
 
+/**
+ * Accept reads and pull data from the stream.
+ * @param stream target stream, will pull data from there.
+ */
 static void hound_server_write_data(void *stream)
 {
@@ -524,6 +667,8 @@
 	size_t size = 0;
 	int ret_answer = EOK;
+	/* accept data read and drain */
 	while (async_data_read_receive_call(&callid, &call, &size)
 	    || (IPC_GET_IMETHOD(call) == IPC_M_HOUND_STREAM_DRAIN)) {
+		/* drain does not make much sense but it is allowed */
 		if (IPC_GET_IMETHOD(call) == IPC_M_HOUND_STREAM_DRAIN) {
 			int ret = ENOTSUP;
@@ -533,4 +678,5 @@
 			continue;
 		}
+		/* there was an error last time */
 		if (ret_answer != EOK) {
 			async_answer_0(callid, ret_answer);
@@ -559,4 +705,10 @@
  ***/
 
+/**
+ * Register new hound service to the location service.
+ * @param[in] name server name
+ * @param[out] id assigned service id.
+ * @return Error code.
+ */
 int hound_server_register(const char *name, service_id_t *id)
 {
@@ -571,4 +723,8 @@
 }
 
+/**
+ * Unregister server from the location service.
+ * @param id previously assigned service id.
+ */
 void hound_server_unregister(service_id_t id)
 {
@@ -576,4 +732,9 @@
 }
 
+/**
+ * Set callback on device category change event.
+ * @param cb Callback function.
+ * @return Error code.
+ */
 int hound_server_set_device_change_callback(dev_change_callback_t cb)
 {
@@ -581,5 +742,9 @@
 }
 
-
+/**
+ * Walk through all device in the audio-pcm category.
+ * @param callback Function to call on every device.
+ * @return Error code.
+ */
 int hound_server_devices_iterate(device_callback_t callback)
 {
