Skip to content

Commit d64a047

Browse files
committed
Merge branch 'drm-fixes-4.11' of git://people.freedesktop.org/~agd5f/linux into drm-fixes
A few small fixes for 4.11 * 'drm-fixes-4.11' of git://people.freedesktop.org/~agd5f/linux: drm/amd/amdgpu: add POLARIS12 PCI ID drm/amdgpu: fix the clearing wb size drm/amdgpu: reinstate oland workaround for sclk drm/radeon: reinstate oland workaround for sclk
2 parents f505a5c + cf8c73a commit d64a047

File tree

4 files changed

+17
-8
lines changed

4 files changed

+17
-8
lines changed

drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -475,7 +475,7 @@ static int amdgpu_wb_init(struct amdgpu_device *adev)
475475
int r;
476476

477477
if (adev->wb.wb_obj == NULL) {
478-
r = amdgpu_bo_create_kernel(adev, AMDGPU_MAX_WB * 4,
478+
r = amdgpu_bo_create_kernel(adev, AMDGPU_MAX_WB * sizeof(uint32_t),
479479
PAGE_SIZE, AMDGPU_GEM_DOMAIN_GTT,
480480
&adev->wb.wb_obj, &adev->wb.gpu_addr,
481481
(void **)&adev->wb.wb);
@@ -488,7 +488,7 @@ static int amdgpu_wb_init(struct amdgpu_device *adev)
488488
memset(&adev->wb.used, 0, sizeof(adev->wb.used));
489489

490490
/* clear wb memory */
491-
memset((char *)adev->wb.wb, 0, AMDGPU_GPU_PAGE_SIZE);
491+
memset((char *)adev->wb.wb, 0, AMDGPU_MAX_WB * sizeof(uint32_t));
492492
}
493493

494494
return 0;

drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -421,6 +421,7 @@ static const struct pci_device_id pciidlist[] = {
421421
{0x1002, 0x6985, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12},
422422
{0x1002, 0x6986, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12},
423423
{0x1002, 0x6987, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12},
424+
{0x1002, 0x6995, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12},
424425
{0x1002, 0x699F, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12},
425426

426427
{0, 0, 0}

drivers/gpu/drm/amd/amdgpu/si_dpm.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3465,9 +3465,13 @@ static void si_apply_state_adjust_rules(struct amdgpu_device *adev,
34653465
max_sclk = 75000;
34663466
}
34673467
} else if (adev->asic_type == CHIP_OLAND) {
3468-
if ((adev->pdev->device == 0x6604) &&
3469-
(adev->pdev->subsystem_vendor == 0x1028) &&
3470-
(adev->pdev->subsystem_device == 0x066F)) {
3468+
if ((adev->pdev->revision == 0xC7) ||
3469+
(adev->pdev->revision == 0x80) ||
3470+
(adev->pdev->revision == 0x81) ||
3471+
(adev->pdev->revision == 0x83) ||
3472+
(adev->pdev->revision == 0x87) ||
3473+
(adev->pdev->device == 0x6604) ||
3474+
(adev->pdev->device == 0x6605)) {
34713475
max_sclk = 75000;
34723476
}
34733477
}

drivers/gpu/drm/radeon/si_dpm.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2985,9 +2985,13 @@ static void si_apply_state_adjust_rules(struct radeon_device *rdev,
29852985
max_sclk = 75000;
29862986
}
29872987
} else if (rdev->family == CHIP_OLAND) {
2988-
if ((rdev->pdev->device == 0x6604) &&
2989-
(rdev->pdev->subsystem_vendor == 0x1028) &&
2990-
(rdev->pdev->subsystem_device == 0x066F)) {
2988+
if ((rdev->pdev->revision == 0xC7) ||
2989+
(rdev->pdev->revision == 0x80) ||
2990+
(rdev->pdev->revision == 0x81) ||
2991+
(rdev->pdev->revision == 0x83) ||
2992+
(rdev->pdev->revision == 0x87) ||
2993+
(rdev->pdev->device == 0x6604) ||
2994+
(rdev->pdev->device == 0x6605)) {
29912995
max_sclk = 75000;
29922996
}
29932997
}

0 commit comments

Comments
 (0)