[1/2] drm/i915: change to_mock() to an inline function
diff mbox series

Message ID 20191108051356.29980-1-yamada.masahiro@socionext.com
State New
Headers show
Series
  • [1/2] drm/i915: change to_mock() to an inline function
Related show

Commit Message

Masahiro Yamada Nov. 8, 2019, 5:13 a.m. UTC
Since this function is defined in a header file, it should be
'static inline' instead of 'static'.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---

 drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Chris Wilson Nov. 8, 2019, 9:12 a.m. UTC | #1
Quoting Masahiro Yamada (2019-11-08 05:13:55)
> Since this function is defined in a header file, it should be
> 'static inline' instead of 'static'.
> 
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris

Patch
diff mbox series

diff --git a/drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.h b/drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.h
index f0f8bbd82dfc..22818bbb139d 100644
--- a/drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.h
+++ b/drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.h
@@ -14,7 +14,7 @@  struct mock_dmabuf {
 	struct page *pages[];
 };
 
-static struct mock_dmabuf *to_mock(struct dma_buf *buf)
+static inline struct mock_dmabuf *to_mock(struct dma_buf *buf)
 {
 	return buf->priv;
 }