Index: uspace/lib/pcm/include/pcm/format.h
===================================================================
--- uspace/lib/pcm/include/pcm/format.h	(revision 7db073ffc60e7a91fb52ca2d8df810429301a493)
+++ uspace/lib/pcm/include/pcm/format.h	(revision 192565bb8d97d3d2b9c03b06e4ed08402ecbbccf)
@@ -41,4 +41,5 @@
 #include <pcm/sample_format.h>
 
+/** Linear PCM audio parameters */
 typedef struct {
 	unsigned channels;
@@ -50,4 +51,9 @@
 extern const pcm_format_t AUDIO_FORMAT_ANY;
 
+/**
+ * Frame size helper function.
+ * @param a pointer to a PCM format structure.
+ * @return Size in bytes.
+ */
 static inline size_t pcm_format_frame_size(const pcm_format_t *a)
 {
@@ -55,4 +61,10 @@
 }
 
+/**
+ * Convert byte size to frame count.
+ * @param size Byte-size.
+ * @param a pointer to a PCM format structure.
+ * @return Frame count.
+ */
 static inline size_t pcm_format_size_to_frames(size_t size,
     const pcm_format_t *a)
@@ -62,5 +74,11 @@
 }
 
-static inline suseconds_t pcm_format_size_to_usec(size_t size,
+/**
+ * Convert byte size to audio playback time.
+ * @param size Byte-size.
+ * @param a pointer to a PCM format structure.
+ * @return Number of microseconds.
+ */
+static inline useconds_t pcm_format_size_to_usec(size_t size,
     const pcm_format_t *a)
 {
@@ -70,4 +88,10 @@
 
 bool pcm_format_same(const pcm_format_t *a, const pcm_format_t* b);
+
+/**
+ * Helper function, compares with ANY metaformat.
+ * @param f pointer to format structure.
+ * @return True if @p f points to ANY format, false otherwise.
+ */
 static inline bool pcm_format_is_any(const pcm_format_t *f)
 {
Index: uspace/lib/pcm/include/pcm/sample_format.h
===================================================================
--- uspace/lib/pcm/include/pcm/sample_format.h	(revision 7db073ffc60e7a91fb52ca2d8df810429301a493)
+++ uspace/lib/pcm/include/pcm/sample_format.h	(revision 192565bb8d97d3d2b9c03b06e4ed08402ecbbccf)
@@ -40,4 +40,5 @@
 #include <time.h>
 
+/** Known and supported PCM sample formats */
 typedef enum {
 	PCM_SAMPLE_UINT8,
@@ -63,4 +64,9 @@
 } pcm_sample_format_t;
 
+/**
+ * Query if the format uses signed values.
+ * @param format PCM sample format.
+ * @return True if the format uses signed values, false otherwise.
+ */
 static inline bool pcm_sample_format_is_signed(pcm_sample_format_t format)
 {
@@ -91,4 +97,9 @@
 }
 
+/**
+ * Query byte-size of samples.
+ * @param format PCM sample format.
+ * @return Size in bytes of a single sample.
+ */
 static inline size_t pcm_sample_format_size(pcm_sample_format_t format)
 {
@@ -122,4 +133,10 @@
 }
 
+/**
+ * Query sie of the entire frame.
+ * @param channels Number of samples in every frame.
+ * @param format PCM sample format.
+ * @return Size in bytes.
+ */
 static inline size_t pcm_sample_format_frame_size(unsigned channels,
     pcm_sample_format_t format)
@@ -128,4 +145,11 @@
 }
 
+/**
+ * Count number of frames that fit into a buffer (even incomplete frames).
+ * @param size Size of the buffer.
+ * @param channels Number of samples in every frame.
+ * @param format PCM sample format.
+ * @return Number of frames (even incomplete).
+ */
 static inline size_t pcm_sample_format_size_to_frames(size_t size,
     unsigned channels, pcm_sample_format_t format)
@@ -135,12 +159,25 @@
 }
 
+/**
+ * Convert byte size to time.
+ * @param size Size of the buffer.
+ * @param sample_rate Samples per second.
+ * @param channels Number of samples in every frame.
+ * @param format PCM sample format.
+ * @return Number of useconds of audio data.
+ */
 static inline useconds_t pcm_sample_format_size_to_usec(size_t size,
     unsigned sample_rate, unsigned channels, pcm_sample_format_t format)
 {
-	const long long frames =
+	const unsigned long long frames =
 	    pcm_sample_format_size_to_frames(size, channels, format);
 	return (frames * 1000000ULL) / sample_rate;
 }
 
+/**
+ * Get readable name of a sample format.
+ * @param format PCM sample format.
+ * @return Valid string representation.
+ */
 static inline const char * pcm_sample_format_str(pcm_sample_format_t format)
 {
