18c1c0a1bSFrancisco Iglesias /* 28c1c0a1bSFrancisco Iglesias * QEMU model of Versal's PMC IOU SLCR (system level control registers) 38c1c0a1bSFrancisco Iglesias * 48c1c0a1bSFrancisco Iglesias * Copyright (c) 2021 Xilinx Inc. 58c1c0a1bSFrancisco Iglesias * Written by Edgar E. Iglesias <edgar.iglesias@xilinx.com> 68c1c0a1bSFrancisco Iglesias * 78c1c0a1bSFrancisco Iglesias * Permission is hereby granted, free of charge, to any person obtaining a copy 88c1c0a1bSFrancisco Iglesias * of this software and associated documentation files (the "Software"), to deal 98c1c0a1bSFrancisco Iglesias * in the Software without restriction, including without limitation the rights 108c1c0a1bSFrancisco Iglesias * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 118c1c0a1bSFrancisco Iglesias * copies of the Software, and to permit persons to whom the Software is 128c1c0a1bSFrancisco Iglesias * furnished to do so, subject to the following conditions: 138c1c0a1bSFrancisco Iglesias * 148c1c0a1bSFrancisco Iglesias * The above copyright notice and this permission notice shall be included in 158c1c0a1bSFrancisco Iglesias * all copies or substantial portions of the Software. 168c1c0a1bSFrancisco Iglesias * 178c1c0a1bSFrancisco Iglesias * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 188c1c0a1bSFrancisco Iglesias * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 198c1c0a1bSFrancisco Iglesias * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 208c1c0a1bSFrancisco Iglesias * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 218c1c0a1bSFrancisco Iglesias * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 228c1c0a1bSFrancisco Iglesias * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 238c1c0a1bSFrancisco Iglesias * THE SOFTWARE. 248c1c0a1bSFrancisco Iglesias */ 258c1c0a1bSFrancisco Iglesias 268c1c0a1bSFrancisco Iglesias #include "qemu/osdep.h" 278c1c0a1bSFrancisco Iglesias #include "hw/sysbus.h" 288c1c0a1bSFrancisco Iglesias #include "hw/register.h" 298c1c0a1bSFrancisco Iglesias #include "hw/irq.h" 308c1c0a1bSFrancisco Iglesias #include "qemu/bitops.h" 318c1c0a1bSFrancisco Iglesias #include "qemu/log.h" 328c1c0a1bSFrancisco Iglesias #include "migration/vmstate.h" 338c1c0a1bSFrancisco Iglesias #include "hw/qdev-properties.h" 348c1c0a1bSFrancisco Iglesias #include "hw/misc/xlnx-versal-pmc-iou-slcr.h" 358c1c0a1bSFrancisco Iglesias 368c1c0a1bSFrancisco Iglesias #ifndef XILINX_VERSAL_PMC_IOU_SLCR_ERR_DEBUG 378c1c0a1bSFrancisco Iglesias #define XILINX_VERSAL_PMC_IOU_SLCR_ERR_DEBUG 0 388c1c0a1bSFrancisco Iglesias #endif 398c1c0a1bSFrancisco Iglesias 408c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_0, 0x0) 418c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_0, L3_SEL, 7, 3) 428c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_0, L2_SEL, 5, 2) 438c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_0, L1_SEL, 3, 2) 448c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_0, L0_SEL, 1, 2) 458c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_1, 0x4) 468c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_1, L3_SEL, 7, 3) 478c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_1, L2_SEL, 5, 2) 488c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_1, L1_SEL, 3, 2) 498c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_1, L0_SEL, 1, 2) 508c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_2, 0x8) 518c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_2, L3_SEL, 7, 3) 528c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_2, L2_SEL, 5, 2) 538c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_2, L1_SEL, 3, 2) 548c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_2, L0_SEL, 1, 2) 558c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_3, 0xc) 568c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_3, L3_SEL, 7, 3) 578c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_3, L2_SEL, 5, 2) 588c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_3, L1_SEL, 3, 2) 598c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_3, L0_SEL, 1, 2) 608c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_4, 0x10) 618c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_4, L3_SEL, 7, 3) 628c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_4, L2_SEL, 5, 2) 638c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_4, L1_SEL, 3, 2) 648c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_4, L0_SEL, 1, 2) 658c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_5, 0x14) 668c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_5, L3_SEL, 7, 3) 678c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_5, L2_SEL, 5, 2) 688c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_5, L1_SEL, 3, 2) 698c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_5, L0_SEL, 1, 2) 708c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_6, 0x18) 718c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_6, L3_SEL, 7, 3) 728c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_6, L2_SEL, 5, 2) 738c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_6, L1_SEL, 3, 2) 748c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_6, L0_SEL, 1, 2) 758c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_7, 0x1c) 768c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_7, L3_SEL, 7, 3) 778c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_7, L2_SEL, 5, 2) 788c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_7, L1_SEL, 3, 2) 798c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_7, L0_SEL, 1, 2) 808c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_8, 0x20) 818c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_8, L3_SEL, 7, 3) 828c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_8, L2_SEL, 5, 2) 838c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_8, L1_SEL, 3, 2) 848c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_8, L0_SEL, 1, 2) 858c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_9, 0x24) 868c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_9, L3_SEL, 7, 3) 878c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_9, L2_SEL, 5, 2) 888c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_9, L1_SEL, 3, 2) 898c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_9, L0_SEL, 1, 2) 908c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_10, 0x28) 918c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_10, L3_SEL, 7, 3) 928c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_10, L2_SEL, 5, 2) 938c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_10, L1_SEL, 3, 2) 948c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_10, L0_SEL, 1, 2) 958c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_11, 0x2c) 968c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_11, L3_SEL, 7, 3) 978c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_11, L2_SEL, 5, 2) 988c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_11, L1_SEL, 3, 2) 998c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_11, L0_SEL, 1, 2) 1008c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_12, 0x30) 1018c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_12, L3_SEL, 7, 3) 1028c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_12, L2_SEL, 5, 2) 1038c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_12, L1_SEL, 3, 2) 1048c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_12, L0_SEL, 1, 2) 1058c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_13, 0x34) 1068c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_13, L3_SEL, 7, 3) 1078c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_13, L2_SEL, 5, 2) 1088c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_13, L1_SEL, 3, 2) 1098c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_13, L0_SEL, 1, 2) 1108c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_14, 0x38) 1118c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_14, L3_SEL, 7, 3) 1128c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_14, L2_SEL, 5, 2) 1138c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_14, L1_SEL, 3, 2) 1148c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_14, L0_SEL, 1, 2) 1158c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_15, 0x3c) 1168c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_15, L3_SEL, 7, 3) 1178c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_15, L2_SEL, 5, 2) 1188c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_15, L1_SEL, 3, 2) 1198c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_15, L0_SEL, 1, 2) 1208c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_16, 0x40) 1218c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_16, L3_SEL, 7, 3) 1228c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_16, L2_SEL, 5, 2) 1238c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_16, L1_SEL, 3, 2) 1248c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_16, L0_SEL, 1, 2) 1258c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_17, 0x44) 1268c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_17, L3_SEL, 7, 3) 1278c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_17, L2_SEL, 5, 2) 1288c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_17, L1_SEL, 3, 2) 1298c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_17, L0_SEL, 1, 2) 1308c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_18, 0x48) 1318c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_18, L3_SEL, 7, 3) 1328c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_18, L2_SEL, 5, 2) 1338c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_18, L1_SEL, 3, 2) 1348c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_18, L0_SEL, 1, 2) 1358c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_19, 0x4c) 1368c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_19, L3_SEL, 7, 3) 1378c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_19, L2_SEL, 5, 2) 1388c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_19, L1_SEL, 3, 2) 1398c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_19, L0_SEL, 1, 2) 1408c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_20, 0x50) 1418c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_20, L3_SEL, 7, 3) 1428c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_20, L2_SEL, 5, 2) 1438c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_20, L1_SEL, 3, 2) 1448c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_20, L0_SEL, 1, 2) 1458c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_21, 0x54) 1468c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_21, L3_SEL, 7, 3) 1478c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_21, L2_SEL, 5, 2) 1488c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_21, L1_SEL, 3, 2) 1498c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_21, L0_SEL, 1, 2) 1508c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_22, 0x58) 1518c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_22, L3_SEL, 7, 3) 1528c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_22, L2_SEL, 5, 2) 1538c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_22, L1_SEL, 3, 2) 1548c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_22, L0_SEL, 1, 2) 1558c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_23, 0x5c) 1568c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_23, L3_SEL, 7, 3) 1578c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_23, L2_SEL, 5, 2) 1588c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_23, L1_SEL, 3, 2) 1598c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_23, L0_SEL, 1, 2) 1608c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_24, 0x60) 1618c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_24, L3_SEL, 7, 3) 1628c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_24, L2_SEL, 5, 2) 1638c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_24, L1_SEL, 3, 2) 1648c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_24, L0_SEL, 1, 2) 1658c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_25, 0x64) 1668c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_25, L3_SEL, 7, 3) 1678c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_25, L2_SEL, 5, 2) 1688c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_25, L1_SEL, 3, 2) 1698c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_25, L0_SEL, 1, 2) 1708c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_26, 0x68) 1718c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_26, L3_SEL, 7, 3) 1728c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_26, L2_SEL, 5, 2) 1738c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_26, L1_SEL, 3, 2) 1748c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_26, L0_SEL, 1, 2) 1758c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_27, 0x6c) 1768c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_27, L3_SEL, 7, 3) 1778c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_27, L2_SEL, 5, 2) 1788c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_27, L1_SEL, 3, 2) 1798c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_27, L0_SEL, 1, 2) 1808c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_28, 0x70) 1818c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_28, L3_SEL, 7, 3) 1828c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_28, L2_SEL, 5, 2) 1838c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_28, L1_SEL, 3, 2) 1848c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_28, L0_SEL, 1, 2) 1858c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_29, 0x74) 1868c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_29, L3_SEL, 7, 3) 1878c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_29, L2_SEL, 5, 2) 1888c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_29, L1_SEL, 3, 2) 1898c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_29, L0_SEL, 1, 2) 1908c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_30, 0x78) 1918c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_30, L3_SEL, 7, 3) 1928c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_30, L2_SEL, 5, 2) 1938c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_30, L1_SEL, 3, 2) 1948c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_30, L0_SEL, 1, 2) 1958c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_31, 0x7c) 1968c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_31, L3_SEL, 7, 3) 1978c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_31, L2_SEL, 5, 2) 1988c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_31, L1_SEL, 3, 2) 1998c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_31, L0_SEL, 1, 2) 2008c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_32, 0x80) 2018c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_32, L3_SEL, 7, 3) 2028c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_32, L2_SEL, 5, 2) 2038c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_32, L1_SEL, 3, 2) 2048c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_32, L0_SEL, 1, 2) 2058c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_33, 0x84) 2068c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_33, L3_SEL, 7, 3) 2078c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_33, L2_SEL, 5, 2) 2088c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_33, L1_SEL, 3, 2) 2098c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_33, L0_SEL, 1, 2) 2108c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_34, 0x88) 2118c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_34, L3_SEL, 7, 3) 2128c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_34, L2_SEL, 5, 2) 2138c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_34, L1_SEL, 3, 2) 2148c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_34, L0_SEL, 1, 2) 2158c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_35, 0x8c) 2168c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_35, L3_SEL, 7, 3) 2178c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_35, L2_SEL, 5, 2) 2188c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_35, L1_SEL, 3, 2) 2198c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_35, L0_SEL, 1, 2) 2208c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_36, 0x90) 2218c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_36, L3_SEL, 7, 3) 2228c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_36, L2_SEL, 5, 2) 2238c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_36, L1_SEL, 3, 2) 2248c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_36, L0_SEL, 1, 2) 2258c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_37, 0x94) 2268c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_37, L3_SEL, 7, 3) 2278c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_37, L2_SEL, 5, 2) 2288c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_37, L1_SEL, 3, 2) 2298c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_37, L0_SEL, 1, 2) 2308c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_38, 0x98) 2318c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_38, L3_SEL, 7, 3) 2328c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_38, L2_SEL, 5, 2) 2338c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_38, L1_SEL, 3, 2) 2348c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_38, L0_SEL, 1, 2) 2358c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_39, 0x9c) 2368c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_39, L3_SEL, 7, 3) 2378c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_39, L2_SEL, 5, 2) 2388c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_39, L1_SEL, 3, 2) 2398c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_39, L0_SEL, 1, 2) 2408c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_40, 0xa0) 2418c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_40, L3_SEL, 7, 3) 2428c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_40, L2_SEL, 5, 2) 2438c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_40, L1_SEL, 3, 2) 2448c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_40, L0_SEL, 1, 2) 2458c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_41, 0xa4) 2468c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_41, L3_SEL, 7, 3) 2478c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_41, L2_SEL, 5, 2) 2488c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_41, L1_SEL, 3, 2) 2498c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_41, L0_SEL, 1, 2) 2508c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_42, 0xa8) 2518c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_42, L3_SEL, 7, 3) 2528c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_42, L2_SEL, 5, 2) 2538c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_42, L1_SEL, 3, 2) 2548c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_42, L0_SEL, 1, 2) 2558c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_43, 0xac) 2568c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_43, L3_SEL, 7, 3) 2578c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_43, L2_SEL, 5, 2) 2588c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_43, L1_SEL, 3, 2) 2598c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_43, L0_SEL, 1, 2) 2608c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_44, 0xb0) 2618c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_44, L3_SEL, 7, 3) 2628c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_44, L2_SEL, 5, 2) 2638c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_44, L1_SEL, 3, 2) 2648c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_44, L0_SEL, 1, 2) 2658c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_45, 0xb4) 2668c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_45, L3_SEL, 7, 3) 2678c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_45, L2_SEL, 5, 2) 2688c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_45, L1_SEL, 3, 2) 2698c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_45, L0_SEL, 1, 2) 2708c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_46, 0xb8) 2718c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_46, L3_SEL, 7, 3) 2728c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_46, L2_SEL, 5, 2) 2738c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_46, L1_SEL, 3, 2) 2748c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_46, L0_SEL, 1, 2) 2758c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_47, 0xbc) 2768c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_47, L3_SEL, 7, 3) 2778c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_47, L2_SEL, 5, 2) 2788c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_47, L1_SEL, 3, 2) 2798c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_47, L0_SEL, 1, 2) 2808c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_48, 0xc0) 2818c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_48, L3_SEL, 7, 3) 2828c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_48, L2_SEL, 5, 2) 2838c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_48, L1_SEL, 3, 2) 2848c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_48, L0_SEL, 1, 2) 2858c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_49, 0xc4) 2868c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_49, L3_SEL, 7, 3) 2878c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_49, L2_SEL, 5, 2) 2888c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_49, L1_SEL, 3, 2) 2898c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_49, L0_SEL, 1, 2) 2908c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_50, 0xc8) 2918c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_50, L3_SEL, 7, 3) 2928c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_50, L2_SEL, 5, 2) 2938c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_50, L1_SEL, 3, 2) 2948c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_50, L0_SEL, 1, 2) 2958c1c0a1bSFrancisco Iglesias REG32(MIO_PIN_51, 0xcc) 2968c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_51, L3_SEL, 7, 3) 2978c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_51, L2_SEL, 5, 2) 2988c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_51, L1_SEL, 3, 2) 2998c1c0a1bSFrancisco Iglesias FIELD(MIO_PIN_51, L0_SEL, 1, 2) 3008c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_RX, 0x100) 3018c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_RX, BNK0_EN_RX, 0, 26) 3028c1c0a1bSFrancisco Iglesias REG32(BNK0_SEL_RX0, 0x104) 3038c1c0a1bSFrancisco Iglesias REG32(BNK0_SEL_RX1, 0x108) 3048c1c0a1bSFrancisco Iglesias FIELD(BNK0_SEL_RX1, BNK0_SEL_RX, 0, 20) 3058c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_RX_SCHMITT_HYST, 0x10c) 3068c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_RX_SCHMITT_HYST, BNK0_EN_RX_SCHMITT_HYST, 0, 26) 3078c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_WK_PD, 0x110) 3088c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_WK_PD, BNK0_EN_WK_PD, 0, 26) 3098c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_WK_PU, 0x114) 3108c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_WK_PU, BNK0_EN_WK_PU, 0, 26) 3118c1c0a1bSFrancisco Iglesias REG32(BNK0_SEL_DRV0, 0x118) 3128c1c0a1bSFrancisco Iglesias REG32(BNK0_SEL_DRV1, 0x11c) 3138c1c0a1bSFrancisco Iglesias FIELD(BNK0_SEL_DRV1, BNK0_SEL_DRV, 0, 20) 3148c1c0a1bSFrancisco Iglesias REG32(BNK0_SEL_SLEW, 0x120) 3158c1c0a1bSFrancisco Iglesias FIELD(BNK0_SEL_SLEW, BNK0_SEL_SLEW, 0, 26) 3168c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_DFT_OPT_INV, 0x124) 3178c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_DFT_OPT_INV, BNK0_EN_DFT_OPT_INV, 0, 26) 3188c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_PAD2PAD_LOOPBACK, 0x128) 3198c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_PAD2PAD_LOOPBACK, BNK0_EN_PAD2PAD_LOOPBACK, 0, 13) 3208c1c0a1bSFrancisco Iglesias REG32(BNK0_RX_SPARE0, 0x12c) 3218c1c0a1bSFrancisco Iglesias REG32(BNK0_RX_SPARE1, 0x130) 3228c1c0a1bSFrancisco Iglesias FIELD(BNK0_RX_SPARE1, BNK0_RX_SPARE, 0, 20) 3238c1c0a1bSFrancisco Iglesias REG32(BNK0_TX_SPARE0, 0x134) 3248c1c0a1bSFrancisco Iglesias REG32(BNK0_TX_SPARE1, 0x138) 3258c1c0a1bSFrancisco Iglesias FIELD(BNK0_TX_SPARE1, BNK0_TX_SPARE, 0, 20) 3268c1c0a1bSFrancisco Iglesias REG32(BNK0_SEL_EN1P8, 0x13c) 3278c1c0a1bSFrancisco Iglesias FIELD(BNK0_SEL_EN1P8, BNK0_SEL_EN1P8, 0, 1) 3288c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_B_POR_DETECT, 0x140) 3298c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_B_POR_DETECT, BNK0_EN_B_POR_DETECT, 0, 1) 3308c1c0a1bSFrancisco Iglesias REG32(BNK0_LPF_BYP_POR_DETECT, 0x144) 3318c1c0a1bSFrancisco Iglesias FIELD(BNK0_LPF_BYP_POR_DETECT, BNK0_LPF_BYP_POR_DETECT, 0, 1) 3328c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_LATCH, 0x148) 3338c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_LATCH, BNK0_EN_LATCH, 0, 1) 3348c1c0a1bSFrancisco Iglesias REG32(BNK0_VBG_LPF_BYP_B, 0x14c) 3358c1c0a1bSFrancisco Iglesias FIELD(BNK0_VBG_LPF_BYP_B, BNK0_VBG_LPF_BYP_B, 0, 1) 3368c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_AMP_B, 0x150) 3378c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_AMP_B, BNK0_EN_AMP_B, 0, 2) 3388c1c0a1bSFrancisco Iglesias REG32(BNK0_SPARE_BIAS, 0x154) 3398c1c0a1bSFrancisco Iglesias FIELD(BNK0_SPARE_BIAS, BNK0_SPARE_BIAS, 0, 4) 3408c1c0a1bSFrancisco Iglesias REG32(BNK0_DRIVER_BIAS, 0x158) 3418c1c0a1bSFrancisco Iglesias FIELD(BNK0_DRIVER_BIAS, BNK0_DRIVER_BIAS, 0, 15) 3428c1c0a1bSFrancisco Iglesias REG32(BNK0_VMODE, 0x15c) 3438c1c0a1bSFrancisco Iglesias FIELD(BNK0_VMODE, BNK0_VMODE, 0, 1) 3448c1c0a1bSFrancisco Iglesias REG32(BNK0_SEL_AUX_IO_RX, 0x160) 3458c1c0a1bSFrancisco Iglesias FIELD(BNK0_SEL_AUX_IO_RX, BNK0_SEL_AUX_IO_RX, 0, 26) 3468c1c0a1bSFrancisco Iglesias REG32(BNK0_EN_TX_HS_MODE, 0x164) 3478c1c0a1bSFrancisco Iglesias FIELD(BNK0_EN_TX_HS_MODE, BNK0_EN_TX_HS_MODE, 0, 26) 3488c1c0a1bSFrancisco Iglesias REG32(MIO_MST_TRI0, 0x200) 3498c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_25_TRI, 25, 1) 3508c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_24_TRI, 24, 1) 3518c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_23_TRI, 23, 1) 3528c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_22_TRI, 22, 1) 3538c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_21_TRI, 21, 1) 3548c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_20_TRI, 20, 1) 3558c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_19_TRI, 19, 1) 3568c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_18_TRI, 18, 1) 3578c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_17_TRI, 17, 1) 3588c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_16_TRI, 16, 1) 3598c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_15_TRI, 15, 1) 3608c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_14_TRI, 14, 1) 3618c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_13_TRI, 13, 1) 3628c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_12_TRI, 12, 1) 3638c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_11_TRI, 11, 1) 3648c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_10_TRI, 10, 1) 3658c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_09_TRI, 9, 1) 3668c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_08_TRI, 8, 1) 3678c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_07_TRI, 7, 1) 3688c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_06_TRI, 6, 1) 3698c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_05_TRI, 5, 1) 3708c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_04_TRI, 4, 1) 3718c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_03_TRI, 3, 1) 3728c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_02_TRI, 2, 1) 3738c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_01_TRI, 1, 1) 3748c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI0, PIN_00_TRI, 0, 1) 3758c1c0a1bSFrancisco Iglesias REG32(MIO_MST_TRI1, 0x204) 3768c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_51_TRI, 25, 1) 3778c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_50_TRI, 24, 1) 3788c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_49_TRI, 23, 1) 3798c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_48_TRI, 22, 1) 3808c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_47_TRI, 21, 1) 3818c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_46_TRI, 20, 1) 3828c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_45_TRI, 19, 1) 3838c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_44_TRI, 18, 1) 3848c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_43_TRI, 17, 1) 3858c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_42_TRI, 16, 1) 3868c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_41_TRI, 15, 1) 3878c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_40_TRI, 14, 1) 3888c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_39_TRI, 13, 1) 3898c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_38_TRI, 12, 1) 3908c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_37_TRI, 11, 1) 3918c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_36_TRI, 10, 1) 3928c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_35_TRI, 9, 1) 3938c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_34_TRI, 8, 1) 3948c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_33_TRI, 7, 1) 3958c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_32_TRI, 6, 1) 3968c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_31_TRI, 5, 1) 3978c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_30_TRI, 4, 1) 3988c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_29_TRI, 3, 1) 3998c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_28_TRI, 2, 1) 4008c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_27_TRI, 1, 1) 4018c1c0a1bSFrancisco Iglesias FIELD(MIO_MST_TRI1, PIN_26_TRI, 0, 1) 4028c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_RX, 0x300) 4038c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_RX, BNK1_EN_RX, 0, 26) 4048c1c0a1bSFrancisco Iglesias REG32(BNK1_SEL_RX0, 0x304) 4058c1c0a1bSFrancisco Iglesias REG32(BNK1_SEL_RX1, 0x308) 4068c1c0a1bSFrancisco Iglesias FIELD(BNK1_SEL_RX1, BNK1_SEL_RX, 0, 20) 4078c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_RX_SCHMITT_HYST, 0x30c) 4088c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_RX_SCHMITT_HYST, BNK1_EN_RX_SCHMITT_HYST, 0, 26) 4098c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_WK_PD, 0x310) 4108c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_WK_PD, BNK1_EN_WK_PD, 0, 26) 4118c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_WK_PU, 0x314) 4128c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_WK_PU, BNK1_EN_WK_PU, 0, 26) 4138c1c0a1bSFrancisco Iglesias REG32(BNK1_SEL_DRV0, 0x318) 4148c1c0a1bSFrancisco Iglesias REG32(BNK1_SEL_DRV1, 0x31c) 4158c1c0a1bSFrancisco Iglesias FIELD(BNK1_SEL_DRV1, BNK1_SEL_DRV, 0, 20) 4168c1c0a1bSFrancisco Iglesias REG32(BNK1_SEL_SLEW, 0x320) 4178c1c0a1bSFrancisco Iglesias FIELD(BNK1_SEL_SLEW, BNK1_SEL_SLEW, 0, 26) 4188c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_DFT_OPT_INV, 0x324) 4198c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_DFT_OPT_INV, BNK1_EN_DFT_OPT_INV, 0, 26) 4208c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_PAD2PAD_LOOPBACK, 0x328) 4218c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_PAD2PAD_LOOPBACK, BNK1_EN_PAD2PAD_LOOPBACK, 0, 13) 4228c1c0a1bSFrancisco Iglesias REG32(BNK1_RX_SPARE0, 0x32c) 4238c1c0a1bSFrancisco Iglesias REG32(BNK1_RX_SPARE1, 0x330) 4248c1c0a1bSFrancisco Iglesias FIELD(BNK1_RX_SPARE1, BNK1_RX_SPARE, 0, 20) 4258c1c0a1bSFrancisco Iglesias REG32(BNK1_TX_SPARE0, 0x334) 4268c1c0a1bSFrancisco Iglesias REG32(BNK1_TX_SPARE1, 0x338) 4278c1c0a1bSFrancisco Iglesias FIELD(BNK1_TX_SPARE1, BNK1_TX_SPARE, 0, 20) 4288c1c0a1bSFrancisco Iglesias REG32(BNK1_SEL_EN1P8, 0x33c) 4298c1c0a1bSFrancisco Iglesias FIELD(BNK1_SEL_EN1P8, BNK1_SEL_EN1P8, 0, 1) 4308c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_B_POR_DETECT, 0x340) 4318c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_B_POR_DETECT, BNK1_EN_B_POR_DETECT, 0, 1) 4328c1c0a1bSFrancisco Iglesias REG32(BNK1_LPF_BYP_POR_DETECT, 0x344) 4338c1c0a1bSFrancisco Iglesias FIELD(BNK1_LPF_BYP_POR_DETECT, BNK1_LPF_BYP_POR_DETECT, 0, 1) 4348c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_LATCH, 0x348) 4358c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_LATCH, BNK1_EN_LATCH, 0, 1) 4368c1c0a1bSFrancisco Iglesias REG32(BNK1_VBG_LPF_BYP_B, 0x34c) 4378c1c0a1bSFrancisco Iglesias FIELD(BNK1_VBG_LPF_BYP_B, BNK1_VBG_LPF_BYP_B, 0, 1) 4388c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_AMP_B, 0x350) 4398c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_AMP_B, BNK1_EN_AMP_B, 0, 2) 4408c1c0a1bSFrancisco Iglesias REG32(BNK1_SPARE_BIAS, 0x354) 4418c1c0a1bSFrancisco Iglesias FIELD(BNK1_SPARE_BIAS, BNK1_SPARE_BIAS, 0, 4) 4428c1c0a1bSFrancisco Iglesias REG32(BNK1_DRIVER_BIAS, 0x358) 4438c1c0a1bSFrancisco Iglesias FIELD(BNK1_DRIVER_BIAS, BNK1_DRIVER_BIAS, 0, 15) 4448c1c0a1bSFrancisco Iglesias REG32(BNK1_VMODE, 0x35c) 4458c1c0a1bSFrancisco Iglesias FIELD(BNK1_VMODE, BNK1_VMODE, 0, 1) 4468c1c0a1bSFrancisco Iglesias REG32(BNK1_SEL_AUX_IO_RX, 0x360) 4478c1c0a1bSFrancisco Iglesias FIELD(BNK1_SEL_AUX_IO_RX, BNK1_SEL_AUX_IO_RX, 0, 26) 4488c1c0a1bSFrancisco Iglesias REG32(BNK1_EN_TX_HS_MODE, 0x364) 4498c1c0a1bSFrancisco Iglesias FIELD(BNK1_EN_TX_HS_MODE, BNK1_EN_TX_HS_MODE, 0, 26) 4508c1c0a1bSFrancisco Iglesias REG32(SD0_CLK_CTRL, 0x400) 4518c1c0a1bSFrancisco Iglesias FIELD(SD0_CLK_CTRL, SDIO0_FBCLK_SEL, 2, 1) 4528c1c0a1bSFrancisco Iglesias FIELD(SD0_CLK_CTRL, SDIO0_RX_SRC_SEL, 0, 2) 4538c1c0a1bSFrancisco Iglesias REG32(SD0_CTRL_REG, 0x404) 4548c1c0a1bSFrancisco Iglesias FIELD(SD0_CTRL_REG, SD0_EMMC_SEL, 0, 1) 4558c1c0a1bSFrancisco Iglesias REG32(SD0_CONFIG_REG1, 0x410) 4568c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG1, SD0_BASECLK, 7, 8) 4578c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG1, SD0_TUNIGCOUNT, 1, 6) 4588c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG1, SD0_ASYNCWKPENA, 0, 1) 4598c1c0a1bSFrancisco Iglesias REG32(SD0_CONFIG_REG2, 0x414) 4608c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_SLOTTYPE, 12, 2) 4618c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_ASYCINTR, 11, 1) 4628c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_64BIT, 10, 1) 4638c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_1P8V, 9, 1) 4648c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_3P0V, 8, 1) 4658c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_3P3V, 7, 1) 4668c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_SUSPRES, 6, 1) 4678c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_SDMA, 5, 1) 4688c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_HIGHSPEED, 4, 1) 4698c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_ADMA2, 3, 1) 4708c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_8BIT, 2, 1) 4718c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG2, SD0_MAXBLK, 0, 2) 4728c1c0a1bSFrancisco Iglesias REG32(SD0_CONFIG_REG3, 0x418) 4738c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_TUNINGSDR50, 10, 1) 4748c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_RETUNETMR, 6, 4) 4758c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_DDRIVER, 5, 1) 4768c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_CDRIVER, 4, 1) 4778c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_ADRIVER, 3, 1) 4788c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_DDR50, 2, 1) 4798c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_SDR104, 1, 1) 4808c1c0a1bSFrancisco Iglesias FIELD(SD0_CONFIG_REG3, SD0_SDR50, 0, 1) 4818c1c0a1bSFrancisco Iglesias REG32(SD0_INITPRESET, 0x41c) 4828c1c0a1bSFrancisco Iglesias FIELD(SD0_INITPRESET, SD0_INITPRESET, 0, 13) 4838c1c0a1bSFrancisco Iglesias REG32(SD0_DSPPRESET, 0x420) 4848c1c0a1bSFrancisco Iglesias FIELD(SD0_DSPPRESET, SD0_DSPPRESET, 0, 13) 4858c1c0a1bSFrancisco Iglesias REG32(SD0_HSPDPRESET, 0x424) 4868c1c0a1bSFrancisco Iglesias FIELD(SD0_HSPDPRESET, SD0_HSPDPRESET, 0, 13) 4878c1c0a1bSFrancisco Iglesias REG32(SD0_SDR12PRESET, 0x428) 4888c1c0a1bSFrancisco Iglesias FIELD(SD0_SDR12PRESET, SD0_SDR12PRESET, 0, 13) 4898c1c0a1bSFrancisco Iglesias REG32(SD0_SDR25PRESET, 0x42c) 4908c1c0a1bSFrancisco Iglesias FIELD(SD0_SDR25PRESET, SD0_SDR25PRESET, 0, 13) 4918c1c0a1bSFrancisco Iglesias REG32(SD0_SDR50PRSET, 0x430) 4928c1c0a1bSFrancisco Iglesias FIELD(SD0_SDR50PRSET, SD0_SDR50PRESET, 0, 13) 4938c1c0a1bSFrancisco Iglesias REG32(SD0_SDR104PRST, 0x434) 4948c1c0a1bSFrancisco Iglesias FIELD(SD0_SDR104PRST, SD0_SDR104PRESET, 0, 13) 4958c1c0a1bSFrancisco Iglesias REG32(SD0_DDR50PRESET, 0x438) 4968c1c0a1bSFrancisco Iglesias FIELD(SD0_DDR50PRESET, SD0_DDR50PRESET, 0, 13) 4978c1c0a1bSFrancisco Iglesias REG32(SD0_MAXCUR1P8, 0x43c) 4988c1c0a1bSFrancisco Iglesias FIELD(SD0_MAXCUR1P8, SD0_MAXCUR1P8, 0, 8) 4998c1c0a1bSFrancisco Iglesias REG32(SD0_MAXCUR3P0, 0x440) 5008c1c0a1bSFrancisco Iglesias FIELD(SD0_MAXCUR3P0, SD0_MAXCUR3P0, 0, 8) 5018c1c0a1bSFrancisco Iglesias REG32(SD0_MAXCUR3P3, 0x444) 5028c1c0a1bSFrancisco Iglesias FIELD(SD0_MAXCUR3P3, SD0_MAXCUR3P3, 0, 8) 5038c1c0a1bSFrancisco Iglesias REG32(SD0_DLL_CTRL, 0x448) 5048c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_CTRL, SD0_CLKSTABLE_CFG, 9, 1) 5058c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_CTRL, SD0_DLL_CFG, 5, 4) 5068c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_CTRL, SD0_DLL_PSDONE, 4, 1) 5078c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_CTRL, SD0_DLL_OVF, 3, 1) 5088c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_CTRL, SD0_DLL_RST, 2, 1) 5098c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_CTRL, SD0_DLL_TESTMODE, 1, 1) 5108c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_CTRL, SD0_DLL_LOCK, 0, 1) 5118c1c0a1bSFrancisco Iglesias REG32(SD0_CDN_CTRL, 0x44c) 5128c1c0a1bSFrancisco Iglesias FIELD(SD0_CDN_CTRL, SD0_CDN_CTRL, 0, 1) 5138c1c0a1bSFrancisco Iglesias REG32(SD0_DLL_TEST, 0x450) 5148c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_TEST, DLL_DIV, 16, 8) 5158c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_TEST, DLL_TX_SEL, 9, 7) 5168c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_TEST, DLL_RX_SEL, 0, 9) 5178c1c0a1bSFrancisco Iglesias REG32(SD0_RX_TUNING_SEL, 0x454) 5188c1c0a1bSFrancisco Iglesias FIELD(SD0_RX_TUNING_SEL, SD0_RX_SEL, 0, 9) 5198c1c0a1bSFrancisco Iglesias REG32(SD0_DLL_DIV_MAP0, 0x458) 5208c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP0, DIV_3, 24, 8) 5218c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP0, DIV_2, 16, 8) 5228c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP0, DIV_1, 8, 8) 5238c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP0, DIV_0, 0, 8) 5248c1c0a1bSFrancisco Iglesias REG32(SD0_DLL_DIV_MAP1, 0x45c) 5258c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP1, DIV_7, 24, 8) 5268c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP1, DIV_6, 16, 8) 5278c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP1, DIV_5, 8, 8) 5288c1c0a1bSFrancisco Iglesias FIELD(SD0_DLL_DIV_MAP1, DIV_4, 0, 8) 5298c1c0a1bSFrancisco Iglesias REG32(SD0_IOU_COHERENT_CTRL, 0x460) 5308c1c0a1bSFrancisco Iglesias FIELD(SD0_IOU_COHERENT_CTRL, SD0_AXI_COH, 0, 4) 5318c1c0a1bSFrancisco Iglesias REG32(SD0_IOU_INTERCONNECT_ROUTE, 0x464) 5328c1c0a1bSFrancisco Iglesias FIELD(SD0_IOU_INTERCONNECT_ROUTE, SD0, 0, 1) 5338c1c0a1bSFrancisco Iglesias REG32(SD0_IOU_RAM, 0x468) 5348c1c0a1bSFrancisco Iglesias FIELD(SD0_IOU_RAM, EMASA0, 6, 1) 5358c1c0a1bSFrancisco Iglesias FIELD(SD0_IOU_RAM, EMAB0, 3, 3) 5368c1c0a1bSFrancisco Iglesias FIELD(SD0_IOU_RAM, EMAA0, 0, 3) 5378c1c0a1bSFrancisco Iglesias REG32(SD0_IOU_INTERCONNECT_QOS, 0x46c) 5388c1c0a1bSFrancisco Iglesias FIELD(SD0_IOU_INTERCONNECT_QOS, SD0_QOS, 0, 4) 5398c1c0a1bSFrancisco Iglesias REG32(SD1_CLK_CTRL, 0x480) 5408c1c0a1bSFrancisco Iglesias FIELD(SD1_CLK_CTRL, SDIO1_FBCLK_SEL, 1, 1) 5418c1c0a1bSFrancisco Iglesias FIELD(SD1_CLK_CTRL, SDIO1_RX_SRC_SEL, 0, 1) 5428c1c0a1bSFrancisco Iglesias REG32(SD1_CTRL_REG, 0x484) 5438c1c0a1bSFrancisco Iglesias FIELD(SD1_CTRL_REG, SD1_EMMC_SEL, 0, 1) 5448c1c0a1bSFrancisco Iglesias REG32(SD1_CONFIG_REG1, 0x490) 5458c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG1, SD1_BASECLK, 7, 8) 5468c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG1, SD1_TUNIGCOUNT, 1, 6) 5478c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG1, SD1_ASYNCWKPENA, 0, 1) 5488c1c0a1bSFrancisco Iglesias REG32(SD1_CONFIG_REG2, 0x494) 5498c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_SLOTTYPE, 12, 2) 5508c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_ASYCINTR, 11, 1) 5518c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_64BIT, 10, 1) 5528c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_1P8V, 9, 1) 5538c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_3P0V, 8, 1) 5548c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_3P3V, 7, 1) 5558c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_SUSPRES, 6, 1) 5568c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_SDMA, 5, 1) 5578c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_HIGHSPEED, 4, 1) 5588c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_ADMA2, 3, 1) 5598c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_8BIT, 2, 1) 5608c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG2, SD1_MAXBLK, 0, 2) 5618c1c0a1bSFrancisco Iglesias REG32(SD1_CONFIG_REG3, 0x498) 5628c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_TUNINGSDR50, 10, 1) 5638c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_RETUNETMR, 6, 4) 5648c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_DDRIVER, 5, 1) 5658c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_CDRIVER, 4, 1) 5668c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_ADRIVER, 3, 1) 5678c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_DDR50, 2, 1) 5688c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_SDR104, 1, 1) 5698c1c0a1bSFrancisco Iglesias FIELD(SD1_CONFIG_REG3, SD1_SDR50, 0, 1) 5708c1c0a1bSFrancisco Iglesias REG32(SD1_INITPRESET, 0x49c) 5718c1c0a1bSFrancisco Iglesias FIELD(SD1_INITPRESET, SD1_INITPRESET, 0, 13) 5728c1c0a1bSFrancisco Iglesias REG32(SD1_DSPPRESET, 0x4a0) 5738c1c0a1bSFrancisco Iglesias FIELD(SD1_DSPPRESET, SD1_DSPPRESET, 0, 13) 5748c1c0a1bSFrancisco Iglesias REG32(SD1_HSPDPRESET, 0x4a4) 5758c1c0a1bSFrancisco Iglesias FIELD(SD1_HSPDPRESET, SD1_HSPDPRESET, 0, 13) 5768c1c0a1bSFrancisco Iglesias REG32(SD1_SDR12PRESET, 0x4a8) 5778c1c0a1bSFrancisco Iglesias FIELD(SD1_SDR12PRESET, SD1_SDR12PRESET, 0, 13) 5788c1c0a1bSFrancisco Iglesias REG32(SD1_SDR25PRESET, 0x4ac) 5798c1c0a1bSFrancisco Iglesias FIELD(SD1_SDR25PRESET, SD1_SDR25PRESET, 0, 13) 5808c1c0a1bSFrancisco Iglesias REG32(SD1_SDR50PRSET, 0x4b0) 5818c1c0a1bSFrancisco Iglesias FIELD(SD1_SDR50PRSET, SD1_SDR50PRESET, 0, 13) 5828c1c0a1bSFrancisco Iglesias REG32(SD1_SDR104PRST, 0x4b4) 5838c1c0a1bSFrancisco Iglesias FIELD(SD1_SDR104PRST, SD1_SDR104PRESET, 0, 13) 5848c1c0a1bSFrancisco Iglesias REG32(SD1_DDR50PRESET, 0x4b8) 5858c1c0a1bSFrancisco Iglesias FIELD(SD1_DDR50PRESET, SD1_DDR50PRESET, 0, 13) 5868c1c0a1bSFrancisco Iglesias REG32(SD1_MAXCUR1P8, 0x4bc) 5878c1c0a1bSFrancisco Iglesias FIELD(SD1_MAXCUR1P8, SD1_MAXCUR1P8, 0, 8) 5888c1c0a1bSFrancisco Iglesias REG32(SD1_MAXCUR3P0, 0x4c0) 5898c1c0a1bSFrancisco Iglesias FIELD(SD1_MAXCUR3P0, SD1_MAXCUR3P0, 0, 8) 5908c1c0a1bSFrancisco Iglesias REG32(SD1_MAXCUR3P3, 0x4c4) 5918c1c0a1bSFrancisco Iglesias FIELD(SD1_MAXCUR3P3, SD1_MAXCUR3P3, 0, 8) 5928c1c0a1bSFrancisco Iglesias REG32(SD1_DLL_CTRL, 0x4c8) 5938c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_CTRL, SD1_CLKSTABLE_CFG, 9, 1) 5948c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_CTRL, SD1_DLL_CFG, 5, 4) 5958c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_CTRL, SD1_DLL_PSDONE, 4, 1) 5968c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_CTRL, SD1_DLL_OVF, 3, 1) 5978c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_CTRL, SD1_DLL_RST, 2, 1) 5988c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_CTRL, SD1_DLL_TESTMODE, 1, 1) 5998c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_CTRL, SD1_DLL_LOCK, 0, 1) 6008c1c0a1bSFrancisco Iglesias REG32(SD1_CDN_CTRL, 0x4cc) 6018c1c0a1bSFrancisco Iglesias FIELD(SD1_CDN_CTRL, SD1_CDN_CTRL, 0, 1) 6028c1c0a1bSFrancisco Iglesias REG32(SD1_DLL_TEST, 0x4d0) 6038c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_TEST, DLL_DIV, 16, 8) 6048c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_TEST, DLL_TX_SEL, 9, 7) 6058c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_TEST, DLL_RX_SEL, 0, 9) 6068c1c0a1bSFrancisco Iglesias REG32(SD1_RX_TUNING_SEL, 0x4d4) 6078c1c0a1bSFrancisco Iglesias FIELD(SD1_RX_TUNING_SEL, SD1_RX_SEL, 0, 9) 6088c1c0a1bSFrancisco Iglesias REG32(SD1_DLL_DIV_MAP0, 0x4d8) 6098c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP0, DIV_3, 24, 8) 6108c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP0, DIV_2, 16, 8) 6118c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP0, DIV_1, 8, 8) 6128c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP0, DIV_0, 0, 8) 6138c1c0a1bSFrancisco Iglesias REG32(SD1_DLL_DIV_MAP1, 0x4dc) 6148c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP1, DIV_7, 24, 8) 6158c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP1, DIV_6, 16, 8) 6168c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP1, DIV_5, 8, 8) 6178c1c0a1bSFrancisco Iglesias FIELD(SD1_DLL_DIV_MAP1, DIV_4, 0, 8) 6188c1c0a1bSFrancisco Iglesias REG32(SD1_IOU_COHERENT_CTRL, 0x4e0) 6198c1c0a1bSFrancisco Iglesias FIELD(SD1_IOU_COHERENT_CTRL, SD1_AXI_COH, 0, 4) 6208c1c0a1bSFrancisco Iglesias REG32(SD1_IOU_INTERCONNECT_ROUTE, 0x4e4) 6218c1c0a1bSFrancisco Iglesias FIELD(SD1_IOU_INTERCONNECT_ROUTE, SD1, 0, 1) 6228c1c0a1bSFrancisco Iglesias REG32(SD1_IOU_RAM, 0x4e8) 6238c1c0a1bSFrancisco Iglesias FIELD(SD1_IOU_RAM, EMASA0, 6, 1) 6248c1c0a1bSFrancisco Iglesias FIELD(SD1_IOU_RAM, EMAB0, 3, 3) 6258c1c0a1bSFrancisco Iglesias FIELD(SD1_IOU_RAM, EMAA0, 0, 3) 6268c1c0a1bSFrancisco Iglesias REG32(SD1_IOU_INTERCONNECT_QOS, 0x4ec) 6278c1c0a1bSFrancisco Iglesias FIELD(SD1_IOU_INTERCONNECT_QOS, SD1_QOS, 0, 4) 6288c1c0a1bSFrancisco Iglesias REG32(OSPI_QSPI_IOU_AXI_MUX_SEL, 0x504) 6298c1c0a1bSFrancisco Iglesias FIELD(OSPI_QSPI_IOU_AXI_MUX_SEL, OSPI_MUX_SEL, 1, 1) 6308c1c0a1bSFrancisco Iglesias FIELD(OSPI_QSPI_IOU_AXI_MUX_SEL, QSPI_OSPI_MUX_SEL, 0, 1) 6318c1c0a1bSFrancisco Iglesias REG32(QSPI_IOU_COHERENT_CTRL, 0x508) 6328c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_COHERENT_CTRL, QSPI_AXI_COH, 0, 4) 6338c1c0a1bSFrancisco Iglesias REG32(QSPI_IOU_INTERCONNECT_ROUTE, 0x50c) 6348c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_INTERCONNECT_ROUTE, QSPI, 0, 1) 6358c1c0a1bSFrancisco Iglesias REG32(QSPI_IOU_RAM, 0x510) 6368c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_RAM, EMASA1, 13, 1) 6378c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_RAM, EMAB1, 10, 3) 6388c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_RAM, EMAA1, 7, 3) 6398c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_RAM, EMASA0, 6, 1) 6408c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_RAM, EMAB0, 3, 3) 6418c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_RAM, EMAA0, 0, 3) 6428c1c0a1bSFrancisco Iglesias REG32(QSPI_IOU_INTERCONNECT_QOS, 0x514) 6438c1c0a1bSFrancisco Iglesias FIELD(QSPI_IOU_INTERCONNECT_QOS, QSPI_QOS, 0, 4) 6448c1c0a1bSFrancisco Iglesias REG32(OSPI_IOU_COHERENT_CTRL, 0x530) 6458c1c0a1bSFrancisco Iglesias FIELD(OSPI_IOU_COHERENT_CTRL, OSPI_AXI_COH, 0, 4) 6468c1c0a1bSFrancisco Iglesias REG32(OSPI_IOU_INTERCONNECT_ROUTE, 0x534) 6478c1c0a1bSFrancisco Iglesias FIELD(OSPI_IOU_INTERCONNECT_ROUTE, OSPI, 0, 1) 6488c1c0a1bSFrancisco Iglesias REG32(OSPI_IOU_RAM, 0x538) 6498c1c0a1bSFrancisco Iglesias FIELD(OSPI_IOU_RAM, EMAS0, 5, 1) 6508c1c0a1bSFrancisco Iglesias FIELD(OSPI_IOU_RAM, EMAW0, 3, 2) 6518c1c0a1bSFrancisco Iglesias FIELD(OSPI_IOU_RAM, EMA0, 0, 3) 6528c1c0a1bSFrancisco Iglesias REG32(OSPI_IOU_INTERCONNECT_QOS, 0x53c) 6538c1c0a1bSFrancisco Iglesias FIELD(OSPI_IOU_INTERCONNECT_QOS, OSPI_QOS, 0, 4) 6548c1c0a1bSFrancisco Iglesias REG32(OSPI_REFCLK_DLY_CTRL, 0x540) 6558c1c0a1bSFrancisco Iglesias FIELD(OSPI_REFCLK_DLY_CTRL, DLY1, 3, 2) 6568c1c0a1bSFrancisco Iglesias FIELD(OSPI_REFCLK_DLY_CTRL, DLY0, 0, 3) 6578c1c0a1bSFrancisco Iglesias REG32(CUR_PWR_ST, 0x600) 6588c1c0a1bSFrancisco Iglesias FIELD(CUR_PWR_ST, U2PMU, 0, 2) 6598c1c0a1bSFrancisco Iglesias REG32(CONNECT_ST, 0x604) 6608c1c0a1bSFrancisco Iglesias FIELD(CONNECT_ST, U2PMU, 0, 1) 6618c1c0a1bSFrancisco Iglesias REG32(PW_STATE_REQ, 0x608) 6628c1c0a1bSFrancisco Iglesias FIELD(PW_STATE_REQ, BIT_1_0, 0, 2) 6638c1c0a1bSFrancisco Iglesias REG32(HOST_U2_PORT_DISABLE, 0x60c) 6648c1c0a1bSFrancisco Iglesias FIELD(HOST_U2_PORT_DISABLE, BIT_0, 0, 1) 6658c1c0a1bSFrancisco Iglesias REG32(DBG_U2PMU, 0x610) 6668c1c0a1bSFrancisco Iglesias REG32(DBG_U2PMU_EXT1, 0x614) 6678c1c0a1bSFrancisco Iglesias REG32(DBG_U2PMU_EXT2, 0x618) 6688c1c0a1bSFrancisco Iglesias FIELD(DBG_U2PMU_EXT2, BIT_67_64, 0, 4) 6698c1c0a1bSFrancisco Iglesias REG32(PME_GEN_U2PMU, 0x61c) 6708c1c0a1bSFrancisco Iglesias FIELD(PME_GEN_U2PMU, BIT_0, 0, 1) 6718c1c0a1bSFrancisco Iglesias REG32(PWR_CONFIG_USB2, 0x620) 6728c1c0a1bSFrancisco Iglesias FIELD(PWR_CONFIG_USB2, STRAP, 0, 30) 6738c1c0a1bSFrancisco Iglesias REG32(PHY_HUB, 0x624) 6748c1c0a1bSFrancisco Iglesias FIELD(PHY_HUB, VBUS_CTRL, 1, 1) 6758c1c0a1bSFrancisco Iglesias FIELD(PHY_HUB, OVER_CURRENT, 0, 1) 6768c1c0a1bSFrancisco Iglesias REG32(CTRL, 0x700) 6778c1c0a1bSFrancisco Iglesias FIELD(CTRL, SLVERR_ENABLE, 0, 1) 6788c1c0a1bSFrancisco Iglesias REG32(ISR, 0x800) 6798c1c0a1bSFrancisco Iglesias FIELD(ISR, ADDR_DECODE_ERR, 0, 1) 6808c1c0a1bSFrancisco Iglesias REG32(IMR, 0x804) 6818c1c0a1bSFrancisco Iglesias FIELD(IMR, ADDR_DECODE_ERR, 0, 1) 6828c1c0a1bSFrancisco Iglesias REG32(IER, 0x808) 6838c1c0a1bSFrancisco Iglesias FIELD(IER, ADDR_DECODE_ERR, 0, 1) 6848c1c0a1bSFrancisco Iglesias REG32(IDR, 0x80c) 6858c1c0a1bSFrancisco Iglesias FIELD(IDR, ADDR_DECODE_ERR, 0, 1) 6868c1c0a1bSFrancisco Iglesias REG32(ITR, 0x810) 6878c1c0a1bSFrancisco Iglesias FIELD(ITR, ADDR_DECODE_ERR, 0, 1) 6888c1c0a1bSFrancisco Iglesias REG32(PARITY_ISR, 0x814) 6898c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_AXI_SD1_IOU, 12, 1) 6908c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_AXI_SD0_IOU, 11, 1) 6918c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_AXI_QSPI_IOU, 10, 1) 6928c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_AXI_OSPI_IOU, 9, 1) 6938c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_IOU_SD1, 8, 1) 6948c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_IOU_SD0, 7, 1) 6958c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_IOU_QSPI1, 6, 1) 6968c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_IOUSLCR_SECURE_APB, 5, 1) 6978c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_IOUSLCR_APB, 4, 1) 6988c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_QSPI0_APB, 3, 1) 6998c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_OSPI_APB, 2, 1) 7008c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_I2C_APB, 1, 1) 7018c1c0a1bSFrancisco Iglesias FIELD(PARITY_ISR, PERR_GPIO_APB, 0, 1) 7028c1c0a1bSFrancisco Iglesias REG32(PARITY_IMR, 0x818) 7038c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_AXI_SD1_IOU, 12, 1) 7048c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_AXI_SD0_IOU, 11, 1) 7058c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_AXI_QSPI_IOU, 10, 1) 7068c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_AXI_OSPI_IOU, 9, 1) 7078c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_IOU_SD1, 8, 1) 7088c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_IOU_SD0, 7, 1) 7098c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_IOU_QSPI1, 6, 1) 7108c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_IOUSLCR_SECURE_APB, 5, 1) 7118c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_IOUSLCR_APB, 4, 1) 7128c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_QSPI0_APB, 3, 1) 7138c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_OSPI_APB, 2, 1) 7148c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_I2C_APB, 1, 1) 7158c1c0a1bSFrancisco Iglesias FIELD(PARITY_IMR, PERR_GPIO_APB, 0, 1) 7168c1c0a1bSFrancisco Iglesias REG32(PARITY_IER, 0x81c) 7178c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_AXI_SD1_IOU, 12, 1) 7188c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_AXI_SD0_IOU, 11, 1) 7198c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_AXI_QSPI_IOU, 10, 1) 7208c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_AXI_OSPI_IOU, 9, 1) 7218c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_IOU_SD1, 8, 1) 7228c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_IOU_SD0, 7, 1) 7238c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_IOU_QSPI1, 6, 1) 7248c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_IOUSLCR_SECURE_APB, 5, 1) 7258c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_IOUSLCR_APB, 4, 1) 7268c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_QSPI0_APB, 3, 1) 7278c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_OSPI_APB, 2, 1) 7288c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_I2C_APB, 1, 1) 7298c1c0a1bSFrancisco Iglesias FIELD(PARITY_IER, PERR_GPIO_APB, 0, 1) 7308c1c0a1bSFrancisco Iglesias REG32(PARITY_IDR, 0x820) 7318c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_AXI_SD1_IOU, 12, 1) 7328c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_AXI_SD0_IOU, 11, 1) 7338c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_AXI_QSPI_IOU, 10, 1) 7348c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_AXI_OSPI_IOU, 9, 1) 7358c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_IOU_SD1, 8, 1) 7368c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_IOU_SD0, 7, 1) 7378c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_IOU_QSPI1, 6, 1) 7388c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_IOUSLCR_SECURE_APB, 5, 1) 7398c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_IOUSLCR_APB, 4, 1) 7408c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_QSPI0_APB, 3, 1) 7418c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_OSPI_APB, 2, 1) 7428c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_I2C_APB, 1, 1) 7438c1c0a1bSFrancisco Iglesias FIELD(PARITY_IDR, PERR_GPIO_APB, 0, 1) 7448c1c0a1bSFrancisco Iglesias REG32(PARITY_ITR, 0x824) 7458c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_AXI_SD1_IOU, 12, 1) 7468c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_AXI_SD0_IOU, 11, 1) 7478c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_AXI_QSPI_IOU, 10, 1) 7488c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_AXI_OSPI_IOU, 9, 1) 7498c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_IOU_SD1, 8, 1) 7508c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_IOU_SD0, 7, 1) 7518c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_IOU_QSPI1, 6, 1) 7528c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_IOUSLCR_SECURE_APB, 5, 1) 7538c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_IOUSLCR_APB, 4, 1) 7548c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_QSPI0_APB, 3, 1) 7558c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_OSPI_APB, 2, 1) 7568c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_I2C_APB, 1, 1) 7578c1c0a1bSFrancisco Iglesias FIELD(PARITY_ITR, PERR_GPIO_APB, 0, 1) 7588c1c0a1bSFrancisco Iglesias REG32(WPROT0, 0x828) 7598c1c0a1bSFrancisco Iglesias FIELD(WPROT0, ACTIVE, 0, 1) 7608c1c0a1bSFrancisco Iglesias 7618c1c0a1bSFrancisco Iglesias static void parity_imr_update_irq(XlnxVersalPmcIouSlcr *s) 7628c1c0a1bSFrancisco Iglesias { 7638c1c0a1bSFrancisco Iglesias bool pending = s->regs[R_PARITY_ISR] & ~s->regs[R_PARITY_IMR]; 7648c1c0a1bSFrancisco Iglesias qemu_set_irq(s->irq_parity_imr, pending); 7658c1c0a1bSFrancisco Iglesias } 7668c1c0a1bSFrancisco Iglesias 7678c1c0a1bSFrancisco Iglesias static void parity_isr_postw(RegisterInfo *reg, uint64_t val64) 7688c1c0a1bSFrancisco Iglesias { 7698c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 7708c1c0a1bSFrancisco Iglesias parity_imr_update_irq(s); 7718c1c0a1bSFrancisco Iglesias } 7728c1c0a1bSFrancisco Iglesias 7738c1c0a1bSFrancisco Iglesias static uint64_t parity_ier_prew(RegisterInfo *reg, uint64_t val64) 7748c1c0a1bSFrancisco Iglesias { 7758c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 7768c1c0a1bSFrancisco Iglesias uint32_t val = val64; 7778c1c0a1bSFrancisco Iglesias 7788c1c0a1bSFrancisco Iglesias s->regs[R_PARITY_IMR] &= ~val; 7798c1c0a1bSFrancisco Iglesias parity_imr_update_irq(s); 7808c1c0a1bSFrancisco Iglesias return 0; 7818c1c0a1bSFrancisco Iglesias } 7828c1c0a1bSFrancisco Iglesias 7838c1c0a1bSFrancisco Iglesias static uint64_t parity_idr_prew(RegisterInfo *reg, uint64_t val64) 7848c1c0a1bSFrancisco Iglesias { 7858c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 7868c1c0a1bSFrancisco Iglesias uint32_t val = val64; 7878c1c0a1bSFrancisco Iglesias 7888c1c0a1bSFrancisco Iglesias s->regs[R_PARITY_IMR] |= val; 7898c1c0a1bSFrancisco Iglesias parity_imr_update_irq(s); 7908c1c0a1bSFrancisco Iglesias return 0; 7918c1c0a1bSFrancisco Iglesias } 7928c1c0a1bSFrancisco Iglesias 7938c1c0a1bSFrancisco Iglesias static uint64_t parity_itr_prew(RegisterInfo *reg, uint64_t val64) 7948c1c0a1bSFrancisco Iglesias { 7958c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 7968c1c0a1bSFrancisco Iglesias uint32_t val = val64; 7978c1c0a1bSFrancisco Iglesias 7988c1c0a1bSFrancisco Iglesias s->regs[R_PARITY_ISR] |= val; 7998c1c0a1bSFrancisco Iglesias parity_imr_update_irq(s); 8008c1c0a1bSFrancisco Iglesias return 0; 8018c1c0a1bSFrancisco Iglesias } 8028c1c0a1bSFrancisco Iglesias 8038c1c0a1bSFrancisco Iglesias static void imr_update_irq(XlnxVersalPmcIouSlcr *s) 8048c1c0a1bSFrancisco Iglesias { 8058c1c0a1bSFrancisco Iglesias bool pending = s->regs[R_ISR] & ~s->regs[R_IMR]; 8068c1c0a1bSFrancisco Iglesias qemu_set_irq(s->irq_imr, pending); 8078c1c0a1bSFrancisco Iglesias } 8088c1c0a1bSFrancisco Iglesias 8098c1c0a1bSFrancisco Iglesias static void isr_postw(RegisterInfo *reg, uint64_t val64) 8108c1c0a1bSFrancisco Iglesias { 8118c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 8128c1c0a1bSFrancisco Iglesias imr_update_irq(s); 8138c1c0a1bSFrancisco Iglesias } 8148c1c0a1bSFrancisco Iglesias 8158c1c0a1bSFrancisco Iglesias static uint64_t ier_prew(RegisterInfo *reg, uint64_t val64) 8168c1c0a1bSFrancisco Iglesias { 8178c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 8188c1c0a1bSFrancisco Iglesias uint32_t val = val64; 8198c1c0a1bSFrancisco Iglesias 8208c1c0a1bSFrancisco Iglesias s->regs[R_IMR] &= ~val; 8218c1c0a1bSFrancisco Iglesias imr_update_irq(s); 8228c1c0a1bSFrancisco Iglesias return 0; 8238c1c0a1bSFrancisco Iglesias } 8248c1c0a1bSFrancisco Iglesias 8258c1c0a1bSFrancisco Iglesias static uint64_t idr_prew(RegisterInfo *reg, uint64_t val64) 8268c1c0a1bSFrancisco Iglesias { 8278c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 8288c1c0a1bSFrancisco Iglesias uint32_t val = val64; 8298c1c0a1bSFrancisco Iglesias 8308c1c0a1bSFrancisco Iglesias s->regs[R_IMR] |= val; 8318c1c0a1bSFrancisco Iglesias imr_update_irq(s); 8328c1c0a1bSFrancisco Iglesias return 0; 8338c1c0a1bSFrancisco Iglesias } 8348c1c0a1bSFrancisco Iglesias 8358c1c0a1bSFrancisco Iglesias static uint64_t itr_prew(RegisterInfo *reg, uint64_t val64) 8368c1c0a1bSFrancisco Iglesias { 8378c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 8388c1c0a1bSFrancisco Iglesias uint32_t val = val64; 8398c1c0a1bSFrancisco Iglesias 8408c1c0a1bSFrancisco Iglesias s->regs[R_ISR] |= val; 8418c1c0a1bSFrancisco Iglesias imr_update_irq(s); 8428c1c0a1bSFrancisco Iglesias return 0; 8438c1c0a1bSFrancisco Iglesias } 8448c1c0a1bSFrancisco Iglesias 8458c1c0a1bSFrancisco Iglesias static uint64_t sd0_ctrl_reg_prew(RegisterInfo *reg, uint64_t val64) 8468c1c0a1bSFrancisco Iglesias { 8478c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 8488c1c0a1bSFrancisco Iglesias uint32_t prev = ARRAY_FIELD_EX32(s->regs, SD0_CTRL_REG, SD0_EMMC_SEL); 8498c1c0a1bSFrancisco Iglesias 8508c1c0a1bSFrancisco Iglesias if (prev != (val64 & R_SD0_CTRL_REG_SD0_EMMC_SEL_MASK)) { 8518c1c0a1bSFrancisco Iglesias qemu_set_irq(s->sd_emmc_sel[0], !!val64); 8528c1c0a1bSFrancisco Iglesias } 8538c1c0a1bSFrancisco Iglesias 8548c1c0a1bSFrancisco Iglesias return val64; 8558c1c0a1bSFrancisco Iglesias } 8568c1c0a1bSFrancisco Iglesias 8578c1c0a1bSFrancisco Iglesias static uint64_t sd1_ctrl_reg_prew(RegisterInfo *reg, uint64_t val64) 8588c1c0a1bSFrancisco Iglesias { 8598c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 8608c1c0a1bSFrancisco Iglesias uint32_t prev = ARRAY_FIELD_EX32(s->regs, SD1_CTRL_REG, SD1_EMMC_SEL); 8618c1c0a1bSFrancisco Iglesias 8628c1c0a1bSFrancisco Iglesias if (prev != (val64 & R_SD1_CTRL_REG_SD1_EMMC_SEL_MASK)) { 8638c1c0a1bSFrancisco Iglesias qemu_set_irq(s->sd_emmc_sel[1], !!val64); 8648c1c0a1bSFrancisco Iglesias } 8658c1c0a1bSFrancisco Iglesias 8668c1c0a1bSFrancisco Iglesias return val64; 8678c1c0a1bSFrancisco Iglesias } 8688c1c0a1bSFrancisco Iglesias 8698c1c0a1bSFrancisco Iglesias static uint64_t ospi_qspi_iou_axi_mux_sel_prew(RegisterInfo *reg, 8708c1c0a1bSFrancisco Iglesias uint64_t val64) 8718c1c0a1bSFrancisco Iglesias { 8728c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(reg->opaque); 8738c1c0a1bSFrancisco Iglesias uint32_t val32 = (uint32_t) val64; 8748c1c0a1bSFrancisco Iglesias uint8_t ospi_mux_sel = FIELD_EX32(val32, OSPI_QSPI_IOU_AXI_MUX_SEL, 8758c1c0a1bSFrancisco Iglesias OSPI_MUX_SEL); 8768c1c0a1bSFrancisco Iglesias uint8_t qspi_ospi_mux_sel = FIELD_EX32(val32, OSPI_QSPI_IOU_AXI_MUX_SEL, 8778c1c0a1bSFrancisco Iglesias QSPI_OSPI_MUX_SEL); 8788c1c0a1bSFrancisco Iglesias 8798c1c0a1bSFrancisco Iglesias if (ospi_mux_sel != 8808c1c0a1bSFrancisco Iglesias ARRAY_FIELD_EX32(s->regs, OSPI_QSPI_IOU_AXI_MUX_SEL, OSPI_MUX_SEL)) { 8818c1c0a1bSFrancisco Iglesias qemu_set_irq(s->ospi_mux_sel, !!ospi_mux_sel); 8828c1c0a1bSFrancisco Iglesias } 8838c1c0a1bSFrancisco Iglesias 8848c1c0a1bSFrancisco Iglesias if (qspi_ospi_mux_sel != 8858c1c0a1bSFrancisco Iglesias ARRAY_FIELD_EX32(s->regs, OSPI_QSPI_IOU_AXI_MUX_SEL, 8868c1c0a1bSFrancisco Iglesias QSPI_OSPI_MUX_SEL)) { 8878c1c0a1bSFrancisco Iglesias qemu_set_irq(s->qspi_ospi_mux_sel, !!qspi_ospi_mux_sel); 8888c1c0a1bSFrancisco Iglesias } 8898c1c0a1bSFrancisco Iglesias 8908c1c0a1bSFrancisco Iglesias return val64; 8918c1c0a1bSFrancisco Iglesias } 8928c1c0a1bSFrancisco Iglesias 8938c1c0a1bSFrancisco Iglesias static RegisterAccessInfo pmc_iou_slcr_regs_info[] = { 8948c1c0a1bSFrancisco Iglesias { .name = "MIO_PIN_0", .addr = A_MIO_PIN_0, 8958c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 8968c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_1", .addr = A_MIO_PIN_1, 8978c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 8988c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_2", .addr = A_MIO_PIN_2, 8998c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9008c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_3", .addr = A_MIO_PIN_3, 9018c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9028c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_4", .addr = A_MIO_PIN_4, 9038c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9048c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_5", .addr = A_MIO_PIN_5, 9058c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9068c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_6", .addr = A_MIO_PIN_6, 9078c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9088c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_7", .addr = A_MIO_PIN_7, 9098c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9108c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_8", .addr = A_MIO_PIN_8, 9118c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9128c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_9", .addr = A_MIO_PIN_9, 9138c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9148c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_10", .addr = A_MIO_PIN_10, 9158c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9168c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_11", .addr = A_MIO_PIN_11, 9178c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9188c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_12", .addr = A_MIO_PIN_12, 9198c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9208c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_13", .addr = A_MIO_PIN_13, 9218c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9228c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_14", .addr = A_MIO_PIN_14, 9238c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9248c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_15", .addr = A_MIO_PIN_15, 9258c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9268c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_16", .addr = A_MIO_PIN_16, 9278c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9288c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_17", .addr = A_MIO_PIN_17, 9298c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9308c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_18", .addr = A_MIO_PIN_18, 9318c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9328c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_19", .addr = A_MIO_PIN_19, 9338c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9348c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_20", .addr = A_MIO_PIN_20, 9358c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9368c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_21", .addr = A_MIO_PIN_21, 9378c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9388c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_22", .addr = A_MIO_PIN_22, 9398c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9408c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_23", .addr = A_MIO_PIN_23, 9418c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9428c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_24", .addr = A_MIO_PIN_24, 9438c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9448c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_25", .addr = A_MIO_PIN_25, 9458c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9468c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_26", .addr = A_MIO_PIN_26, 9478c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9488c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_27", .addr = A_MIO_PIN_27, 9498c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9508c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_28", .addr = A_MIO_PIN_28, 9518c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9528c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_29", .addr = A_MIO_PIN_29, 9538c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9548c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_30", .addr = A_MIO_PIN_30, 9558c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9568c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_31", .addr = A_MIO_PIN_31, 9578c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9588c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_32", .addr = A_MIO_PIN_32, 9598c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9608c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_33", .addr = A_MIO_PIN_33, 9618c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9628c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_34", .addr = A_MIO_PIN_34, 9638c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9648c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_35", .addr = A_MIO_PIN_35, 9658c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9668c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_36", .addr = A_MIO_PIN_36, 9678c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9688c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_37", .addr = A_MIO_PIN_37, 9698c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9708c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_38", .addr = A_MIO_PIN_38, 9718c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9728c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_39", .addr = A_MIO_PIN_39, 9738c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9748c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_40", .addr = A_MIO_PIN_40, 9758c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9768c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_41", .addr = A_MIO_PIN_41, 9778c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9788c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_42", .addr = A_MIO_PIN_42, 9798c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9808c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_43", .addr = A_MIO_PIN_43, 9818c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9828c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_44", .addr = A_MIO_PIN_44, 9838c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9848c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_45", .addr = A_MIO_PIN_45, 9858c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9868c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_46", .addr = A_MIO_PIN_46, 9878c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9888c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_47", .addr = A_MIO_PIN_47, 9898c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9908c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_48", .addr = A_MIO_PIN_48, 9918c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9928c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_49", .addr = A_MIO_PIN_49, 9938c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9948c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_50", .addr = A_MIO_PIN_50, 9958c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9968c1c0a1bSFrancisco Iglesias },{ .name = "MIO_PIN_51", .addr = A_MIO_PIN_51, 9978c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc01, 9988c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_RX", .addr = A_BNK0_EN_RX, 9998c1c0a1bSFrancisco Iglesias .reset = 0x3ffffff, 10008c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10018c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SEL_RX0", .addr = A_BNK0_SEL_RX0, 10028c1c0a1bSFrancisco Iglesias .reset = 0xffffffff, 10038c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SEL_RX1", .addr = A_BNK0_SEL_RX1, 10048c1c0a1bSFrancisco Iglesias .reset = 0xfffff, 10058c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10068c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_RX_SCHMITT_HYST", .addr = A_BNK0_EN_RX_SCHMITT_HYST, 10078c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10088c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_WK_PD", .addr = A_BNK0_EN_WK_PD, 10098c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10108c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_WK_PU", .addr = A_BNK0_EN_WK_PU, 10118c1c0a1bSFrancisco Iglesias .reset = 0x3ffffff, 10128c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10138c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SEL_DRV0", .addr = A_BNK0_SEL_DRV0, 10148c1c0a1bSFrancisco Iglesias .reset = 0xffffffff, 10158c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SEL_DRV1", .addr = A_BNK0_SEL_DRV1, 10168c1c0a1bSFrancisco Iglesias .reset = 0xfffff, 10178c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10188c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SEL_SLEW", .addr = A_BNK0_SEL_SLEW, 10198c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10208c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_DFT_OPT_INV", .addr = A_BNK0_EN_DFT_OPT_INV, 10218c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10228c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_PAD2PAD_LOOPBACK", 10238c1c0a1bSFrancisco Iglesias .addr = A_BNK0_EN_PAD2PAD_LOOPBACK, 10248c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 10258c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_RX_SPARE0", .addr = A_BNK0_RX_SPARE0, 10268c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_RX_SPARE1", .addr = A_BNK0_RX_SPARE1, 10278c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10288c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_TX_SPARE0", .addr = A_BNK0_TX_SPARE0, 10298c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_TX_SPARE1", .addr = A_BNK0_TX_SPARE1, 10308c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10318c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SEL_EN1P8", .addr = A_BNK0_SEL_EN1P8, 10328c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10338c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_B_POR_DETECT", .addr = A_BNK0_EN_B_POR_DETECT, 10348c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10358c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_LPF_BYP_POR_DETECT", .addr = A_BNK0_LPF_BYP_POR_DETECT, 10368c1c0a1bSFrancisco Iglesias .reset = 0x1, 10378c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10388c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_LATCH", .addr = A_BNK0_EN_LATCH, 10398c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10408c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_VBG_LPF_BYP_B", .addr = A_BNK0_VBG_LPF_BYP_B, 10418c1c0a1bSFrancisco Iglesias .reset = 0x1, 10428c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10438c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_AMP_B", .addr = A_BNK0_EN_AMP_B, 10448c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffc, 10458c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SPARE_BIAS", .addr = A_BNK0_SPARE_BIAS, 10468c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 10478c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_DRIVER_BIAS", .addr = A_BNK0_DRIVER_BIAS, 10488c1c0a1bSFrancisco Iglesias .rsvd = 0xffff8000, 10498c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_VMODE", .addr = A_BNK0_VMODE, 10508c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10518c1c0a1bSFrancisco Iglesias .ro = 0x1, 10528c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_SEL_AUX_IO_RX", .addr = A_BNK0_SEL_AUX_IO_RX, 10538c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10548c1c0a1bSFrancisco Iglesias },{ .name = "BNK0_EN_TX_HS_MODE", .addr = A_BNK0_EN_TX_HS_MODE, 10558c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10568c1c0a1bSFrancisco Iglesias },{ .name = "MIO_MST_TRI0", .addr = A_MIO_MST_TRI0, 10578c1c0a1bSFrancisco Iglesias .reset = 0x3ffffff, 10588c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10598c1c0a1bSFrancisco Iglesias },{ .name = "MIO_MST_TRI1", .addr = A_MIO_MST_TRI1, 10608c1c0a1bSFrancisco Iglesias .reset = 0x3ffffff, 10618c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10628c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_RX", .addr = A_BNK1_EN_RX, 10638c1c0a1bSFrancisco Iglesias .reset = 0x3ffffff, 10648c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10658c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SEL_RX0", .addr = A_BNK1_SEL_RX0, 10668c1c0a1bSFrancisco Iglesias .reset = 0xffffffff, 10678c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SEL_RX1", .addr = A_BNK1_SEL_RX1, 10688c1c0a1bSFrancisco Iglesias .reset = 0xfffff, 10698c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10708c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_RX_SCHMITT_HYST", .addr = A_BNK1_EN_RX_SCHMITT_HYST, 10718c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10728c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_WK_PD", .addr = A_BNK1_EN_WK_PD, 10738c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10748c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_WK_PU", .addr = A_BNK1_EN_WK_PU, 10758c1c0a1bSFrancisco Iglesias .reset = 0x3ffffff, 10768c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10778c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SEL_DRV0", .addr = A_BNK1_SEL_DRV0, 10788c1c0a1bSFrancisco Iglesias .reset = 0xffffffff, 10798c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SEL_DRV1", .addr = A_BNK1_SEL_DRV1, 10808c1c0a1bSFrancisco Iglesias .reset = 0xfffff, 10818c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10828c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SEL_SLEW", .addr = A_BNK1_SEL_SLEW, 10838c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10848c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_DFT_OPT_INV", .addr = A_BNK1_EN_DFT_OPT_INV, 10858c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 10868c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_PAD2PAD_LOOPBACK", 10878c1c0a1bSFrancisco Iglesias .addr = A_BNK1_EN_PAD2PAD_LOOPBACK, 10888c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 10898c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_RX_SPARE0", .addr = A_BNK1_RX_SPARE0, 10908c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_RX_SPARE1", .addr = A_BNK1_RX_SPARE1, 10918c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10928c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_TX_SPARE0", .addr = A_BNK1_TX_SPARE0, 10938c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_TX_SPARE1", .addr = A_BNK1_TX_SPARE1, 10948c1c0a1bSFrancisco Iglesias .rsvd = 0xfff00000, 10958c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SEL_EN1P8", .addr = A_BNK1_SEL_EN1P8, 10968c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10978c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_B_POR_DETECT", .addr = A_BNK1_EN_B_POR_DETECT, 10988c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 10998c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_LPF_BYP_POR_DETECT", .addr = A_BNK1_LPF_BYP_POR_DETECT, 11008c1c0a1bSFrancisco Iglesias .reset = 0x1, 11018c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11028c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_LATCH", .addr = A_BNK1_EN_LATCH, 11038c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11048c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_VBG_LPF_BYP_B", .addr = A_BNK1_VBG_LPF_BYP_B, 11058c1c0a1bSFrancisco Iglesias .reset = 0x1, 11068c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11078c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_AMP_B", .addr = A_BNK1_EN_AMP_B, 11088c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffc, 11098c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SPARE_BIAS", .addr = A_BNK1_SPARE_BIAS, 11108c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 11118c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_DRIVER_BIAS", .addr = A_BNK1_DRIVER_BIAS, 11128c1c0a1bSFrancisco Iglesias .rsvd = 0xffff8000, 11138c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_VMODE", .addr = A_BNK1_VMODE, 11148c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11158c1c0a1bSFrancisco Iglesias .ro = 0x1, 11168c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_SEL_AUX_IO_RX", .addr = A_BNK1_SEL_AUX_IO_RX, 11178c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 11188c1c0a1bSFrancisco Iglesias },{ .name = "BNK1_EN_TX_HS_MODE", .addr = A_BNK1_EN_TX_HS_MODE, 11198c1c0a1bSFrancisco Iglesias .rsvd = 0xfc000000, 11208c1c0a1bSFrancisco Iglesias },{ .name = "SD0_CLK_CTRL", .addr = A_SD0_CLK_CTRL, 11218c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff8, 11228c1c0a1bSFrancisco Iglesias },{ .name = "SD0_CTRL_REG", .addr = A_SD0_CTRL_REG, 11238c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11248c1c0a1bSFrancisco Iglesias .pre_write = sd0_ctrl_reg_prew, 11258c1c0a1bSFrancisco Iglesias },{ .name = "SD0_CONFIG_REG1", .addr = A_SD0_CONFIG_REG1, 11268c1c0a1bSFrancisco Iglesias .reset = 0x3250, 11278c1c0a1bSFrancisco Iglesias .rsvd = 0xffff8000, 11288c1c0a1bSFrancisco Iglesias },{ .name = "SD0_CONFIG_REG2", .addr = A_SD0_CONFIG_REG2, 11298c1c0a1bSFrancisco Iglesias .reset = 0xffc, 11308c1c0a1bSFrancisco Iglesias .rsvd = 0xffffc000, 11318c1c0a1bSFrancisco Iglesias },{ .name = "SD0_CONFIG_REG3", .addr = A_SD0_CONFIG_REG3, 11328c1c0a1bSFrancisco Iglesias .reset = 0x407, 11338c1c0a1bSFrancisco Iglesias .rsvd = 0xfffff800, 11348c1c0a1bSFrancisco Iglesias },{ .name = "SD0_INITPRESET", .addr = A_SD0_INITPRESET, 11358c1c0a1bSFrancisco Iglesias .reset = 0x100, 11368c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11378c1c0a1bSFrancisco Iglesias },{ .name = "SD0_DSPPRESET", .addr = A_SD0_DSPPRESET, 11388c1c0a1bSFrancisco Iglesias .reset = 0x4, 11398c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11408c1c0a1bSFrancisco Iglesias },{ .name = "SD0_HSPDPRESET", .addr = A_SD0_HSPDPRESET, 11418c1c0a1bSFrancisco Iglesias .reset = 0x2, 11428c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11438c1c0a1bSFrancisco Iglesias },{ .name = "SD0_SDR12PRESET", .addr = A_SD0_SDR12PRESET, 11448c1c0a1bSFrancisco Iglesias .reset = 0x4, 11458c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11468c1c0a1bSFrancisco Iglesias },{ .name = "SD0_SDR25PRESET", .addr = A_SD0_SDR25PRESET, 11478c1c0a1bSFrancisco Iglesias .reset = 0x2, 11488c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11498c1c0a1bSFrancisco Iglesias },{ .name = "SD0_SDR50PRSET", .addr = A_SD0_SDR50PRSET, 11508c1c0a1bSFrancisco Iglesias .reset = 0x1, 11518c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11528c1c0a1bSFrancisco Iglesias },{ .name = "SD0_SDR104PRST", .addr = A_SD0_SDR104PRST, 11538c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11548c1c0a1bSFrancisco Iglesias },{ .name = "SD0_DDR50PRESET", .addr = A_SD0_DDR50PRESET, 11558c1c0a1bSFrancisco Iglesias .reset = 0x2, 11568c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 11578c1c0a1bSFrancisco Iglesias },{ .name = "SD0_MAXCUR1P8", .addr = A_SD0_MAXCUR1P8, 11588c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff00, 11598c1c0a1bSFrancisco Iglesias },{ .name = "SD0_MAXCUR3P0", .addr = A_SD0_MAXCUR3P0, 11608c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff00, 11618c1c0a1bSFrancisco Iglesias },{ .name = "SD0_MAXCUR3P3", .addr = A_SD0_MAXCUR3P3, 11628c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff00, 11638c1c0a1bSFrancisco Iglesias },{ .name = "SD0_DLL_CTRL", .addr = A_SD0_DLL_CTRL, 11648c1c0a1bSFrancisco Iglesias .reset = 0x1, 11658c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc00, 11668c1c0a1bSFrancisco Iglesias .ro = 0x19, 11678c1c0a1bSFrancisco Iglesias },{ .name = "SD0_CDN_CTRL", .addr = A_SD0_CDN_CTRL, 11688c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11698c1c0a1bSFrancisco Iglesias },{ .name = "SD0_DLL_TEST", .addr = A_SD0_DLL_TEST, 11708c1c0a1bSFrancisco Iglesias .rsvd = 0xff000000, 11718c1c0a1bSFrancisco Iglesias },{ .name = "SD0_RX_TUNING_SEL", .addr = A_SD0_RX_TUNING_SEL, 11728c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffe00, 11738c1c0a1bSFrancisco Iglesias .ro = 0x1ff, 11748c1c0a1bSFrancisco Iglesias },{ .name = "SD0_DLL_DIV_MAP0", .addr = A_SD0_DLL_DIV_MAP0, 11758c1c0a1bSFrancisco Iglesias .reset = 0x50505050, 11768c1c0a1bSFrancisco Iglesias },{ .name = "SD0_DLL_DIV_MAP1", .addr = A_SD0_DLL_DIV_MAP1, 11778c1c0a1bSFrancisco Iglesias .reset = 0x50505050, 11788c1c0a1bSFrancisco Iglesias },{ .name = "SD0_IOU_COHERENT_CTRL", .addr = A_SD0_IOU_COHERENT_CTRL, 11798c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 11808c1c0a1bSFrancisco Iglesias },{ .name = "SD0_IOU_INTERCONNECT_ROUTE", 11818c1c0a1bSFrancisco Iglesias .addr = A_SD0_IOU_INTERCONNECT_ROUTE, 11828c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11838c1c0a1bSFrancisco Iglesias },{ .name = "SD0_IOU_RAM", .addr = A_SD0_IOU_RAM, 11848c1c0a1bSFrancisco Iglesias .reset = 0x24, 11858c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff80, 11868c1c0a1bSFrancisco Iglesias },{ .name = "SD0_IOU_INTERCONNECT_QOS", 11878c1c0a1bSFrancisco Iglesias .addr = A_SD0_IOU_INTERCONNECT_QOS, 11888c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 11898c1c0a1bSFrancisco Iglesias },{ .name = "SD1_CLK_CTRL", .addr = A_SD1_CLK_CTRL, 11908c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffc, 11918c1c0a1bSFrancisco Iglesias },{ .name = "SD1_CTRL_REG", .addr = A_SD1_CTRL_REG, 11928c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 11938c1c0a1bSFrancisco Iglesias .pre_write = sd1_ctrl_reg_prew, 11948c1c0a1bSFrancisco Iglesias },{ .name = "SD1_CONFIG_REG1", .addr = A_SD1_CONFIG_REG1, 11958c1c0a1bSFrancisco Iglesias .reset = 0x3250, 11968c1c0a1bSFrancisco Iglesias .rsvd = 0xffff8000, 11978c1c0a1bSFrancisco Iglesias },{ .name = "SD1_CONFIG_REG2", .addr = A_SD1_CONFIG_REG2, 11988c1c0a1bSFrancisco Iglesias .reset = 0xffc, 11998c1c0a1bSFrancisco Iglesias .rsvd = 0xffffc000, 12008c1c0a1bSFrancisco Iglesias },{ .name = "SD1_CONFIG_REG3", .addr = A_SD1_CONFIG_REG3, 12018c1c0a1bSFrancisco Iglesias .reset = 0x407, 12028c1c0a1bSFrancisco Iglesias .rsvd = 0xfffff800, 12038c1c0a1bSFrancisco Iglesias },{ .name = "SD1_INITPRESET", .addr = A_SD1_INITPRESET, 12048c1c0a1bSFrancisco Iglesias .reset = 0x100, 12058c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12068c1c0a1bSFrancisco Iglesias },{ .name = "SD1_DSPPRESET", .addr = A_SD1_DSPPRESET, 12078c1c0a1bSFrancisco Iglesias .reset = 0x4, 12088c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12098c1c0a1bSFrancisco Iglesias },{ .name = "SD1_HSPDPRESET", .addr = A_SD1_HSPDPRESET, 12108c1c0a1bSFrancisco Iglesias .reset = 0x2, 12118c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12128c1c0a1bSFrancisco Iglesias },{ .name = "SD1_SDR12PRESET", .addr = A_SD1_SDR12PRESET, 12138c1c0a1bSFrancisco Iglesias .reset = 0x4, 12148c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12158c1c0a1bSFrancisco Iglesias },{ .name = "SD1_SDR25PRESET", .addr = A_SD1_SDR25PRESET, 12168c1c0a1bSFrancisco Iglesias .reset = 0x2, 12178c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12188c1c0a1bSFrancisco Iglesias },{ .name = "SD1_SDR50PRSET", .addr = A_SD1_SDR50PRSET, 12198c1c0a1bSFrancisco Iglesias .reset = 0x1, 12208c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12218c1c0a1bSFrancisco Iglesias },{ .name = "SD1_SDR104PRST", .addr = A_SD1_SDR104PRST, 12228c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12238c1c0a1bSFrancisco Iglesias },{ .name = "SD1_DDR50PRESET", .addr = A_SD1_DDR50PRESET, 12248c1c0a1bSFrancisco Iglesias .reset = 0x2, 12258c1c0a1bSFrancisco Iglesias .rsvd = 0xffffe000, 12268c1c0a1bSFrancisco Iglesias },{ .name = "SD1_MAXCUR1P8", .addr = A_SD1_MAXCUR1P8, 12278c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff00, 12288c1c0a1bSFrancisco Iglesias },{ .name = "SD1_MAXCUR3P0", .addr = A_SD1_MAXCUR3P0, 12298c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff00, 12308c1c0a1bSFrancisco Iglesias },{ .name = "SD1_MAXCUR3P3", .addr = A_SD1_MAXCUR3P3, 12318c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff00, 12328c1c0a1bSFrancisco Iglesias },{ .name = "SD1_DLL_CTRL", .addr = A_SD1_DLL_CTRL, 12338c1c0a1bSFrancisco Iglesias .reset = 0x1, 12348c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffc00, 12358c1c0a1bSFrancisco Iglesias .ro = 0x19, 12368c1c0a1bSFrancisco Iglesias },{ .name = "SD1_CDN_CTRL", .addr = A_SD1_CDN_CTRL, 12378c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 12388c1c0a1bSFrancisco Iglesias },{ .name = "SD1_DLL_TEST", .addr = A_SD1_DLL_TEST, 12398c1c0a1bSFrancisco Iglesias .rsvd = 0xff000000, 12408c1c0a1bSFrancisco Iglesias },{ .name = "SD1_RX_TUNING_SEL", .addr = A_SD1_RX_TUNING_SEL, 12418c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffe00, 12428c1c0a1bSFrancisco Iglesias .ro = 0x1ff, 12438c1c0a1bSFrancisco Iglesias },{ .name = "SD1_DLL_DIV_MAP0", .addr = A_SD1_DLL_DIV_MAP0, 12448c1c0a1bSFrancisco Iglesias .reset = 0x50505050, 12458c1c0a1bSFrancisco Iglesias },{ .name = "SD1_DLL_DIV_MAP1", .addr = A_SD1_DLL_DIV_MAP1, 12468c1c0a1bSFrancisco Iglesias .reset = 0x50505050, 12478c1c0a1bSFrancisco Iglesias },{ .name = "SD1_IOU_COHERENT_CTRL", .addr = A_SD1_IOU_COHERENT_CTRL, 12488c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 12498c1c0a1bSFrancisco Iglesias },{ .name = "SD1_IOU_INTERCONNECT_ROUTE", 12508c1c0a1bSFrancisco Iglesias .addr = A_SD1_IOU_INTERCONNECT_ROUTE, 12518c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 12528c1c0a1bSFrancisco Iglesias },{ .name = "SD1_IOU_RAM", .addr = A_SD1_IOU_RAM, 12538c1c0a1bSFrancisco Iglesias .reset = 0x24, 12548c1c0a1bSFrancisco Iglesias .rsvd = 0xffffff80, 12558c1c0a1bSFrancisco Iglesias },{ .name = "SD1_IOU_INTERCONNECT_QOS", 12568c1c0a1bSFrancisco Iglesias .addr = A_SD1_IOU_INTERCONNECT_QOS, 12578c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 12588c1c0a1bSFrancisco Iglesias },{ .name = "OSPI_QSPI_IOU_AXI_MUX_SEL", 12598c1c0a1bSFrancisco Iglesias .addr = A_OSPI_QSPI_IOU_AXI_MUX_SEL, 12608c1c0a1bSFrancisco Iglesias .reset = 0x1, 12618c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffc, 12628c1c0a1bSFrancisco Iglesias .pre_write = ospi_qspi_iou_axi_mux_sel_prew, 12638c1c0a1bSFrancisco Iglesias },{ .name = "QSPI_IOU_COHERENT_CTRL", .addr = A_QSPI_IOU_COHERENT_CTRL, 12648c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 12658c1c0a1bSFrancisco Iglesias },{ .name = "QSPI_IOU_INTERCONNECT_ROUTE", 12668c1c0a1bSFrancisco Iglesias .addr = A_QSPI_IOU_INTERCONNECT_ROUTE, 12678c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 12688c1c0a1bSFrancisco Iglesias },{ .name = "QSPI_IOU_RAM", .addr = A_QSPI_IOU_RAM, 12698c1c0a1bSFrancisco Iglesias .reset = 0x1224, 12708c1c0a1bSFrancisco Iglesias .rsvd = 0xffffc000, 12718c1c0a1bSFrancisco Iglesias },{ .name = "QSPI_IOU_INTERCONNECT_QOS", 12728c1c0a1bSFrancisco Iglesias .addr = A_QSPI_IOU_INTERCONNECT_QOS, 12738c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 12748c1c0a1bSFrancisco Iglesias },{ .name = "OSPI_IOU_COHERENT_CTRL", .addr = A_OSPI_IOU_COHERENT_CTRL, 12758c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 12768c1c0a1bSFrancisco Iglesias },{ .name = "OSPI_IOU_INTERCONNECT_ROUTE", 12778c1c0a1bSFrancisco Iglesias .addr = A_OSPI_IOU_INTERCONNECT_ROUTE, 12788c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 12798c1c0a1bSFrancisco Iglesias },{ .name = "OSPI_IOU_RAM", .addr = A_OSPI_IOU_RAM, 12808c1c0a1bSFrancisco Iglesias .reset = 0xa, 12818c1c0a1bSFrancisco Iglesias .rsvd = 0xffffffc0, 12828c1c0a1bSFrancisco Iglesias },{ .name = "OSPI_IOU_INTERCONNECT_QOS", 12838c1c0a1bSFrancisco Iglesias .addr = A_OSPI_IOU_INTERCONNECT_QOS, 12848c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 12858c1c0a1bSFrancisco Iglesias },{ .name = "OSPI_REFCLK_DLY_CTRL", .addr = A_OSPI_REFCLK_DLY_CTRL, 12868c1c0a1bSFrancisco Iglesias .reset = 0x13, 12878c1c0a1bSFrancisco Iglesias .rsvd = 0xffffffe0, 12888c1c0a1bSFrancisco Iglesias },{ .name = "CUR_PWR_ST", .addr = A_CUR_PWR_ST, 12898c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffc, 12908c1c0a1bSFrancisco Iglesias .ro = 0x3, 12918c1c0a1bSFrancisco Iglesias },{ .name = "CONNECT_ST", .addr = A_CONNECT_ST, 12928c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 12938c1c0a1bSFrancisco Iglesias .ro = 0x1, 12948c1c0a1bSFrancisco Iglesias },{ .name = "PW_STATE_REQ", .addr = A_PW_STATE_REQ, 12958c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffc, 12968c1c0a1bSFrancisco Iglesias },{ .name = "HOST_U2_PORT_DISABLE", .addr = A_HOST_U2_PORT_DISABLE, 12978c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 12988c1c0a1bSFrancisco Iglesias },{ .name = "DBG_U2PMU", .addr = A_DBG_U2PMU, 12998c1c0a1bSFrancisco Iglesias .ro = 0xffffffff, 13008c1c0a1bSFrancisco Iglesias },{ .name = "DBG_U2PMU_EXT1", .addr = A_DBG_U2PMU_EXT1, 13018c1c0a1bSFrancisco Iglesias .ro = 0xffffffff, 13028c1c0a1bSFrancisco Iglesias },{ .name = "DBG_U2PMU_EXT2", .addr = A_DBG_U2PMU_EXT2, 13038c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffff0, 13048c1c0a1bSFrancisco Iglesias .ro = 0xf, 13058c1c0a1bSFrancisco Iglesias },{ .name = "PME_GEN_U2PMU", .addr = A_PME_GEN_U2PMU, 13068c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffe, 13078c1c0a1bSFrancisco Iglesias .ro = 0x1, 13088c1c0a1bSFrancisco Iglesias },{ .name = "PWR_CONFIG_USB2", .addr = A_PWR_CONFIG_USB2, 13098c1c0a1bSFrancisco Iglesias .rsvd = 0xc0000000, 13108c1c0a1bSFrancisco Iglesias },{ .name = "PHY_HUB", .addr = A_PHY_HUB, 13118c1c0a1bSFrancisco Iglesias .rsvd = 0xfffffffc, 13128c1c0a1bSFrancisco Iglesias .ro = 0x2, 13138c1c0a1bSFrancisco Iglesias },{ .name = "CTRL", .addr = A_CTRL, 13148c1c0a1bSFrancisco Iglesias },{ .name = "ISR", .addr = A_ISR, 13158c1c0a1bSFrancisco Iglesias .w1c = 0x1, 13168c1c0a1bSFrancisco Iglesias .post_write = isr_postw, 13178c1c0a1bSFrancisco Iglesias },{ .name = "IMR", .addr = A_IMR, 13188c1c0a1bSFrancisco Iglesias .reset = 0x1, 13198c1c0a1bSFrancisco Iglesias .ro = 0x1, 13208c1c0a1bSFrancisco Iglesias },{ .name = "IER", .addr = A_IER, 13218c1c0a1bSFrancisco Iglesias .pre_write = ier_prew, 13228c1c0a1bSFrancisco Iglesias },{ .name = "IDR", .addr = A_IDR, 13238c1c0a1bSFrancisco Iglesias .pre_write = idr_prew, 13248c1c0a1bSFrancisco Iglesias },{ .name = "ITR", .addr = A_ITR, 13258c1c0a1bSFrancisco Iglesias .pre_write = itr_prew, 13268c1c0a1bSFrancisco Iglesias },{ .name = "PARITY_ISR", .addr = A_PARITY_ISR, 13278c1c0a1bSFrancisco Iglesias .w1c = 0x1fff, 13288c1c0a1bSFrancisco Iglesias .post_write = parity_isr_postw, 13298c1c0a1bSFrancisco Iglesias },{ .name = "PARITY_IMR", .addr = A_PARITY_IMR, 13308c1c0a1bSFrancisco Iglesias .reset = 0x1fff, 13318c1c0a1bSFrancisco Iglesias .ro = 0x1fff, 13328c1c0a1bSFrancisco Iglesias },{ .name = "PARITY_IER", .addr = A_PARITY_IER, 13338c1c0a1bSFrancisco Iglesias .pre_write = parity_ier_prew, 13348c1c0a1bSFrancisco Iglesias },{ .name = "PARITY_IDR", .addr = A_PARITY_IDR, 13358c1c0a1bSFrancisco Iglesias .pre_write = parity_idr_prew, 13368c1c0a1bSFrancisco Iglesias },{ .name = "PARITY_ITR", .addr = A_PARITY_ITR, 13378c1c0a1bSFrancisco Iglesias .pre_write = parity_itr_prew, 13388c1c0a1bSFrancisco Iglesias },{ .name = "WPROT0", .addr = A_WPROT0, 13398c1c0a1bSFrancisco Iglesias .reset = 0x1, 13408c1c0a1bSFrancisco Iglesias } 13418c1c0a1bSFrancisco Iglesias }; 13428c1c0a1bSFrancisco Iglesias 13438c1c0a1bSFrancisco Iglesias static void xlnx_versal_pmc_iou_slcr_reset_init(Object *obj, ResetType type) 13448c1c0a1bSFrancisco Iglesias { 13458c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(obj); 13468c1c0a1bSFrancisco Iglesias unsigned int i; 13478c1c0a1bSFrancisco Iglesias 13488c1c0a1bSFrancisco Iglesias for (i = 0; i < ARRAY_SIZE(s->regs_info); ++i) { 13498c1c0a1bSFrancisco Iglesias register_reset(&s->regs_info[i]); 13508c1c0a1bSFrancisco Iglesias } 13518c1c0a1bSFrancisco Iglesias } 13528c1c0a1bSFrancisco Iglesias 1353*ad80e367SPeter Maydell static void xlnx_versal_pmc_iou_slcr_reset_hold(Object *obj, ResetType type) 13548c1c0a1bSFrancisco Iglesias { 13558c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(obj); 13568c1c0a1bSFrancisco Iglesias 13578c1c0a1bSFrancisco Iglesias parity_imr_update_irq(s); 13588c1c0a1bSFrancisco Iglesias imr_update_irq(s); 13598c1c0a1bSFrancisco Iglesias 13608c1c0a1bSFrancisco Iglesias /* 13618c1c0a1bSFrancisco Iglesias * Setup OSPI_QSPI mux 13628c1c0a1bSFrancisco Iglesias * By default axi slave interface is enabled for ospi-dma 13638c1c0a1bSFrancisco Iglesias */ 13648c1c0a1bSFrancisco Iglesias qemu_set_irq(s->ospi_mux_sel, 0); 13658c1c0a1bSFrancisco Iglesias qemu_set_irq(s->qspi_ospi_mux_sel, 1); 13668c1c0a1bSFrancisco Iglesias } 13678c1c0a1bSFrancisco Iglesias 13688c1c0a1bSFrancisco Iglesias static const MemoryRegionOps pmc_iou_slcr_ops = { 13698c1c0a1bSFrancisco Iglesias .read = register_read_memory, 13708c1c0a1bSFrancisco Iglesias .write = register_write_memory, 13718c1c0a1bSFrancisco Iglesias .endianness = DEVICE_LITTLE_ENDIAN, 13728c1c0a1bSFrancisco Iglesias .valid = { 13738c1c0a1bSFrancisco Iglesias .min_access_size = 4, 13748c1c0a1bSFrancisco Iglesias .max_access_size = 4, 13758c1c0a1bSFrancisco Iglesias }, 13768c1c0a1bSFrancisco Iglesias }; 13778c1c0a1bSFrancisco Iglesias 13788c1c0a1bSFrancisco Iglesias static void xlnx_versal_pmc_iou_slcr_realize(DeviceState *dev, Error **errp) 13798c1c0a1bSFrancisco Iglesias { 13808c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(dev); 13818c1c0a1bSFrancisco Iglesias 13828c1c0a1bSFrancisco Iglesias qdev_init_gpio_out_named(dev, s->sd_emmc_sel, "sd-emmc-sel", 2); 13838c1c0a1bSFrancisco Iglesias qdev_init_gpio_out_named(dev, &s->qspi_ospi_mux_sel, 13848c1c0a1bSFrancisco Iglesias "qspi-ospi-mux-sel", 1); 13858c1c0a1bSFrancisco Iglesias qdev_init_gpio_out_named(dev, &s->ospi_mux_sel, "ospi-mux-sel", 1); 13868c1c0a1bSFrancisco Iglesias } 13878c1c0a1bSFrancisco Iglesias 13888c1c0a1bSFrancisco Iglesias static void xlnx_versal_pmc_iou_slcr_init(Object *obj) 13898c1c0a1bSFrancisco Iglesias { 13908c1c0a1bSFrancisco Iglesias XlnxVersalPmcIouSlcr *s = XILINX_VERSAL_PMC_IOU_SLCR(obj); 13918c1c0a1bSFrancisco Iglesias SysBusDevice *sbd = SYS_BUS_DEVICE(obj); 13928c1c0a1bSFrancisco Iglesias RegisterInfoArray *reg_array; 13938c1c0a1bSFrancisco Iglesias 13948c1c0a1bSFrancisco Iglesias memory_region_init(&s->iomem, obj, TYPE_XILINX_VERSAL_PMC_IOU_SLCR, 13958c1c0a1bSFrancisco Iglesias XILINX_VERSAL_PMC_IOU_SLCR_R_MAX * 4); 13968c1c0a1bSFrancisco Iglesias reg_array = 13978c1c0a1bSFrancisco Iglesias register_init_block32(DEVICE(obj), pmc_iou_slcr_regs_info, 13988c1c0a1bSFrancisco Iglesias ARRAY_SIZE(pmc_iou_slcr_regs_info), 13998c1c0a1bSFrancisco Iglesias s->regs_info, s->regs, 14008c1c0a1bSFrancisco Iglesias &pmc_iou_slcr_ops, 14018c1c0a1bSFrancisco Iglesias XILINX_VERSAL_PMC_IOU_SLCR_ERR_DEBUG, 14028c1c0a1bSFrancisco Iglesias XILINX_VERSAL_PMC_IOU_SLCR_R_MAX * 4); 14038c1c0a1bSFrancisco Iglesias memory_region_add_subregion(&s->iomem, 14048c1c0a1bSFrancisco Iglesias 0x0, 14058c1c0a1bSFrancisco Iglesias ®_array->mem); 14068c1c0a1bSFrancisco Iglesias sysbus_init_mmio(sbd, &s->iomem); 14078c1c0a1bSFrancisco Iglesias sysbus_init_irq(sbd, &s->irq_parity_imr); 14088c1c0a1bSFrancisco Iglesias sysbus_init_irq(sbd, &s->irq_imr); 14098c1c0a1bSFrancisco Iglesias } 14108c1c0a1bSFrancisco Iglesias 14118c1c0a1bSFrancisco Iglesias static const VMStateDescription vmstate_pmc_iou_slcr = { 14128c1c0a1bSFrancisco Iglesias .name = TYPE_XILINX_VERSAL_PMC_IOU_SLCR, 14138c1c0a1bSFrancisco Iglesias .version_id = 1, 14148c1c0a1bSFrancisco Iglesias .minimum_version_id = 1, 1415e4ea952fSRichard Henderson .fields = (const VMStateField[]) { 14168c1c0a1bSFrancisco Iglesias VMSTATE_UINT32_ARRAY(regs, XlnxVersalPmcIouSlcr, 14178c1c0a1bSFrancisco Iglesias XILINX_VERSAL_PMC_IOU_SLCR_R_MAX), 14188c1c0a1bSFrancisco Iglesias VMSTATE_END_OF_LIST(), 14198c1c0a1bSFrancisco Iglesias } 14208c1c0a1bSFrancisco Iglesias }; 14218c1c0a1bSFrancisco Iglesias 14228c1c0a1bSFrancisco Iglesias static void xlnx_versal_pmc_iou_slcr_class_init(ObjectClass *klass, void *data) 14238c1c0a1bSFrancisco Iglesias { 14248c1c0a1bSFrancisco Iglesias DeviceClass *dc = DEVICE_CLASS(klass); 14258c1c0a1bSFrancisco Iglesias ResettableClass *rc = RESETTABLE_CLASS(klass); 14268c1c0a1bSFrancisco Iglesias 14278c1c0a1bSFrancisco Iglesias dc->realize = xlnx_versal_pmc_iou_slcr_realize; 14288c1c0a1bSFrancisco Iglesias dc->vmsd = &vmstate_pmc_iou_slcr; 14298c1c0a1bSFrancisco Iglesias rc->phases.enter = xlnx_versal_pmc_iou_slcr_reset_init; 14308c1c0a1bSFrancisco Iglesias rc->phases.hold = xlnx_versal_pmc_iou_slcr_reset_hold; 14318c1c0a1bSFrancisco Iglesias } 14328c1c0a1bSFrancisco Iglesias 14338c1c0a1bSFrancisco Iglesias static const TypeInfo xlnx_versal_pmc_iou_slcr_info = { 14348c1c0a1bSFrancisco Iglesias .name = TYPE_XILINX_VERSAL_PMC_IOU_SLCR, 14358c1c0a1bSFrancisco Iglesias .parent = TYPE_SYS_BUS_DEVICE, 14368c1c0a1bSFrancisco Iglesias .instance_size = sizeof(XlnxVersalPmcIouSlcr), 14378c1c0a1bSFrancisco Iglesias .class_init = xlnx_versal_pmc_iou_slcr_class_init, 14388c1c0a1bSFrancisco Iglesias .instance_init = xlnx_versal_pmc_iou_slcr_init, 14398c1c0a1bSFrancisco Iglesias }; 14408c1c0a1bSFrancisco Iglesias 14418c1c0a1bSFrancisco Iglesias static void xlnx_versal_pmc_iou_slcr_register_types(void) 14428c1c0a1bSFrancisco Iglesias { 14438c1c0a1bSFrancisco Iglesias type_register_static(&xlnx_versal_pmc_iou_slcr_info); 14448c1c0a1bSFrancisco Iglesias } 14458c1c0a1bSFrancisco Iglesias 14468c1c0a1bSFrancisco Iglesias type_init(xlnx_versal_pmc_iou_slcr_register_types) 1447