162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 262306a36Sopenharmony_ci#ifndef __ASM_ARCH_RESET_H 362306a36Sopenharmony_ci#define __ASM_ARCH_RESET_H 462306a36Sopenharmony_ci 562306a36Sopenharmony_ci#define RESET_STATUS_HARDWARE (1 << 0) /* Hardware Reset */ 662306a36Sopenharmony_ci#define RESET_STATUS_WATCHDOG (1 << 1) /* Watchdog Reset */ 762306a36Sopenharmony_ci#define RESET_STATUS_LOWPOWER (1 << 2) /* Low Power/Sleep Exit */ 862306a36Sopenharmony_ci#define RESET_STATUS_GPIO (1 << 3) /* GPIO Reset */ 962306a36Sopenharmony_ci#define RESET_STATUS_ALL (0xf) 1062306a36Sopenharmony_ci 1162306a36Sopenharmony_ciextern void clear_reset_status(unsigned int mask); 1262306a36Sopenharmony_ciextern void pxa_register_wdt(unsigned int reset_status); 1362306a36Sopenharmony_ci 1462306a36Sopenharmony_ci/** 1562306a36Sopenharmony_ci * init_gpio_reset() - register GPIO as reset generator 1662306a36Sopenharmony_ci * @gpio: gpio nr 1762306a36Sopenharmony_ci * @output: set gpio as output instead of input during normal work 1862306a36Sopenharmony_ci * @level: output level 1962306a36Sopenharmony_ci */ 2062306a36Sopenharmony_ciextern int init_gpio_reset(int gpio, int output, int level); 2162306a36Sopenharmony_ci 2262306a36Sopenharmony_ci#endif /* __ASM_ARCH_RESET_H */ 23