From: "Roman Beránek" <roman.beranek@prusa3d.cz>
To: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Cc: Thierry Reding <thierry.reding@gmail.com>,
Lee Jones <lee.jones@linaro.org>,
Maxime Ripard <mripard@kernel.org>, Chen-Yu Tsai <wens@csie.org>,
Jernej Skrabec <jernej.skrabec@siol.net>,
linux-pwm@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
linux-sunxi@lists.linux.dev, linux-sunxi@googlegroups.com,
Roman Beranek <roman.beranek@prusa3d.com>
Subject: Re: [PATCH] pwm: sun4i: Round delay time up to a nearest jiffy
Date: Wed, 28 Apr 2021 14:07:56 +0200 [thread overview]
Message-ID: <CAL8eAtopkMVmt8XDbzLRsJ_JgGNwZ-FgdNPOWkh-yboTqceUyw@mail.gmail.com> (raw)
In-Reply-To: <20210428061357.725m72aikc52n4gg@pengutronix.de>
[-- Attachment #1: Type: text/plain, Size: 1248 bytes --]
Hello Uwe,
Correct, the output may stay in an active state. I only discovered this
bug as I investigated a report of unreliable screen timeout. The period
we use the PWM with is 50 us.
The PWMx_RDY bit stays 0 well after the last period ends, so if the bit
has any function at all, this one is certainly not it.
Cheers,
Roman
On Wed, Apr 28, 2021 at 8:14 AM Uwe Kleine-König <
u.kleine-koenig@pengutronix.de> wrote:
> Hello Roman,
>
> On Wed, Apr 28, 2021 at 02:19:46AM +0200, Roman Beranek wrote:
> > More often than not, a PWM period may span nowhere near as far
> > as 1 jiffy, yet it still must be waited upon before the channel
> > is disabled.
>
> I wonder what happens if you don't wait long enough. Is this a
> theoretical issue, or do you see an (occasional?) breakage that is fixed
> by this patch?
>
> I guess the problem is that if you disable too early the output freezes
> and that might be in a state where the output is still active? Would
> polling the PWMx_RDY bit in the control register help here?
>
> Best regards
> Uwe
>
> --
> Pengutronix e.K. | Uwe Kleine-König |
> Industrial Linux Solutions | https://www.pengutronix.de/ |
>
[-- Attachment #2: Type: text/html, Size: 3062 bytes --]
next prev parent reply other threads:[~2021-04-28 12:07 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-28 0:19 [PATCH] pwm: sun4i: Round delay time up to a nearest jiffy Roman Beranek
2021-04-28 6:13 ` Uwe Kleine-König
2021-04-28 12:07 ` Roman Beránek [this message]
2021-04-28 12:14 ` Roman Beránek
2021-04-29 12:04 ` Uwe Kleine-König
2021-04-30 2:19 ` Roman Beránek
2021-04-30 6:41 ` Uwe Kleine-König
2021-04-30 7:17 ` Roman Beranek
2021-04-30 9:51 ` Uwe Kleine-König
2021-04-30 15:10 ` Roman Beranek
2021-04-30 16:18 ` [linux-sunxi] " dev
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=CAL8eAtopkMVmt8XDbzLRsJ_JgGNwZ-FgdNPOWkh-yboTqceUyw@mail.gmail.com \
--to=roman.beranek@prusa3d.cz \
--cc=jernej.skrabec@siol.net \
--cc=lee.jones@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-pwm@vger.kernel.org \
--cc=linux-sunxi@googlegroups.com \
--cc=linux-sunxi@lists.linux.dev \
--cc=mripard@kernel.org \
--cc=roman.beranek@prusa3d.com \
--cc=thierry.reding@gmail.com \
--cc=u.kleine-koenig@pengutronix.de \
--cc=wens@csie.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 read-only IMAP folder(s) and NNTP newsgroup(s).