summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/radeon/r100.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2012-04-03 14:53:05 +0400
committerDave Airlie <airlied@redhat.com>2012-04-12 12:27:47 +0400
commit2099810f903caa1920f3ef6014fb7f36e4786490 (patch)
treed1cc8db0b4e224c83ccd5ea071102212b37185a3 /drivers/gpu/drm/radeon/r100.c
parent0034102808e0dbbf3a2394b82b1bb40b5778de9e (diff)
downloadlinux-2099810f903caa1920f3ef6014fb7f36e4786490.tar.xz
drm/radeon: enable pci bus mastering after card is initialised (v2)
This closes a race seen with kexec where we enable PCI bus mastering but the card has been reinitialised fully yet. This was previously fixed by a patch from Jerome, but this should close the race completely. v2: add SI support as suggested by Alex. Reported-and-tested-by: Markus Trippelsdorf <markus@trippelsdorf.de> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/r100.c')
-rw-r--r--drivers/gpu/drm/radeon/r100.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/r100.c b/drivers/gpu/drm/radeon/r100.c
index 81801c176aa5..e11df778e194 100644
--- a/drivers/gpu/drm/radeon/r100.c
+++ b/drivers/gpu/drm/radeon/r100.c
@@ -1180,6 +1180,10 @@ int r100_cp_init(struct radeon_device *rdev, unsigned ring_size)
WREG32(RADEON_CP_RB_WPTR_DELAY, 0);
WREG32(RADEON_CP_CSQ_MODE, 0x00004D4D);
WREG32(RADEON_CP_CSQ_CNTL, RADEON_CSQ_PRIBM_INDBM);
+
+ /* at this point everything should be setup correctly to enable master */
+ pci_set_master(rdev->pdev);
+
radeon_ring_start(rdev, RADEON_RING_TYPE_GFX_INDEX, &rdev->ring[RADEON_RING_TYPE_GFX_INDEX]);
r = radeon_ring_test(rdev, RADEON_RING_TYPE_GFX_INDEX, ring);
if (r) {