Merge remote-tracking branch 'drm-intel/drm-intel-next-queued' into drm-intel-next-queued
Pull in patches Jani merged while I was at XDC. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
This commit is contained in:
commit
0f8b83984f
|
@ -1137,6 +1137,10 @@ int i915_driver_unload(struct drm_device *dev)
|
|||
dev_priv->vbt.child_dev = NULL;
|
||||
dev_priv->vbt.child_dev_num = 0;
|
||||
}
|
||||
kfree(dev_priv->vbt.sdvo_lvds_vbt_mode);
|
||||
dev_priv->vbt.sdvo_lvds_vbt_mode = NULL;
|
||||
kfree(dev_priv->vbt.lfp_lvds_vbt_mode);
|
||||
dev_priv->vbt.lfp_lvds_vbt_mode = NULL;
|
||||
|
||||
vga_switcheroo_unregister_client(dev->pdev);
|
||||
vga_client_register(dev->pdev, NULL, NULL, NULL);
|
||||
|
|
|
@ -1713,8 +1713,8 @@ i915_gem_mmap_ioctl(struct drm_device *dev, void *data,
|
|||
|
||||
/**
|
||||
* i915_gem_fault - fault a page into the GTT
|
||||
* vma: VMA in question
|
||||
* vmf: fault info
|
||||
* @vma: VMA in question
|
||||
* @vmf: fault info
|
||||
*
|
||||
* The fault handler is set up by drm_gem_mmap() when a object is GTT mapped
|
||||
* from userspace. The fault handler takes care of binding the object to
|
||||
|
@ -4985,9 +4985,9 @@ int i915_gem_open(struct drm_device *dev, struct drm_file *file)
|
|||
|
||||
/**
|
||||
* i915_gem_track_fb - update frontbuffer tracking
|
||||
* old: current GEM buffer for the frontbuffer slots
|
||||
* new: new GEM buffer for the frontbuffer slots
|
||||
* frontbuffer_bits: bitmask of frontbuffer slots
|
||||
* @old: current GEM buffer for the frontbuffer slots
|
||||
* @new: new GEM buffer for the frontbuffer slots
|
||||
* @frontbuffer_bits: bitmask of frontbuffer slots
|
||||
*
|
||||
* This updates the frontbuffer tracking bits @frontbuffer_bits by clearing them
|
||||
* from @old and setting them in @new. Both @old and @new can be NULL.
|
||||
|
|
|
@ -17,8 +17,8 @@
|
|||
/* pipe updates */
|
||||
|
||||
TRACE_EVENT(i915_pipe_update_start,
|
||||
TP_PROTO(struct intel_crtc *crtc, u32 min, u32 max),
|
||||
TP_ARGS(crtc, min, max),
|
||||
TP_PROTO(struct intel_crtc *crtc),
|
||||
TP_ARGS(crtc),
|
||||
|
||||
TP_STRUCT__entry(
|
||||
__field(enum pipe, pipe)
|
||||
|
@ -33,8 +33,8 @@ TRACE_EVENT(i915_pipe_update_start,
|
|||
__entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
|
||||
crtc->pipe);
|
||||
__entry->scanline = intel_get_crtc_scanline(crtc);
|
||||
__entry->min = min;
|
||||
__entry->max = max;
|
||||
__entry->min = crtc->debug.min_vbl;
|
||||
__entry->max = crtc->debug.max_vbl;
|
||||
),
|
||||
|
||||
TP_printk("pipe %c, frame=%u, scanline=%u, min=%u, max=%u",
|
||||
|
@ -43,8 +43,8 @@ TRACE_EVENT(i915_pipe_update_start,
|
|||
);
|
||||
|
||||
TRACE_EVENT(i915_pipe_update_vblank_evaded,
|
||||
TP_PROTO(struct intel_crtc *crtc, u32 min, u32 max, u32 frame),
|
||||
TP_ARGS(crtc, min, max, frame),
|
||||
TP_PROTO(struct intel_crtc *crtc),
|
||||
TP_ARGS(crtc),
|
||||
|
||||
TP_STRUCT__entry(
|
||||
__field(enum pipe, pipe)
|
||||
|
@ -56,10 +56,10 @@ TRACE_EVENT(i915_pipe_update_vblank_evaded,
|
|||
|
||||
TP_fast_assign(
|
||||
__entry->pipe = crtc->pipe;
|
||||
__entry->frame = frame;
|
||||
__entry->scanline = intel_get_crtc_scanline(crtc);
|
||||
__entry->min = min;
|
||||
__entry->max = max;
|
||||
__entry->frame = crtc->debug.start_vbl_count;
|
||||
__entry->scanline = crtc->debug.scanline_start;
|
||||
__entry->min = crtc->debug.min_vbl;
|
||||
__entry->max = crtc->debug.max_vbl;
|
||||
),
|
||||
|
||||
TP_printk("pipe %c, frame=%u, scanline=%u, min=%u, max=%u",
|
||||
|
@ -68,8 +68,8 @@ TRACE_EVENT(i915_pipe_update_vblank_evaded,
|
|||
);
|
||||
|
||||
TRACE_EVENT(i915_pipe_update_end,
|
||||
TP_PROTO(struct intel_crtc *crtc, u32 frame),
|
||||
TP_ARGS(crtc, frame),
|
||||
TP_PROTO(struct intel_crtc *crtc, u32 frame, int scanline_end),
|
||||
TP_ARGS(crtc, frame, scanline_end),
|
||||
|
||||
TP_STRUCT__entry(
|
||||
__field(enum pipe, pipe)
|
||||
|
@ -80,7 +80,7 @@ TRACE_EVENT(i915_pipe_update_end,
|
|||
TP_fast_assign(
|
||||
__entry->pipe = crtc->pipe;
|
||||
__entry->frame = frame;
|
||||
__entry->scanline = intel_get_crtc_scanline(crtc);
|
||||
__entry->scanline = scanline_end;
|
||||
),
|
||||
|
||||
TP_printk("pipe %c, frame=%u, scanline=%u",
|
||||
|
|
|
@ -2882,7 +2882,7 @@ static bool bxt_ddi_pll_get_hw_state(struct drm_i915_private *dev_priv,
|
|||
* here just read out lanes 0/1 and output a note if lanes 2/3 differ.
|
||||
*/
|
||||
hw_state->pcsdw12 = I915_READ(BXT_PORT_PCS_DW12_LN01(port));
|
||||
if (I915_READ(BXT_PORT_PCS_DW12_LN23(port) != hw_state->pcsdw12))
|
||||
if (I915_READ(BXT_PORT_PCS_DW12_LN23(port)) != hw_state->pcsdw12)
|
||||
DRM_DEBUG_DRIVER("lane stagger config different for lane 01 (%08x) and 23 (%08x)\n",
|
||||
hw_state->pcsdw12,
|
||||
I915_READ(BXT_PORT_PCS_DW12_LN23(port)));
|
||||
|
|
|
@ -4582,6 +4582,9 @@ static bool cpt_digital_port_connected(struct drm_i915_private *dev_priv,
|
|||
case PORT_D:
|
||||
bit = SDE_PORTD_HOTPLUG_CPT;
|
||||
break;
|
||||
case PORT_E:
|
||||
bit = SDE_PORTE_HOTPLUG_SPT;
|
||||
break;
|
||||
default:
|
||||
MISSING_CASE(port->port);
|
||||
return false;
|
||||
|
|
|
@ -565,8 +565,12 @@ struct intel_crtc {
|
|||
|
||||
int scanline_offset;
|
||||
|
||||
unsigned start_vbl_count;
|
||||
ktime_t start_vbl_time;
|
||||
struct {
|
||||
unsigned start_vbl_count;
|
||||
ktime_t start_vbl_time;
|
||||
int min_vbl, max_vbl;
|
||||
int scanline_start;
|
||||
} debug;
|
||||
|
||||
struct intel_crtc_atomic_commit atomic;
|
||||
|
||||
|
|
|
@ -95,7 +95,6 @@ void intel_pipe_update_start(struct intel_crtc *crtc)
|
|||
max = vblank_start - 1;
|
||||
|
||||
local_irq_disable();
|
||||
crtc->start_vbl_count = 0;
|
||||
|
||||
if (min <= 0 || max <= 0)
|
||||
return;
|
||||
|
@ -103,7 +102,9 @@ void intel_pipe_update_start(struct intel_crtc *crtc)
|
|||
if (WARN_ON(drm_crtc_vblank_get(&crtc->base)))
|
||||
return;
|
||||
|
||||
trace_i915_pipe_update_start(crtc, min, max);
|
||||
crtc->debug.min_vbl = min;
|
||||
crtc->debug.max_vbl = max;
|
||||
trace_i915_pipe_update_start(crtc);
|
||||
|
||||
for (;;) {
|
||||
/*
|
||||
|
@ -134,11 +135,12 @@ void intel_pipe_update_start(struct intel_crtc *crtc)
|
|||
|
||||
drm_crtc_vblank_put(&crtc->base);
|
||||
|
||||
crtc->start_vbl_time = ktime_get();
|
||||
crtc->start_vbl_count = dev->driver->get_vblank_counter(dev, pipe);
|
||||
crtc->debug.scanline_start = scanline;
|
||||
crtc->debug.start_vbl_time = ktime_get();
|
||||
crtc->debug.start_vbl_count =
|
||||
dev->driver->get_vblank_counter(dev, pipe);
|
||||
|
||||
trace_i915_pipe_update_vblank_evaded(crtc, min, max,
|
||||
crtc->start_vbl_count);
|
||||
trace_i915_pipe_update_vblank_evaded(crtc);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -154,17 +156,23 @@ void intel_pipe_update_end(struct intel_crtc *crtc)
|
|||
{
|
||||
struct drm_device *dev = crtc->base.dev;
|
||||
enum pipe pipe = crtc->pipe;
|
||||
int scanline_end = intel_get_crtc_scanline(crtc);
|
||||
u32 end_vbl_count = dev->driver->get_vblank_counter(dev, pipe);
|
||||
ktime_t end_vbl_time = ktime_get();
|
||||
|
||||
trace_i915_pipe_update_end(crtc, end_vbl_count);
|
||||
trace_i915_pipe_update_end(crtc, end_vbl_count, scanline_end);
|
||||
|
||||
local_irq_enable();
|
||||
|
||||
if (crtc->start_vbl_count && crtc->start_vbl_count != end_vbl_count)
|
||||
DRM_ERROR("Atomic update failure on pipe %c (start=%u end=%u) time %lld us\n",
|
||||
pipe_name(pipe), crtc->start_vbl_count, end_vbl_count,
|
||||
ktime_us_delta(end_vbl_time, crtc->start_vbl_time));
|
||||
if (crtc->debug.start_vbl_count &&
|
||||
crtc->debug.start_vbl_count != end_vbl_count) {
|
||||
DRM_ERROR("Atomic update failure on pipe %c (start=%u end=%u) time %lld us, min %d, max %d, scanline start %d, end %d\n",
|
||||
pipe_name(pipe), crtc->debug.start_vbl_count,
|
||||
end_vbl_count,
|
||||
ktime_us_delta(end_vbl_time, crtc->debug.start_vbl_time),
|
||||
crtc->debug.min_vbl, crtc->debug.max_vbl,
|
||||
crtc->debug.scanline_start, scanline_end);
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in New Issue