Merge tag 'extcon-next-for-5.4' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux/fpc-iii.git] / drivers / clk / sunxi-ng / ccu_reset.h
blobe9b973cae4af9a2c0c5eb5915ccc3537ab512506
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3 * Copyright (c) 2016 Maxime Ripard. All rights reserved.
4 */
6 #ifndef _CCU_RESET_H_
7 #define _CCU_RESET_H_
9 #include <linux/reset-controller.h>
10 #include <linux/spinlock.h>
12 struct ccu_reset_map {
13 u16 reg;
14 u32 bit;
18 struct ccu_reset {
19 void __iomem *base;
20 struct ccu_reset_map *reset_map;
21 spinlock_t *lock;
23 struct reset_controller_dev rcdev;
26 static inline struct ccu_reset *rcdev_to_ccu_reset(struct reset_controller_dev *rcdev)
28 return container_of(rcdev, struct ccu_reset, rcdev);
31 extern const struct reset_control_ops ccu_reset_ops;
33 #endif /* _CCU_RESET_H_ */