Make sure CHIP_IS_AGP flag is set when not overriding to PCI mode.

This allows using AGP after overriding to PCI mode in a previous session
without reloading the DRM.
main
Michel Dänzer 2006-07-19 19:16:26 +02:00
parent c91748e702
commit 2a47f6bfec
1 changed files with 5 additions and 0 deletions

View File

@ -1351,6 +1351,11 @@ static int radeon_do_init_cp(drm_device_t * dev, drm_radeon_init_t * init)
DRM_DEBUG("Forcing AGP card to PCI mode\n");
dev_priv->flags &= ~CHIP_IS_AGP;
}
else if (!(dev_priv->flags & CHIP_IS_AGP))
{
DRM_DEBUG("Restoring AGP flag\n");
dev_priv->flags |= CHIP_IS_AGP;
}
if ((!(dev_priv->flags & CHIP_IS_AGP)) && !dev->sg) {
DRM_ERROR("PCI GART memory not allocated!\n");