diff options
| author | 2017-07-02 11:49:40 +0530 | |
|---|---|---|
| committer | 2017-08-15 15:18:25 +0300 | |
| commit | 815ed41b9bd0ecbe9dbd58e594da94c2a35480d1 (patch) | |
| tree | 8272d207853a3573858eea2c78c0b099c181fa7b /drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c | |
| parent | drm/omap: omap_display_timings: constify videomode structures (diff) | |
| download | wireguard-linux-815ed41b9bd0ecbe9dbd58e594da94c2a35480d1.tar.xz wireguard-linux-815ed41b9bd0ecbe9dbd58e594da94c2a35480d1.zip | |
drm/omap: dma-buf: Constify dma_buf_ops structures.
dma_buf_ops are not supposed to change at runtime. All functions
working with dma_buf_ops provided by <linux/dma-buf.h> work with
const dma_buf_ops. So mark the non-const structs as const.
File size before:
text data bss dec hex filename
1240 112 0 1352 548 drivers/gpu/drm/omapdrm/omap_gem_dmabuf.o
File size After adding 'const':
text data bss dec hex filename
1352 0 0 1352 548 drivers/gpu/drm/omapdrm/omap_gem_dmabuf.o
Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c')
| -rw-r--r-- | drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c b/drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c index 863a881dd7cd..afdbad5c866a 100644 --- a/drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c +++ b/drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c @@ -144,7 +144,7 @@ static int omap_gem_dmabuf_mmap(struct dma_buf *buffer, return omap_gem_mmap_obj(obj, vma); } -static struct dma_buf_ops omap_dmabuf_ops = { +static const struct dma_buf_ops omap_dmabuf_ops = { .map_dma_buf = omap_gem_map_dma_buf, .unmap_dma_buf = omap_gem_unmap_dma_buf, .release = drm_gem_dmabuf_release, |
