1 /* $NetBSD: qcom,pmic-mpp.h,v 1.1.1.1.6.2 2017/08/28 17:53:03 skrll Exp $ */ 2 3 /* 4 * This header provides constants for the Qualcomm PMIC's 5 * Multi-Purpose Pin binding. 6 */ 7 8 #ifndef _DT_BINDINGS_PINCTRL_QCOM_PMIC_MPP_H 9 #define _DT_BINDINGS_PINCTRL_QCOM_PMIC_MPP_H 10 11 /* power-source */ 12 13 /* Digital Input/Output: level [PM8058] */ 14 #define PM8058_MPP_VPH 0 15 #define PM8058_MPP_S3 1 16 #define PM8058_MPP_L2 2 17 #define PM8058_MPP_L3 3 18 19 /* Digital Input/Output: level [PM8901] */ 20 #define PM8901_MPP_MSMIO 0 21 #define PM8901_MPP_DIG 1 22 #define PM8901_MPP_L5 2 23 #define PM8901_MPP_S4 3 24 #define PM8901_MPP_VPH 4 25 26 /* Digital Input/Output: level [PM8921] */ 27 #define PM8921_MPP_S4 1 28 #define PM8921_MPP_L15 3 29 #define PM8921_MPP_L17 4 30 #define PM8921_MPP_VPH 7 31 32 /* Digital Input/Output: level [PM8821] */ 33 #define PM8821_MPP_1P8 0 34 #define PM8821_MPP_VPH 7 35 36 /* Digital Input/Output: level [PM8018] */ 37 #define PM8018_MPP_L4 0 38 #define PM8018_MPP_L14 1 39 #define PM8018_MPP_S3 2 40 #define PM8018_MPP_L6 3 41 #define PM8018_MPP_L2 4 42 #define PM8018_MPP_L5 5 43 #define PM8018_MPP_VPH 7 44 45 /* Digital Input/Output: level [PM8038] */ 46 #define PM8038_MPP_L20 0 47 #define PM8038_MPP_L11 1 48 #define PM8038_MPP_L5 2 49 #define PM8038_MPP_L15 3 50 #define PM8038_MPP_L17 4 51 #define PM8038_MPP_VPH 7 52 53 #define PM8841_MPP_VPH 0 54 #define PM8841_MPP_S3 2 55 56 #define PM8916_MPP_VPH 0 57 #define PM8916_MPP_L2 2 58 #define PM8916_MPP_L5 3 59 60 #define PM8941_MPP_VPH 0 61 #define PM8941_MPP_L1 1 62 #define PM8941_MPP_S3 2 63 #define PM8941_MPP_L6 3 64 65 #define PMA8084_MPP_VPH 0 66 #define PMA8084_MPP_L1 1 67 #define PMA8084_MPP_S4 2 68 #define PMA8084_MPP_L6 3 69 70 #define PM8994_MPP_VPH 0 71 /* Only supported for MPP_05-MPP_08 */ 72 #define PM8994_MPP_L19 1 73 #define PM8994_MPP_S4 2 74 #define PM8994_MPP_L12 3 75 76 /* 77 * Analog Input - Set the source for analog input. 78 * To be used with "qcom,amux-route" property 79 */ 80 #define PMIC_MPP_AMUX_ROUTE_CH5 0 81 #define PMIC_MPP_AMUX_ROUTE_CH6 1 82 #define PMIC_MPP_AMUX_ROUTE_CH7 2 83 #define PMIC_MPP_AMUX_ROUTE_CH8 3 84 #define PMIC_MPP_AMUX_ROUTE_ABUS1 4 85 #define PMIC_MPP_AMUX_ROUTE_ABUS2 5 86 #define PMIC_MPP_AMUX_ROUTE_ABUS3 6 87 #define PMIC_MPP_AMUX_ROUTE_ABUS4 7 88 89 /* Analog Output: level */ 90 #define PMIC_MPP_AOUT_LVL_1V25 0 91 #define PMIC_MPP_AOUT_LVL_1V25_2 1 92 #define PMIC_MPP_AOUT_LVL_0V625 2 93 #define PMIC_MPP_AOUT_LVL_0V3125 3 94 #define PMIC_MPP_AOUT_LVL_MPP 4 95 #define PMIC_MPP_AOUT_LVL_ABUS1 5 96 #define PMIC_MPP_AOUT_LVL_ABUS2 6 97 #define PMIC_MPP_AOUT_LVL_ABUS3 7 98 99 /* To be used with "function" */ 100 #define PMIC_MPP_FUNC_NORMAL "normal" 101 #define PMIC_MPP_FUNC_PAIRED "paired" 102 #define PMIC_MPP_FUNC_DTEST1 "dtest1" 103 #define PMIC_MPP_FUNC_DTEST2 "dtest2" 104 #define PMIC_MPP_FUNC_DTEST3 "dtest3" 105 #define PMIC_MPP_FUNC_DTEST4 "dtest4" 106 107 #endif 108