diff options
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3777-drm-amdgpu-move-getting-pcie-info-to-common-code.patch')
-rw-r--r-- | meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3777-drm-amdgpu-move-getting-pcie-info-to-common-code.patch | 108 |
1 files changed, 108 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3777-drm-amdgpu-move-getting-pcie-info-to-common-code.patch b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3777-drm-amdgpu-move-getting-pcie-info-to-common-code.patch new file mode 100644 index 00000000..b06b7037 --- /dev/null +++ b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3777-drm-amdgpu-move-getting-pcie-info-to-common-code.patch @@ -0,0 +1,108 @@ +From 97881a95494810e7d72e0ec8331473b3c1bb3c66 Mon Sep 17 00:00:00 2001 +From: Alex Deucher <alexander.deucher@amd.com> +Date: Fri, 9 Mar 2018 15:14:11 -0500 +Subject: [PATCH 3777/4131] drm/amdgpu: move getting pcie info to common code +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +No need to replicate it in several places. + +Reviewed-by: Rex Zhu <rezhu@amd.com> +Acked-by: Christian König <christian.koenig@amd.com> +Signed-off-by: Alex Deucher <alexander.deucher@amd.com> +Signed-off-by: Kalyan Alle <kalyan.alle@amd.com> +--- + drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 -- + drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 6 +++++- + drivers/gpu/drm/amd/amdgpu/cik.c | 2 -- + drivers/gpu/drm/amd/amdgpu/soc15.c | 2 -- + drivers/gpu/drm/amd/amdgpu/vi.c | 2 -- + 5 files changed, 5 insertions(+), 9 deletions(-) + +diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h +index 2dc34f0..05a2c77 100644 +--- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h ++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h +@@ -1101,8 +1101,6 @@ struct amdgpu_wb { + int amdgpu_device_wb_get(struct amdgpu_device *adev, u32 *wb); + void amdgpu_device_wb_free(struct amdgpu_device *adev, u32 wb); + +-void amdgpu_device_get_pcie_info(struct amdgpu_device *adev); +- + /* + * SDMA + */ +diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +index f111b78..44ea5c9 100644 +--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c ++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +@@ -87,6 +87,8 @@ static const char *amdgpu_asic_name[] = { + "LAST", + }; + ++static void amdgpu_device_get_pcie_info(struct amdgpu_device *adev); ++ + bool amdgpu_device_is_px(struct drm_device *dev) + { + struct amdgpu_device *adev = dev->dev_private; +@@ -1957,6 +1959,8 @@ int amdgpu_device_init(struct amdgpu_device *adev, + if (adev->rio_mem == NULL) + DRM_INFO("PCI I/O BAR is not found.\n"); + ++ amdgpu_device_get_pcie_info(adev); ++ + /* early init functions */ + r = amdgpu_device_ip_early_init(adev); + if (r) +@@ -2839,7 +2843,7 @@ int amdgpu_device_gpu_recover(struct amdgpu_device *adev, + return r; + } + +-void amdgpu_device_get_pcie_info(struct amdgpu_device *adev) ++static void amdgpu_device_get_pcie_info(struct amdgpu_device *adev) + { + u32 mask; + int ret; +diff --git a/drivers/gpu/drm/amd/amdgpu/cik.c b/drivers/gpu/drm/amd/amdgpu/cik.c +index f14dd1b..71b3562 100644 +--- a/drivers/gpu/drm/amd/amdgpu/cik.c ++++ b/drivers/gpu/drm/amd/amdgpu/cik.c +@@ -1887,8 +1887,6 @@ static int cik_common_early_init(void *handle) + return -EINVAL; + } + +- amdgpu_device_get_pcie_info(adev); +- + return 0; + } + +diff --git a/drivers/gpu/drm/amd/amdgpu/soc15.c b/drivers/gpu/drm/amd/amdgpu/soc15.c +index b2cf0be..28b0dbf 100644 +--- a/drivers/gpu/drm/amd/amdgpu/soc15.c ++++ b/drivers/gpu/drm/amd/amdgpu/soc15.c +@@ -691,8 +691,6 @@ static int soc15_common_early_init(void *handle) + xgpu_ai_mailbox_set_irq_funcs(adev); + } + +- amdgpu_device_get_pcie_info(adev); +- + return 0; + } + +diff --git a/drivers/gpu/drm/amd/amdgpu/vi.c b/drivers/gpu/drm/amd/amdgpu/vi.c +index 4beed5b..3a73d01 100644 +--- a/drivers/gpu/drm/amd/amdgpu/vi.c ++++ b/drivers/gpu/drm/amd/amdgpu/vi.c +@@ -1140,8 +1140,6 @@ static int vi_common_early_init(void *handle) + xgpu_vi_mailbox_set_irq_funcs(adev); + } + +- amdgpu_device_get_pcie_info(adev); +- + return 0; + } + +-- +2.7.4 + |