drm/amdgpu: get RAS poison status from DF v4_6_2
[linux-2.6-microblaze.git] / drivers / gpu / drm / amd / amdgpu / amdgpu_discovery.c
index d1bc7b2..5f9d759 100644 (file)
@@ -35,6 +35,7 @@
 #include "df_v1_7.h"
 #include "df_v3_6.h"
 #include "df_v4_3.h"
+#include "df_v4_6_2.h"
 #include "nbio_v6_1.h"
 #include "nbio_v7_0.h"
 #include "nbio_v7_4.h"
@@ -662,7 +663,7 @@ struct ip_hw_instance {
        u8  harvest;
 
        int num_base_addresses;
-       u32 base_addr[];
+       u32 base_addr[] __counted_by(num_base_addresses);
 };
 
 struct ip_hw_id {
@@ -1846,6 +1847,9 @@ static int amdgpu_discovery_set_smu_ip_blocks(struct amdgpu_device *adev)
        case IP_VERSION(13, 0, 11):
                amdgpu_device_ip_block_add(adev, &smu_v13_0_ip_block);
                break;
+       case IP_VERSION(14, 0, 0):
+               amdgpu_device_ip_block_add(adev, &smu_v14_0_ip_block);
+               break;
        default:
                dev_err(adev->dev,
                        "Failed to add smu ip block(MP1_HWIP:0x%x)\n",
@@ -1893,6 +1897,7 @@ static int amdgpu_discovery_set_display_ip_blocks(struct amdgpu_device *adev)
                case IP_VERSION(3, 1, 6):
                case IP_VERSION(3, 2, 0):
                case IP_VERSION(3, 2, 1):
+               case IP_VERSION(3, 5, 0):
                        if (amdgpu_sriov_vf(adev))
                                amdgpu_discovery_set_sriov_display(adev);
                        else
@@ -2555,6 +2560,9 @@ int amdgpu_discovery_set_ip_blocks(struct amdgpu_device *adev)
        case IP_VERSION(4, 3, 0):
                adev->df.funcs = &df_v4_3_funcs;
                break;
+       case IP_VERSION(4, 6, 2):
+               adev->df.funcs = &df_v4_6_2_funcs;
+               break;
        default:
                break;
        }