From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: Mayuresh Janorkar <mayur@ti.com>
Cc: linux-omap@vger.kernel.org, Mythri P K <mythripk@ti.com>
Subject: Re: [PATCH v2 3/7] OMAP: DSS: Adding a picodlp panel driver
Date: Tue, 03 May 2011 21:26:28 +0300 [thread overview]
Message-ID: <1304447188.26126.25.camel@deskari> (raw)
In-Reply-To: <1304347971-1504-4-git-send-email-mayur@ti.com>
On Mon, 2011-05-02 at 20:22 +0530, Mayuresh Janorkar wrote:
> From: Mythri P K <mythripk@ti.com>
>
> A projector panel named picodlp is supported by OMAP.
> panel driver is required to be added with the name picodlp_panel.
>
> It is a WVGA panel with resolution 864 X 480 and panel timing data
> is defined in the panel driver.
>
> picodlp makes use of parallel (DPI) interface multiplexed with secondary lcd
> in case of OMAP4.
>
> Signed-off-by: Mythri P K <mythripk@ti.com>
> Signed-off-by: Mayuresh Janorkar <mayur@ti.com>
> ---
> Changes since v1:
> 1. Removed msleep
>
> drivers/video/omap2/displays/panel-picodlp.c | 226 ++++++++++++++++++++++++++
> 1 files changed, 226 insertions(+), 0 deletions(-)
> create mode 100644 drivers/video/omap2/displays/panel-picodlp.c
<snip>
> +static void picodlp_panel_disable(struct omap_dss_device *dssdev)
> +{
> + struct picodlp_data *picod = dev_get_drvdata(&dssdev->dev);
> +
> + mutex_lock(&picod->lock);
> + /* Turn off DLP Power */
> + if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE)
> + picodlp_panel_power_off(dssdev);
> +
> + dev_dbg(&dssdev->dev, " disabling picodlp panel\n");
> + dssdev->state = OMAP_DSS_DISPLAY_DISABLED;
> +
> + mutex_unlock(&picod->lock);
Many of the debug prints in this file have an extra space in the
beginning of the string, like above.
You should try to keep the code inside lock and unlock as minimal as
possible. Here the dev_dbg() could as well be outside the lock (granted,
dev_dbg() is a null op if DEBUG is not defined, but still).
Additionally, usually it's good to print the debug print before doing
the action, so here (and similar cases elsewhere in this file) it would
make sense to move the dev_dbg() before the lock.
> +}
> +
> +static int picodlp_panel_suspend(struct omap_dss_device *dssdev)
> +{
> + struct picodlp_data *picod = dev_get_drvdata(&dssdev->dev);
> +
> + mutex_lock(&picod->lock);
> + /* Turn off DLP Power */
> + if (dssdev->state != OMAP_DSS_DISPLAY_ACTIVE) {
> + dev_dbg(&dssdev->dev, " unable to suspend picodlp panel,"\
> + " panel is not ACTIVE\n");
This is not a debug print, but an error. Similar problem in the function
below.
Tomi
next prev parent reply other threads:[~2011-05-03 18:26 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-02 14:52 [PATCH v2 0/7] picodlp projector driver Mayuresh Janorkar
2011-05-02 14:52 ` [PATCH v2 1/7] OMAP: DSS: Adding a header file for picodlp panel data Mayuresh Janorkar
2011-05-03 18:33 ` Tomi Valkeinen
2011-05-02 14:52 ` [PATCH v2 2/7] OMAP: DSS: Adding a picodlp panel header file Mayuresh Janorkar
2011-05-02 14:52 ` [PATCH v2 3/7] OMAP: DSS: Adding a picodlp panel driver Mayuresh Janorkar
2011-05-03 18:26 ` Tomi Valkeinen [this message]
2011-05-04 9:24 ` Janorkar, Mayuresh
2011-05-02 14:52 ` [PATCH v2 4/7] OMAP: DSS: Add i2c client driver for picodlp Mayuresh Janorkar
2011-05-03 18:44 ` Tomi Valkeinen
2011-05-04 10:01 ` Janorkar, Mayuresh
2011-05-04 11:05 ` Tomi Valkeinen
2011-05-04 14:29 ` Janorkar, Mayuresh
2011-05-02 14:52 ` [PATCH v2 5/7] OMAP: DSS: Adding initialization routine to picodlp panel Mayuresh Janorkar
2011-05-03 18:58 ` Tomi Valkeinen
2011-05-04 14:31 ` Janorkar, Mayuresh
2011-05-05 9:35 ` Tomi Valkeinen
2011-05-02 14:52 ` [PATCH v2 6/7] OMAP4: DSS: Adding a picodlp in OMAP4430 SDP board file Mayuresh Janorkar
2011-05-02 14:52 ` [PATCH v2 7/7] OMAP4: DSS: Adding picodlp panel entry in Kconfig and Makefile Mayuresh Janorkar
2011-05-03 19:06 ` [PATCH v2 0/7] picodlp projector driver Tomi Valkeinen
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=1304447188.26126.25.camel@deskari \
--to=tomi.valkeinen@ti.com \
--cc=linux-omap@vger.kernel.org \
--cc=mayur@ti.com \
--cc=mythripk@ti.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox