aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2010-02-11 18:05:42 -0500
committerBen Skeggs <bskeggs@redhat.com>2010-02-25 00:08:31 -0500
commit2ccb04ecc704618d9cd2e26aad067dbb2a057366 (patch)
tree6834723b3811b3b1d19476188e51aeff27f566ff /drivers/gpu/drm/nouveau
parent9a391ad8a2cdd7e5be9b6aabb56f4a46683ba377 (diff)
drm/nouveau: remove PUSHBUF_CAL macro
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_gem.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_gem.c b/drivers/gpu/drm/nouveau/nouveau_gem.c
index 986b67099f6c..df72cd847025 100644
--- a/drivers/gpu/drm/nouveau/nouveau_gem.c
+++ b/drivers/gpu/drm/nouveau/nouveau_gem.c
@@ -614,8 +614,6 @@ out:
614 return ret; 614 return ret;
615} 615}
616 616
617#define PUSHBUF_CAL (dev_priv->card_type >= NV_20)
618
619int 617int
620nouveau_gem_ioctl_pushbuf_call(struct drm_device *dev, void *data, 618nouveau_gem_ioctl_pushbuf_call(struct drm_device *dev, void *data,
621 struct drm_file *file_priv) 619 struct drm_file *file_priv)
@@ -703,7 +701,7 @@ nouveau_gem_ioctl_pushbuf_call(struct drm_device *dev, void *data,
703 /* If presumed return address doesn't match, we need to map the 701 /* If presumed return address doesn't match, we need to map the
704 * push buffer and fix it.. 702 * push buffer and fix it..
705 */ 703 */
706 if (!PUSHBUF_CAL) { 704 if (dev_priv->card_type < NV_20) {
707 uint32_t retaddy; 705 uint32_t retaddy;
708 706
709 if (chan->dma.free < 4 + NOUVEAU_DMA_SKIPS) { 707 if (chan->dma.free < 4 + NOUVEAU_DMA_SKIPS) {
@@ -741,7 +739,7 @@ nouveau_gem_ioctl_pushbuf_call(struct drm_device *dev, void *data,
741 req->offset / 4, 739 req->offset / 4,
742 pbvirt, is_iomem); 740 pbvirt, is_iomem);
743 741
744 if (!PUSHBUF_CAL) { 742 if (dev_priv->card_type < NV_20) {
745 nouveau_bo_wr32(pbbo, 743 nouveau_bo_wr32(pbbo,
746 req->offset / 4 + req->nr_dwords - 2, 744 req->offset / 4 + req->nr_dwords - 2,
747 req->suffix0); 745 req->suffix0);
@@ -763,7 +761,7 @@ nouveau_gem_ioctl_pushbuf_call(struct drm_device *dev, void *data,
763 761
764 nv50_dma_push(chan, pbbo, req->offset, req->nr_dwords); 762 nv50_dma_push(chan, pbbo, req->offset, req->nr_dwords);
765 } else 763 } else
766 if (PUSHBUF_CAL) { 764 if (dev_priv->card_type >= NV_20) {
767 ret = RING_SPACE(chan, 2); 765 ret = RING_SPACE(chan, 2);
768 if (ret) { 766 if (ret) {
769 NV_ERROR(dev, "cal_space: %d\n", ret); 767 NV_ERROR(dev, "cal_space: %d\n", ret);
@@ -805,7 +803,7 @@ out_next:
805 req->suffix0 = 0x00000000; 803 req->suffix0 = 0x00000000;
806 req->suffix1 = 0x00000000; 804 req->suffix1 = 0x00000000;
807 } else 805 } else
808 if (PUSHBUF_CAL) { 806 if (dev_priv->card_type >= NV_20) {
809 req->suffix0 = 0x00020000; 807 req->suffix0 = 0x00020000;
810 req->suffix1 = 0x00000000; 808 req->suffix1 = 0x00000000;
811 } else { 809 } else {