From: Mark yao <mark.yao-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
To: Tomeu Vizoso <tomeu-XCtybt49RKsYaV1qd6yewg@public.gmane.org>
Cc: "Heiko Stübner" <heiko-4mtYJXux2i+zQB+pC5nmwQ@public.gmane.org>,
"Boris BREZILLON"
<boris.brezillon-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>,
"David Airlie" <airlied-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
"Rob Clark" <robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
"Daniel Vetter" <daniel-/w4YWyX8dFk@public.gmane.org>,
"Rob Herring" <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
"Pawel Moll" <pawel.moll-5wv7dgnIgG8@public.gmane.org>,
"Mark Rutland" <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
"Ian Campbell"
<ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>,
"Kumar Gala" <galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>,
"Randy Dunlap" <rdunlap-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>,
"Grant Likely"
<grant.likely-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
"Greg Kroah-Hartman"
<gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>,
"John Stultz"
<john.stultz-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
"Rom Lemarchand" <romlem-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>,
"devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"linux-doc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<linux-doc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org"
<dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org>
Subject: Re: [PATCH v15 1/3] drm: rockchip: Add basic drm driver
Date: Tue, 15 Mar 2016 09:30:22 +0800 [thread overview]
Message-ID: <56E765AE.1000606@rock-chips.com> (raw)
In-Reply-To: <CAAObsKANPWAHdoFG3SHK_RAwzZ6d=TVKGZP8ukk3a6CxewOajw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
On 2016年03月14日 21:35, Tomeu Vizoso wrote:
> On 2 December 2014 at 10:15, Mark Yao <mark.yao-TNX95d0MmH7DzftRWevZcw@public.gmane.org> wrote:
>> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_vop.c b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
>> new file mode 100644
>> index 0000000..e7ca25b
>> --- /dev/null
>> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
>> @@ -0,0 +1,1455 @@
> ...
>> +static bool vop_crtc_mode_fixup(struct drm_crtc *crtc,
>> + const struct drm_display_mode *mode,
>> + struct drm_display_mode *adjusted_mode)
>> +{
>> + if (adjusted_mode->htotal == 0 || adjusted_mode->vtotal == 0)
>> + return false;
> Hi Mark,
>
> what's the rationale for this?
>
> Disabling a CRTC as in [0] will cause mode_fixup() to be called with
> an empty mode, failing that test.
>
> Removing the check seems to get things working fine for a short while,
> but a later modeset invariably gets the VOP to hang (as reported by
> [1]).
>
> Do you know why that check was put in place and what exactly could be
> causing the hw to hang?
>
> [0] https://cgit.freedesktop.org/xorg/app/intel-gpu-tools/tree/lib/igt_kms.c#n1616
> [1] https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/drivers/gpu/drm/rockchip/rockchip_drm_vop.c#n873
>
> Thanks,
>
> Tomeu
>
Hi Tomeu
Just thinking that "adjusted_mode->htotal == 0 || adjusted_mode->vtotal
== 0" is not a good mode for vop.
And you said VOP hang, only WARN_ON error message? or system hang, die?
I think maybe crtc disable too fast, vblank is off, then no one can feed the wait_update_complete.
Can you test it again with following patch?
drivers/gpu/drm/rockchip/rockchip_drm_vop.c
@@ -503,6 +503,8 @@ static void vop_crtc_disable(struct drm_crtc *crtc)
if (!vop->is_enabled)
return;
+ vop_crtc_wait_for_update(crtc);
+
drm_crtc_vblank_off(crtc);
Thanks.
--
Mark Yao
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2016-03-15 1:30 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-02 9:13 [PATCH v15 0/3] Add drm driver for Rockchip Socs Mark Yao
2014-12-02 9:15 ` [PATCH v15 1/3] drm: rockchip: Add basic drm driver Mark Yao
[not found] ` <1417511739-7141-1-git-send-email-mark.yao-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2016-03-14 13:35 ` Tomeu Vizoso
[not found] ` <CAAObsKANPWAHdoFG3SHK_RAwzZ6d=TVKGZP8ukk3a6CxewOajw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-03-15 1:30 ` Mark yao [this message]
[not found] ` <56E765AE.1000606-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2016-03-16 15:23 ` Tomeu Vizoso
[not found] ` <CAAObsKCQhfofhycAC9B2ApkD5o+9BnxE4yzR+DWjfZNc1hhSug-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-03-17 13:49 ` Tomeu Vizoso
2014-12-02 9:16 ` [PATCH v15 2/3] dt-bindings: video: Add for rockchip display subsytem Mark Yao
[not found] ` <1417511600-7054-1-git-send-email-mark.yao-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2014-12-02 9:18 ` [PATCH v15 3/3] dt-bindings: video: Add documentation for rockchip vop Mark Yao
2014-12-02 9:39 ` [GIT PULL] core drm support for Rockchip SoCs v15 Mark yao
2014-12-02 9:31 ` [PATCH v15 0/3] Add drm driver for Rockchip Socs Heiko Stübner
2014-12-04 19:29 ` Daniel Kurtz
2014-12-05 7:26 ` Dave Airlie
[not found] ` <CAPM=9tzcB0XaenK1RjJoOBpJjrq84atJP59=kh6WMA2-OcFpEA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-12-05 8:33 ` Heiko Stübner
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=56E765AE.1000606@rock-chips.com \
--to=mark.yao-tnx95d0mmh7dzftrwevzcw@public.gmane.org \
--cc=airlied-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=boris.brezillon-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org \
--cc=daniel-/w4YWyX8dFk@public.gmane.org \
--cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
--cc=galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
--cc=grant.likely-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org \
--cc=heiko-4mtYJXux2i+zQB+pC5nmwQ@public.gmane.org \
--cc=ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org \
--cc=john.stultz-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=linux-doc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
--cc=pawel.moll-5wv7dgnIgG8@public.gmane.org \
--cc=rdunlap-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
--cc=robdclark-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=romlem-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org \
--cc=tomeu-XCtybt49RKsYaV1qd6yewg@public.gmane.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).