Lines Matching refs:dev_priv
112 struct drm_i915_private *dev_priv = dev->dev_private;
148 struct drm_i915_private *dev_priv = dev->dev_private;
157 ctx->obj = i915_gem_alloc_object(dev, dev_priv->hw_context_size);
175 ctx->ring = &dev_priv->ring[RCS];
217 static int create_default_context(struct drm_i915_private *dev_priv)
222 BUG_ON(!mutex_is_locked(&dev_priv->dev->struct_mutex));
224 ctx = create_hw_context(dev_priv->dev, NULL);
234 dev_priv->ring[RCS].default_context = ctx;
259 struct drm_i915_private *dev_priv = dev->dev_private;
262 dev_priv->hw_contexts_disabled = true;
268 if (dev_priv->hw_contexts_disabled ||
269 dev_priv->ring[RCS].default_context)
272 dev_priv->hw_context_size = ptob(DIV_ROUND_UP(get_context_size(dev), 4096));
274 if (dev_priv->hw_context_size > (1<<20)) {
275 dev_priv->hw_contexts_disabled = true;
280 if (create_default_context(dev_priv)) {
281 dev_priv->hw_contexts_disabled = true;
291 struct drm_i915_private *dev_priv = dev->dev_private;
292 struct i915_hw_context *dctx = dev_priv->ring[RCS].default_context;
294 if (dev_priv->hw_contexts_disabled || dctx == NULL)
329 struct drm_i915_private *dev_priv = ring->dev->dev_private;
333 if (dev_priv->hw_contexts_disabled)
518 struct drm_i915_private *dev_priv = ring->dev->dev_private;
521 if (dev_priv->hw_contexts_disabled)
524 WARN_ON(!mutex_is_locked(&dev_priv->dev->struct_mutex));
526 if (ring != &dev_priv->ring[RCS])
545 struct drm_i915_private *dev_priv = dev->dev_private;
554 if (dev_priv->hw_contexts_disabled)