summaryrefslogtreecommitdiff
path: root/shared-core/nouveau_state.c
diff options
context:
space:
mode:
authorBen Skeggs <skeggsb@gmail.com>2007-02-28 15:14:08 +1100
committerBen Skeggs <skeggsb@gmail.com>2007-02-28 15:41:53 +1100
commit72caa48c82e4334d3292185dbadf758d2dd14c16 (patch)
tree8afcc5dd8d7e16d7ce4feb26303e0bbc85be773b /shared-core/nouveau_state.c
parent6a51da7325163151678c27dcbf51595092773d7a (diff)
nouveau: intrusive drm interface changes
graphics objects: - No longer takes flags/dmaobj parameters, requires some major changes to the ddx to setup the object through the FIFO. This change is likely to cause breakages on some cards (tested on NV05,NV28,NV35, NV40 and NV4E). dma objects: - now takes a "class" parameter, not really used yet but we may need it at some point. - parameters are checked, so clients can't randomly create DMA objects pointing at whatever they feel like. misc: - Added FB_SIZE/AGP_SIZE getparams - Read PFIFO_INTR in PFIFO irq handler, not PMC_INTR - Dump PGRAPH trap info on PGRAPH_INTR_NOTIFY if NSOURCE isn't NOTIFICATION_PENDING.
Diffstat (limited to 'shared-core/nouveau_state.c')
-rw-r--r--shared-core/nouveau_state.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/shared-core/nouveau_state.c b/shared-core/nouveau_state.c
index f1f272e7..e1fc6330 100644
--- a/shared-core/nouveau_state.c
+++ b/shared-core/nouveau_state.c
@@ -181,8 +181,14 @@ int nouveau_ioctl_getparam(DRM_IOCTL_ARGS)
case NOUVEAU_GETPARAM_AGP_PHYSICAL:
getparam.value=dev_priv->agp_phys;
break;
+ case NOUVEAU_GETPARAM_FB_SIZE:
+ getparam.value=dev_priv->fb_available_size;
+ break;
+ case NOUVEAU_GETPARAM_AGP_SIZE:
+ getparam.value=dev_priv->agp_available_size;
+ break;
default:
- DRM_ERROR("unknown parameter %d\n", getparam.param);
+ DRM_ERROR("unknown parameter %lld\n", getparam.param);
return DRM_ERR(EINVAL);
}
@@ -207,7 +213,8 @@ int nouveau_ioctl_setparam(DRM_IOCTL_ARGS)
case NOUVEAU_MEM_FB:
break;
default:
- DRM_ERROR("invalid CMDBUF_LOCATION value=%d\n", setparam.value);
+ DRM_ERROR("invalid CMDBUF_LOCATION value=%lld\n",
+ setparam.value);
return DRM_ERR(EINVAL);
}
dev_priv->config.cmdbuf.location = setparam.value;
@@ -216,7 +223,7 @@ int nouveau_ioctl_setparam(DRM_IOCTL_ARGS)
dev_priv->config.cmdbuf.size = setparam.value;
break;
default:
- DRM_ERROR("unknown parameter %d\n", setparam.param);
+ DRM_ERROR("unknown parameter %lld\n", setparam.param);
return DRM_ERR(EINVAL);
}