From: Sascha Hauer <s.hauer@pengutronix.de>
To: Robert Jarzmik <robert.jarzmik@free.fr>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH V2 1/2] drivers/pwm: add PXA pulse width modulator controller
Date: Wed, 15 Feb 2012 09:32:02 +0100 [thread overview]
Message-ID: <20120215083202.GX3852@pengutronix.de> (raw)
In-Reply-To: <1329224294-31475-1-git-send-email-robert.jarzmik@free.fr>
Hi Robert,
On Tue, Feb 14, 2012 at 01:58:13PM +0100, Robert Jarzmik wrote:
> Add PXA embedded pulse width modulator support. The PWM can
> generate signals from 49.6kHz to 1.625MHz.
> The driver is for pxa2xx family. The pxa3xx was not handled yet.
>
> Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
> ---
> arch/arm/mach-pxa/Makefile | 1 +
> arch/arm/mach-pxa/devices.c | 5 +
> arch/arm/mach-pxa/include/mach/clock.h | 1 +
> arch/arm/mach-pxa/include/mach/devices.h | 2 +-
> arch/arm/mach-pxa/include/mach/regs-pwm.h | 20 +++
> arch/arm/mach-pxa/speed-pxa27x.c | 5 +
> drivers/pwm/Kconfig | 6 +
> drivers/pwm/Makefile | 1 +
> drivers/pwm/pxa_pwm.c | 219 +++++++++++++++++++++++++++++
> 9 files changed, 259 insertions(+), 1 deletions(-)
> create mode 100644 arch/arm/mach-pxa/include/mach/regs-pwm.h
> create mode 100644 drivers/pwm/pxa_pwm.c
>
> +
> +static int __init pxa_pwm_register_vars(struct device_d *dev,
> + struct pxa_pwm_chip *pxa_pwm)
> +{
> + int ret;
> +
> + ret = dev_add_param(dev, "duty_ns", set_duty_ns, NULL, 0);
> + if (!ret)
> + ret = dev_add_param(dev, "period_ns", set_period_ns, NULL, 0);
> + if (!ret)
> + ret = dev_add_param(dev, "enable", set_enable, NULL, 0);
> + if (!ret)
> + ret = dev_set_param(dev, "enable", 0);
> + return ret;
> +}
Nice to make the pwms accessible from the command line, but shouldn't
this be in the core? From what I see all we have to do is to add
duty_ns and period_ns to struct pwm_chip.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2012-02-15 8:32 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-31 9:36 [PATCH] Add pwm core support Sascha Hauer
2012-02-01 8:20 ` Robert Jarzmik
2012-02-01 22:42 ` [PATCH] drivers/pwm: add PXA pulse width modulator controller Robert Jarzmik
2012-02-03 9:52 ` Sascha Hauer
2012-02-03 15:39 ` Robert Jarzmik
2012-02-08 15:26 ` Robert Jarzmik
2012-02-09 8:10 ` Sascha Hauer
2012-02-09 11:50 ` Robert Jarzmik
2012-02-09 13:44 ` Sascha Hauer
2012-02-09 14:30 ` Robert Jarzmik
2012-02-14 12:58 ` [PATCH V2 1/2] " Robert Jarzmik
2012-02-14 12:58 ` [PATCH V2 2/2] drivers/video: remove pxafb enable on load Robert Jarzmik
2012-02-15 8:32 ` Sascha Hauer [this message]
2012-02-15 11:22 ` [PATCH V2 1/2] drivers/pwm: add PXA pulse width modulator controller Robert Jarzmik
2012-02-15 15:21 ` Robert Jarzmik
2012-02-16 7:40 ` Sascha Hauer
2012-02-16 18:23 ` [PATCH V3 1/3] drivers/pwm: add duty_ns and period_ns to core pwm chip Robert Jarzmik
2012-02-16 18:23 ` [PATCH V3 2/3] drivers/pwm: add PXA pulse width modulator controller Robert Jarzmik
2012-02-16 18:23 ` [PATCH V3 3/3] drivers/video: remove pxafb enable on load Robert Jarzmik
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=20120215083202.GX3852@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=robert.jarzmik@free.fr \
/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