blob: a87923ff0b4ba8f44b8182a8b45a74f965821bc0 [file] [log] [blame]
Soren Brinkmann76fcae32016-03-06 20:16:27 -08001/*
Michal Simek2a47faa2023-04-14 08:43:51 +02002 * Copyright (c) 2013-2019, Arm Limited and Contributors. All rights reserved.
Rajan Vaja2ba71872022-08-31 12:54:34 +02003 * Copyright (c) 2020-2022, Xilinx, Inc. All rights reserved.
Jay Buddhabhattia63b3542023-02-28 02:22:02 -08004 * Copyright (c) 2022-2023, Advanced Micro Devices, Inc. All rights reserved.
Soren Brinkmann76fcae32016-03-06 20:16:27 -08005 *
dp-armfa3cf0b2017-05-03 09:38:09 +01006 * SPDX-License-Identifier: BSD-3-Clause
Soren Brinkmann76fcae32016-03-06 20:16:27 -08007 */
8
9/*
10 * Contains APU specific macros and macros to be defined depending on
11 * the execution environment.
12 */
13
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000014#ifndef PM_CLIENT_H
15#define PM_CLIENT_H
Soren Brinkmann76fcae32016-03-06 20:16:27 -080016
Soren Brinkmann76fcae32016-03-06 20:16:27 -080017#include "pm_common.h"
Isla Mitchelle3631462017-07-14 10:46:32 +010018#include "pm_defs.h"
Soren Brinkmann76fcae32016-03-06 20:16:27 -080019
20/* Functions to be implemented by each PU */
Venkatesh Yadav Abbarapue7c45382022-05-19 14:49:49 +053021void pm_client_suspend(const struct pm_proc *proc, uint32_t state);
Soren Brinkmann76fcae32016-03-06 20:16:27 -080022void pm_client_abort_suspend(void);
23void pm_client_wakeup(const struct pm_proc *proc);
Soren Brinkmann76fcae32016-03-06 20:16:27 -080024
Jay Buddhabhattia63b3542023-02-28 02:22:02 -080025#if !defined(PLAT_zynqmp)
26enum pm_device_node_idx irq_to_pm_node_idx(uint32_t irq);
27#endif
28
Soren Brinkmann76fcae32016-03-06 20:16:27 -080029/* Global variables to be set in pm_client.c */
30extern const struct pm_proc *primary_proc;
31
Rajan Vaja2ba71872022-08-31 12:54:34 +020032#if defined(PLAT_zynqmp)
Tejas Patelf6b2b3c2020-01-10 03:08:40 -080033enum pm_ret_status pm_set_suspend_mode(uint32_t mode);
34const struct pm_proc *pm_get_proc_by_node(enum pm_node_id nid);
Rajan Vaja2ba71872022-08-31 12:54:34 +020035#endif /* PLAT_zynqmp */
Tejas Patelf6b2b3c2020-01-10 03:08:40 -080036
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000037#endif /* PM_CLIENT_H */