Re: [PATCH v3] drm/i915/gvt: declare gvt as i915's soft dependency

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

 



Thank you for the help to improve the patch! - Henry

On 07/04/2018 05:21 PM, Chris Wilson wrote:
Quoting hang.yuan@xxxxxxxxxxxxxxx (2018-07-04 04:07:45)
From: Hang Yuan <hang.yuan@xxxxxxxxxxxxxxx>

This helps initramfs builder and other tools to know the full dependencies
of i915 and have gvt module loaded with i915.

v2: add condition and change to pre-dependency (Chris)
v3: move declaration to gvt.c. (Chris)

Signed-off-by: Hang Yuan <hang.yuan@xxxxxxxxxxxxxxx>
---
  drivers/gpu/drm/i915/gvt/gvt.c | 7 +++++++
  1 file changed, 7 insertions(+)

diff --git a/drivers/gpu/drm/i915/gvt/gvt.c b/drivers/gpu/drm/i915/gvt/gvt.c
index 4e65266..00f487e9 100644
--- a/drivers/gpu/drm/i915/gvt/gvt.c
+++ b/drivers/gpu/drm/i915/gvt/gvt.c
@@ -468,3 +468,10 @@ int intel_gvt_init_device(struct drm_i915_private *dev_priv)
         kfree(gvt);
         return ret;
  }
+
+#if IS_ENABLED(CONFIG_DRM_I915_GVT_KVMGT)
+MODULE_SOFTDEP("pre: kvmgt");
+#elif IS_ENABLED(CONFIG_DRM_I915_GVT_XENGT)
+MODULE_SOFTDEP("pre: xengt");
+#endif

This looks like the best one can do under the constraints of the macro.
It matches my limited knowledge of how this works, so
Reviewed-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
-Chris

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux