From: Mark yao <mark.yao@rock-chips.com>
To: Yakir Yang <ykk@rock-chips.com>, Mark Yao <yzq@rock-chips.com>,
Heiko Stuebner <heiko@sntech.de>,
tfiga@chromium.org
Cc: David Airlie <airlied@linux.ie>,
daniel.vetter@ffwll.ch, Thierry Reding <treding@nvidia.com>,
dianders@chromium.org, linux-kernel@vger.kernel.org,
dri-devel@lists.freedesktop.org,
linux-rockchip@lists.infradead.org
Subject: Re: [PATCH] drm/rockchip: vop: do axi reset in vop initial time
Date: Wed, 1 Jun 2016 17:49:32 +0800 [thread overview]
Message-ID: <574EAFAC.6010201@rock-chips.com> (raw)
In-Reply-To: <1464772752-9808-1-git-send-email-ykk@rock-chips.com>
On 2016年06月01日 17:19, Yakir Yang wrote:
> There is a bug in RK3399 VOP, when bootloader/kernel only enable
> VOP Big or VOP Little to display, then VOP IOMMU would failed to
> reset at the initial time and VOP register couldn't write rightly.
>
> After do the pure reset of VOP module, then things back to right.
>
> Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Hi Yakir
I think you get vop iommu reset failed should be IOMMU Page fault, the
vop iommu access a ummap address.
You should ensure all vop windows access right iommu mapping address
before attach iommu.
Actually, I'm working no flash display from bootloader to kernel, and
prepare remove all the reset on vop initial, because it would flash the
display.
Thanks.
> ---
> drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 15 ++++++++++++++-
> 1 file changed, 14 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_vop.c b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
> index 1c4d5b5..4150323 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
> @@ -1292,7 +1292,7 @@ static int vop_initial(struct vop *vop)
> {
> const struct vop_data *vop_data = vop->data;
> const struct vop_reg_data *init_table = vop_data->init_table;
> - struct reset_control *ahb_rst;
> + struct reset_control *ahb_rst, *axi_rst;
> int i, ret;
>
> vop->hclk = devm_clk_get(vop->dev, "hclk_vop");
> @@ -1331,6 +1331,19 @@ static int vop_initial(struct vop *vop)
> }
>
> /*
> + * do aclk_reset, reset all vop registers.
> + */
> + axi_rst = devm_reset_control_get(vop->dev, "axi");
> + if (IS_ERR(axi_rst)) {
> + dev_err(vop->dev, "failed to get axi reset\n");
> + ret = PTR_ERR(axi_rst);
> + goto err_disable_aclk;
> + }
> + reset_control_assert(axi_rst);
> + usleep_range(10, 20);
> + reset_control_deassert(axi_rst);
> +
> + /*
> * do hclk_reset, reset all vop registers.
> */
> ahb_rst = devm_reset_control_get(vop->dev, "ahb");
--
Mark Yao
next prev parent reply other threads:[~2016-06-01 9:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-01 9:19 [PATCH] drm/rockchip: vop: do axi reset in vop initial time Yakir Yang
2016-06-01 9:49 ` Mark yao [this message]
2016-06-01 15:19 ` Thierry Reding
2016-06-02 3:11 ` Yakir Yang
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=574EAFAC.6010201@rock-chips.com \
--to=mark.yao@rock-chips.com \
--cc=airlied@linux.ie \
--cc=daniel.vetter@ffwll.ch \
--cc=dianders@chromium.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=heiko@sntech.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=tfiga@chromium.org \
--cc=treding@nvidia.com \
--cc=ykk@rock-chips.com \
--cc=yzq@rock-chips.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