summaryrefslogtreecommitdiff
path: root/chip/stm32
diff options
context:
space:
mode:
authorShawn Nematbakhsh <shawnn@chromium.org>2017-06-23 09:32:33 -0700
committerchrome-bot <chrome-bot@chromium.org>2017-06-26 11:12:07 -0700
commitceb3e318c8c6fe15129ade47b169c3c03c729fe1 (patch)
tree11287cbace11fb654bc7e977639927f78912a54a /chip/stm32
parent92b7baff54aba25610a9b847037a3a41109ebce8 (diff)
downloadchrome-ec-ceb3e318c8c6fe15129ade47b169c3c03c729fe1.tar.gz
watchdog: Don't discard irqprio data due to CONFIG_LTO
Don't discard irqprio data when the IRQ_PRIORITY macro is used directly (for watchdog / watchdog timer). This change is probably a NOP for all platforms, since the power-on default for the IRQ prio register seems to be zero, which is the same priority we're setting in our direct use of IRQ_PRIORITY. BUG=chromium:634701 BRANCH=None TEST=Verify 'prio_44' entry exists in irqprio section by checking ec.RO.map on kevin. Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org> Change-Id: Idaffc484a2ce4749c18212f179b3951ff570aed0 Reviewed-on: https://chromium-review.googlesource.com/545201 Commit-Ready: Shawn N <shawnn@chromium.org> Tested-by: Shawn N <shawnn@chromium.org> Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'chip/stm32')
-rw-r--r--chip/stm32/hwtimer.c2
-rw-r--r--chip/stm32/hwtimer32.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/chip/stm32/hwtimer.c b/chip/stm32/hwtimer.c
index 5844c83d81..da20522367 100644
--- a/chip/stm32/hwtimer.c
+++ b/chip/stm32/hwtimer.c
@@ -395,7 +395,7 @@ void IRQ_HANDLER(IRQ_WD)(void)
"bl watchdog_check\n"
"pop {r0,pc}\n");
}
-const struct irq_priority IRQ_PRIORITY(IRQ_WD)
+const struct irq_priority __keep IRQ_PRIORITY(IRQ_WD)
__attribute__((section(".rodata.irqprio")))
= {IRQ_WD, 0}; /* put the watchdog at the highest
priority */
diff --git a/chip/stm32/hwtimer32.c b/chip/stm32/hwtimer32.c
index cf2247157f..c3625955a5 100644
--- a/chip/stm32/hwtimer32.c
+++ b/chip/stm32/hwtimer32.c
@@ -235,7 +235,7 @@ void IRQ_HANDLER(IRQ_WD)(void)
"bl watchdog_check\n"
"pop {r0,pc}\n");
}
-const struct irq_priority IRQ_PRIORITY(IRQ_WD)
+const struct irq_priority __keep IRQ_PRIORITY(IRQ_WD)
__attribute__((section(".rodata.irqprio")))
= {IRQ_WD, 0}; /* put the watchdog at the highest
priority */