All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Simek <monstr@monstr.eu>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Quanyang Wang <quanyang.wang@windriver.com>,
	Hyun Kwon <hyun.kwon@xilinx.com>, David Airlie <airlied@linux.ie>,
	Daniel Vetter <daniel@ffwll.ch>,
	dri-devel@lists.freedesktop.org,
	linux-arm <linux-arm-kernel@lists.infradead.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [V2][PATCH] drm: xlnx: zynqmp: release reset to DP controller before accessing DP registers
Date: Fri, 6 Aug 2021 12:37:07 +0200	[thread overview]
Message-ID: <CAHTX3d+uZsqevn0+7Lo+z62mk-1+S7n7VuO-QU8Q1Y-gP0Ugyw@mail.gmail.com> (raw)
In-Reply-To: <YFquZaW4JTTM7ogS@pendragon.ideasonboard.com>

Hi,

st 24. 3. 2021 v 4:15 odesílatel Laurent Pinchart
<laurent.pinchart@ideasonboard.com> napsal:
>
> Hi Quanyang,
>
> Thank you for the patch.
>
> On Tue, Mar 23, 2021 at 10:55:01AM +0800, quanyang.wang@windriver.com wrote:
> > From: Quanyang Wang <quanyang.wang@windriver.com>
> >
> > When insmod zynqmp-dpsub.ko after rmmod it, system will hang with the
> > error log as below:
> >
> > root@xilinx-zynqmp:~# insmod zynqmp-dpsub.ko
> > [   88.391289] [drm] Initialized zynqmp-dpsub 1.0.0 20130509 for fd4a0000.display on minor 0
> > [   88.529906] Console: switching to colour frame buffer device 128x48
> > [   88.549402] zynqmp-dpsub fd4a0000.display: [drm] fb0: zynqmp-dpsubdrm frame buffer device
> > [   88.571624] zynqmp-dpsub fd4a0000.display: ZynqMP DisplayPort Subsystem driver probed
> > root@xilinx-zynqmp:~# rmmod zynqmp_dpsub
> > [   94.023404] Console: switching to colour dummy device 80x25
> > root@xilinx-zynqmp:~# insmod zynqmp-dpsub.ko
> >       <hang here>
> >
> > This is because that in zynqmp_dp_probe it tries to access some DP
> > registers while the DP controller is still in the reset state. When
> > running "rmmod zynqmp_dpsub", zynqmp_dp_reset(dp, true) in
> > zynqmp_dp_phy_exit is called to force the DP controller into the reset
> > state. Then insmod will call zynqmp_dp_probe to program the DP registers,
> > but at this moment the DP controller hasn't been brought out of the reset
> > state yet since the function zynqmp_dp_reset(dp, false) is called later and
> > this will result the system hang.
> >
> > Releasing the reset to DP controller before any read/write operation to it
> > will fix this issue. And for symmetry, move zynqmp_dp_reset() call from
> > zynqmp_dp_phy_exit() to zynqmp_dp_remove().
> >
> > Signed-off-by: Quanyang Wang <quanyang.wang@windriver.com>
>
> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

Can someone pick this patch?

Thanks,
Michal

WARNING: multiple messages have this Message-ID (diff)
From: Michal Simek <monstr@monstr.eu>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Quanyang Wang <quanyang.wang@windriver.com>,
	Hyun Kwon <hyun.kwon@xilinx.com>,
	 David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>,
	dri-devel@lists.freedesktop.org,
	 linux-arm <linux-arm-kernel@lists.infradead.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [V2][PATCH] drm: xlnx: zynqmp: release reset to DP controller before accessing DP registers
Date: Fri, 6 Aug 2021 12:37:07 +0200	[thread overview]
Message-ID: <CAHTX3d+uZsqevn0+7Lo+z62mk-1+S7n7VuO-QU8Q1Y-gP0Ugyw@mail.gmail.com> (raw)
In-Reply-To: <YFquZaW4JTTM7ogS@pendragon.ideasonboard.com>

Hi,

st 24. 3. 2021 v 4:15 odesílatel Laurent Pinchart
<laurent.pinchart@ideasonboard.com> napsal:
>
> Hi Quanyang,
>
> Thank you for the patch.
>
> On Tue, Mar 23, 2021 at 10:55:01AM +0800, quanyang.wang@windriver.com wrote:
> > From: Quanyang Wang <quanyang.wang@windriver.com>
> >
> > When insmod zynqmp-dpsub.ko after rmmod it, system will hang with the
> > error log as below:
> >
> > root@xilinx-zynqmp:~# insmod zynqmp-dpsub.ko
> > [   88.391289] [drm] Initialized zynqmp-dpsub 1.0.0 20130509 for fd4a0000.display on minor 0
> > [   88.529906] Console: switching to colour frame buffer device 128x48
> > [   88.549402] zynqmp-dpsub fd4a0000.display: [drm] fb0: zynqmp-dpsubdrm frame buffer device
> > [   88.571624] zynqmp-dpsub fd4a0000.display: ZynqMP DisplayPort Subsystem driver probed
> > root@xilinx-zynqmp:~# rmmod zynqmp_dpsub
> > [   94.023404] Console: switching to colour dummy device 80x25
> > root@xilinx-zynqmp:~# insmod zynqmp-dpsub.ko
> >       <hang here>
> >
> > This is because that in zynqmp_dp_probe it tries to access some DP
> > registers while the DP controller is still in the reset state. When
> > running "rmmod zynqmp_dpsub", zynqmp_dp_reset(dp, true) in
> > zynqmp_dp_phy_exit is called to force the DP controller into the reset
> > state. Then insmod will call zynqmp_dp_probe to program the DP registers,
> > but at this moment the DP controller hasn't been brought out of the reset
> > state yet since the function zynqmp_dp_reset(dp, false) is called later and
> > this will result the system hang.
> >
> > Releasing the reset to DP controller before any read/write operation to it
> > will fix this issue. And for symmetry, move zynqmp_dp_reset() call from
> > zynqmp_dp_phy_exit() to zynqmp_dp_remove().
> >
> > Signed-off-by: Quanyang Wang <quanyang.wang@windriver.com>
>
> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

Can someone pick this patch?

Thanks,
Michal

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-08-06 10:37 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-23  2:55 [V2][PATCH] drm: xlnx: zynqmp: release reset to DP controller before accessing DP registers quanyang.wang
2021-03-23  2:55 ` quanyang.wang
2021-03-23  2:55 ` quanyang.wang
2021-03-24  3:13 ` Laurent Pinchart
2021-03-24  3:13   ` Laurent Pinchart
2021-03-24  3:13   ` Laurent Pinchart
2021-08-06 10:37   ` Michal Simek [this message]
2021-08-06 10:37     ` Michal Simek
2021-08-06 10:37     ` Michal Simek
2021-08-06 10:43     ` Laurent Pinchart
2021-08-06 10:43       ` Laurent Pinchart

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=CAHTX3d+uZsqevn0+7Lo+z62mk-1+S7n7VuO-QU8Q1Y-gP0Ugyw@mail.gmail.com \
    --to=monstr@monstr.eu \
    --cc=airlied@linux.ie \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=hyun.kwon@xilinx.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=quanyang.wang@windriver.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.