我最近在我的计算机上安装了 AMD RX 560 GPU 卡。它似乎工作正常 - 机器成功启动,我正在上面输入此消息。但是,由于某种原因,驱动程序amdgpu
没有认领该卡。(是的,显示器插入了独立卡的 HDMI 端口,而不是内置 VGA 端口。)
lsmod
启动后立即显示amdgpu
模块已加载。但是,lshw -c video
报告卡为 UNCLAIMED(同时正确报告其他详细信息,例如芯片组)。此外,glxinfo
报告渲染器为llvmpipe
,如果机器使用硬件视频加速,我认为这不是我应该期望的。
该机器的板载视频是 Nvidia,所以我不可能将我的新 AMD 卡与板载卡混淆。
我的问题很简单,为什么amdgpu
驱动程序会这样运行?我怎样才能让它充当我的显卡驱动程序?还是我糊涂了,事情实际上是按预期运行的?(在这种情况下,我如何为 OpenGL 启用硬件加速?)
输出lsmod
:
Module Size Used by
snd_hda_codec_realtek 90112 1
snd_hda_codec_generic 77824 1 snd_hda_codec_realtek
snd_hda_codec_hdmi 53248 2
snd_hda_intel 40960 5
snd_hda_codec 135168 4 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel
kvm_amd 65536 0
snd_hda_core 77824 5 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
kvm 548864 1 kvm_amd
snd_hwdep 16384 1 snd_hda_codec
snd_pcm 106496 4 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_core
irqbypass 16384 1 kvm
snd_seq_midi 16384 0
snd_seq_midi_event 16384 1 snd_seq_midi
input_leds 16384 0
snd_rawmidi 32768 1 snd_seq_midi
snd_seq 69632 2 snd_seq_midi_event,snd_seq_midi
snd_seq_device 16384 3 snd_seq,snd_rawmidi,snd_seq_midi
snd_timer 32768 2 snd_pcm,snd_seq
snd 81920 21 snd_hda_codec_realtek,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_seq,snd_rawmidi,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel,snd_seq_device
soundcore 16384 1 snd
edac_mce_amd 24576 0
serio_raw 16384 0
k10temp 16384 0
edac_core 53248 0
shpchp 36864 0
asus_atk0110 20480 0
8250_fintek 16384 0
i2c_nforce2 16384 0
binfmt_misc 20480 1
mac_hid 16384 0
amdkfd 131072 1
amd_iommu_v2 20480 1 amdkfd
amdgpu 991232 0
ttm 98304 1 amdgpu
drm_kms_helper 155648 1 amdgpu
drm 364544 3 ttm,drm_kms_helper,amdgpu
i2c_algo_bit 16384 1 amdgpu
fb_sys_fops 16384 1 drm_kms_helper
syscopyarea 16384 1 drm_kms_helper
sysfillrect 16384 1 drm_kms_helper
sysimgblt 16384 1 drm_kms_helper
parport_pc 32768 0
ppdev 20480 0
lp 20480 0
parport 49152 3 lp,ppdev,parport_pc
autofs4 40960 2
hid_logitech_hidpp 20480 0
hid_logitech_dj 20480 0
hid_generic 16384 0
usbhid 49152 1
hid 122880 5 hid_generic,usbhid,hid_logitech_dj,hid_logitech_hidpp
pata_acpi 16384 0
mxm_wmi 16384 0
firewire_ohci 40960 0
firewire_core 65536 1 firewire_ohci
psmouse 131072 0
ahci 36864 2
crc_itu_t 16384 1 firewire_core
forcedeth 69632 0
libahci 32768 1 ahci
pata_amd 20480 0
video 40960 0
wmi 20480 1 mxm_wmi
fjes 28672 0
输出lshw -c video
(内置的 Nvidia 芯片没有出现,我猜想安装独立卡和/或将显示器连接到独立卡会在硬件级别禁用它,或者其他什么):
*-display UNCLAIMED
description: VGA compatible controller
product: Baffin [Radeon RX 550 640SP / RX 560]
vendor: Advanced Micro Devices, Inc. [AMD/ATI]
physical id: 0
bus info: pci@0000:02:00.0
version: cf
width: 64 bits
clock: 33MHz
capabilities: pm pciexpress msi vga_controller bus_master cap_list
configuration: latency=0
resources: memory:d0000000-dfffffff memory:efe00000-efffffff ioport:dc00(size=256) memory:fdc80000-fdcbffff memory:fdcc0000-fdcdffff
输出glxinfo
(为简洁起见,剪切模式等):
name of display: :0
display: :0 screen: 0
direct rendering: Yes
server glx vendor string: SGI
server glx version string: 1.4
server glx extensions:
GLX_ARB_create_context, GLX_ARB_create_context_profile,
GLX_ARB_fbconfig_float, GLX_ARB_framebuffer_sRGB, GLX_ARB_multisample,
GLX_EXT_create_context_es2_profile, GLX_EXT_create_context_es_profile,
GLX_EXT_fbconfig_packed_float, GLX_EXT_framebuffer_sRGB,
GLX_EXT_import_context, GLX_EXT_texture_from_pixmap, GLX_EXT_visual_info,
GLX_EXT_visual_rating, GLX_MESA_copy_sub_buffer, GLX_OML_swap_method,
GLX_SGIS_multisample, GLX_SGIX_fbconfig, GLX_SGIX_pbuffer,
GLX_SGIX_visual_select_group, GLX_SGI_make_current_read
client glx vendor string: Mesa Project and SGI
client glx version string: 1.4
client glx extensions:
GLX_ARB_create_context, GLX_ARB_create_context_profile,
GLX_ARB_create_context_robustness, GLX_ARB_fbconfig_float,
GLX_ARB_framebuffer_sRGB, GLX_ARB_get_proc_address, GLX_ARB_multisample,
GLX_EXT_buffer_age, GLX_EXT_create_context_es2_profile,
GLX_EXT_create_context_es_profile, GLX_EXT_fbconfig_packed_float,
GLX_EXT_framebuffer_sRGB, GLX_EXT_import_context,
GLX_EXT_texture_from_pixmap, GLX_EXT_visual_info, GLX_EXT_visual_rating,
GLX_INTEL_swap_event, GLX_MESA_copy_sub_buffer,
GLX_MESA_multithread_makecurrent, GLX_MESA_query_renderer,
GLX_MESA_swap_control, GLX_OML_swap_method, GLX_OML_sync_control,
GLX_SGIS_multisample, GLX_SGIX_fbconfig, GLX_SGIX_pbuffer,
GLX_SGIX_visual_select_group, GLX_SGI_make_current_read,
GLX_SGI_swap_control, GLX_SGI_video_sync
GLX version: 1.4
GLX extensions:
GLX_ARB_create_context, GLX_ARB_create_context_profile,
GLX_ARB_fbconfig_float, GLX_ARB_framebuffer_sRGB,
GLX_ARB_get_proc_address, GLX_ARB_multisample,
GLX_EXT_create_context_es2_profile, GLX_EXT_create_context_es_profile,
GLX_EXT_fbconfig_packed_float, GLX_EXT_framebuffer_sRGB,
GLX_EXT_import_context, GLX_EXT_texture_from_pixmap, GLX_EXT_visual_info,
GLX_EXT_visual_rating, GLX_MESA_copy_sub_buffer,
GLX_MESA_multithread_makecurrent, GLX_MESA_query_renderer,
GLX_OML_swap_method, GLX_SGIS_multisample, GLX_SGIX_fbconfig,
GLX_SGIX_pbuffer, GLX_SGIX_visual_select_group, GLX_SGI_make_current_read
Extended renderer info (GLX_MESA_query_renderer):
Vendor: VMware, Inc. (0xffffffff)
Device: llvmpipe (LLVM 5.0, 128 bits) (0xffffffff)
Version: 17.2.8
Accelerated: no
Video memory: 7982MB
Unified memory: no
Preferred profile: core (0x1)
Max core profile version: 3.3
Max compat profile version: 3.0
答案1
(已更新。)问题解决了。我将 Ubuntu 安装升级到 17.10,重新启动,现在有了加速图形管道。因此,这并没有回答如何让 amdgpu 在 16.04 上工作的具体问题,但从有关该主题的其他问题数量来看,答案似乎是“别费心了。只需升级。”
更新:在 17.10 重新启动几次后,视频配置没有任何变化,我又回到了原点。4.13 内核现在启动时出现黑屏,机器完全没有响应 -Ctrl-Alt-Fn
没有带我进入文本登录会话。如果我启动较旧的 4.4 内核,机器会成功启动,但再次没有硬件加速 :-(
更新 2:从源代码构建的 4.16 内核似乎能够在启用 AMDGPU 支持的情况下持续启动并为 RX 560 工作。