All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
To: Daniel Vetter <daniel-/w4YWyX8dFk@public.gmane.org>
Cc: "Alex Deucher" <alexander.deucher-5C7GfCeVMHo@public.gmane.org>,
	intel-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	"Christian König" <christian.koenig-5C7GfCeVMHo@public.gmane.org>
Subject: Re: [PATCH] drm: Pass crtc to .best_encoder()
Date: Tue, 26 Jun 2018 18:38:13 +0300	[thread overview]
Message-ID: <20180626153812.GA20518@intel.com> (raw)
In-Reply-To: <20180626152325.GC13978-dv86pmgwkMBes7Z6vYuT8azUEOm+Xw19@public.gmane.org>

On Tue, Jun 26, 2018 at 05:23:25PM +0200, Daniel Vetter wrote:
> On Fri, Jun 15, 2018 at 10:52:21PM +0300, Ville Syrjala wrote:
> > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > 
> > To pick the correct MST encoder i915 wants to know which crtc is going
> > to be feeding us. To that end let's pass the crtc to the .best_encoder()
> > hook. The atomic variant already knows the crtc via the connector state,
> > but the non-atomic hooks is still being used by the fb_helper even on
> > atomic drivers.
> 
> Can't we instead fix the fb helpers to use atomic_best_encoder?

We'd need a connector state for that. Not sure we want to construct a
fake one on demand or something.

> Or just
> drop that code, userspace doesn't really know any better either and just
> needs to figure this out without the help of ->best_encoder, so it should
> be possible.

I have to admit I don't even remmber how userspace does this. OK, yeah
so each connector has a list of encoders and each encoder has the
possible_crtcs bitmask. So we should be able to just iterate through
all the encoders for the connector. Not sure there couldn't be some
some false positives if best_encoder() doesn't quite agree with the
answer for some reason.

But yeah, this does seem like a nicer option because we can then nuke
the extra .best_encoder() hook for i915 mst.

Now the question becomes whether I get to review the
connecor->encoder_ids[] assignments in every driver. I suppose they
should be mostly OK if userspace manages to work.

-- 
Ville Syrjälä
Intel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

      parent reply	other threads:[~2018-06-26 15:38 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-15 19:52 [PATCH] drm: Pass crtc to .best_encoder() Ville Syrjala
2018-06-15 21:52 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
2018-06-15 22:10 ` ✓ Fi.CI.BAT: success " Patchwork
2018-06-16 12:39 ` ✗ Fi.CI.IGT: failure " Patchwork
2018-06-26 15:01 ` [PATCH] " Harry Wentland
2018-06-26 15:45   ` Harry Wentland
     [not found] ` <20180615195221.18119-1-ville.syrjala-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2018-06-26 15:23   ` Daniel Vetter
     [not found]     ` <20180626152325.GC13978-dv86pmgwkMBes7Z6vYuT8azUEOm+Xw19@public.gmane.org>
2018-06-26 15:38       ` Ville Syrjälä [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180626153812.GA20518@intel.com \
    --to=ville.syrjala-vuqaysv1563yd54fqh9/ca@public.gmane.org \
    --cc=alexander.deucher-5C7GfCeVMHo@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=christian.koenig-5C7GfCeVMHo@public.gmane.org \
    --cc=daniel-/w4YWyX8dFk@public.gmane.org \
    --cc=dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=intel-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.