1 /*
2  * Arm SCP/MCP Software
3  * Copyright (c) 2022, Arm Limited and Contributors. All rights reserved.
4  *
5  * SPDX-License-Identifier: BSD-3-Clause
6  */
7 
8 #ifndef BOOTCTL_REG_H
9 #define BOOTCTL_REG_H
10 
11 #include <fwk_macros.h>
12 
13 #include <stdint.h>
14 
15 struct bootctl_reg {
16     FWK_RW uint32_t BOOT_REMAP;
17            uint32_t RESERVED1;
18     FWK_RW uint32_t BOOT_HSSPI;
19            uint32_t RESERVED2[2];
20     FWK_R uint32_t BOOT_MODE;
21 };
22 
23 /* BOOT_HSSPI register field */
24 #define ADRDEC_HSSPIx(val, bs) (((val)&0x1) << (bs))
25 #define ADRDEC_HSSPIx_MASK(bs) ADRDEC_HSSPIx(1, bs)
26 #define CMDSEL_HSSPIx(val, bs) (((val)&0x1) << (bs))
27 #define CMDSEL_HSSPIx_MASK(bs) CMDSEL_HSSPIx(1, bs)
28 #define ADRDEC_HSSPI1_BIT      0
29 #define CMDSEL_HSSPI1_BIT      1
30 #define ADRDEC_HSSPI2_BIT      4
31 #define CMDSEL_HSSPI2_BIT      5
32 #define HSEL_BMEM              0
33 #define HSEL_MEM               1
34 #define QUAD_READ_MODE         0
35 #define FAST_READ_MODE         1
36 
37 #endif /* BOOTCTL_REG_H */
38