OSDN Git Service

drm/i915: change to_mock() to an inline function
authorMasahiro Yamada <yamada.masahiro@socionext.com>
Fri, 8 Nov 2019 05:13:55 +0000 (14:13 +0900)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 8 Nov 2019 09:12:34 +0000 (09:12 +0000)
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>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20191108051356.29980-1-yamada.masahiro@socionext.com
drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.h

index f0f8bbd..22818bb 100644 (file)
@@ -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;
 }