0001
0002
0003
0004
0005
0006 #ifndef _CCU_RESET_H_
0007 #define _CCU_RESET_H_
0008
0009 #include <linux/reset-controller.h>
0010 #include <linux/spinlock.h>
0011
0012 struct ccu_reset_map {
0013 u16 reg;
0014 u32 bit;
0015 };
0016
0017
0018 struct ccu_reset {
0019 void __iomem *base;
0020 struct ccu_reset_map *reset_map;
0021 spinlock_t *lock;
0022
0023 struct reset_controller_dev rcdev;
0024 };
0025
0026 static inline struct ccu_reset *rcdev_to_ccu_reset(struct reset_controller_dev *rcdev)
0027 {
0028 return container_of(rcdev, struct ccu_reset, rcdev);
0029 }
0030
0031 extern const struct reset_control_ops ccu_reset_ops;
0032
0033 #endif