From: fabioestevam@yahoo.com (Fabio Estevam)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] mx35_3ds: Add watchdog support
Date: Mon, 15 Nov 2010 09:31:34 -0800 (PST) [thread overview]
Message-ID: <78127.99191.qm@web51001.mail.re2.yahoo.com> (raw)
In-Reply-To: <20101115155201.GH8942@pengutronix.de>
Hi Uwe and Wolfram,
--- On Mon, 11/15/10, Uwe Kleine-K?nig <u.kleine-koenig@pengutronix.de> wrote:
> From: Uwe Kleine-K?nig <u.kleine-koenig@pengutronix.de>
> Subject: Re: [PATCH] mx35_3ds: Add watchdog support
> To: "Fabio Estevam" <fabioestevam@yahoo.com>
> Cc: fabio.estevam at freescale.com, s.hauer at pengutronix.de, linux-arm-kernel at lists.infradead.org
> Date: Monday, November 15, 2010, 1:52 PM
> Hi Fabio,
>
> On Mon, Nov 15, 2010 at 06:31:09AM -0800, Fabio Estevam
> wrote:
> > mx35_3ds: Add watchdog support.
> I just converted the mx3 watchdog device to dynamic
> allocation.? Will
> take care of mx35_3ds.
Ok, understood.
I have also started testing watchdog on MX51.
As there is no watchdog clock entry in the CCM block on MX51 I thought on doing the following:
diff --git a/drivers/watchdog/imx2_wdt.c b/drivers/watchdog/imx2_wdt.c
index 2ee7dac..63f600c 100644
--- a/drivers/watchdog/imx2_wdt.c
+++ b/drivers/watchdog/imx2_wdt.c
@@ -270,10 +270,12 @@ static int __init imx2_wdt_probe(struct
platform_device *pdev)
return -ENOMEM;
}
- imx2_wdt.clk = clk_get_sys("imx-wdt.0", NULL);
- if (IS_ERR(imx2_wdt.clk)) {
- dev_err(&pdev->dev, "can't get Watchdog clock\n");
- return PTR_ERR(imx2_wdt.clk);
+ if (!cpu_is_mx51()) {
+ imx2_wdt.clk = clk_get_sys("imx-wdt.0", NULL);
+ if (IS_ERR(imx2_wdt.clk)) {
+ dev_err(&pdev->dev, "can't get Watchdog clock\n");
+ return PTR_ERR(imx2_wdt.clk);
+ }
}
Does this look a correct approach?
Regards,
Fabio Estevam
next prev parent reply other threads:[~2010-11-15 17:31 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-15 14:31 [PATCH] mx35_3ds: Add watchdog support Fabio Estevam
2010-11-15 15:52 ` Uwe Kleine-König
2010-11-15 17:31 ` Fabio Estevam [this message]
2010-11-15 19:04 ` Russell King - ARM Linux
2010-11-16 6:38 ` Uwe Kleine-König
2010-11-16 9:25 ` Fabio Estevam
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=78127.99191.qm@web51001.mail.re2.yahoo.com \
--to=fabioestevam@yahoo.com \
--cc=linux-arm-kernel@lists.infradead.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 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.