Skip to content

Commit fe7acaa

Browse files
committed
drm/gpuvm: allow building as module
Currently, the DRM GPUVM does not have any core dependencies preventing a module build. Also, new features from subsequent patches require helpers (namely drm_exec) which can be built as module. Reviewed-by: Christian König <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent f72c2db commit fe7acaa

File tree

4 files changed

+12
-1
lines changed

4 files changed

+12
-1
lines changed

drivers/gpu/drm/Kconfig

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,13 @@ config DRM_EXEC
216216
help
217217
Execution context for command submissions
218218

219+
config DRM_GPUVM
220+
tristate
221+
depends on DRM
222+
help
223+
GPU-VM representation providing helpers to manage a GPUs virtual
224+
address space
225+
219226
config DRM_BUDDY
220227
tristate
221228
depends on DRM

drivers/gpu/drm/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ drm-y := \
4545
drm_vblank.o \
4646
drm_vblank_work.o \
4747
drm_vma_manager.o \
48-
drm_gpuvm.o \
4948
drm_writeback.o
5049
drm-$(CONFIG_DRM_LEGACY) += \
5150
drm_agpsupport.o \
@@ -81,6 +80,7 @@ obj-$(CONFIG_DRM_PANEL_ORIENTATION_QUIRKS) += drm_panel_orientation_quirks.o
8180
#
8281
#
8382
obj-$(CONFIG_DRM_EXEC) += drm_exec.o
83+
obj-$(CONFIG_DRM_GPUVM) += drm_gpuvm.o
8484

8585
obj-$(CONFIG_DRM_BUDDY) += drm_buddy.o
8686

drivers/gpu/drm/drm_gpuvm.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1723,3 +1723,6 @@ drm_gpuva_ops_free(struct drm_gpuvm *gpuvm,
17231723
kfree(ops);
17241724
}
17251725
EXPORT_SYMBOL_GPL(drm_gpuva_ops_free);
1726+
1727+
MODULE_DESCRIPTION("DRM GPUVM");
1728+
MODULE_LICENSE("GPL");

drivers/gpu/drm/nouveau/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ config DRM_NOUVEAU
1111
select DRM_TTM
1212
select DRM_TTM_HELPER
1313
select DRM_EXEC
14+
select DRM_GPUVM
1415
select DRM_SCHED
1516
select I2C
1617
select I2C_ALGOBIT

0 commit comments

Comments
 (0)