]> Git Repo - J-linux.git/blobdiff - drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c
Merge tag 'riscv-for-linus-4.20-mw2' of git://git.kernel.org/pub/scm/linux/kernel...
[J-linux.git] / drivers / gpu / drm / amd / amdgpu / amdgpu_ucode.c
index 57ed38422089a8a5325f6d21a39d4431cfbc4d62..7b33867036e7b43ab89b0548baab335e9aa1edaf 100644 (file)
@@ -297,8 +297,6 @@ amdgpu_ucode_get_load_type(struct amdgpu_device *adev, int load_type)
        case CHIP_POLARIS11:
        case CHIP_POLARIS12:
        case CHIP_VEGAM:
-               if (load_type != AMDGPU_FW_LOAD_SMU)
-                       pr_warning("%d is not supported on VI\n", load_type);
                return AMDGPU_FW_LOAD_SMU;
        case CHIP_VEGA10:
        case CHIP_RAVEN:
@@ -453,7 +451,6 @@ int amdgpu_ucode_init_bo(struct amdgpu_device *adev)
        uint64_t fw_offset = 0;
        int i;
        struct amdgpu_firmware_info *ucode = NULL;
-       const struct common_firmware_header *header = NULL;
 
  /* for baremetal, the ucode is allocated in gtt, so don't need to fill the bo when reset/suspend */
        if (!amdgpu_sriov_vf(adev) && (adev->in_gpu_reset || adev->in_suspend))
@@ -474,7 +471,6 @@ int amdgpu_ucode_init_bo(struct amdgpu_device *adev)
        for (i = 0; i < adev->firmware.max_ucodes; i++) {
                ucode = &adev->firmware.ucode[i];
                if (ucode->fw) {
-                       header = (const struct common_firmware_header *)ucode->fw->data;
                        amdgpu_ucode_init_single_fw(adev, ucode, adev->firmware.fw_buf_mc + fw_offset,
                                                    adev->firmware.fw_buf_ptr + fw_offset);
                        if (i == AMDGPU_UCODE_ID_CP_MEC1 &&
@@ -490,22 +486,3 @@ int amdgpu_ucode_init_bo(struct amdgpu_device *adev)
        }
        return 0;
 }
-
-int amdgpu_ucode_fini_bo(struct amdgpu_device *adev)
-{
-       int i;
-       struct amdgpu_firmware_info *ucode = NULL;
-
-       if (!adev->firmware.fw_size)
-               return 0;
-
-       for (i = 0; i < adev->firmware.max_ucodes; i++) {
-               ucode = &adev->firmware.ucode[i];
-               if (ucode->fw) {
-                       ucode->mc_addr = 0;
-                       ucode->kaddr = NULL;
-               }
-       }
-
-       return 0;
-}
This page took 0.031519 seconds and 4 git commands to generate.