dri-devel Archive on lore.kernel.org
 help / color / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Liu Ying <victor.liu@nxp.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>,
	Intel Graphics Development <intel-gfx@lists.freedesktop.org>,
	DRI Development <dri-devel@lists.freedesktop.org>,
	NXP Linux Team <linux-imx@nxp.com>,
	Pengutronix Kernel Team <kernel@pengutronix.de>,
	Daniel Vetter <daniel.vetter@intel.com>,
	Shawn Guo <shawnguo@kernel.org>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 05/12] drm/imx: Don't set allow_fb_modifiers explicitly
Date: Wed, 14 Apr 2021 11:10:46 +0200
Message-ID: <YHaxls5WbuU/5pts@phenom.ffwll.local> (raw)
In-Reply-To: <9395e1fde2725d4fe01c206d9172b8acd7cdf921.camel@nxp.com>

On Wed, Apr 14, 2021 at 10:24:22AM +0800, Liu Ying wrote:
> Hi Daniel,
> 
> On Tue, 2021-04-13 at 16:14 +0200, Lucas Stach wrote:
> > Am Dienstag, dem 13.04.2021 um 16:04 +0200 schrieb Daniel Vetter:
> > > On Tue, Apr 13, 2021 at 01:47:28PM +0200, Lucas Stach wrote:
> > > > Am Dienstag, dem 13.04.2021 um 11:48 +0200 schrieb Daniel Vetter:
> > > > > Since
> > > > > 
> > > > > commit 890880ddfdbe256083170866e49c87618b706ac7
> > > > > Author: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
> > > > > Date:   Fri Jan 4 09:56:10 2019 +0100
> > > > > 
> > > > >     drm: Auto-set allow_fb_modifiers when given modifiers at plane init
> > > > > 
> > > > > this is done automatically as part of plane init, if drivers set the
> > > > > modifier list correctly. Which is the case here.
> > > > > 
> > > > > This one actually set it twice on top of what drm_plane_init does, so
> > > > > double-redundant!
> > > > 
> > > > That's not true. imx-dcss and imx-drm are two totally separate drivers.
> > > > Maybe we should move imx-drm into its own ipuv3 directory one day to
> > > > make this more clear. Change is still correct, though.
> > > 
> > > Hm I greeped for drm_universal_plane_init and didn't find anythinf for the
> > > imx main driver ... where are planes set up for that? Need to review that
> > > they have the modifiers listed in all cases.
> > 
> > That's in drivers/gpu/drm/imx/ipuv3-plane.c and modifiers are always
> > set on plane init.

Oh I didn't grep for the new drmm_universal_plane_alloc. Thanks for
pointing this out.

> > 
> > Regards,
> > Lucas
> > 
> > > > Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
> > > > 
> > > > > Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
> > > > > Cc: Philipp Zabel <p.zabel@pengutronix.de>
> > > > > Cc: Shawn Guo <shawnguo@kernel.org>
> > > > > Cc: Sascha Hauer <s.hauer@pengutronix.de>
> > > > > Cc: Pengutronix Kernel Team <kernel@pengutronix.de>
> > > > > Cc: Fabio Estevam <festevam@gmail.com>
> > > > > Cc: NXP Linux Team <linux-imx@nxp.com>
> > > > > Cc: linux-arm-kernel@lists.infradead.org
> > > > > ---
> > > > >  drivers/gpu/drm/imx/dcss/dcss-kms.c | 1 -
> > > > >  drivers/gpu/drm/imx/imx-drm-core.c  | 1 -
> 
> Nit: Since this patch touches two totally separate drivers(imx-dcss and
> imx-drm), it would be good to split it into two patches.

I think if you expect that, then you need to move the imx-drm driver into
a subdirectory like dcss. And like e.g. drm/msm works too. As-is this is
just kinda confusing for people not involved in imx.
-Daniel

