From: jsg Date: Mon, 8 Jul 2024 02:20:29 +0000 (+0000) Subject: drm/amdgpu/atomfirmware: fix parsing of vram_info X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=bbf6c1fca15cc479bb8a109351e4e04ee1fd60fa;p=openbsd drm/amdgpu/atomfirmware: fix parsing of vram_info From Alex Deucher 01f58871af9c2cffcb57b77336994e6bfe37c1f0 in linux-6.6.y/6.6.37 f6f49dda49db72e7a0b4ca32c77391d5ff5ce232 in mainline linux --- diff --git a/sys/dev/pci/drm/amd/amdgpu/amdgpu_atomfirmware.c b/sys/dev/pci/drm/amd/amdgpu/amdgpu_atomfirmware.c index 23651a9738c..6521d06c7e4 100644 --- a/sys/dev/pci/drm/amd/amdgpu/amdgpu_atomfirmware.c +++ b/sys/dev/pci/drm/amd/amdgpu/amdgpu_atomfirmware.c @@ -399,7 +399,7 @@ amdgpu_atomfirmware_get_vram_info(struct amdgpu_device *adev, mem_channel_number = vram_info->v30.channel_num; mem_channel_width = vram_info->v30.channel_width; if (vram_width) - *vram_width = mem_channel_number * (1 << mem_channel_width); + *vram_width = mem_channel_number * 16; break; default: return -EINVAL;