11.1Sjmcneill/* $NetBSD: am33xx.h,v 1.1.1.3 2020/01/03 14:33:03 skrll Exp $ */ 21.1Sjmcneill 31.1.1.2Sjmcneill/* SPDX-License-Identifier: GPL-2.0 */ 41.1Sjmcneill/* 51.1Sjmcneill * This header provides constants specific to AM33XX pinctrl bindings. 61.1Sjmcneill */ 71.1Sjmcneill 81.1Sjmcneill#ifndef _DT_BINDINGS_PINCTRL_AM33XX_H 91.1Sjmcneill#define _DT_BINDINGS_PINCTRL_AM33XX_H 101.1Sjmcneill 111.1Sjmcneill#include <dt-bindings/pinctrl/omap.h> 121.1Sjmcneill 131.1Sjmcneill/* am33xx specific mux bit defines */ 141.1Sjmcneill#undef PULL_ENA 151.1Sjmcneill#undef INPUT_EN 161.1Sjmcneill 171.1Sjmcneill#define PULL_DISABLE (1 << 3) 181.1Sjmcneill#define INPUT_EN (1 << 5) 191.1Sjmcneill#define SLEWCTRL_SLOW (1 << 6) 201.1Sjmcneill#define SLEWCTRL_FAST 0 211.1Sjmcneill 221.1Sjmcneill/* update macro depending on INPUT_EN and PULL_ENA */ 231.1Sjmcneill#undef PIN_OUTPUT 241.1Sjmcneill#undef PIN_OUTPUT_PULLUP 251.1Sjmcneill#undef PIN_OUTPUT_PULLDOWN 261.1Sjmcneill#undef PIN_INPUT 271.1Sjmcneill#undef PIN_INPUT_PULLUP 281.1Sjmcneill#undef PIN_INPUT_PULLDOWN 291.1Sjmcneill 301.1Sjmcneill#define PIN_OUTPUT (PULL_DISABLE) 311.1Sjmcneill#define PIN_OUTPUT_PULLUP (PULL_UP) 321.1Sjmcneill#define PIN_OUTPUT_PULLDOWN 0 331.1Sjmcneill#define PIN_INPUT (INPUT_EN | PULL_DISABLE) 341.1Sjmcneill#define PIN_INPUT_PULLUP (INPUT_EN | PULL_UP) 351.1Sjmcneill#define PIN_INPUT_PULLDOWN (INPUT_EN) 361.1Sjmcneill 371.1Sjmcneill/* undef non-existing modes */ 381.1Sjmcneill#undef PIN_OFF_NONE 391.1Sjmcneill#undef PIN_OFF_OUTPUT_HIGH 401.1Sjmcneill#undef PIN_OFF_OUTPUT_LOW 411.1Sjmcneill#undef PIN_OFF_INPUT_PULLUP 421.1Sjmcneill#undef PIN_OFF_INPUT_PULLDOWN 431.1Sjmcneill#undef PIN_OFF_WAKEUPENABLE 441.1Sjmcneill 451.1.1.3Sskrll#define AM335X_PIN_OFFSET_MIN 0x0800U 461.1.1.3Sskrll 471.1.1.3Sskrll#define AM335X_PIN_GPMC_AD0 0x800 481.1.1.3Sskrll#define AM335X_PIN_GPMC_AD1 0x804 491.1.1.3Sskrll#define AM335X_PIN_GPMC_AD2 0x808 501.1.1.3Sskrll#define AM335X_PIN_GPMC_AD3 0x80c 511.1.1.3Sskrll#define AM335X_PIN_GPMC_AD4 0x810 521.1.1.3Sskrll#define AM335X_PIN_GPMC_AD5 0x814 531.1.1.3Sskrll#define AM335X_PIN_GPMC_AD6 0x818 541.1.1.3Sskrll#define AM335X_PIN_GPMC_AD7 0x81c 551.1.1.3Sskrll#define AM335X_PIN_GPMC_AD8 0x820 561.1.1.3Sskrll#define AM335X_PIN_GPMC_AD9 0x824 571.1.1.3Sskrll#define AM335X_PIN_GPMC_AD10 0x828 581.1.1.3Sskrll#define AM335X_PIN_GPMC_AD11 0x82c 591.1.1.3Sskrll#define AM335X_PIN_GPMC_AD12 0x830 601.1.1.3Sskrll#define AM335X_PIN_GPMC_AD13 0x834 611.1.1.3Sskrll#define AM335X_PIN_GPMC_AD14 0x838 621.1.1.3Sskrll#define AM335X_PIN_GPMC_AD15 0x83c 631.1.1.3Sskrll#define AM335X_PIN_GPMC_A0 0x840 641.1.1.3Sskrll#define AM335X_PIN_GPMC_A1 0x844 651.1.1.3Sskrll#define AM335X_PIN_GPMC_A2 0x848 661.1.1.3Sskrll#define AM335X_PIN_GPMC_A3 0x84c 671.1.1.3Sskrll#define AM335X_PIN_GPMC_A4 0x850 681.1.1.3Sskrll#define AM335X_PIN_GPMC_A5 0x854 691.1.1.3Sskrll#define AM335X_PIN_GPMC_A6 0x858 701.1.1.3Sskrll#define AM335X_PIN_GPMC_A7 0x85c 711.1.1.3Sskrll#define AM335X_PIN_GPMC_A8 0x860 721.1.1.3Sskrll#define AM335X_PIN_GPMC_A9 0x864 731.1.1.3Sskrll#define AM335X_PIN_GPMC_A10 0x868 741.1.1.3Sskrll#define AM335X_PIN_GPMC_A11 0x86c 751.1.1.3Sskrll#define AM335X_PIN_GPMC_WAIT0 0x870 761.1.1.3Sskrll#define AM335X_PIN_GPMC_WPN 0x874 771.1.1.3Sskrll#define AM335X_PIN_GPMC_BEN1 0x878 781.1.1.3Sskrll#define AM335X_PIN_GPMC_CSN0 0x87c 791.1.1.3Sskrll#define AM335X_PIN_GPMC_CSN1 0x880 801.1.1.3Sskrll#define AM335X_PIN_GPMC_CSN2 0x884 811.1.1.3Sskrll#define AM335X_PIN_GPMC_CSN3 0x888 821.1.1.3Sskrll#define AM335X_PIN_GPMC_CLK 0x88c 831.1.1.3Sskrll#define AM335X_PIN_GPMC_ADVN_ALE 0x890 841.1.1.3Sskrll#define AM335X_PIN_GPMC_OEN_REN 0x894 851.1.1.3Sskrll#define AM335X_PIN_GPMC_WEN 0x898 861.1.1.3Sskrll#define AM335X_PIN_GPMC_BEN0_CLE 0x89c 871.1.1.3Sskrll#define AM335X_PIN_LCD_DATA0 0x8a0 881.1.1.3Sskrll#define AM335X_PIN_LCD_DATA1 0x8a4 891.1.1.3Sskrll#define AM335X_PIN_LCD_DATA2 0x8a8 901.1.1.3Sskrll#define AM335X_PIN_LCD_DATA3 0x8ac 911.1.1.3Sskrll#define AM335X_PIN_LCD_DATA4 0x8b0 921.1.1.3Sskrll#define AM335X_PIN_LCD_DATA5 0x8b4 931.1.1.3Sskrll#define AM335X_PIN_LCD_DATA6 0x8b8 941.1.1.3Sskrll#define AM335X_PIN_LCD_DATA7 0x8bc 951.1.1.3Sskrll#define AM335X_PIN_LCD_DATA8 0x8c0 961.1.1.3Sskrll#define AM335X_PIN_LCD_DATA9 0x8c4 971.1.1.3Sskrll#define AM335X_PIN_LCD_DATA10 0x8c8 981.1.1.3Sskrll#define AM335X_PIN_LCD_DATA11 0x8cc 991.1.1.3Sskrll#define AM335X_PIN_LCD_DATA12 0x8d0 1001.1.1.3Sskrll#define AM335X_PIN_LCD_DATA13 0x8d4 1011.1.1.3Sskrll#define AM335X_PIN_LCD_DATA14 0x8d8 1021.1.1.3Sskrll#define AM335X_PIN_LCD_DATA15 0x8dc 1031.1.1.3Sskrll#define AM335X_PIN_LCD_VSYNC 0x8e0 1041.1.1.3Sskrll#define AM335X_PIN_LCD_HSYNC 0x8e4 1051.1.1.3Sskrll#define AM335X_PIN_LCD_PCLK 0x8e8 1061.1.1.3Sskrll#define AM335X_PIN_LCD_AC_BIAS_EN 0x8ec 1071.1.1.3Sskrll#define AM335X_PIN_MMC0_DAT3 0x8f0 1081.1.1.3Sskrll#define AM335X_PIN_MMC0_DAT2 0x8f4 1091.1.1.3Sskrll#define AM335X_PIN_MMC0_DAT1 0x8f8 1101.1.1.3Sskrll#define AM335X_PIN_MMC0_DAT0 0x8fc 1111.1.1.3Sskrll#define AM335X_PIN_MMC0_CLK 0x900 1121.1.1.3Sskrll#define AM335X_PIN_MMC0_CMD 0x904 1131.1.1.3Sskrll#define AM335X_PIN_MII1_COL 0x908 1141.1.1.3Sskrll#define AM335X_PIN_MII1_CRS 0x90c 1151.1.1.3Sskrll#define AM335X_PIN_MII1_RX_ER 0x910 1161.1.1.3Sskrll#define AM335X_PIN_MII1_TX_EN 0x914 1171.1.1.3Sskrll#define AM335X_PIN_MII1_RX_DV 0x918 1181.1.1.3Sskrll#define AM335X_PIN_MII1_TXD3 0x91c 1191.1.1.3Sskrll#define AM335X_PIN_MII1_TXD2 0x920 1201.1.1.3Sskrll#define AM335X_PIN_MII1_TXD1 0x924 1211.1.1.3Sskrll#define AM335X_PIN_MII1_TXD0 0x928 1221.1.1.3Sskrll#define AM335X_PIN_MII1_TX_CLK 0x92c 1231.1.1.3Sskrll#define AM335X_PIN_MII1_RX_CLK 0x930 1241.1.1.3Sskrll#define AM335X_PIN_MII1_RXD3 0x934 1251.1.1.3Sskrll#define AM335X_PIN_MII1_RXD2 0x938 1261.1.1.3Sskrll#define AM335X_PIN_MII1_RXD1 0x93c 1271.1.1.3Sskrll#define AM335X_PIN_MII1_RXD0 0x940 1281.1.1.3Sskrll#define AM335X_PIN_RMII1_REF_CLK 0x944 1291.1.1.3Sskrll#define AM335X_PIN_MDIO 0x948 1301.1.1.3Sskrll#define AM335X_PIN_MDC 0x94c 1311.1.1.3Sskrll#define AM335X_PIN_SPI0_SCLK 0x950 1321.1.1.3Sskrll#define AM335X_PIN_SPI0_D0 0x954 1331.1.1.3Sskrll#define AM335X_PIN_SPI0_D1 0x958 1341.1.1.3Sskrll#define AM335X_PIN_SPI0_CS0 0x95c 1351.1.1.3Sskrll#define AM335X_PIN_SPI0_CS1 0x960 1361.1.1.3Sskrll#define AM335X_PIN_ECAP0_IN_PWM0_OUT 0x964 1371.1.1.3Sskrll#define AM335X_PIN_UART0_CTSN 0x968 1381.1.1.3Sskrll#define AM335X_PIN_UART0_RTSN 0x96c 1391.1.1.3Sskrll#define AM335X_PIN_UART0_RXD 0x970 1401.1.1.3Sskrll#define AM335X_PIN_UART0_TXD 0x974 1411.1.1.3Sskrll#define AM335X_PIN_UART1_CTSN 0x978 1421.1.1.3Sskrll#define AM335X_PIN_UART1_RTSN 0x97c 1431.1.1.3Sskrll#define AM335X_PIN_UART1_RXD 0x980 1441.1.1.3Sskrll#define AM335X_PIN_UART1_TXD 0x984 1451.1.1.3Sskrll#define AM335X_PIN_I2C0_SDA 0x988 1461.1.1.3Sskrll#define AM335X_PIN_I2C0_SCL 0x98c 1471.1.1.3Sskrll#define AM335X_PIN_MCASP0_ACLKX 0x990 1481.1.1.3Sskrll#define AM335X_PIN_MCASP0_FSX 0x994 1491.1.1.3Sskrll#define AM335X_PIN_MCASP0_AXR0 0x998 1501.1.1.3Sskrll#define AM335X_PIN_MCASP0_AHCLKR 0x99c 1511.1.1.3Sskrll#define AM335X_PIN_MCASP0_ACLKR 0x9a0 1521.1.1.3Sskrll#define AM335X_PIN_MCASP0_FSR 0x9a4 1531.1.1.3Sskrll#define AM335X_PIN_MCASP0_AXR1 0x9a8 1541.1.1.3Sskrll#define AM335X_PIN_MCASP0_AHCLKX 0x9ac 1551.1.1.3Sskrll#define AM335X_PIN_XDMA_EVENT_INTR0 0x9b0 1561.1.1.3Sskrll#define AM335X_PIN_XDMA_EVENT_INTR1 0x9b4 1571.1.1.3Sskrll#define AM335X_PIN_WARMRSTN 0x9b8 1581.1.1.3Sskrll#define AM335X_PIN_NNMI 0x9c0 1591.1.1.3Sskrll#define AM335X_PIN_TMS 0x9d0 1601.1.1.3Sskrll#define AM335X_PIN_TDI 0x9d4 1611.1.1.3Sskrll#define AM335X_PIN_TDO 0x9d8 1621.1.1.3Sskrll#define AM335X_PIN_TCK 0x9dc 1631.1.1.3Sskrll#define AM335X_PIN_TRSTN 0x9e0 1641.1.1.3Sskrll#define AM335X_PIN_EMU0 0x9e4 1651.1.1.3Sskrll#define AM335X_PIN_EMU1 0x9e8 1661.1.1.3Sskrll#define AM335X_PIN_RTC_PWRONRSTN 0x9f8 1671.1.1.3Sskrll#define AM335X_PIN_PMIC_POWER_EN 0x9fc 1681.1.1.3Sskrll#define AM335X_PIN_EXT_WAKEUP 0xa00 1691.1.1.3Sskrll#define AM335X_PIN_USB0_DRVVBUS 0xa1c 1701.1.1.3Sskrll#define AM335X_PIN_USB1_DRVVBUS 0xa34 1711.1Sjmcneill 1721.1.1.3Sskrll#define AM335X_PIN_OFFSET_MAX 0x0a34U 1731.1.1.3Sskrll 1741.1.1.3Sskrll#endif 175