summaryrefslogtreecommitdiffstats
path: root/target/linux/brcm47xx/patches-3.6/550-ssb-set-the-pmu-watchdog-if-available.patch
diff options
context:
space:
mode:
authorhauke <hauke@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-12-12 22:42:18 +0000
committerhauke <hauke@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-12-12 22:42:18 +0000
commit811c287737892fe00307b9e7afb832fd459f6e6a (patch)
tree361f1acf0bb77a59cdddefa0a8427afb494fe932 /target/linux/brcm47xx/patches-3.6/550-ssb-set-the-pmu-watchdog-if-available.patch
parent9c0265ae1924e58fd92470bc395ea63f1e9c81cf (diff)
kernel: update bcma and ssb to master-2012-12-11-2 from wireless-testing
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@34651 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/brcm47xx/patches-3.6/550-ssb-set-the-pmu-watchdog-if-available.patch')
-rw-r--r--target/linux/brcm47xx/patches-3.6/550-ssb-set-the-pmu-watchdog-if-available.patch54
1 files changed, 0 insertions, 54 deletions
diff --git a/target/linux/brcm47xx/patches-3.6/550-ssb-set-the-pmu-watchdog-if-available.patch b/target/linux/brcm47xx/patches-3.6/550-ssb-set-the-pmu-watchdog-if-available.patch
deleted file mode 100644
index f7cc07bcd..000000000
--- a/target/linux/brcm47xx/patches-3.6/550-ssb-set-the-pmu-watchdog-if-available.patch
+++ /dev/null
@@ -1,54 +0,0 @@
---- a/drivers/ssb/driver_chipcommon.c
-+++ b/drivers/ssb/driver_chipcommon.c
-@@ -288,6 +288,24 @@ static u32 ssb_chipco_alp_clock(struct s
- return 20000000;
- }
-
-+static u32 ssb_chipco_watchdog_get_max_timer(struct ssb_chipcommon *cc)
-+{
-+ u32 nb;
-+
-+ if (cc->capabilities & SSB_CHIPCO_CAP_PMU) {
-+ if (cc->dev->id.revision < 26)
-+ nb = 16;
-+ else
-+ nb = (cc->dev->id.revision >= 37) ? 32 : 24;
-+ } else {
-+ nb = 28;
-+ }
-+ if (nb == 32)
-+ return 0xffffffff;
-+ else
-+ return (1 << nb) - 1;
-+}
-+
- void ssb_chipcommon_init(struct ssb_chipcommon *cc)
- {
- if (!cc->dev)
-@@ -405,8 +423,24 @@ void ssb_chipco_timing_init(struct ssb_c
- /* Set chip watchdog reset timer to fire in 'ticks' backplane cycles */
- void ssb_chipco_watchdog_timer_set(struct ssb_chipcommon *cc, u32 ticks)
- {
-- /* instant NMI */
-- chipco_write32(cc, SSB_CHIPCO_WATCHDOG, ticks);
-+ u32 maxt;
-+ enum ssb_clkmode clkmode;
-+
-+ maxt = ssb_chipco_watchdog_get_max_timer(cc);
-+ if (cc->capabilities & SSB_CHIPCO_CAP_PMU) {
-+ if (ticks == 1)
-+ ticks = 2;
-+ else if (ticks > maxt)
-+ ticks = maxt;
-+ chipco_write32(cc, SSB_CHIPCO_PMU_WATCHDOG, ticks);
-+ } else {
-+ clkmode = ticks ? SSB_CLKMODE_FAST : SSB_CLKMODE_DYNAMIC;
-+ ssb_chipco_set_clockmode(cc, clkmode);
-+ if (ticks > maxt)
-+ ticks = maxt;
-+ /* instant NMI */
-+ chipco_write32(cc, SSB_CHIPCO_WATCHDOG, ticks);
-+ }
- }
-
- void ssb_chipco_irq_mask(struct ssb_chipcommon *cc, u32 mask, u32 value)