Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Hauke Mehrtens <hauke@hauke-m.de>
To: "Rafał Miłecki" <zajec5@gmail.com>
Cc: Ralf Baechle <ralf@linux-mips.org>,
	"linux-mips@linux-mips.org" <linux-mips@linux-mips.org>
Subject: Re: [PATCH] MIPS: BCM47XX: make reboot more relaiable
Date: Wed, 30 Jul 2014 20:50:04 +0200	[thread overview]
Message-ID: <53D93E5C.2000706@hauke-m.de> (raw)
In-Reply-To: <CACna6rw_OswnvN7YD7AVnCNKtKJAk8UGXEjUdVJEvaBF3ErAmQ@mail.gmail.com>

On 07/30/2014 08:06 PM, Rafał Miłecki wrote:
> On 28 July 2014 23:53, Hauke Mehrtens <hauke@hauke-m.de> wrote:
>> The reboot on the BCM47XX SoCs is done, by setting the watchdog counter
>> to 1 and let it trigger a reboot, when it reaches 0. Some devices with
>> a BCM4705/BCM4785 SoC do not reboot when the counter is set to 1 and
>> decreased to 0 by the hardware. It looks like it works more reliable
>> when we set it to 3. As far as I understand the hardware, this should
>> not make any difference, but I do not have access to any documentation
>> for this SoC.
>> It is still not 100% reliable.
> 
> Did you see code in hndmips.c of Broadcom SDK? Maybe we need this
> magic ASM code they have it there?
> 
> if (CHIPID(sih->chip) == BCM4785_CHIP_ID)
>     MTC0(C0_BROADCOM, 4, (1 << 22));
> si_watchdog(sih, 1);
> if (CHIPID(sih->chip) == BCM4785_CHIP_ID) {
>     __asm__ __volatile__(
>         ".set\tmips3\n\t"
>         "sync\n\t"
>         "wait\n\t"
>         ".set\tmips0");
> }
> while (1);
> 
> Maybe it'll work better and more reliable?
> 
This looks interesting, I haven't seen this.

Please drop this patch for now, I will create a new one

Hauke

  reply	other threads:[~2014-07-30 18:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-28 21:53 [PATCH] MIPS: BCM47XX: make reboot more relaiable Hauke Mehrtens
2014-07-30 18:06 ` Rafał Miłecki
2014-07-30 18:50   ` Hauke Mehrtens [this message]
2014-07-31  5:14     ` Rafał Miłecki

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=53D93E5C.2000706@hauke-m.de \
    --to=hauke@hauke-m.de \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.org \
    --cc=zajec5@gmail.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