/* Called by r300_do_cp_cmdbuf to update the internal buffer age and state. The actual age emit is done by r300_do_cp_cmdbuf, which is why you must be careful about how this function is called.  */
static void r300_discard_buffer(struct drm_device *dev, struct drm_master *master, struct drm_buf *buf)
/* Called by r300_do_cp_cmdbuf to update the internal buffer age and state. The actual age emit is done by r300_do_cp_cmdbuf, which is why you must be careful about how this function is called.  */
static void r300_discard_buffer(struct drm_device *dev, struct drm_master *master, struct drm_buf *buf)
{
	drm_radeon_buf_priv_t *buf_priv = buf->dev_private;
	struct drm_radeon_master_private *master_priv = master->driver_priv;
	buf_priv->age = ++master_priv->sarea_priv->last_dispatch;
	buf->pending = 1;
	buf->used = 0;
}