blob: 3e9547682833c25cfd2e5c5c0c48f49c05a570ed [file] [log] [blame]
Dinh Nguyenad51f7c2012-10-04 06:46:02 +00001/*
2 * Copyright (C) 2012 Altera Corporation <www.altera.com>
3 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02004 * SPDX-License-Identifier: GPL-2.0+
Dinh Nguyenad51f7c2012-10-04 06:46:02 +00005 */
6
7#ifndef _RESET_MANAGER_H_
8#define _RESET_MANAGER_H_
9
10void reset_cpu(ulong addr);
11void reset_deassert_peripherals_handoff(void);
12
13struct socfpga_reset_manager {
Chin Liang See1922dad2013-08-07 10:08:03 -050014 u32 status;
Dinh Nguyenad51f7c2012-10-04 06:46:02 +000015 u32 ctrl;
Chin Liang See1922dad2013-08-07 10:08:03 -050016 u32 counts;
17 u32 padding1;
Dinh Nguyenad51f7c2012-10-04 06:46:02 +000018 u32 mpu_mod_reset;
19 u32 per_mod_reset;
20 u32 per2_mod_reset;
21 u32 brg_mod_reset;
22};
23
Chin Liang See1922dad2013-08-07 10:08:03 -050024#if defined(CONFIG_SOCFPGA_VIRTUAL_TARGET)
25#define RSTMGR_CTRL_SWWARMRSTREQ_LSB 2
26#else
Dinh Nguyenad51f7c2012-10-04 06:46:02 +000027#define RSTMGR_CTRL_SWWARMRSTREQ_LSB 1
Chin Liang See1922dad2013-08-07 10:08:03 -050028#endif
Dinh Nguyenad51f7c2012-10-04 06:46:02 +000029
30#endif /* _RESET_MANAGER_H_ */