summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f1473af)
raw | patch | inline | side by side (parent: f1473af)
author | Sundar Raman <a0393242@ti.com> | |
Tue, 23 Apr 2013 20:13:33 +0000 (15:13 -0500) | ||
committer | Sundar Raman <a0393242@ti.com> | |
Fri, 26 Jul 2013 20:58:27 +0000 (15:58 -0500) |
Since the flags function param of omap_tiler_heap_allocate
is used to pass the omap_tiler_info struct, pass the
actual flags param from the client inside omap_tiler_info
struct and re-populate it into the buffer struct.
Change-Id: I06f3b6125c2760f7b4bcc7f174458139d80ec000
Signed-off-by: Sundar Raman <a0393242@ti.com>
is used to pass the omap_tiler_info struct, pass the
actual flags param from the client inside omap_tiler_info
struct and re-populate it into the buffer struct.
Change-Id: I06f3b6125c2760f7b4bcc7f174458139d80ec000
Signed-off-by: Sundar Raman <a0393242@ti.com>
drivers/gpu/ion/omap/omap_tiler_heap.c | patch | blob | history |
index af4988ad2121cd5d4fd40e83e9c92c6248bcfa88..c3ac4f169c3dcb347a33fdd647e6e2661eeaa6b5 100644 (file)
u32 vsize; /* virtual stride of buffer */
u32 vstride; /* virtual size of buffer */
u32 phys_stride; /* Physical stride of the buffer */
+ u32 flags; /* Flags specifying cached or not */
};
static int omap_tiler_heap_allocate(struct ion_heap *heap,
unsigned long size, unsigned long align,
unsigned long flags)
{
+ struct omap_tiler_info *info;
+
/* This means the buffer is already allocated and populated, we're getting here because
* of dummy handle creation, so simply return*/
if (size == 0) {
* This will be used later on inside map_dma function to create
* the sg list for tiler buffer
*/
- buffer->priv_virt = (void *)flags;
+ info = (struct omap_tiler_info *) flags;
+ if (!info)
+ pr_err("%s: flags argument is not setup\n", __func__);
+ buffer->priv_virt = info;
+ /* Re-update correct flags inside buffer */
+ buffer->flags = info->flags;
return 0;
}
info->phys_addrs = (u32 *)(info + 1);
info->tiler_addrs = info->phys_addrs + n_phys_pages;
info->fmt = data->fmt;
+ info->flags = data->flags;
/* Allocate tiler space
FIXME: we only support PAGE_SIZE alignment right now. */