162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 262306a36Sopenharmony_ci * 362306a36Sopenharmony_ci * include/asm-sh/cpu-sh4/watchdog.h 462306a36Sopenharmony_ci * 562306a36Sopenharmony_ci * Copyright (C) 2002, 2003 Paul Mundt 662306a36Sopenharmony_ci * Copyright (C) 2009 Siemens AG 762306a36Sopenharmony_ci * Copyright (C) 2009 Sitdikov Valentin 862306a36Sopenharmony_ci */ 962306a36Sopenharmony_ci#ifndef __ASM_CPU_SH4_WATCHDOG_H 1062306a36Sopenharmony_ci#define __ASM_CPU_SH4_WATCHDOG_H 1162306a36Sopenharmony_ci 1262306a36Sopenharmony_ci#if defined(CONFIG_CPU_SUBTYPE_SH7785) || defined(CONFIG_CPU_SUBTYPE_SH7780) 1362306a36Sopenharmony_ci/* Prefix definition */ 1462306a36Sopenharmony_ci#define WTBST_HIGH 0x55 1562306a36Sopenharmony_ci/* Register definitions */ 1662306a36Sopenharmony_ci#define WTCNT_R 0xffcc0010 /*WDTCNT*/ 1762306a36Sopenharmony_ci#define WTCSR 0xffcc0004 /*WDTCSR*/ 1862306a36Sopenharmony_ci#define WTCNT 0xffcc0000 /*WDTST*/ 1962306a36Sopenharmony_ci#define WTST WTCNT 2062306a36Sopenharmony_ci#define WTBST 0xffcc0008 /*WDTBST*/ 2162306a36Sopenharmony_ci/* Register definitions */ 2262306a36Sopenharmony_ci#elif defined(CONFIG_CPU_SUBTYPE_SH7722) || \ 2362306a36Sopenharmony_ci defined(CONFIG_CPU_SUBTYPE_SH7723) || \ 2462306a36Sopenharmony_ci defined(CONFIG_CPU_SUBTYPE_SH7724) 2562306a36Sopenharmony_ci#define WTCNT 0xa4520000 2662306a36Sopenharmony_ci#define WTCSR 0xa4520004 2762306a36Sopenharmony_ci#else 2862306a36Sopenharmony_ci/* Register definitions */ 2962306a36Sopenharmony_ci#define WTCNT 0xffc00008 3062306a36Sopenharmony_ci#define WTCSR 0xffc0000c 3162306a36Sopenharmony_ci#endif 3262306a36Sopenharmony_ci 3362306a36Sopenharmony_ci/* Bit definitions */ 3462306a36Sopenharmony_ci#define WTCSR_TME 0x80 3562306a36Sopenharmony_ci#define WTCSR_WT 0x40 3662306a36Sopenharmony_ci#define WTCSR_RSTS 0x20 3762306a36Sopenharmony_ci#define WTCSR_WOVF 0x10 3862306a36Sopenharmony_ci#define WTCSR_IOVF 0x08 3962306a36Sopenharmony_ci 4062306a36Sopenharmony_ci#endif /* __ASM_CPU_SH4_WATCHDOG_H */ 4162306a36Sopenharmony_ci 42