public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Reinhard Meyer <u-boot@emk-elektronik.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v4] at91: Don't initialize watchdog if CONFIG_SKIP_WATCHDOG_INIT is defined
Date: Fri, 20 Aug 2010 22:05:52 +0200	[thread overview]
Message-ID: <4C6EE020.8060301@emk-elektronik.de> (raw)
In-Reply-To: <201008201310.53830.vapier@gentoo.org>

Dear Mike Frysinger,
> On Friday, August 20, 2010 08:31:22 Reinhard Meyer wrote:
>> just to bring in my thoughts to this watchdog issue,
>> and to explain what I think the issue is here:
>>
>> 1. on (all?) AT91SAM9 devices the watchdog is initially enabled
>> (after Reset) with a 16 second timeout (provides a 32kHz Xtal
>> is used).
>
> ah, i think that's the kicker and what needs to be noted.  i wasnt aware of
> devices that did this sort of thing.
I think that's rather ingenious, with a little hardware one
could toggle between boot devices or toggle some higher address
line of a NOR flash to try several bootloaders.

So... lets proceed here...

For the doc/README.at91-watchdog (new file):

"<explanation of AT91 watchdog function, like in my previous mail>

If CONFIG_SYS_WDTC_WDMR_VAL is defined u-boot will write that
value into the watchdog mode register. Otherwise the watchdog
is left in its initial state: active with 16 second timeout.

Note that the watchdog mode register can only be written once.

If the watchdog is left running or programmed to be running,
you need to enable its retriggering by defining
CONFIG_AT91SAM9_WATCHDOG and CONFIG_HW_WATCHDOG."

Alexander, can you prepare a revised patch with README like above
and a better (positive logic) subject like
"AT91: program WDMR only if CONFIG_SYS_WDTC_WDMR_VAL is defined"?

Maybe change CONFIG_SYS_WDTC_WDMR_VAL to CONFIG_AT91_WDTC_WDMR_VAL,
because its AT91 specific but user changeable?

Best Regards,
Reinhard

      reply	other threads:[~2010-08-20 20:05 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-21 12:01 [U-Boot] [PATCH] at91: Don't initialize watchdog if CONFIG_SYS_WDTC_WDMR_VAL is undefined Alexander Stein
2010-07-21 18:20 ` Wolfgang Denk
2010-07-22  6:17   ` Alexander Stein
2010-07-22  7:09     ` Wolfgang Denk
2010-07-22  7:24       ` Alexander Stein
2010-07-22 13:53         ` Wolfgang Denk
2010-07-26  6:11           ` Alexander Stein
     [not found]           ` <201007260810.47268.alexander.stein@systec-electronic.com>
2010-07-26  9:01             ` Wolfgang Denk
2010-07-26  9:34               ` [U-Boot] [PATCH v2] at91: Don't initialize watchdog if CONFIG_SKIP_WATCHDOG_INIT " Alexander Stein
2010-07-26 10:49                 ` Wolfgang Denk
2010-07-26 12:03                   ` [U-Boot] [PATCH v3] " Alexander Stein
2010-08-08 22:59                     ` Wolfgang Denk
2010-08-09  6:40                       ` [U-Boot] [PATCH v4] at91: Don't initialize watchdog if CONFIG_SKIP_WATCHDOG_INIT is defined Alexander Stein
2010-08-09  7:13                         ` Mike Frysinger
2010-08-09 11:42                           ` Alexander Stein
2010-08-14  6:29                             ` Mike Frysinger
2010-08-20 12:31                               ` Reinhard Meyer
2010-08-20 17:10                                 ` Mike Frysinger
2010-08-20 20:05                                   ` Reinhard Meyer [this message]

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=4C6EE020.8060301@emk-elektronik.de \
    --to=u-boot@emk-elektronik.de \
    --cc=u-boot@lists.denx.de \
    /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