[PATCH 40/46] dma-buf: move dma-buf symbols into the DMA_BUF module namespace.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Sagar Chormale <sagar.chormale@xxxxxxxxx>

In order to better track where in the kernel the dma-buf code is used,
put the symbols in the namespace DMA_BUF and modify all users of the
symbols to properly import the namespace to not break the build at the
same time.

Now the output of modinfo shows the use of these symbols, making it
easier to watch for users over time.

$ modinfo drivers/misc/fastrpc.ko | grep import
import_ns:      DMA_BUF

Cc: "Pan, Xinhui" <Xinhui.Pan@xxxxxxx>
Cc: David Airlie <airlied@xxxxxxxx>
Cc: Maarten Lankhorst <maarten.lankhorst@xxxxxxxxxxxxxxx>
Cc: Maxime Ripard <mripard@xxxxxxxxxx>
Cc: Thomas Zimmermann <tzimmermann@xxxxxxx>
Cc: Mauro Carvalho Chehab <mchehab@xxxxxxxxxx>
Cc: dri-devel@xxxxxxxxxxxxxxxxxxxxx
Acked-by: Daniel Vetter <daniel.vetter@xxxxxxxx>
Acked-by: Christian König <christian.koenig@xxxxxxx>
Acked-by: Arnd Bergmann <arnd@xxxxxxxx>
Acked-by: Sumit Semwal <sumit.semwal@xxxxxxxxxx>
Acked-by: Alex Deucher <alexander.deucher@xxxxxxx>
Link: https://lore.kernel.org/r/20211010124628.17691-1-gregkh@xxxxxxxxxxxxxxxxxxx
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
-------------------------------------------------------------------------------
Backports

'commit 16b0314aa746 ("dma-buf: move dma-buf symbols into the DMA_BUF
module namespace.")'

Signed-off-by: Sagar Chormale <sagar.chormale@xxxxxxxxx>
---
 drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c b/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
index d7e4ef3fa589d..6d14315dfce40 100644
--- a/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
+++ b/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
@@ -9,6 +9,9 @@
 #include <linux/list.h>
 #include <linux/pci-p2pdma.h>
 #include <linux/scatterlist.h>
+#ifdef BPM_MODULE_IMPORT_NS_SUPPORT
+#include <linux/module.h>
+#endif
 #include <drm/intel_iaf_platform.h>
 
 #include "gem/i915_gem_dmabuf.h"
@@ -23,6 +26,10 @@
 #include "i915_trace.h"
 #include "intel_iaf.h"
 
+#ifdef BPM_MODULE_IMPORT_NS_SUPPORT
+MODULE_IMPORT_NS(DMA_BUF);
+#endif
+
 I915_SELFTEST_DECLARE(static bool force_different_devices;)
 
 static const struct drm_i915_gem_object_ops i915_gem_object_dmabuf_ops;



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux