aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/r100.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2009-09-21 00:33:58 -0400
committerDave Airlie <airlied@redhat.com>2009-09-21 01:00:27 -0400
commit28d520433b6375740990ab99d69b0d0067fd656b (patch)
treed3affea0fb69f84b9c924c03d78c5df23946306f /drivers/gpu/drm/radeon/r100.c
parentaadd4e17452d3d5c2269cd2b000b7de7cfb6c79e (diff)
drm/vgaarb: add VGA arbitration support to the drm and kms.
VGA arb requires DRM support for non-kms drivers, to turn on/off irqs when disabling the mem/io regions. VGA arb requires KMS support for GPUs where we can turn off VGA decoding. Currently we know how to do this for intel and radeon kms drivers, which allows them to be removed from the arbiter. This patch comes from Fedora rawhide kernel. 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.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/r100.c b/drivers/gpu/drm/radeon/r100.c
index 737970b43aef..be51c5f7d0f6 100644
--- a/drivers/gpu/drm/radeon/r100.c
+++ b/drivers/gpu/drm/radeon/r100.c
@@ -1955,6 +1955,20 @@ void r100_vram_init_sizes(struct radeon_device *rdev)
1955 rdev->mc.real_vram_size = rdev->mc.aper_size; 1955 rdev->mc.real_vram_size = rdev->mc.aper_size;
1956} 1956}
1957 1957
1958void r100_vga_set_state(struct radeon_device *rdev, bool state)
1959{
1960 uint32_t temp;
1961
1962 temp = RREG32(RADEON_CONFIG_CNTL);
1963 if (state == false) {
1964 temp &= ~(1<<8);
1965 temp |= (1<<9);
1966 } else {
1967 temp &= ~(1<<9);
1968 }
1969 WREG32(RADEON_CONFIG_CNTL, temp);
1970}
1971
1958void r100_vram_info(struct radeon_device *rdev) 1972void r100_vram_info(struct radeon_device *rdev)
1959{ 1973{
1960 r100_vram_get_type(rdev); 1974 r100_vram_get_type(rdev);