Michal Simek | 04b7e62 | 2015-01-15 10:01:51 +0100 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2014 - 2015 Xilinx, Inc. |
| 3 | * Michal Simek <michal.simek@xilinx.com> |
| 4 | * |
| 5 | * SPDX-License-Identifier: GPL-2.0+ |
| 6 | */ |
| 7 | |
| 8 | #ifndef _ASM_ARCH_SYS_PROTO_H |
| 9 | #define _ASM_ARCH_SYS_PROTO_H |
| 10 | |
Siva Durga Prasad Paladugu | 0e39bd7 | 2017-02-02 01:10:46 +0530 | [diff] [blame] | 11 | #define PAYLOAD_ARG_CNT 5 |
| 12 | |
Siva Durga Prasad Paladugu | 9f0a8e9 | 2017-07-25 11:51:36 +0530 | [diff] [blame] | 13 | #define ZYNQMP_CSU_SILICON_VER_MASK 0xF |
Siva Durga Prasad Paladugu | b1acb65 | 2018-02-28 13:26:53 +0530 | [diff] [blame^] | 14 | #define ZYNQMP_SIP_SVC_PM_SECURE_IMG_LOAD 0xC200002D |
| 15 | #define KEY_PTR_LEN 32 |
Siva Durga Prasad Paladugu | 9f0a8e9 | 2017-07-25 11:51:36 +0530 | [diff] [blame] | 16 | |
| 17 | enum { |
| 18 | IDCODE, |
| 19 | VERSION, |
Michal Simek | 50d8cef | 2017-08-22 14:58:53 +0200 | [diff] [blame] | 20 | IDCODE2, |
Siva Durga Prasad Paladugu | 9f0a8e9 | 2017-07-25 11:51:36 +0530 | [diff] [blame] | 21 | }; |
| 22 | |
| 23 | enum { |
| 24 | ZYNQMP_SILICON_V1, |
| 25 | ZYNQMP_SILICON_V2, |
| 26 | ZYNQMP_SILICON_V3, |
| 27 | ZYNQMP_SILICON_V4, |
| 28 | }; |
| 29 | |
Siva Durga Prasad Paladugu | 5e2a907 | 2017-07-13 19:01:09 +0530 | [diff] [blame] | 30 | enum { |
| 31 | TCM_LOCK, |
| 32 | TCM_SPLIT, |
| 33 | }; |
| 34 | |
Michal Simek | 44dd520 | 2017-07-31 10:37:09 +0200 | [diff] [blame] | 35 | int zynq_board_read_rom_ethaddr(unsigned char *ethaddr); |
Michal Simek | 04b7e62 | 2015-01-15 10:01:51 +0100 | [diff] [blame] | 36 | unsigned int zynqmp_get_silicon_version(void); |
| 37 | |
Michal Simek | 456e454 | 2017-01-09 10:05:16 +0100 | [diff] [blame] | 38 | void handoff_setup(void); |
| 39 | |
Michal Simek | 8b35330 | 2017-02-07 14:32:26 +0100 | [diff] [blame] | 40 | void zynqmp_pmufw_version(void); |
Siva Durga Prasad Paladugu | 0e39bd7 | 2017-02-02 01:10:46 +0530 | [diff] [blame] | 41 | int zynqmp_mmio_write(const u32 address, const u32 mask, const u32 value); |
| 42 | int zynqmp_mmio_read(const u32 address, u32 *value); |
| 43 | int invoke_smc(u32 pm_api_id, u32 arg0, u32 arg1, u32 arg2, u32 arg3, |
| 44 | u32 *ret_payload); |
| 45 | |
Siva Durga Prasad Paladugu | 5e2a907 | 2017-07-13 19:01:09 +0530 | [diff] [blame] | 46 | void initialize_tcm(bool mode); |
| 47 | |
Siva Durga Prasad Paladugu | cd35d52 | 2017-07-25 11:51:38 +0530 | [diff] [blame] | 48 | int chip_id(unsigned char id); |
| 49 | |
Michal Simek | 04b7e62 | 2015-01-15 10:01:51 +0100 | [diff] [blame] | 50 | #endif /* _ASM_ARCH_SYS_PROTO_H */ |