1c38ae95cSJerome Brunet /* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ 2c38ae95cSJerome Brunet /* 3c38ae95cSJerome Brunet * Copyright (c) 2024 BayLibre, SAS. 4c38ae95cSJerome Brunet * Author: Jerome Brunet <jbrunet@baylibre.com> 5c38ae95cSJerome Brunet */ 6c38ae95cSJerome Brunet 7c38ae95cSJerome Brunet #ifndef __MESON_RESET_H 8c38ae95cSJerome Brunet #define __MESON_RESET_H 9c38ae95cSJerome Brunet 10c38ae95cSJerome Brunet #include <linux/module.h> 11c38ae95cSJerome Brunet #include <linux/regmap.h> 12c38ae95cSJerome Brunet #include <linux/reset-controller.h> 13c38ae95cSJerome Brunet 14c38ae95cSJerome Brunet struct meson_reset_param { 15*fb4c3158SJerome Brunet const struct reset_control_ops *reset_ops; 16c38ae95cSJerome Brunet unsigned int reset_num; 17c38ae95cSJerome Brunet unsigned int reset_offset; 18c38ae95cSJerome Brunet unsigned int level_offset; 19c38ae95cSJerome Brunet bool level_low_reset; 20c38ae95cSJerome Brunet }; 21c38ae95cSJerome Brunet 22c38ae95cSJerome Brunet int meson_reset_controller_register(struct device *dev, struct regmap *map, 23c38ae95cSJerome Brunet const struct meson_reset_param *param); 24c38ae95cSJerome Brunet 25*fb4c3158SJerome Brunet extern const struct reset_control_ops meson_reset_ops; 26*fb4c3158SJerome Brunet extern const struct reset_control_ops meson_reset_toggle_ops; 27*fb4c3158SJerome Brunet 28c38ae95cSJerome Brunet #endif /* __MESON_RESET_H */ 29