mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hoegeun Kwon <hoegeun.kwon@samsung.com>
To: Andrzej Hajda <a.hajda@samsung.com>,
	thierry.reding@gmail.com, airlied@linux.ie, robh+dt@kernel.org,
	mark.rutland@arm.com, catalin.marinas@arm.com,
	will.deacon@arm.com, kgene@kernel.org, krzk@kernel.org
Cc: dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org,
	javier@osg.samsung.com, inki.dae@samsung.com,
	Hyungwon Hwang <human.hwang@samsung.com>,
	Hoegeun Kwon <hoegeun.kwon@samsung.com>
Subject: Re: [PATCH 2/3] drm/panel: Add support for s6e63j0x03 panel driver
Date: Wed, 14 Jun 2017 16:19:59 +0900	[thread overview]
Message-ID: <d87f4fcc-ad22-cd21-d6c5-a5ef1a5a8ab0@samsung.com> (raw)
In-Reply-To: <04f1d0f1-0010-d21a-1d02-e4e5f9440e56@samsung.com>

Hi Andrzej,

Thanks for your review.

On 06/12/2017 10:16 PM, Andrzej Hajda wrote:
> Hi Hoegeun,
>
> Nice to see patches completing support for mainlined platforms.
>
> On 09.06.2017 06:59, Hoegeun Kwon wrote:
>> This patch adds MIPI-DSI based S6E63J0X03 AMOLED LCD panel driver
>> which uses mipi_dsi bus to communicate with panel. The panel has
>> 320×320 resolution in 1.63" physical panel. This panel is used in
>> Samsung Galaxy Gear 2.
>>
>> Signed-off-by: Inki Dae <inki.dae@samsung.com>
>> Signed-off-by: Hyungwon Hwang <human.hwang@samsung.com>
>> Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
>> ---
>>   drivers/gpu/drm/panel/Kconfig                    |   7 +
>>   drivers/gpu/drm/panel/Makefile                   |   1 +
>>   drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c | 491 +++++++++++++++++++++++
>>   3 files changed, 499 insertions(+)
>>   create mode 100644 drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c
>>
>>

...

>> +
>> +static int s6e63j0x03_enable(struct drm_panel *panel)
>> +{
>> +	struct s6e63j0x03 *ctx = panel_to_s6e63j0x03(panel);
>> +	struct backlight_device *bl_dev = ctx->bl_dev;
>> +	u8 seq[] = { MIPI_DCS_SET_DISPLAY_ON };
>> +	int ret;
>> +
>> +	ret = s6e63j0x03_dcs_write_seq(ctx, seq, ARRAY_SIZE(seq));
>> +	if (ret > 0)
>> +		bl_dev->props.power = FB_BLANK_UNBLANK;
>> +
>> +	return 0;
>> +}
> For many (maybe most) panels power on sequence is as follows:
> 0. Enable power supplies and gpios.
> 1. Initialization, including MIPI_DCS_EXIT_SLEEP_MODE
> 2. Wait for 120ms, to avoid display glitches.
> 3. Unblanking and adjusting display, including MIPI_DCS_SET_DISPLAY_ON.
>
> And power-off:
> 4. MIPI_DCS_SET_DISPLAY_OFF
> 5. MIPI_DCS_ENTER_SLEEP_MODE
> 6. Wait for 120ms
> 7. Disable power supplies and gpios.
>
> I suppose waiting for 120ms is a good indicator what should be put into
> prepare/enable/disable/unprepare phase.
> In my opinion it should be as follows:
> Prepare: 0, 1
> Enable: 2, 3
> Disable: 4,5,6
> Unprepare: 7
>
> What do you think about it?
> Could you arrange the code this way and test if it works correctly?
> Maybe you/other developers have some opinions about it?

I agree with you.
I will send ver2 patch with the above style.
And modify it to use as mipi_dsi_dcs_*.

>> +
>> +static const struct drm_display_mode default_mode = {
>> +	.clock = 4644,
>> +	.hdisplay = 320,
>> +	.hsync_start = 320 + 1,
>> +	.hsync_end = 320 + 1 + 1,
>> +	.htotal = 320 + 1 + 1 + 1,
>> +	.vdisplay = 320,
>> +	.vsync_start = 320 + 150,
>> +	.vsync_end = 320 + 150 + 1,
>> +	.vtotal = 320 + 150 + 1 + 2,
>> +	.vrefresh = 30,
>> +	.flags = 0,
>> +};
> clock should be equal vtotal*htotal*vrefresh, it is little higher? what
> is the reason?
> What is actual refresh rate?

The actual refresh rate is 30.43Hz
So I will modfiy the clock Hz to 4649.

((323 * 473 )* 30.43) / 1000 = 4649

Best regards,
Hoegeun

  reply	other threads:[~2017-06-14  7:20 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20170609045937epcas5p2120f6388b74fa73ea6ed835f7741f61e@epcas5p2.samsung.com>
2017-06-09  4:59 ` [PATCH 0/3] Add support for the s6e63j0x03 panel on Rinato board Hoegeun Kwon
     [not found]   ` <CGME20170609045938epcas5p2025914487ca22a0a2d419824402e89e9@epcas5p2.samsung.com>
2017-06-09  4:59     ` [PATCH 1/3] dt-bindings: Add support for samsung s6e63j0x03 panel binding Hoegeun Kwon
2017-06-12 12:29       ` Andrzej Hajda
2017-06-14 15:28       ` Rob Herring
     [not found]   ` <CGME20170609045938epcas5p216c0ff705d60a32ee57ecb55de9233b5@epcas5p2.samsung.com>
2017-06-09  4:59     ` [PATCH 2/3] drm/panel: Add support for s6e63j0x03 panel driver Hoegeun Kwon
2017-06-12 13:16       ` Andrzej Hajda
2017-06-14  7:19         ` Hoegeun Kwon [this message]
     [not found]   ` <CGME20170609045939epcas1p2e4b50c78978b8f14630ca29550c1cb34@epcas1p2.samsung.com>
2017-06-09  4:59     ` [PATCH 3/3] ARM: dts: exynos: Remove the display-timing and delay from rinato dts Hoegeun Kwon
2017-06-09  7:45       ` Krzysztof Kozlowski
2017-06-09  8:35         ` Hoegeun Kwon

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=d87f4fcc-ad22-cd21-d6c5-a5ef1a5a8ab0@samsung.com \
    --to=hoegeun.kwon@samsung.com \
    --cc=a.hajda@samsung.com \
    --cc=airlied@linux.ie \
    --cc=catalin.marinas@arm.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=human.hwang@samsung.com \
    --cc=inki.dae@samsung.com \
    --cc=javier@osg.samsung.com \
    --cc=kgene@kernel.org \
    --cc=krzk@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=thierry.reding@gmail.com \
    --cc=will.deacon@arm.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

all inboxes | Powered by JetHome®