MOS Source Code
Loading...
Searching...
No Matches
power.h
Go to the documentation of this file.
1// SPDX-License-Identifier: GPL-3.0-or-later
2
3#pragma once
4
5#include <stdnoreturn.h>
6typedef void (*power_callback_t)(void *data);
7
15
19[[noreturn]] void power_shutdown(void);
bool callback(pb_istream_t *stream, uint8_t *buf, size_t count)
MOSAPI void(1, 2) fatal_abort(const char *fmt
void power_shutdown(void)
Shutdown the system.
Definition power.c:33
void(* power_callback_t)(void *data)
Definition power.h:6
void power_register_shutdown_callback(power_callback_t callback, void *data)
Register a callback to be called when the system is about to shut down.
Definition power.c:24