Linux Watchdog driver development
 help / color / mirror / Atom feed
* [PATCH 00/14] Add initial support for Octeon CN63XX
@ 2010-10-07 23:03 David Daney
  2010-10-07 23:03 ` [PATCH 13/14] watchdog: octeon-wdt: Use I/O clock rate for timing calculations David Daney
  0 siblings, 1 reply; 4+ messages in thread
From: David Daney @ 2010-10-07 23:03 UTC (permalink / raw)
  To: linux-mips, ralf
  Cc: David Daney, Jeff Garzik, linux-ide, Wim Van Sebroeck,
	linux-watchdog

The OCTEON II CN63XX is a new member of the OCTEON family of SOCs.  It
has up to 6 CPU cores and the programing its I/O blocks is similar to
previous OCTEON parts.  There are however, some differences, hence
this patch set.

With these first 14 patches, we support everything *except* USB, PCIe and
Ethernet.  Patches to add support for those will follow.

The Compact Flash and Watchdog patches are the only ones that fall
outside of the MIPS architecture part of the tree.  Since these are
trivial one-liners, it may be possible to merge them via Ralf's
linux-mips.org tree.

David Daney (14):
  MIPS: Octeon: Update register definitions for CN63XX chips
  MIPS: Octeon: Add cn63XX to Octeon chip detection macros.
  MIPS: Octeon: Update L2 Cache code for CN63XX
  MIPS: Add identifiers for Octeon II CPUs.
  MIPS: Octeon: Handle Octeon II caches.
  MIPS: Octeon: Probe for Octeon II CPUs.
  MIPS: Octeon: Enable Read Inhibit / eXecute Inhibit on Octeon II.
  MIPS: Octeon: Scale Octeon2 clocks in  octeon_init_cvmcount()
  MIPS: Octeon: Remove bogus code from octeon_get_clock_rate()
  MIPS: Octeon: Add octeon_get_io_clock_rate() for cn63xx
  MIPS: Octeon: Use I/O clock rate for calculations.
  ata: pata_octeon_cf: Use I/O clock rate for timing calculations.
  watchdog: octeon-wdt: Use I/O clock rate for timing calculations.
  MIPS: Octeon: Apply CN63XXP1 errata workarounds.

 arch/mips/Makefile                                 |    1 +
 arch/mips/cavium-octeon/Kconfig                    |   11 +
 arch/mips/cavium-octeon/csrc-octeon.c              |   34 +-
 arch/mips/cavium-octeon/executive/cvmx-l2c.c       |  811 +++++++++++--------
 arch/mips/cavium-octeon/octeon-platform.c          |    2 +-
 arch/mips/cavium-octeon/serial.c                   |    2 +-
 arch/mips/cavium-octeon/setup.c                    |  120 ++-
 arch/mips/include/asm/cpu.h                        |    3 +-
 .../asm/mach-cavium-octeon/cpu-feature-overrides.h |    2 +-
 arch/mips/include/asm/octeon/cvmx-agl-defs.h       |  616 ++++++++++-----
 arch/mips/include/asm/octeon/cvmx-asm.h            |   11 +
 arch/mips/include/asm/octeon/cvmx-ciu-defs.h       |  857 ++++++++++++++++++--
 arch/mips/include/asm/octeon/cvmx-gpio-defs.h      |   74 ++-
 arch/mips/include/asm/octeon/cvmx-iob-defs.h       |  242 ++++--
 arch/mips/include/asm/octeon/cvmx-ipd-defs.h       |  314 +++++---
 arch/mips/include/asm/octeon/cvmx-l2c-defs.h       |  738 +++++++++++++++--
 arch/mips/include/asm/octeon/cvmx-l2c.h            |  225 +++---
 arch/mips/include/asm/octeon/cvmx-l2d-defs.h       |   38 +-
 arch/mips/include/asm/octeon/cvmx-l2t-defs.h       |    5 +-
 arch/mips/include/asm/octeon/cvmx-led-defs.h       |   41 +-
 arch/mips/include/asm/octeon/cvmx-mio-defs.h       |  807 ++++++++++++++-----
 arch/mips/include/asm/octeon/cvmx-mixx-defs.h      |  200 ++++--
 arch/mips/include/asm/octeon/cvmx-npei-defs.h      |  681 +++++++---------
 arch/mips/include/asm/octeon/cvmx-npi-defs.h       |  362 +++------
 arch/mips/include/asm/octeon/cvmx-pci-defs.h       |  265 ++----
 arch/mips/include/asm/octeon/cvmx-pciercx-defs.h   |  435 +++++++----
 arch/mips/include/asm/octeon/cvmx-pescx-defs.h     |   50 +-
 arch/mips/include/asm/octeon/cvmx-pexp-defs.h      |  378 +++++-----
 arch/mips/include/asm/octeon/cvmx-pow-defs.h       |  157 +++--
 arch/mips/include/asm/octeon/cvmx-rnm-defs.h       |   67 ++-
 arch/mips/include/asm/octeon/cvmx-smix-defs.h      |   46 +-
 arch/mips/include/asm/octeon/octeon-model.h        |   36 +-
 arch/mips/include/asm/octeon/octeon.h              |    1 +
 arch/mips/kernel/cpu-probe.c                       |    7 +
 arch/mips/mm/c-octeon.c                            |   16 +-
 arch/mips/mm/uasm.c                                |   20 +-
 drivers/ata/pata_octeon_cf.c                       |    2 +-
 drivers/watchdog/octeon-wdt-main.c                 |    4 +-
 38 files changed, 5049 insertions(+), 2632 deletions(-)

Cc: Jeff Garzik <jgarzik@pobox.com>
Cc: linux-ide@vger.kernel.org
Cc: Wim Van Sebroeck <wim@iguana.be>
Cc: linux-watchdog@vger.kernel.org
-- 
1.7.2.3

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 13/14] watchdog: octeon-wdt: Use I/O clock rate for timing calculations.
  2010-10-07 23:03 [PATCH 00/14] Add initial support for Octeon CN63XX David Daney
@ 2010-10-07 23:03 ` David Daney
  2010-10-10 18:23   ` Wim Van Sebroeck
  0 siblings, 1 reply; 4+ messages in thread
From: David Daney @ 2010-10-07 23:03 UTC (permalink / raw)
  To: linux-mips, ralf; +Cc: David Daney, Wim Van Sebroeck, linux-watchdog

The creation of the I/O clock domain requires some adjustments.  Since
the watchdog counters are clocked by the I/O clock, use its rate for
timing calculations.

Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Cc: Wim Van Sebroeck <wim@iguana.be>
Cc: linux-watchdog@vger.kernel.org
---
 drivers/watchdog/octeon-wdt-main.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/watchdog/octeon-wdt-main.c b/drivers/watchdog/octeon-wdt-main.c
index 2a41017..fb0aed0 100644
--- a/drivers/watchdog/octeon-wdt-main.c
+++ b/drivers/watchdog/octeon-wdt-main.c
@@ -477,7 +477,7 @@ static void octeon_wdt_calc_parameters(int t)
 
 	countdown_reset = periods > 2 ? periods - 2 : 0;
 	heartbeat = t;
-	timeout_cnt = ((octeon_get_clock_rate() >> 8) * timeout_sec) >> 8;
+	timeout_cnt = ((octeon_get_io_clock_rate() >> 8) * timeout_sec) >> 8;
 }
 
 static int octeon_wdt_set_heartbeat(int t)
@@ -676,7 +676,7 @@ static int __init octeon_wdt_init(void)
 	max_timeout_sec = 6;
 	do {
 		max_timeout_sec--;
-		timeout_cnt = ((octeon_get_clock_rate() >> 8) * max_timeout_sec) >> 8;
+		timeout_cnt = ((octeon_get_io_clock_rate() >> 8) * max_timeout_sec) >> 8;
 	} while (timeout_cnt > 65535);
 
 	BUG_ON(timeout_cnt == 0);
-- 
1.7.2.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 13/14] watchdog: octeon-wdt: Use I/O clock rate for timing calculations.
  2010-10-07 23:03 ` [PATCH 13/14] watchdog: octeon-wdt: Use I/O clock rate for timing calculations David Daney
