mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-28 11:18:45 +07:00
c1a9634f1a
Provide managed resource version of reboot_mode_register() and reboot_mode_unregister() to simplify implementations. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Tested-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Sebastian Reichel <sre@kernel.org>
19 lines
561 B
C
19 lines
561 B
C
#ifndef __REBOOT_MODE_H__
|
|
#define __REBOOT_MODE_H__
|
|
|
|
struct reboot_mode_driver {
|
|
struct device *dev;
|
|
struct list_head head;
|
|
int (*write)(struct reboot_mode_driver *reboot, unsigned int magic);
|
|
struct notifier_block reboot_notifier;
|
|
};
|
|
|
|
int reboot_mode_register(struct reboot_mode_driver *reboot);
|
|
int reboot_mode_unregister(struct reboot_mode_driver *reboot);
|
|
int devm_reboot_mode_register(struct device *dev,
|
|
struct reboot_mode_driver *reboot);
|
|
void devm_reboot_mode_unregister(struct device *dev,
|
|
struct reboot_mode_driver *reboot);
|
|
|
|
#endif
|