Index: uspace/drv/audio/sb16/dma.h
===================================================================
--- uspace/drv/audio/sb16/dma.h	(revision 751d17a25bb4d9c1c37dfe4dc9a1442bbbf90e4d)
+++ uspace/drv/audio/sb16/dma.h	(revision a0d1d9d4e874cc0afc7c3062290913bbff199bc9)
@@ -65,22 +65,27 @@
  * @return Address of the aligned and big enough memory place, NULL on failure.
  */
-static inline void * malloc24(size_t size)
+static inline void *dma_create_buffer24(size_t size)
 {
-	/* This works only reliably when the host has less than 16MB of memory
-	 * as physical address needs to fit into 24 bits */
-
-	/* If we need more than one page there is no guarantee that the
-	 * memory will be continuous */
-	if (size > PAGE_SIZE)
+	void *free_address = as_get_mappable_page(size);
+	if (free_address == 0)
 		return NULL;
-	return memalign(DMA_ALIGNENT, size);
+	void *address =
+	    as_area_create(free_address, size, AS_AREA_READ | AS_AREA_WRITE);
+	if (address != free_address)
+		return NULL;
+	bzero(address, size);
+	return address;
 }
 /*----------------------------------------------------------------------------*/
 /** DMA mallocator simulator
  *
- * @param[in] addr Address of the place allocated by malloc24
+ * @param[in] addr Address of the place allocated by dma_create_buffer24
  */
-static inline void free24(void *addr)
-	{ free(addr); }
+static inline void dma_destroy_buffer(void *page)
+{
+        if (page)
+		as_area_destroy(page);
+}
+
 
 #endif
Index: uspace/drv/audio/sb16/dsp.c
===================================================================
--- uspace/drv/audio/sb16/dsp.c	(revision 751d17a25bb4d9c1c37dfe4dc9a1442bbbf90e4d)
+++ uspace/drv/audio/sb16/dsp.c	(revision a0d1d9d4e874cc0afc7c3062290913bbff199bc9)
@@ -43,5 +43,5 @@
 #include "dsp.h"
 
-#define BUFFER_SIZE (PAGE_SIZE / 4)
+#define BUFFER_SIZE (PAGE_SIZE)
 #define PLAY_BLOCK_SIZE (BUFFER_SIZE / 2)
 
@@ -108,5 +108,5 @@
 {
 	assert(dsp);
-	uint8_t *buffer = malloc24(BUFFER_SIZE);
+	uint8_t *buffer = dma_create_buffer24(BUFFER_SIZE);
 	if (buffer == NULL) {
 		ddf_log_error("Failed to allocate buffer.\n");
@@ -118,5 +118,5 @@
 	/* Set 16 bit channel */
 	const int ret = dma_setup_channel(SB_DMA_CHAN_16, pa, BUFFER_SIZE,
-	    DMA_MODE_READ | DMA_MODE_AUTO | DMA_MODE_SINGLE);
+	    DMA_MODE_READ | DMA_MODE_AUTO | DMA_MODE_ON_DEMAND);
 	if (ret == EOK) {
 		dsp->buffer.data = buffer;
@@ -127,5 +127,5 @@
 		ddf_log_error("Failed to setup DMA16 channel %s.\n",
 		    str_error(ret));
-		free24(buffer);
+		dma_destroy_buffer(buffer);
 	}
 	return ret;
@@ -134,5 +134,5 @@
 static inline void sb_clear_buffer(sb_dsp_t *dsp)
 {
-	free24(dsp->buffer.data);
+	dma_destroy_buffer(dsp->buffer.data);
 	dsp->buffer.data = NULL;
 	dsp->buffer.position = NULL;
