Enable the following options in the kernel configuration and
recompile the kernel if necessary:
Note
The corresponding Mesa Gallium3D driver name is provided as the
comment for the configuration entries. If you don't know the name
of the Mesa Gallium3D driver for your GPU, see Mesa Gallium3D Drivers
below.
For the GPUs supported by the Iris Gallium3D driver, with
CONFIG_DRM_I915 enabled and
CONFIG_DRM_XE_FORCE_PROBE set to the
string *, the i915 driver will be
used if it supports the GPU, and the Xe driver will be used if it
supports the GPU but the i915 driver does not. If you are sure
your GPU is supported by the i915 driver, you can disable the Xe
driver to save some build time. If your GPU is supported by both
drivers and you want to use the Xe driver, you can disable the
i915 driver, or make the i915 driver deny your GPU via the
CONFIG_DRM_I915_FORCE_PROBE option,
for example setting it to !7d55
would make i915 deny the Meteor Lake integrated GPU (of which the
PCI ID is 8086:7d55), leaving it for
the Xe driver.
CONFIG_DRM_RADEON, CONFIG_DRM_AMDGPU, CONFIG_DRM_NOUVEAU, CONFIG_DRM_I915, and CONFIG_DRM_XE may require firmware. See About Firmware for details.
Selecting CONFIG_DRM_RADEON,
CONFIG_DRM_AMDGPU, or CONFIG_DRM_NOUVEAU as “y” is not recommended. If it is,
any required firmware must be built as a part of the kernel image
or the initramfs for the driver to function correctly.
The sub-entries under CONFIG_DRM_AMDGPU are used to ensure the AMDGPU
kernel driver supports all GPUs using the radeonsi driver. They are not needed if you
won't need CONFIG_DRM_AMDGPU itself.
They may be unneeded for some GPU models.
For llvmpipe or softpipe, CONFIG_DRM_VGEM is required or X clients may fail
to start with a cryptic message Error: couldn't get an RGB, Double-buffered
visual. Strictly speaking, it can be compiled as a module.
But the module will not be loaded automatically, so it's more
convenient to build it as a part of the kernel image.