diff --git a/test/cmocka/src/lib/alloc/alloc.c b/test/cmocka/src/lib/alloc/alloc.c index 41c986219..4d6fed0d5 100644 --- a/test/cmocka/src/lib/alloc/alloc.c +++ b/test/cmocka/src/lib/alloc/alloc.c @@ -89,38 +89,38 @@ static struct test_case test_cases[] = { * the RZONE_BUFFER and RZONE_RUNTIME tests will not work. */ - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_BULK, - // "rmalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_BULK, - // "rmalloc"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_BULK, - // "rmalloc"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_BULK, + "rmalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_BULK, + "rmalloc"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_BULK, + "rmalloc"), - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_BULK, - // "rmalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_BULK, - // "rmalloc"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_BULK, - // "rmalloc"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_BULK, + "rmalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_BULK, + "rmalloc"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_BULK, + "rmalloc"), - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_BULK, - // "rmalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_BULK, - // "rmalloc"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_BULK, - // "rmalloc"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_BULK, + "rmalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_BULK, + "rmalloc"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_BULK, + "rmalloc"), - //TEST_CASE(16, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 128, TEST_BULK, - // "rmalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 256, TEST_BULK, - // "rmalloc"), + TEST_CASE(16, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 128, TEST_BULK, + "rmalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 256, TEST_BULK, + "rmalloc"), - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_BULK, "rmalloc_dma"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_BULK, "rmalloc_dma"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_BULK, "rmalloc_dma"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_BULK, "rmalloc_dma"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_BULK, "rmalloc_dma"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_BULK, "rmalloc_dma"), /* * rzalloc tests @@ -141,78 +141,80 @@ static struct test_case test_cases[] = { TEST_CASE(16, RZONE_SYS, SOF_MEM_CAPS_RAM, 128, TEST_ZERO, "rzalloc"), TEST_CASE(4, RZONE_SYS, SOF_MEM_CAPS_RAM, 256, TEST_ZERO, "rzalloc"), - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_ZERO, - // "rzalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_ZERO, - // "rzalloc"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_ZERO, - // "rzalloc"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_ZERO, + "rzalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_ZERO, + "rzalloc"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 2, TEST_ZERO, + "rzalloc"), - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_ZERO, - // "rzalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_ZERO, - // "rzalloc"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_ZERO, - // "rzalloc"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_ZERO, + "rzalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_ZERO, + "rzalloc"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 4, TEST_ZERO, + "rzalloc"), - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_ZERO, - // "rzalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_ZERO, - // "rzalloc"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_ZERO, - // "rzalloc"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_ZERO, + "rzalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_ZERO, + "rzalloc"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 8, TEST_ZERO, + "rzalloc"), - //TEST_CASE(16, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 128, TEST_ZERO, - // "rzalloc"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 256, TEST_ZERO, - // "rzalloc"), + TEST_CASE(16, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 128, TEST_ZERO, + "rzalloc"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM, 256, TEST_ZERO, + "rzalloc"), - //TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_ZERO, "rzalloc_dma"), - //TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_ZERO, "rzalloc_dma"), - //TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_ZERO, "rzalloc_dma"), + TEST_CASE(1, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_ZERO, "rzalloc_dma"), + TEST_CASE(4, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_ZERO, "rzalloc_dma"), + TEST_CASE(256, RZONE_RUNTIME, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_ZERO, "rzalloc_dma"), /* * rballoc tests */ - //TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 1024, - // TEST_IMMEDIATE_FREE, "rballoc"), + TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 1024, + TEST_IMMEDIATE_FREE, "rballoc"), - //TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 2, TEST_BULK, - // "rballoc"), - //TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 2, TEST_BULK, - // "rballoc"), - //TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 2, TEST_BULK, - // "rballoc"), + TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 2, TEST_BULK, + "rballoc"), + TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 2, TEST_BULK, + "rballoc"), + TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 2, TEST_BULK, + "rballoc"), - //TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 4, TEST_BULK, - // "rballoc"), - //TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 4, TEST_BULK, - // "rballoc"), - //TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 4, TEST_BULK, - // "rballoc"), + TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 4, TEST_BULK, + "rballoc"), + TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 4, TEST_BULK, + "rballoc"), + TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 4, TEST_BULK, + "rballoc"), - //TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 8, TEST_BULK, - // "rballoc"), - //TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 8, TEST_BULK, - // "rballoc"), - //TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 8, TEST_BULK, - // "rballoc"), + TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 8, TEST_BULK, + "rballoc"), + TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 8, TEST_BULK, + "rballoc"), + TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 8, TEST_BULK, + "rballoc"), //TEST_CASE(16, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 64, TEST_BULK, // "rballoc"), //TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM, 64, TEST_BULK, // "rballoc"), - //TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_BULK, "rballoc_dma"), - //TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_BULK, "rballoc_dma"), - //TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, - // TEST_BULK, "rballoc_dma") + TEST_CASE(1, RZONE_BUFFER, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_BULK, "rballoc_dma"), + TEST_CASE(4, RZONE_BUFFER, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_BULK, "rballoc_dma"), + TEST_CASE(256, RZONE_BUFFER, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 2, + TEST_BULK, "rballoc_dma"), + TEST_CASE(2048, RZONE_BUFFER, SOF_MEM_CAPS_RAM | SOF_MEM_CAPS_DMA, 100, + TEST_IMMEDIATE_FREE, "rballoc_dma") }; static int setup(void **state)