Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-or-later */
0002 /*
0003  * include/linux/mfd/wm8994/gpio.h - GPIO configuration for WM8994
0004  *
0005  * Copyright 2009 Wolfson Microelectronics PLC.
0006  *
0007  * Author: Mark Brown <broonie@opensource.wolfsonmicro.com>
0008  */
0009 
0010 #ifndef __MFD_WM8994_GPIO_H__
0011 #define __MFD_WM8994_GPIO_H__
0012 
0013 #define WM8994_GPIO_MAX 11
0014 
0015 #define WM8994_GP_FN_PIN_SPECIFIC    0
0016 #define WM8994_GP_FN_GPIO            1
0017 #define WM8994_GP_FN_SDOUT           2
0018 #define WM8994_GP_FN_IRQ             3
0019 #define WM8994_GP_FN_TEMPERATURE     4
0020 #define WM8994_GP_FN_MICBIAS1_DET    5
0021 #define WM8994_GP_FN_MICBIAS1_SHORT  6
0022 #define WM8994_GP_FN_MICBIAS2_DET    7
0023 #define WM8994_GP_FN_MICBIAS2_SHORT  8
0024 #define WM8994_GP_FN_FLL1_LOCK       9
0025 #define WM8994_GP_FN_FLL2_LOCK      10
0026 #define WM8994_GP_FN_SRC1_LOCK      11
0027 #define WM8994_GP_FN_SRC2_LOCK      12
0028 #define WM8994_GP_FN_DRC1_ACT       13
0029 #define WM8994_GP_FN_DRC2_ACT       14
0030 #define WM8994_GP_FN_DRC3_ACT       15
0031 #define WM8994_GP_FN_WSEQ_STATUS    16
0032 #define WM8994_GP_FN_FIFO_ERROR     17
0033 #define WM8994_GP_FN_OPCLK          18
0034 #define WM8994_GP_FN_THW        19
0035 #define WM8994_GP_FN_DCS_DONE       20
0036 #define WM8994_GP_FN_FLL1_OUT       21
0037 #define WM8994_GP_FN_FLL2_OUT       22
0038 
0039 #define WM8994_GPN_DIR                          0x8000  /* GPN_DIR */
0040 #define WM8994_GPN_DIR_MASK                     0x8000  /* GPN_DIR */
0041 #define WM8994_GPN_DIR_SHIFT                        15  /* GPN_DIR */
0042 #define WM8994_GPN_DIR_WIDTH                         1  /* GPN_DIR */
0043 #define WM8994_GPN_PU                           0x4000  /* GPN_PU */
0044 #define WM8994_GPN_PU_MASK                      0x4000  /* GPN_PU */
0045 #define WM8994_GPN_PU_SHIFT                         14  /* GPN_PU */
0046 #define WM8994_GPN_PU_WIDTH                          1  /* GPN_PU */
0047 #define WM8994_GPN_PD                           0x2000  /* GPN_PD */
0048 #define WM8994_GPN_PD_MASK                      0x2000  /* GPN_PD */
0049 #define WM8994_GPN_PD_SHIFT                         13  /* GPN_PD */
0050 #define WM8994_GPN_PD_WIDTH                          1  /* GPN_PD */
0051 #define WM8994_GPN_POL                          0x0400  /* GPN_POL */
0052 #define WM8994_GPN_POL_MASK                     0x0400  /* GPN_POL */
0053 #define WM8994_GPN_POL_SHIFT                        10  /* GPN_POL */
0054 #define WM8994_GPN_POL_WIDTH                         1  /* GPN_POL */
0055 #define WM8994_GPN_OP_CFG                       0x0200  /* GPN_OP_CFG */
0056 #define WM8994_GPN_OP_CFG_MASK                  0x0200  /* GPN_OP_CFG */
0057 #define WM8994_GPN_OP_CFG_SHIFT                      9  /* GPN_OP_CFG */
0058 #define WM8994_GPN_OP_CFG_WIDTH                      1  /* GPN_OP_CFG */
0059 #define WM8994_GPN_DB                           0x0100  /* GPN_DB */
0060 #define WM8994_GPN_DB_MASK                      0x0100  /* GPN_DB */
0061 #define WM8994_GPN_DB_SHIFT                          8  /* GPN_DB */
0062 #define WM8994_GPN_DB_WIDTH                          1  /* GPN_DB */
0063 #define WM8994_GPN_LVL                          0x0040  /* GPN_LVL */
0064 #define WM8994_GPN_LVL_MASK                     0x0040  /* GPN_LVL */
0065 #define WM8994_GPN_LVL_SHIFT                         6  /* GPN_LVL */
0066 #define WM8994_GPN_LVL_WIDTH                         1  /* GPN_LVL */
0067 #define WM8994_GPN_FN_MASK                      0x001F  /* GPN_FN - [4:0] */
0068 #define WM8994_GPN_FN_SHIFT                          0  /* GPN_FN - [4:0] */
0069 #define WM8994_GPN_FN_WIDTH                          5  /* GPN_FN - [4:0] */
0070 
0071 #endif