@ 2010-10-10 18:23   ` Wim Van Sebroeck
  2010-10-11 12:40     ` Ralf Baechle
  0 siblings, 1 reply; 4+ messages in thread
From: Wim Van Sebroeck @ 2010-10-10 18:23 UTC (permalink / raw)
  To: David Daney; +Cc: linux-mips, ralf, linux-watchdog

Hi David,

> The creation of the I/O clock domain requires some adjustments.  Since
> the watchdog counters are clocked by the I/O clock, use its rate for
> timing calculations.
> 
> Signed-off-by: David Daney <ddaney@caviumnetworks.com>
> Cc: Wim Van Sebroeck <wim@iguana.be>
> Cc: linux-watchdog@vger.kernel.org

Signed-off-by: Wim Van Sebroeck <wim@iguana.be> .

I prefer this one to go through the mips tree.

Kind regards,
Wim.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 13/14] watchdog: octeon-wdt: Use I/O clock rate for timing calculations.
  2010-10-10 18:23   ` Wim Van Sebroeck
@ 2010-10-11 12:40     ` Ralf Baechle
  0 siblings, 0 replies; 4+ messages in thread
From: Ralf Baechle @ 2010-10-11 12:40 UTC (permalink / raw)
  To: Wim Van Sebroeck; +Cc: David Daney, linux-mips, linux-watchdog

On Sun, Oct 10, 2010 at 08:23:42PM +0200, Wim Van Sebroeck wrote:

> > The creation of the I/O clock domain requires some adjustments.  Since
> > the watchdog counters are clocked by the I/O clock, use its rate for
> > timing calculations.
> > 
> > Signed-off-by: David Daney <ddaney@caviumnetworks.com>
> > Cc: Wim Van Sebroeck <wim@iguana.be>
> > Cc: linux-watchdog@vger.kernel.org
> 
> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> .
> 
> I prefer this one to go through the mips tree.

Yes, there are dependencies on other patches.  Applied.

Thanks!

  Ralf

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-10-11 12:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-07 23:03 [PATCH 00/14] Add initial support for Octeon CN63XX David Daney
2010-10-07 23:03 ` [PATCH 13/14] watchdog: octeon-wdt: Use I/O clock rate for timing calculations David Daney
2010-10-10 18:23   ` Wim Van Sebroeck
2010-10-11 12:40     ` Ralf Baechle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox