On Mon, Dec 25, 2017 at 3:49 PM, José Pekkarinen <koalinux at gmail.com> wrote: > Signed-off-by: José Pekkarinen <koalinux at gmail.com> NACK. This will break vega10. The virtualization table only exists on sr-iov capable cards so the checks are safe on all asics. Alex > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 15 +++++++++------ > 1 file changed, 9 insertions(+), 6 deletions(-) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c > index e630d918fefc..7958597028e3 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c > @@ -1933,12 +1933,15 @@ static int amdgpu_resume(struct amdgpu_device *adev) > > static void amdgpu_device_detect_sriov_bios(struct amdgpu_device *adev) > { > - if (adev->is_atom_fw) { > - if (amdgpu_atomfirmware_gpu_supports_virtualization(adev)) > - adev->virt.caps |= AMDGPU_SRIOV_CAPS_SRIOV_VBIOS; > - } else { > - if (amdgpu_atombios_has_gpu_virtualization_table(adev)) > - adev->virt.caps |= AMDGPU_SRIOV_CAPS_SRIOV_VBIOS; > + if (adev->asic_type == CHIP_TONGA || > + adev->asic_type == CHIP_FIJI) { > + if (adev->is_atom_fw) { > + if (amdgpu_atomfirmware_gpu_supports_virtualization(adev)) > + adev->virt.caps |= AMDGPU_SRIOV_CAPS_SRIOV_VBIOS; > + } else { > + if (amdgpu_atombios_has_gpu_virtualization_table(adev)) > + adev->virt.caps |= AMDGPU_SRIOV_CAPS_SRIOV_VBIOS; > + } > } > } > > -- > 2.13.6 > > _______________________________________________ > amd-gfx mailing list > amd-gfx at lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/amd-gfx