[Intel-gfx] [PATCH 03/24] drm/i915: clean up intel_sanitize_crtc

Maarten Lankhorst maarten.lankhorst at linux.intel.com
Tue Jun 2 23:47:53 PDT 2015


Op 03-06-15 om 03:27 schreef Matt Roper:
> On Mon, Jun 01, 2015 at 03:27:06PM +0200, Maarten Lankhorst wrote:
>> Apply force if needed.
> It's not clear to me what this means; can you elaborate?  It seems that
> 'force' in the context of intel_crtc_control() means we're updating the
> 'enable' field as well, not just the 'active' field.
>
>> During boot pipe_config->active will be false.
>> On resume no separate modeset is needed when the state gets restored
>> with the sw state anyway.
> If I understand the git history correctly, there's also a special case
> where intel_modeset_setup_hw_state() gets called on lid status change
> because some BIOS silently change hardware state behind our back.  Are
> we still covered in that case?
Sure why not? At the point we swapped our previous sw state to the atomic struct, which we don't touch here.

But looking some closer I think manually setting enable might not be enough, we should probably
call drm_atomic_set_mode_for_crtc and remove all connectors ourself, I think I may add some helper for that,
if it's useful for others too.

I was looking if crtc_state->enable == !num_connectors was enforced, that seems to be done
by drm_atomic_helper_check_modeset fortunately. So I think right now this patch would fail to do
what it says..

~Maarten


More information about the Intel-gfx mailing list