Skip to content

Commit

Permalink
drm/radeon: fix logic in r600_page_table_init() to match ati_gart
Browse files Browse the repository at this point in the history
This fixes page table init on rs600.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
  • Loading branch information
Alex Deucher authored and Dave Airlie committed Mar 18, 2009
1 parent 06f0a48 commit 41f13fe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/gpu/drm/radeon/r600_cp.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,6 @@ int r600_page_table_init(struct drm_device *dev)
if (entry->busaddr[i] == 0) {
DRM_ERROR("unable to map PCIGART pages!\n");
r600_page_table_cleanup(dev, gart_info);
ret = -EINVAL;
goto done;
}
entry_addr = entry->busaddr[i];
Expand All @@ -191,6 +190,7 @@ int r600_page_table_init(struct drm_device *dev)
entry_addr += ATI_PCIGART_PAGE_SIZE;
}
}
ret = 1;
done:
return ret;
}
Expand Down Expand Up @@ -2095,7 +2095,7 @@ int r600_do_init_cp(struct drm_device *dev, drm_radeon_init_t *init,
dev_priv->gart_info.addr,
dev_priv->pcigart_offset);

if (r600_page_table_init(dev)) {
if (!r600_page_table_init(dev)) {
DRM_ERROR("Failed to init GART table\n");
r600_do_cleanup_cp(dev);
return -EINVAL;
Expand Down

0 comments on commit 41f13fe

Please sign in to comment.