> 
> Thanks,
> Liu Ying
> 
> > > > >  2 files changed, 2 deletions(-)
> > > > > 
> > > > > diff --git a/drivers/gpu/drm/imx/dcss/dcss-kms.c b/drivers/gpu/drm/imx/dcss/dcss-kms.c
> > > > > index b549ce5e7607..37ae68a7fba5 100644
> > > > > --- a/drivers/gpu/drm/imx/dcss/dcss-kms.c
> > > > > +++ b/drivers/gpu/drm/imx/dcss/dcss-kms.c
> > > > > @@ -52,7 +52,6 @@ static void dcss_kms_mode_config_init(struct dcss_kms_dev *kms)
> > > > >  	config->min_height = 1;
> > > > >  	config->max_width = 4096;
> > > > >  	config->max_height = 4096;
> > > > > -	config->allow_fb_modifiers = true;
> > > > >  	config->normalize_zpos = true;
> > > > >  
> > > > > 
> > > > > 
> > > > > 
> > > > >  	config->funcs = &dcss_drm_mode_config_funcs;
> > > > > diff --git a/drivers/gpu/drm/imx/imx-drm-core.c b/drivers/gpu/drm/imx/imx-drm-core.c
> > > > > index 2ded8e4f32d0..8be4edaec958 100644
> > > > > --- a/drivers/gpu/drm/imx/imx-drm-core.c
> > > > > +++ b/drivers/gpu/drm/imx/imx-drm-core.c
> > > > > @@ -209,7 +209,6 @@ static int imx_drm_bind(struct device *dev)
> > > > >  	drm->mode_config.max_height = 4096;
> > > > >  	drm->mode_config.funcs = &imx_drm_mode_config_funcs;
> > > > >  	drm->mode_config.helper_private = &imx_drm_mode_config_helpers;
> > > > > -	drm->mode_config.allow_fb_modifiers = true;
> > > > >  	drm->mode_config.normalize_zpos = true;
> > > > >  
> > > > > 
> > > > > 
> > > > > 
> > > > >  	ret = drmm_mode_config_init(drm);
> > 
> > 
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  reply index

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-13  9:48 [PATCH 01/12] drm/arm: " Daniel Vetter
2021-04-13  9:48 ` [PATCH 02/12] drm/arm/malidp: Always list modifiers Daniel Vetter
2021-04-13  9:48 ` [PATCH 03/12] drm/exynos: Don't set allow_fb_modifiers explicitly Daniel Vetter
2021-04-20  6:31   ` Inki Dae
2021-04-20  8:41     ` Daniel Vetter
2021-04-13  9:48 ` [PATCH 04/12] drm/i915: " Daniel Vetter
2021-04-13  9:48 ` [PATCH 05/12] drm/imx: " Daniel Vetter
2021-04-13 11:47   ` Lucas Stach
2021-04-13 14:04     ` Daniel Vetter
2021-04-13 14:14       ` Lucas Stach
2021-04-14  2:24         ` Liu Ying
2021-04-14  9:10           ` Daniel Vetter [this message]
2021-04-15 11:35     ` Daniel Vetter
2021-04-13  9:48 ` [PATCH 06/12] drm/msm/dpu1: " Daniel Vetter
2021-04-13  9:48 ` [PATCH 07/12] drm/msm/mdp4: Fix modifier support enabling Daniel Vetter
2021-04-13  9:48 ` [PATCH 08/12] drm/nouveau: Don't set allow_fb_modifiers explicitly Daniel Vetter
2021-04-13  9:49 ` [PATCH 09/12] drm/stm: " Daniel Vetter
2021-04-13  9:49 ` [PATCH 10/12] drm/tegra: " Daniel Vetter
2021-04-13 11:37   ` Thierry Reding
2021-04-15 11:33     ` Daniel Vetter
2021-04-13  9:49 ` [PATCH 11/12] drm/vc4: " Daniel Vetter
2021-04-14  8:51   ` Maxime Ripard
2021-04-13  9:49 ` [PATCH 12/12] drm/modifiers: Enforce consistency between the cap an IN_FORMATS Daniel Vetter
2021-04-13 11:54   ` Lucas Stach
2021-04-13 14:17     ` Daniel Vetter
2021-04-13 11:56   ` Pekka Paalanen
2021-04-13 14:11     ` Daniel Vetter
2021-04-13 14:19       ` Daniel Vetter
2021-04-14  7:45       ` Pekka Paalanen
2021-04-13 15:22   ` Simon Ser
2021-04-14  8:52   ` Maxime Ripard
2021-04-14  9:08   ` [PATCH] " Daniel Vetter
2021-04-14 12:14     ` Pekka Paalanen
2021-04-16  6:30     ` Simon Ser

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=YHaxls5WbuU/5pts@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=daniel.vetter@ffwll.ch \
    --cc=daniel.vetter@intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-imx@nxp.com \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@kernel.org \
    --cc=victor.liu@nxp.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

dri-devel Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/dri-devel/0 dri-devel/git/0.git
	git clone --mirror https://lore.kernel.org/dri-devel/1 dri-devel/git/1.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dri-devel dri-devel/ https://lore.kernel.org/dri-devel \
		dri-devel@lists.freedesktop.org
	public-inbox-index dri-devel

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.freedesktop.lists.dri-devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git