#include <linux/io.h>
#include <linux/init.h>
#include <linux/mod_devicetable.h>
#include <linux/platform_device.h>
#include <linux/reset-controller.h>
#include <linux/reboot.h>
#define BITS_PER_HWM_REG …
static const u32 sp_resets[] = …;
struct sp_reset { … };
static inline struct sp_reset *to_sp_reset(struct reset_controller_dev *rcdev)
{ … }
static int sp_reset_update(struct reset_controller_dev *rcdev,
unsigned long id, bool assert)
{ … }
static int sp_reset_assert(struct reset_controller_dev *rcdev,
unsigned long id)
{ … }
static int sp_reset_deassert(struct reset_controller_dev *rcdev,
unsigned long id)
{ … }
static int sp_reset_status(struct reset_controller_dev *rcdev,
unsigned long id)
{ … }
static const struct reset_control_ops sp_reset_ops = …;
static int sp_restart(struct notifier_block *nb, unsigned long mode,
void *cmd)
{ … }
static int sp_reset_probe(struct platform_device *pdev)
{ … }
static const struct of_device_id sp_reset_dt_ids[] = …;
static struct platform_driver sp_reset_driver = …;
builtin_platform_driver(…) …;