File Index
Files and directories
Sign in
FILE

syscore_ops.h

File preview with syntax highlighting.

linux-6.19.14/include/linux/syscore_ops.h C
 1/* SPDX-License-Identifier: GPL-2.0-only */
 2/*
 3 *  syscore_ops.h - System core operations.
 4 *
 5 *  Copyright (C) 2011 Rafael J. Wysocki <rjw@sisk.pl>, Novell Inc.
 6 */
 7
 8#ifndef _LINUX_SYSCORE_OPS_H
 9#define _LINUX_SYSCORE_OPS_H
10
11#include <linux/list.h>
12
13struct syscore_ops {
14	int (*suspend)(void *data);
15	void (*resume)(void *data);
16	void (*shutdown)(void *data);
17};
18
19struct syscore {
20	struct list_head node;
21	const struct syscore_ops *ops;
22	void *data;
23};
24
25extern void register_syscore(struct syscore *syscore);
26extern void unregister_syscore(struct syscore *syscore);
27#ifdef CONFIG_PM_SLEEP
28extern int syscore_suspend(void);
29extern void syscore_resume(void);
30#endif
31extern void syscore_shutdown(void);
32
33#endif
~/ Read-only file preview.