summaryrefslogtreecommitdiff
path: root/chip/ish
diff options
context:
space:
mode:
Diffstat (limited to 'chip/ish')
-rw-r--r--chip/ish/power_mgt.c8
-rw-r--r--chip/ish/power_mgt.h6
-rw-r--r--chip/ish/system.c2
3 files changed, 10 insertions, 6 deletions
diff --git a/chip/ish/power_mgt.c b/chip/ish/power_mgt.c
index ca03d6c29a..6664b589a8 100644
--- a/chip/ish/power_mgt.c
+++ b/chip/ish/power_mgt.c
@@ -3,6 +3,8 @@
* found in the LICENSE file.
*/
+#include <stdnoreturn.h>
+
#include "aontaskfw/ish_aon_share.h"
#include "console.h"
#include "hwtimer.h"
@@ -256,7 +258,7 @@ static void switch_to_aontask(void)
interrupt_enable();
}
-__attribute__ ((noreturn))
+noreturn
static void handle_reset_in_aontask(enum ish_pm_state pm_state)
{
pm_ctx.aon_share->pm_state = pm_state;
@@ -649,7 +651,7 @@ void ish_pm_init(void)
}
}
-__attribute__ ((noreturn))
+noreturn
void ish_pm_reset(enum ish_pm_state pm_state)
{
if (IS_ENABLED(CONFIG_ISH_PM_AONTASK) &&
@@ -756,7 +758,7 @@ DECLARE_IRQ(ISH_PMU_WAKEUP_IRQ, pmu_wakeup_isr);
*
*/
-__maybe_unused __attribute__ ((noreturn))
+__maybe_unused noreturn
static void reset_prep_isr(void)
{
/* mask reset prep avail interrupt */
diff --git a/chip/ish/power_mgt.h b/chip/ish/power_mgt.h
index 6144502286..a1fd5aabb6 100644
--- a/chip/ish/power_mgt.h
+++ b/chip/ish/power_mgt.h
@@ -6,6 +6,8 @@
#ifndef __CROS_EC_POWER_MGT_H
#define __CROS_EC_POWER_MGT_H
+#include <stdnoreturn.h>
+
#include "common.h"
#include "registers.h"
@@ -56,7 +58,7 @@ static inline void ish_mia_halt(void)
}
/* reset ISH mintue-ia cpu core */
-__attribute__((noreturn))
+noreturn
static inline void ish_mia_reset(void)
{
/**
@@ -81,7 +83,7 @@ __maybe_unused static void ish_pm_init(void)
/**
* reset ISH (reset minute-ia cpu core, and power off main SRAM)
*/
-void ish_pm_reset(enum ish_pm_state pm_state) __attribute__((noreturn));
+noreturn void ish_pm_reset(enum ish_pm_state pm_state);
/**
* notify the power management module that the UART for the console is in use.
diff --git a/chip/ish/system.c b/chip/ish/system.c
index caa5e15255..1e6fe87800 100644
--- a/chip/ish/system.c
+++ b/chip/ish/system.c
@@ -57,7 +57,7 @@ uint32_t chip_read_reset_flags(void)
* Used when the watchdog timer exceeds max retries and we want to
* disable ISH completely.
*/
-__attribute__((noreturn))
+noreturn
static void system_halt(void)
{
cflush();