From: Marek Vasut <marex@denx.de>
To: Denis Carikli <denis@eukrea.com>
Cc: devel@driverdev.osuosl.org, "Mark Rutland" <mark.rutland@arm.com>,
driverdev-devel@linuxdriverproject.org,
"Eric Bénard" <eric@eukrea.com>,
"Pawel Moll" <pawel.moll@arm.com>,
"Stephen Warren" <swarren@wwwdotorg.org>,
"David Airlie" <airlied@linux.ie>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Ian Campbell" <ijc+devicetree@hellion.org.uk>,
"Rob Herring" <rob.herring@calxeda.com>,
devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org,
"Sascha Hauer" <kernel@pengutronix.de>,
"Shawn Guo" <shawn.guo@linaro.org>,
"Dan Carpenter" <dan.carpenter@oracle.com>,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCHv5][ 5/8] staging: imx-drm: parallel display: add regulator support.
Date: Thu, 5 Dec 2013 21:55:31 +0100 [thread overview]
Message-ID: <201312052155.31894.marex@denx.de> (raw)
In-Reply-To: <1386268092-21719-5-git-send-email-denis@eukrea.com>
On Thursday, December 05, 2013 at 07:28:09 PM, Denis Carikli wrote:
> Cc: Dan Carpenter <dan.carpenter@oracle.com>
> Cc: Rob Herring <rob.herring@calxeda.com>
> Cc: Pawel Moll <pawel.moll@arm.com>
> Cc: Mark Rutland <mark.rutland@arm.com>
> Cc: Stephen Warren <swarren@wwwdotorg.org>
> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk>
> Cc: devicetree@vger.kernel.org
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: driverdev-devel@linuxdriverproject.org
> Cc: David Airlie <airlied@linux.ie>
> Cc: dri-devel@lists.freedesktop.org
> Cc: Sascha Hauer <kernel@pengutronix.de>
> Cc: Shawn Guo <shawn.guo@linaro.org>
> Cc: linux-arm-kernel@lists.infradead.org
> Cc: Eric Bénard <eric@eukrea.com>
> Signed-off-by: Denis Carikli <denis@eukrea.com>
> ---
> ChangeLog v3->v5:
> - Code clenaup.
>
> ChangeLog v2->v3:
> - Added some interested people in the Cc list.
> - the lcd-supply is now called display-supply (not all display are LCD).
> - The code and documentation was updated accordingly.
> - regulator_is_enabled now guard the regulator enables/disables because
> regulator_disable does not check the regulator state.
> ---
> .../bindings/staging/imx-drm/fsl-imx-drm.txt | 1 +
> drivers/staging/imx-drm/parallel-display.c | 22
> ++++++++++++++++++++ 2 files changed, 23 insertions(+)
>
> diff --git
> a/Documentation/devicetree/bindings/staging/imx-drm/fsl-imx-drm.txt
> b/Documentation/devicetree/bindings/staging/imx-drm/fsl-imx-drm.txt index
> 2d24425..4dd7ce5 100644
> --- a/Documentation/devicetree/bindings/staging/imx-drm/fsl-imx-drm.txt
> +++ b/Documentation/devicetree/bindings/staging/imx-drm/fsl-imx-drm.txt
> @@ -28,6 +28,7 @@ Required properties:
> - compatible: Should be "fsl,imx-parallel-display"
> - crtc: the crtc this display is connected to, see below
> Optional properties:
> +- display-supply : phandle to the regulator device tree node if needed.
> - interface_pix_fmt: How this display is connected to the
> crtc. Currently supported types: "rgb24", "rgb565", "bgr666", "rgb666"
> - edid: verbatim EDID data block describing attached display.
> diff --git a/drivers/staging/imx-drm/parallel-display.c
> b/drivers/staging/imx-drm/parallel-display.c index 65d0c18..61c0aeb 100644
> --- a/drivers/staging/imx-drm/parallel-display.c
> +++ b/drivers/staging/imx-drm/parallel-display.c
> @@ -22,6 +22,7 @@
> #include <drm/drmP.h>
> #include <drm/drm_fb_helper.h>
> #include <drm/drm_crtc_helper.h>
> +#include <linux/regulator/consumer.h>
> #include <linux/videodev2.h>
>
> #include "imx-drm.h"
> @@ -35,6 +36,7 @@ struct imx_parallel_display {
> struct drm_encoder encoder;
> struct imx_drm_encoder *imx_drm_encoder;
> struct device *dev;
> + struct regulator *disp_reg;
> void *edid;
> int edid_len;
> u32 interface_pix_fmt;
> @@ -141,6 +143,13 @@ static void imx_pd_encoder_prepare(struct drm_encoder
> *encoder) {
> struct imx_parallel_display *imxpd = enc_to_imxpd(encoder);
>
> + if (!IS_ERR(imxpd->disp_reg) &&
> + !regulator_is_enabled(imxpd->disp_reg)) {
> + if (regulator_enable(imxpd->disp_reg))
> + dev_err(imxpd->dev,
> + "Failed to enable regulator.\n");
I wonder, is this linebreak needed for this function call ?
[...]
next prev parent reply other threads:[~2013-12-05 20:55 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-05 18:28 [PATCHv5][ 1/8] [media] v4l2: add new V4L2_PIX_FMT_RGB666 pixel format Denis Carikli
[not found] ` <1386268092-21719-1-git-send-email-denis-fO0SIAKYzcbQT0dZR+AlfA@public.gmane.org>
2013-12-05 18:28 ` [PATCHv5][ 2/8] staging: imx-drm: Add RGB666 support for parallel display Denis Carikli
2013-12-06 13:14 ` Thierry Reding
2013-12-06 13:29 ` Lucas Stach
2013-12-06 14:16 ` Thierry Reding
2013-12-05 18:28 ` [PATCHv5][ 3/8] staging: imx-drm: Correct BGR666 and the board's dts that use them Denis Carikli
2013-12-05 20:52 ` Marek Vasut
2013-12-06 13:07 ` Thierry Reding
2013-12-05 18:28 ` [PATCHv5][ 5/8] staging: imx-drm: parallel display: add regulator support Denis Carikli
2013-12-05 20:55 ` Marek Vasut [this message]
2013-12-06 13:23 ` Thierry Reding
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=201312052155.31894.marex@denx.de \
--to=marex@denx.de \
--cc=airlied@linux.ie \
--cc=dan.carpenter@oracle.com \
--cc=denis@eukrea.com \
--cc=devel@driverdev.osuosl.org \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=driverdev-devel@linuxdriverproject.org \
--cc=eric@eukrea.com \
--cc=gregkh@linuxfoundation.org \
--cc=ijc+devicetree@hellion.org.uk \
--cc=kernel@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=mark.rutland@arm.com \
--cc=pawel.moll@arm.com \
--cc=rob.herring@calxeda.com \
--cc=shawn.guo@linaro.org \
--cc=swarren@wwwdotorg.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).