Skip to content

Commit cebba86

Browse files
drm: support fbcon
Signed-off-by: Yusuf Khan <[email protected]>
1 parent 88636e7 commit cebba86

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

kernel-open/conftest.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ test_headers() {
122122
FILES="$FILES drm/drm_ioctl.h"
123123
FILES="$FILES drm/drm_device.h"
124124
FILES="$FILES drm/drm_mode_config.h"
125+
FILES="$FILES drm/drm_fb_helper.h"
125126
FILES="$FILES dt-bindings/interconnect/tegra_icc_id.h"
126127
FILES="$FILES generated/autoconf.h"
127128
FILES="$FILES generated/compile.h"

kernel-open/nvidia-drm/nvidia-drm-drv.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,10 @@
6060
#include <drm/drm_ioctl.h>
6161
#endif
6262

63+
#if defined(NV_DRM_DRM_FB_HELPER_H_PRESENT)
64+
#include <drm/drm_fb_helper.h>
65+
#endif
66+
6367
#include <linux/pci.h>
6468

6569
/*
@@ -84,6 +88,10 @@
8488
#include <drm/drm_atomic_helper.h>
8589
#endif
8690

91+
static int NvDrmEnableFbcon = 0;
92+
module_param(NvDrmEnableFbcon, int, S_IRUGO);
93+
94+
8795
static struct nv_drm_device *dev_list = NULL;
8896

8997
#if defined(NV_DRM_ATOMIC_MODESET_AVAILABLE)
@@ -947,6 +955,12 @@ static void nv_drm_register_drm_device(const nv_gpu_info_t *gpu_info)
947955
nv_dev->next = dev_list;
948956
dev_list = nv_dev;
949957

958+
#if defined(NV_DRM_DRM_FB_HELPER_H_PRESENT)
959+
if (NvDrmEnableFbcon)
960+
drm_fbdev_generic_setup(dev, 0);
961+
962+
#endif
963+
950964
return; /* Success */
951965

952966
failed_drm_register:

0 commit comments

Comments
 (0)