All of
 help / color / mirror / Atom feed
From: Jani Nikula <>
To: "Kandpal, Suraj" <>,
Cc: "Murthy, Arun R" <>
Subject: Re: [Intel-gfx] [PATCH 1/4] drm: add writeback pointers to drm_connector
Date: Fri, 07 Jan 2022 14:28:55 +0200	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

On Thu, 06 Jan 2022, "Kandpal, Suraj" <> wrote:
>> > Adding drm_connector and drm_encoder pointers in
>> > drm_writeback_connector
>> Why?
> The elements of struct drm_writeback_connector are 
> struct drm_writeback_connector {
> 	Struct drm_connector base;
> 	Struct drm_encoder encoder;
> Similarly the elements of intel_encoder and intel_connector are
>  struct intel_encoder {
> 	Struct drm_encoder base;
> Struct intel_connector {
> 	Struct drm_connector base;
> The function drm_writeback_connector_init() will initialize the drm_connector and drm_encoder and attach them as well.
> Since the drm_connector/encoder are both struct in drm_writeback_connector and intel_connector/encoder, one of them should be a pointer, else both will be pointing to 2 separate instances.
> Usually the struct defined in drm framework pointing to any struct will be pointer and allocating them and initialization will be done with the users.
> Like struct drm_connector and drm_encoder are part of drm framework and the users of these such as i915 have included them in their struct intel_connector and intel_encoder. 
> Likewise struct drm_writeback_connector is a special connector and hence is not a user of drm_connector and hence this should be pointers.

Okay, I can see the problem, but the solution you present breaks at
least komeda, mali, rcard-du, vc4, and vkms drivers. Either you need to
change all of them, or figure out another way. I don't know off the top
of my head what the correct answer should be, but you can't break other
drivers. Again, maybe you'll get better ideas with a bigger audience
than just intel-gfx.


>> We can all read the code, the commit message should mostly be about the
>> *why*.
>> Also, drm changes should Cc: dri-devel mailing list.
> Sure we will add this in Cc in the next series of patches
> Thanks,
> Suraj Kandpal

Jani Nikula, Intel Open Source Graphics Center

  reply	other threads:[~2022-01-07 12:29 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-17  7:13 [Intel-gfx] [PATCH 0/4] Adding writeback support for i915 Kandpal, Suraj
2021-12-17  7:13 ` [Intel-gfx] [PATCH 1/4] drm: add writeback pointers to drm_connector Kandpal, Suraj
2021-12-17 10:08   ` Jani Nikula
2022-01-06  8:54     ` Kandpal, Suraj
2022-01-07 12:28       ` Jani Nikula [this message]
2021-12-17  7:13 ` [Intel-gfx] [PATCH 2/4] drm/komeda: change driver to use drm_writeback_connector.base pointer Kandpal, Suraj
2021-12-17 10:11   ` Jani Nikula
2022-01-06  9:11     ` Kandpal, Suraj
2021-12-17  7:13 ` [Intel-gfx] [PATCH 3/4] drm/i915: Define WD trancoder for i915 Kandpal, Suraj
2021-12-17 10:12   ` Jani Nikula
2022-01-06  9:12     ` Kandpal, Suraj
2021-12-17  7:13 ` [Intel-gfx] [PATCH 4/4] drm/i915: Enabling WD Transcoder Kandpal, Suraj
2021-12-17 10:04   ` Jani Nikula
2022-01-06  9:24     ` Kandpal, Suraj
2021-12-17 12:17 ` [Intel-gfx] ✗ Fi.CI.BUILD: failure for Adding writeback support for i915 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:

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

  git send-email \ \ \ \ \ \

* 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.