Loading...
Searching...
No Matches
platform_control
Go to the documentation of this file.
// vi:set ft=cpp: -*- Mode: C++ -*-
/*
* (c) 2014 Steffen Liebergeld <steffen.liebergeld@kernkonzept.com>
* Adam Lackorzynski <adam@os.inf.tu-dresden.de>,
* Alexander Warg <warg@os.inf.tu-dresden.de>
* economic rights: Technische Universität Dresden (Germany)
*
* License: see LICENSE.spdx (in this directory or the directories above)
*/
#pragma once
#include <l4/sys/capability>
#include <l4/sys/platform_control.h>
#include <l4/sys/cxx/ipc_iface>
namespace L4 {
class L4_EXPORT Platform_control
: public Kobject_t<Platform_control, Kobject, L4_PROTO_PLATFORM_CTL>
{
public:
L4_INLINE_RPC_OP(L4_PLATFORM_CTL_SYS_SUSPEND_OP,
l4_msgtag_t, system_suspend, (l4_umword_t extras));
L4_INLINE_RPC_OP(L4_PLATFORM_CTL_SYS_SHUTDOWN_OP,
l4_msgtag_t, system_shutdown, (l4_umword_t reboot));
L4_INLINE_RPC_OP(L4_PLATFORM_CTL_CPU_ALLOW_SHUTDOWN_OP,
l4_msgtag_t, cpu_allow_shutdown,
(l4_umword_t phys_id, l4_umword_t enable));
L4_INLINE_RPC_OP(L4_PLATFORM_CTL_CPU_ENABLE_OP,
l4_msgtag_t, cpu_enable, (l4_umword_t phys_id));
L4_INLINE_RPC_OP(L4_PLATFORM_CTL_CPU_DISABLE_OP,
l4_msgtag_t, cpu_disable, (l4_umword_t phys_id));
typedef L4::Typeid::Rpcs_sys<system_suspend_t, system_shutdown_t,
cpu_allow_shutdown_t, cpu_enable_t,
cpu_disable_t> Rpcs;
};
}
capability
L4::Cap related definitions.
L4::Kobject_t
Helper class to create an L4Re interface class that is derived from a single base class.
Definition __typeinfo.h:750
L4::Platform_control
L4 C++ interface for controlling platform-wide properties, see Platform Control C API for the C inter...
Definition platform_control:38
L4::Platform_control::cpu_disable
l4_msgtag_t cpu_disable(l4_umword_t phys_id)
Disable an online CPU.
L4::Platform_control::cpu_enable
l4_msgtag_t cpu_enable(l4_umword_t phys_id)
Enable an offline CPU.
L4::Platform_control::system_shutdown
l4_msgtag_t system_shutdown(l4_umword_t reboot)
Shutdown/Reboot the system.
L4::Platform_control::cpu_allow_shutdown
l4_msgtag_t cpu_allow_shutdown(l4_umword_t phys_id, l4_umword_t enable)
Allow CPU shutdown.
L4::Platform_control::system_suspend
l4_msgtag_t system_suspend(l4_umword_t extras)
Enter suspend to RAM.
l4_umword_t
unsigned long l4_umword_t
Unsigned machine word.
Definition l4int.h:40
L4_PLATFORM_CTL_CPU_ENABLE_OP
@ L4_PLATFORM_CTL_CPU_ENABLE_OP
enable an offline CPU
Definition platform_control.h:164
L4_PLATFORM_CTL_SYS_SHUTDOWN_OP
@ L4_PLATFORM_CTL_SYS_SHUTDOWN_OP
shutdown/reboot
Definition platform_control.h:162
L4_PLATFORM_CTL_CPU_ALLOW_SHUTDOWN_OP
@ L4_PLATFORM_CTL_CPU_ALLOW_SHUTDOWN_OP
allow CPU shutdown
Definition platform_control.h:163
L4_PLATFORM_CTL_SYS_SUSPEND_OP
@ L4_PLATFORM_CTL_SYS_SUSPEND_OP
Suspend.
Definition platform_control.h:161
L4_PLATFORM_CTL_CPU_DISABLE_OP
@ L4_PLATFORM_CTL_CPU_DISABLE_OP
disable an online CPU
Definition platform_control.h:165
L4_EXPORT
#define L4_EXPORT
Attribute to mark functions, variables, and data types as being exported from a library.
Definition compiler.h:214
ipc_iface
Interface Definition Language.
L4_INLINE_RPC_OP
#define L4_INLINE_RPC_OP(op, res, name, args, attr...)
Define an inline RPC call with specific opcode (type and callable).
Definition ipc_iface:497
platform_control.h
Platform control object.
L4
L4 low-level kernel interface.
Definition l4sys-l4f-groups.dox:50
L4::Typeid::Rpcs_sys
List of RPCs typically used for kernel interfaces.
Definition __typeinfo.h:465
l4_msgtag_t
Message tag data structure.
Definition types.h:154