All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel.vetter@ffwll.ch>
To: Leo Li <sunpeng.li@amd.com>
Cc: Andrey Grodzovsky <andrey.grodzovsky@amd.com>,
	Tony Cheng <Tony.Cheng@amd.com>,
	Intel Graphics Development <intel-gfx@lists.freedesktop.org>,
	DRI Development <dri-devel@lists.freedesktop.org>,
	Shirish S <shirish.s@amd.com>,
	Alex Deucher <alexander.deucher@amd.com>,
	Daniel Vetter <daniel.vetter@intel.com>,
	Harry Wentland <harry.wentland@amd.com>
Subject: Re: [PATCH 08/14] drm/amdgpu: Remove default best_encoder hook from DC
Date: Wed, 5 Sep 2018 15:48:20 +0200	[thread overview]
Message-ID: <CAKMK7uGprt3W7bpCx6Vrt8vRgqEgAx+1qzu33EVfd0jqJ+XcOg@mail.gmail.com> (raw)
In-Reply-To: <d320e1bc-5f76-96ad-3c0e-bf088198eeea@amd.com>

On Wed, Sep 5, 2018 at 3:45 PM, Leo Li <sunpeng.li@amd.com> wrote:
>
>
> On 2018-09-03 12:54 PM, Daniel Vetter wrote:
>>
>> For atomic driver this is the default, no need to reimplement it. We
>> still need to keep the copypasta for not-atomic drivers though, since
>> no one polished the legacy crtc helpers as much as the atomic ones.
>
>
> Thanks for the patch! It seems I made an identical change here:
> https://lists.freedesktop.org/archives/amd-gfx/2018-August/026064.html
>
> One line difference though. I wasn't aware that the default is used when
> .best_encoder is null, so I just hooked it to the default helper.
>
> If it's OK with you, I'll do a follow-up to drop the hook, so we don't
> have two conflicting patches in flight.

I have a follow-up patches to unexport the helper, so would be good if
Alex sends out the pull request so I can sort this all out in
drm-misc-next. I don't want to split up the patch series if possible.
Or we just deal with the conflict, it's minor.

Alex?
-Daniel

