From 6a101cb209e70308f2e1cb63820cd14a34058e37 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Wed, 23 May 2012 14:09:32 +0100 Subject: [PATCH] drm/i915: make some dmabuf things static these functions and the table can all be static/static const. Reported-by: wfg@linux.intel.com Signed-off-by: Dave Airlie --- drivers/gpu/drm/i915/i915_gem_dmabuf.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_gem_dmabuf.c b/drivers/gpu/drm/i915/i915_gem_dmabuf.c index 4f8e142604ab..8e269178d6a5 100644 --- a/drivers/gpu/drm/i915/i915_gem_dmabuf.c +++ b/drivers/gpu/drm/i915/i915_gem_dmabuf.c @@ -27,7 +27,7 @@ #include "i915_drv.h" #include -struct sg_table *i915_gem_map_dma_buf(struct dma_buf_attachment *attachment, +static struct sg_table *i915_gem_map_dma_buf(struct dma_buf_attachment *attachment, enum dma_data_direction dir) { struct drm_i915_gem_object *obj = attachment->dmabuf->priv; @@ -55,7 +55,7 @@ out: return sg; } -void i915_gem_unmap_dma_buf(struct dma_buf_attachment *attachment, +static void i915_gem_unmap_dma_buf(struct dma_buf_attachment *attachment, struct sg_table *sg, enum dma_data_direction dir) { dma_unmap_sg(attachment->dev, sg->sgl, sg->nents, dir); @@ -63,7 +63,7 @@ void i915_gem_unmap_dma_buf(struct dma_buf_attachment *attachment, kfree(sg); } -void i915_gem_dmabuf_release(struct dma_buf *dma_buf) +static void i915_gem_dmabuf_release(struct dma_buf *dma_buf) { struct drm_i915_gem_object *obj = dma_buf->priv; @@ -93,7 +93,7 @@ static void i915_gem_dmabuf_kunmap(struct dma_buf *dma_buf, unsigned long page_n } -struct dma_buf_ops i915_dmabuf_ops = { +static const struct dma_buf_ops i915_dmabuf_ops = { .map_dma_buf = i915_gem_map_dma_buf, .unmap_dma_buf = i915_gem_unmap_dma_buf, .release = i915_gem_dmabuf_release,