From f7e9e9feb09f833d03f5fc3f378083b4664bd374 Mon Sep 17 00:00:00 2001 From: Nils Wallménius Date: Wed, 14 Dec 2016 21:52:45 +0100 Subject: drm/amdgpu: Remove checking for atombios MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is a left over from radeon, amdgpu doesn't support any non-atombios parts and amdgpu_device_init would bail if the check for atombios failed anyway. Reviewed-by: Edward O'Callaghan Signed-off-by: Nils Wallménius Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c') diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c index 8ec1967a850b..f573a953b4c3 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c @@ -394,15 +394,15 @@ bool amdgpu_get_bios(struct amdgpu_device *adev) if (!bios_header_start) { goto free_bios; } + + /* Must be an ATOMBIOS */ tmp = bios_header_start + 4; - if (!memcmp(adev->bios + tmp, "ATOM", 4) || - !memcmp(adev->bios + tmp, "MOTA", 4)) { - adev->is_atom_bios = true; - } else { - adev->is_atom_bios = false; + if (memcmp(adev->bios + tmp, "ATOM", 4) && + memcmp(adev->bios + tmp, "MOTA", 4)) { + goto free_bios; } - DRM_DEBUG("%sBIOS detected\n", adev->is_atom_bios ? "ATOM" : "COM"); + DRM_DEBUG("ATOMBIOS detected\n"); return true; free_bios: kfree(adev->bios); -- cgit v1.2.3-70-g09d2