From: Thierry Reding <thierry.reding@gmail.com>
To: hachyang@gmail.com
Cc: linux-pwm@vger.kernel.org, linux-kernel@vger.kernel.org,
ryang <ryang@hach.com>, Nikolaus Voss <n.voss@weinmann-emt.de>
Subject: Re: [PATCH 1/1] PWM-atmel: Fixed a bug which set the pwm clock prescaler incorrectly. In the defect code the prescaler was always one more than expected value, which resulted in the pwm output with wrong frequency and duty cycle.
Date: Thu, 25 Sep 2014 09:55:09 +0200 [thread overview]
Message-ID: <20140925075508.GB11843@ulmo> (raw)
In-Reply-To: <1410384919-41303-1-git-send-email-ryang@hach.com>
[-- Attachment #1: Type: text/plain, Size: 953 bytes --]
On Wed, Sep 10, 2014 at 03:35:19PM -0600, hachyang@gmail.com wrote:
> From: ryang <ryang@hach.com>
>
> Signed-off-by: ryang <ryang@hach.com>
> ---
> drivers/pwm/pwm-atmel.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/pwm/pwm-atmel.c b/drivers/pwm/pwm-atmel.c
> index 6e700a5..2dca0bf 100644
> --- a/drivers/pwm/pwm-atmel.c
> +++ b/drivers/pwm/pwm-atmel.c
> @@ -128,7 +128,8 @@ static int atmel_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm,
> return -EINVAL;
> }
> }
> -
> + /* Need to reduce the prescaler by 1 */
> + pres--;
> /* Calculate the duty cycles */
> prd = div;
> div *= duty_ns;
> --
> 1.9.1
I think this was fixed by a different patch by Nikolaus in a more direct
way, see: https://lkml.org/lkml/2014/9/24/28
I've pushed that patch to the for-next branch of the PWM tree. Can you
verify that the issue you were seeing is gone?
Thierry
[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2014-09-25 7:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-10 21:35 [PATCH 1/1] PWM-atmel: Fixed a bug which set the pwm clock prescaler incorrectly. In the defect code the prescaler was always one more than expected value, which resulted in the pwm output with wrong frequency and duty cycle hachyang
2014-09-25 7:55 ` Thierry Reding [this message]
2014-09-25 14:44 ` Yang, Robert
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=20140925075508.GB11843@ulmo \
--to=thierry.reding@gmail.com \
--cc=hachyang@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pwm@vger.kernel.org \
--cc=n.voss@weinmann-emt.de \
--cc=ryang@hach.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