[<prev] [next>] [day] [month] [year] [list]
Message-ID: <ea96186f-8d38-a698-f29e-049987ae0163@suse.de>
Date: Wed, 24 Jul 2019 19:16:35 +0200
From: Thomas Zimmermann <tzimmermann@...e.de>
To: Andrzej Pietrasiewicz <andrzej.p@...labora.com>,
dri-devel@...ts.freedesktop.org
Cc: Sam Ravnborg <sam@...nborg.org>,
Neil Armstrong <narmstrong@...libre.com>,
David Airlie <airlied@...ux.ie>,
Douglas Anderson <dianders@...omium.org>,
Thierry Reding <thierry.reding@...il.com>,
Laurent Pinchart <Laurent.pinchart@...asonboard.com>,
kernel@...labora.com, linux-samsung-soc@...r.kernel.org,
linux-rockchip@...ts.infradead.org,
Vincent Abriou <vincent.abriou@...com>,
Krzysztof Kozlowski <krzk@...nel.org>,
Jonathan Hunter <jonathanh@...dia.com>,
Maxime Ripard <maxime.ripard@...tlin.com>,
Chen-Yu Tsai <wens@...e.org>, Kukjin Kim <kgene@...nel.org>,
NXP Linux Team <linux-imx@....com>,
Dave Airlie <airlied@...hat.com>,
intel-gfx@...ts.freedesktop.org, freedreno@...ts.freedesktop.org,
linux-tegra@...r.kernel.org, Jonas Karlman <jonas@...boo.se>,
linux-arm-msm@...r.kernel.org,
Mamta Shukla <mamtashukla555@...il.com>,
linux-mediatek@...ts.infradead.org, Jyri Sarha <jsarha@...com>,
Rodrigo Vivi <rodrigo.vivi@...el.com>,
Matthias Brugger <matthias.bgg@...il.com>,
Thomas Gleixner <tglx@...utronix.de>,
Sean Paul <sean@...rly.run>,
Pengutronix Kernel Team <kernel@...gutronix.de>,
Allison Randal <allison@...utok.net>,
linux-arm-kernel@...ts.infradead.org,
Enrico Weigelt <info@...ux.net>,
Jernej Skrabec <jernej.skrabec@...l.net>,
amd-gfx@...ts.freedesktop.org,
Tomi Valkeinen <tomi.valkeinen@...com>,
Seung-Woo Kim <sw0312.kim@...sung.com>,
linux-kernel@...r.kernel.org, Todor Tomov <todor.tomov@...aro.org>,
Kyungmin Park <kyungmin.park@...sung.com>,
Huang Rui <ray.huang@....com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Alex Deucher <alexander.deucher@....com>,
Shawn Guo <shawnguo@...nel.org>,
Christian König <christian.koenig@....com>,
Gerd Hoffmann <kraxel@...hat.com>
Subject: Re: [PATCH v5 02/24] drm: Add drm_connector_init() variant with ddc
Hi
Am 24.07.19 um 15:59 schrieb Andrzej Pietrasiewicz:
> Allow passing ddc adapter pointer to the init function. Even if
> drm_connector_init() sometime in the future decides to e.g. memset() all
> connector fields to zeros, the newly added function ensures that at its
> completion the ddc member of connector is correctly set.
>
> Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@...labora.com>
> ---
> drivers/gpu/drm/drm_connector.c | 19 +++++++++++++++++++
> include/drm/drm_connector.h | 5 +++++
> 2 files changed, 24 insertions(+)
>
> diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c
> index 068d4b05f1be..06fbfc44fb48 100644
> --- a/drivers/gpu/drm/drm_connector.c
> +++ b/drivers/gpu/drm/drm_connector.c
> @@ -296,6 +296,25 @@ int drm_connector_init(struct drm_device *dev,
> }
> EXPORT_SYMBOL(drm_connector_init);
>
> +int drm_connector_init_with_ddc(struct drm_device *dev,
> + struct drm_connector *connector,
> + const struct drm_connector_funcs *funcs,
> + int connector_type,
> + struct i2c_adapter *ddc)
> +{
> + int ret;
> +
> + ret = drm_connector_init(dev, connector, funcs, connector_type);
> + if (ret)
> + return ret;
> +
> + /* provide ddc symlink in sysfs */
> + connector->ddc = ddc;
> +
> + return ret;
> +}
> +EXPORT_SYMBOL(drm_connector_init_with_ddc);
> +
Thanks for including such a function.
Acked-by: Thomas Zimmermann <tzimmermann@...e.de>
> /**
> * drm_connector_attach_edid_property - attach edid property.
> * @connector: the connector
> diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h
> index 33a6fff85fdb..937fda9c1374 100644
> --- a/include/drm/drm_connector.h
> +++ b/include/drm/drm_connector.h
> @@ -1410,6 +1410,11 @@ int drm_connector_init(struct drm_device *dev,
> struct drm_connector *connector,
> const struct drm_connector_funcs *funcs,
> int connector_type);
> +int drm_connector_init_with_ddc(struct drm_device *dev,
> + struct drm_connector *connector,
> + const struct drm_connector_funcs *funcs,
> + int connector_type,
> + struct i2c_adapter *ddc);
> void drm_connector_attach_edid_property(struct drm_connector *connector);
> int drm_connector_register(struct drm_connector *connector);
> void drm_connector_unregister(struct drm_connector *connector);
>
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Linux GmbH, Maxfeldstrasse 5, 90409 Nuernberg, Germany
GF: Felix Imendörffer, Mary Higgins, Sri Rasiah
HRB 21284 (AG Nürnberg)
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists