From 710384ab66b35c0f6b2c8f2dbd6c8325a090a2de Mon Sep 17 00:00:00 2001 From: Tomi Valkeinen Date: Thu, 30 Aug 2012 16:54:01 +0300 Subject: [PATCH] --- yaml --- r: 333535 b: refs/heads/master c: 5ae1f3723f089a67ef3bbcba9b8ad1150c091632 h: refs/heads/master i: 333533: 520da1079576a40db2774fa86562da83fbf13c3c 333531: 7834cf61be65c8ade3d83497bc7863256bc2dfce 333527: e784fa7bc0edb64faaf1adba8209214a1224c79a 333519: e91bd701c8d2f5695956f64a7456eace1b5d6065 333503: c7e0918abd3d3f1523e9c0e36a6fec0f2f1e8d6c v: v3 --- [refs] | 2 +- trunk/drivers/video/omap2/vram.c | 56 -------------------------------- 2 files changed, 1 insertion(+), 57 deletions(-) diff --git a/[refs] b/[refs] index 545518c20631..2e73d02bb82b 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ca444158723f3b92531dc552c154fed108f8bc15 +refs/heads/master: 5ae1f3723f089a67ef3bbcba9b8ad1150c091632 diff --git a/trunk/drivers/video/omap2/vram.c b/trunk/drivers/video/omap2/vram.c index 87e421e25afe..f2b15c4a75bc 100644 --- a/trunk/drivers/video/omap2/vram.c +++ b/trunk/drivers/video/omap2/vram.c @@ -34,7 +34,6 @@ #include #include -#include #ifdef DEBUG #define DBG(format, ...) pr_debug("VRAM: " format, ## __VA_ARGS__) @@ -250,59 +249,6 @@ int omap_vram_reserve(unsigned long paddr, size_t size) } EXPORT_SYMBOL(omap_vram_reserve); -static void _omap_vram_dma_cb(int lch, u16 ch_status, void *data) -{ - struct completion *compl = data; - complete(compl); -} - -static int _omap_vram_clear(u32 paddr, unsigned pages) -{ - struct completion compl; - unsigned elem_count; - unsigned frame_count; - int r; - int lch; - - init_completion(&compl); - - r = omap_request_dma(OMAP_DMA_NO_DEVICE, "VRAM DMA", - _omap_vram_dma_cb, - &compl, &lch); - if (r) { - pr_err("VRAM: request_dma failed for memory clear\n"); - return -EBUSY; - } - - elem_count = pages * PAGE_SIZE / 4; - frame_count = 1; - - omap_set_dma_transfer_params(lch, OMAP_DMA_DATA_TYPE_S32, - elem_count, frame_count, - OMAP_DMA_SYNC_ELEMENT, - 0, 0); - - omap_set_dma_dest_params(lch, 0, OMAP_DMA_AMODE_POST_INC, - paddr, 0, 0); - - omap_set_dma_color_mode(lch, OMAP_DMA_CONSTANT_FILL, 0x000000); - - omap_start_dma(lch); - - if (wait_for_completion_timeout(&compl, msecs_to_jiffies(1000)) == 0) { - omap_stop_dma(lch); - pr_err("VRAM: dma timeout while clearing memory\n"); - r = -EIO; - goto err; - } - - r = 0; -err: - omap_free_dma(lch); - - return r; -} - static int _omap_vram_alloc(unsigned pages, unsigned long *paddr) { struct vram_region *rm; @@ -337,8 +283,6 @@ static int _omap_vram_alloc(unsigned pages, unsigned long *paddr) *paddr = start; - _omap_vram_clear(start, pages); - return 0; }