xref: /rk3399_ARM-atf/plat/xilinx/common/include/pm_client.h (revision 619bc13eda5b69a8c1e76b5fc0c6ee1f5dbb8a8e)
192c30ac3STejas Patel /*
2*619bc13eSMichal Simek  * Copyright (c) 2013-2019, Arm Limited and Contributors. All rights reserved.
324b5b53aSRajan Vaja  * Copyright (c) 2020-2022, Xilinx, Inc. All rights reserved.
43ae28aa4SJay Buddhabhatti  * Copyright (c) 2022-2023, Advanced Micro Devices, Inc. All rights reserved.
592c30ac3STejas Patel  *
692c30ac3STejas Patel  * SPDX-License-Identifier: BSD-3-Clause
792c30ac3STejas Patel  */
892c30ac3STejas Patel 
992c30ac3STejas Patel /*
1092c30ac3STejas Patel  * Contains APU specific macros and macros to be defined depending on
1192c30ac3STejas Patel  * the execution environment.
1292c30ac3STejas Patel  */
1392c30ac3STejas Patel 
1492c30ac3STejas Patel #ifndef PM_CLIENT_H
1592c30ac3STejas Patel #define PM_CLIENT_H
1692c30ac3STejas Patel 
1792c30ac3STejas Patel #include "pm_common.h"
1892c30ac3STejas Patel #include "pm_defs.h"
1992c30ac3STejas Patel 
2092c30ac3STejas Patel /* Functions to be implemented by each PU */
21ffa91031SVenkatesh Yadav Abbarapu void pm_client_suspend(const struct pm_proc *proc, uint32_t state);
2292c30ac3STejas Patel void pm_client_abort_suspend(void);
2392c30ac3STejas Patel void pm_client_wakeup(const struct pm_proc *proc);
2492c30ac3STejas Patel 
253ae28aa4SJay Buddhabhatti #if !defined(PLAT_zynqmp)
263ae28aa4SJay Buddhabhatti enum pm_device_node_idx irq_to_pm_node_idx(uint32_t irq);
273ae28aa4SJay Buddhabhatti #endif
283ae28aa4SJay Buddhabhatti 
2992c30ac3STejas Patel /* Global variables to be set in pm_client.c */
3092c30ac3STejas Patel extern const struct pm_proc *primary_proc;
3192c30ac3STejas Patel 
3224b5b53aSRajan Vaja #if defined(PLAT_zynqmp)
3392c30ac3STejas Patel enum pm_ret_status pm_set_suspend_mode(uint32_t mode);
3492c30ac3STejas Patel const struct pm_proc *pm_get_proc_by_node(enum pm_node_id nid);
3524b5b53aSRajan Vaja #endif /* PLAT_zynqmp */
3692c30ac3STejas Patel 
3792c30ac3STejas Patel #endif /* PM_CLIENT_H */
38