> Leo
>
>
>>
>> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
>> Cc: Alex Deucher <alexander.deucher@amd.com>
>> Cc: Harry Wentland <harry.wentland@amd.com>
>> Cc: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
>> Cc: Tony Cheng <Tony.Cheng@amd.com>
>> Cc: "Leo (Sunpeng) Li" <sunpeng.li@amd.com>
>> Cc: Shirish S <shirish.s@amd.com>
>> ---
>>   .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 23 -------------------
>>   1 file changed, 23 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
>> b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
>> index af6adffba788..333f9904f135 100644
>> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
>> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
>> @@ -2794,28 +2794,6 @@ static const struct drm_connector_funcs
>> amdgpu_dm_connector_funcs = {
>>         .atomic_get_property = amdgpu_dm_connector_atomic_get_property
>>   };
>>   -static struct drm_encoder *best_encoder(struct drm_connector
>> *connector)
>> -{
>> -       int enc_id = connector->encoder_ids[0];
>> -       struct drm_mode_object *obj;
>> -       struct drm_encoder *encoder;
>> -
>> -       DRM_DEBUG_DRIVER("Finding the best encoder\n");
>> -
>> -       /* pick the encoder ids */
>> -       if (enc_id) {
>> -               obj = drm_mode_object_find(connector->dev, NULL, enc_id,
>> DRM_MODE_OBJECT_ENCODER);
>> -               if (!obj) {
>> -                       DRM_ERROR("Couldn't find a matching encoder for
>> our connector\n");
>> -                       return NULL;
>> -               }
>> -               encoder = obj_to_encoder(obj);
>> -               return encoder;
>> -       }
>> -       DRM_ERROR("No encoder id\n");
>> -       return NULL;
>> -}
>> -
>>   static int get_modes(struct drm_connector *connector)
>>   {
>>         return amdgpu_dm_connector_get_modes(connector);
>> @@ -2934,7 +2912,6 @@ amdgpu_dm_connector_helper_funcs = {
>>          */
>>         .get_modes = get_modes,
>>         .mode_valid = amdgpu_dm_connector_mode_valid,
>> -       .best_encoder = best_encoder
>>   };
>>     static void dm_crtc_helper_disable(struct drm_crtc *crtc)
>>
>



-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2018-09-05 13:48 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-03 16:54 [PATCH 01/14] drm: Add drm/kernel.h header file Daniel Vetter
2018-09-03 16:54 ` [PATCH 02/14] drm: Drop drmP.h from drm_connector.c Daniel Vetter
2018-09-03 16:54 ` [PATCH 03/14] drm: drop drmP.h include from drm_plane.c Daniel Vetter
2018-09-03 16:54 ` [PATCH 04/14] drm: drop drmP.h include from drm_crtc.c Daniel Vetter
2018-09-03 16:54 ` [PATCH 05/14] drm/atomic: trim driver interface/docs Daniel Vetter
     [not found] ` <20180903165439.24845-1-daniel.vetter-/w4YWyX8dFk@public.gmane.org>
2018-09-03 16:54   ` [PATCH 06/14] drm: extract drm_atomic_uapi.c Daniel Vetter
2018-09-04 20:41     ` Rodrigo Vivi
2018-09-05  7:55       ` Daniel Vetter
     [not found]     ` <20180903165439.24845-6-daniel.vetter-/w4YWyX8dFk@public.gmane.org>
2018-09-05  8:00       ` [PATCH] " Daniel Vetter
2018-09-03 16:54 ` [PATCH 07/14] drm/atomic-helper: Unexport drm_atomic_helper_best_encoder Daniel Vetter
2018-09-03 16:54 ` [PATCH 08/14] drm/amdgpu: Remove default best_encoder hook from DC Daniel Vetter
2018-09-05 13:45   ` Leo Li
2018-09-05 13:48     ` Daniel Vetter [this message]
2018-09-06 16:33       ` Deucher, Alexander
2018-09-06 22:12         ` Daniel Vetter
2018-09-03 16:54 ` [PATCH 09/14] drm: Update todo.rst Daniel Vetter
2018-09-03 17:24   ` Sam Ravnborg
2018-09-03 17:38   ` [Intel-gfx] " Emil Velikov
2018-09-04 12:19     ` Daniel Vetter
2018-09-04 20:52       ` Emil Velikov
2018-09-05  8:04   ` [PATCH] " Daniel Vetter
2018-09-03 16:54 ` [PATCH 10/14] drm: Extract drm_atomic_state_helper.[hc] Daniel Vetter
2018-09-03 16:54 ` [PATCH 11/14] drm/vmwgfx: Remove confused comment from vmw_du_connector_atomic_set_property Daniel Vetter
2018-09-03 16:54 ` [PATCH 12/14] drm/vmwgfx: Don't look at state->allow_modeset Daniel Vetter
2018-09-03 16:54 ` [PATCH 13/14] drm/atomic: Improve docs for drm_atomic_state->allow_modeset Daniel Vetter
2018-09-03 16:54 ` [PATCH 14/14] drm/vmwgfx: Add FIXME comments for customer page_flip handlers Daniel Vetter
2018-09-04 13:45   ` Thomas Hellstrom
2018-09-04 14:19     ` Daniel Vetter
2018-09-03 17:47 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/14] drm: Add drm/kernel.h header file Patchwork
2018-09-03 17:53 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-09-03 18:05 ` ✗ Fi.CI.BAT: failure " Patchwork
2018-09-05  8:09 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/14] drm: Add drm/kernel.h header file (rev3) Patchwork
2018-09-05  8:15 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-09-05  8:26 ` ✗ Fi.CI.BAT: failure " Patchwork

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=CAKMK7uGprt3W7bpCx6Vrt8vRgqEgAx+1qzu33EVfd0jqJ+XcOg@mail.gmail.com \
    --to=daniel.vetter@ffwll.ch \
    --cc=Tony.Cheng@amd.com \
    --cc=alexander.deucher@amd.com \
    --cc=andrey.grodzovsky@amd.com \
    --cc=daniel.vetter@intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=harry.wentland@amd.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=shirish.s@amd.com \
    --cc=sunpeng.li@amd.com \
    /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.