aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mfd
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-08-07 20:17:39 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-08-07 20:17:39 -0400
commit54c72d5987ff9f3cf59529d5d4f5cf19eae3f695 (patch)
tree3fee972d54926627895aa07684ddb2e2388e4614 /include/linux/mfd
parent66bb0aa077978dbb76e6283531eb3cc7a878de38 (diff)
parent7caa79917ad4c1f91366b11f18e48623554aaa52 (diff)
Merge tag 'mfd-for-linus-3.17' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd
Pull MFD update from Lee Jones: "Changes to existing drivers: - checkpatch fixes throughout the subsystem - use Regmap to handle IRQs in max77686, extcon-max77693 and mc13xxx-core - use DMA in rtsx_pcr - restrict building on unsupported architectures on timberdale, cs5535 - SPI hardening in cros_ec_spi - more robust error handing in asic3, cros_ec, ab8500-debugfs, max77686 and pcf50633-core - reorder PM runtime and regulator handing during shutdown in arizona - enable wakeup in cros_ec_spi - unused variable/code clean-up in pm8921-core, cros_ec, htc-i2cpld, tps65912-spi, wm5110-tables and ab8500-debugfs - add regulator handing into suspend() in sec-core - remove pointless wrapper functions in extcon-max77693 and i2c-cros-ec-tunnel - use cross-architecture friendly data sizes in stmpe-i2c, arizona, max77686 and tps65910 - devicetree documentation updates throughout - provide power management support in max77686 - few OF clean-ups in max77686 - use manged resources in tps6105x New drivers/supported devices: - add support for s2mpu02 to sec-core - add support for Allwinner A32 to sun6i-prcm - add support for Maxim 77802 in max77686 - add support for DA9063 AD in da9063 - new driver for Intel PMICs (generic) and specifically Crystal Cove (Re-)moved drivers == - move out keyboard functionality cros_ec ==> input/keyboard/cros_ec_keyb" * tag 'mfd-for-linus-3.17' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (101 commits) MAINTAINERS: Update MFD repo location mfd: omap-usb-host: Fix improper mask use. mfd: arizona: Only free the CTRLIF_ERR IRQ if we requested it mfd: arizona: Add missing handling for ISRC3 under/overclocked mfd: wm5110: Add new interrupt register definitions mfd: arizona: Rename thermal shutdown interrupt mfd: wm5110: Add in the output done interrupts mfd: wm5110: Remove non-existant interrupts mfd: tps65912-spi: Remove unused variable mfd: htc-i2cpld: Remove unused code mfd: da9063: Add support for AD silicon variant mfd: arizona: Map MICVDD from extcon device to the Arizona core mfd: arizona: Add MICVDD to mapped regulators for wm8997 mfd: max77686: Ensure device type IDs are architecture agnostic mfd: max77686: Add Maxim 77802 PMIC support mfd: tps6105x: Use managed resources when allocating memory mfd: wm8997-tables: Suppress 'line over 80 chars' warnings mfd: kempld-core: Correct a variety of checkpatch warnings mfd: ipaq-micro: Fix coding style errors/warnings reported by checkpatch mfd: si476x-cmd: Remedy checkpatch style complains ...
Diffstat (limited to 'include/linux/mfd')
-rw-r--r--include/linux/mfd/abx500/ab8500.h1
-rw-r--r--include/linux/mfd/arizona/core.h35
-rw-r--r--include/linux/mfd/arizona/registers.h785
-rw-r--r--include/linux/mfd/cros_ec.h110
-rw-r--r--include/linux/mfd/da9063/core.h3
-rw-r--r--include/linux/mfd/da9063/registers.h129
-rw-r--r--include/linux/mfd/intel_soc_pmic.h30
-rw-r--r--include/linux/mfd/max77686-private.h239
-rw-r--r--include/linux/mfd/max77686.h59
-rw-r--r--include/linux/mfd/mc13783.h1
-rw-r--r--include/linux/mfd/mc13xxx.h23
-rw-r--r--include/linux/mfd/rtsx_pci.h6
-rw-r--r--include/linux/mfd/samsung/core.h1
-rw-r--r--include/linux/mfd/samsung/irq.h24
-rw-r--r--include/linux/mfd/samsung/s2mpu02.h201
-rw-r--r--include/linux/mfd/tps65910.h2
16 files changed, 1485 insertions, 164 deletions
diff --git a/include/linux/mfd/abx500/ab8500.h b/include/linux/mfd/abx500/ab8500.h
index 4e7fe7417fc9..9475fee2bfc5 100644
--- a/include/linux/mfd/abx500/ab8500.h
+++ b/include/linux/mfd/abx500/ab8500.h
@@ -505,6 +505,7 @@ static inline int is_ab9540_2p0_or_earlier(struct ab8500 *ab)
505void ab8500_override_turn_on_stat(u8 mask, u8 set); 505void ab8500_override_turn_on_stat(u8 mask, u8 set);
506 506
507#ifdef CONFIG_AB8500_DEBUG 507#ifdef CONFIG_AB8500_DEBUG
508extern int prcmu_abb_read(u8 slave, u8 reg, u8 *value, u8 size);
508void ab8500_dump_all_banks(struct device *dev); 509void ab8500_dump_all_banks(struct device *dev);
509void ab8500_debug_register_interrupt(int line); 510void ab8500_debug_register_interrupt(int line);
510#else 511#else
diff --git a/include/linux/mfd/arizona/core.h b/include/linux/mfd/arizona/core.h
index a614b33d0a39..f34723f7663c 100644
--- a/include/linux/mfd/arizona/core.h
+++ b/include/linux/mfd/arizona/core.h
@@ -18,7 +18,7 @@
18#include <linux/regulator/consumer.h> 18#include <linux/regulator/consumer.h>
19#include <linux/mfd/arizona/pdata.h> 19#include <linux/mfd/arizona/pdata.h>
20 20
21#define ARIZONA_MAX_CORE_SUPPLIES 3 21#define ARIZONA_MAX_CORE_SUPPLIES 2
22 22
23enum arizona_type { 23enum arizona_type {
24 WM5102 = 1, 24 WM5102 = 1,
@@ -46,8 +46,8 @@ enum arizona_type {
46#define ARIZONA_IRQ_DSP_IRQ6 17 46#define ARIZONA_IRQ_DSP_IRQ6 17
47#define ARIZONA_IRQ_DSP_IRQ7 18 47#define ARIZONA_IRQ_DSP_IRQ7 18
48#define ARIZONA_IRQ_DSP_IRQ8 19 48#define ARIZONA_IRQ_DSP_IRQ8 19
49#define ARIZONA_IRQ_SPK_SHUTDOWN_WARN 20 49#define ARIZONA_IRQ_SPK_OVERHEAT_WARN 20
50#define ARIZONA_IRQ_SPK_SHUTDOWN 21 50#define ARIZONA_IRQ_SPK_OVERHEAT 21
51#define ARIZONA_IRQ_MICDET 22 51#define ARIZONA_IRQ_MICDET 22
52#define ARIZONA_IRQ_HPDET 23 52#define ARIZONA_IRQ_HPDET 23
53#define ARIZONA_IRQ_WSEQ_DONE 24 53#define ARIZONA_IRQ_WSEQ_DONE 24
@@ -78,8 +78,31 @@ enum arizona_type {
78#define ARIZONA_IRQ_FLL1_CLOCK_OK 49 78#define ARIZONA_IRQ_FLL1_CLOCK_OK 49
79#define ARIZONA_IRQ_MICD_CLAMP_RISE 50 79#define ARIZONA_IRQ_MICD_CLAMP_RISE 50
80#define ARIZONA_IRQ_MICD_CLAMP_FALL 51 80#define ARIZONA_IRQ_MICD_CLAMP_FALL 51
81 81#define ARIZONA_IRQ_HP3R_DONE 52
82#define ARIZONA_NUM_IRQ 52 82#define ARIZONA_IRQ_HP3L_DONE 53
83#define ARIZONA_IRQ_HP2R_DONE 54
84#define ARIZONA_IRQ_HP2L_DONE 55
85#define ARIZONA_IRQ_HP1R_DONE 56
86#define ARIZONA_IRQ_HP1L_DONE 57
87#define ARIZONA_IRQ_ISRC3_CFG_ERR 58
88#define ARIZONA_IRQ_DSP_SHARED_WR_COLL 59
89#define ARIZONA_IRQ_SPK_SHUTDOWN 60
90#define ARIZONA_IRQ_SPK1R_SHORT 61
91#define ARIZONA_IRQ_SPK1L_SHORT 62
92#define ARIZONA_IRQ_HP3R_SC_NEG 63
93#define ARIZONA_IRQ_HP3R_SC_POS 64
94#define ARIZONA_IRQ_HP3L_SC_NEG 65
95#define ARIZONA_IRQ_HP3L_SC_POS 66
96#define ARIZONA_IRQ_HP2R_SC_NEG 67
97#define ARIZONA_IRQ_HP2R_SC_POS 68
98#define ARIZONA_IRQ_HP2L_SC_NEG 69
99#define ARIZONA_IRQ_HP2L_SC_POS 70
100#define ARIZONA_IRQ_HP1R_SC_NEG 71
101#define ARIZONA_IRQ_HP1R_SC_POS 72
102#define ARIZONA_IRQ_HP1L_SC_NEG 73
103#define ARIZONA_IRQ_HP1L_SC_POS 74
104
105#define ARIZONA_NUM_IRQ 75
83 106
84struct snd_soc_dapm_context; 107struct snd_soc_dapm_context;
85 108
@@ -109,6 +132,8 @@ struct arizona {
109 struct mutex clk_lock; 132 struct mutex clk_lock;
110 int clk32k_ref; 133 int clk32k_ref;
111 134
135 bool ctrlif_error;
136
112 struct snd_soc_dapm_context *dapm; 137 struct snd_soc_dapm_context *dapm;
113 138
114 int tdm_width[ARIZONA_MAX_AIF]; 139 int tdm_width[ARIZONA_MAX_AIF];
diff --git a/include/linux/mfd/arizona/registers.h b/include/linux/mfd/arizona/registers.h
index 7204d8138b24..dbd23c36de21 100644
--- a/include/linux/mfd/arizona/registers.h
+++ b/include/linux/mfd/arizona/registers.h
@@ -878,22 +878,26 @@
878#define ARIZONA_INTERRUPT_STATUS_3 0xD02 878#define ARIZONA_INTERRUPT_STATUS_3 0xD02
879#define ARIZONA_INTERRUPT_STATUS_4 0xD03 879#define ARIZONA_INTERRUPT_STATUS_4 0xD03
880#define ARIZONA_INTERRUPT_STATUS_5 0xD04 880#define ARIZONA_INTERRUPT_STATUS_5 0xD04
881#define ARIZONA_INTERRUPT_STATUS_6 0xD05
881#define ARIZONA_INTERRUPT_STATUS_1_MASK 0xD08 882#define ARIZONA_INTERRUPT_STATUS_1_MASK 0xD08
882#define ARIZONA_INTERRUPT_STATUS_2_MASK 0xD09 883#define ARIZONA_INTERRUPT_STATUS_2_MASK 0xD09
883#define ARIZONA_INTERRUPT_STATUS_3_MASK 0xD0A 884#define ARIZONA_INTERRUPT_STATUS_3_MASK 0xD0A
884#define ARIZONA_INTERRUPT_STATUS_4_MASK 0xD0B 885#define ARIZONA_INTERRUPT_STATUS_4_MASK 0xD0B
885#define ARIZONA_INTERRUPT_STATUS_5_MASK 0xD0C 886#define ARIZONA_INTERRUPT_STATUS_5_MASK 0xD0C
887#define ARIZONA_INTERRUPT_STATUS_6_MASK 0xD0D
886#define ARIZONA_INTERRUPT_CONTROL 0xD0F 888#define ARIZONA_INTERRUPT_CONTROL 0xD0F
887#define ARIZONA_IRQ2_STATUS_1 0xD10 889#define ARIZONA_IRQ2_STATUS_1 0xD10
888#define ARIZONA_IRQ2_STATUS_2 0xD11 890#define ARIZONA_IRQ2_STATUS_2 0xD11
889#define ARIZONA_IRQ2_STATUS_3 0xD12 891#define ARIZONA_IRQ2_STATUS_3 0xD12
890#define ARIZONA_IRQ2_STATUS_4 0xD13 892#define ARIZONA_IRQ2_STATUS_4 0xD13
891#define ARIZONA_IRQ2_STATUS_5 0xD14 893#define ARIZONA_IRQ2_STATUS_5 0xD14
894#define ARIZONA_IRQ2_STATUS_6 0xD15
892#define ARIZONA_IRQ2_STATUS_1_MASK 0xD18 895#define ARIZONA_IRQ2_STATUS_1_MASK 0xD18
893#define ARIZONA_IRQ2_STATUS_2_MASK 0xD19 896#define ARIZONA_IRQ2_STATUS_2_MASK 0xD19
894#define ARIZONA_IRQ2_STATUS_3_MASK 0xD1A 897#define ARIZONA_IRQ2_STATUS_3_MASK 0xD1A
895#define ARIZONA_IRQ2_STATUS_4_MASK 0xD1B 898#define ARIZONA_IRQ2_STATUS_4_MASK 0xD1B
896#define ARIZONA_IRQ2_STATUS_5_MASK 0xD1C 899#define ARIZONA_IRQ2_STATUS_5_MASK 0xD1C
900#define ARIZONA_IRQ2_STATUS_6_MASK 0xD1D
897#define ARIZONA_IRQ2_CONTROL 0xD1F 901#define ARIZONA_IRQ2_CONTROL 0xD1F
898#define ARIZONA_INTERRUPT_RAW_STATUS_2 0xD20 902#define ARIZONA_INTERRUPT_RAW_STATUS_2 0xD20
899#define ARIZONA_INTERRUPT_RAW_STATUS_3 0xD21 903#define ARIZONA_INTERRUPT_RAW_STATUS_3 0xD21
@@ -902,6 +906,7 @@
902#define ARIZONA_INTERRUPT_RAW_STATUS_6 0xD24 906#define ARIZONA_INTERRUPT_RAW_STATUS_6 0xD24
903#define ARIZONA_INTERRUPT_RAW_STATUS_7 0xD25 907#define ARIZONA_INTERRUPT_RAW_STATUS_7 0xD25
904#define ARIZONA_INTERRUPT_RAW_STATUS_8 0xD26 908#define ARIZONA_INTERRUPT_RAW_STATUS_8 0xD26
909#define ARIZONA_INTERRUPT_RAW_STATUS_9 0xD28
905#define ARIZONA_IRQ_PIN_STATUS 0xD40 910#define ARIZONA_IRQ_PIN_STATUS 0xD40
906#define ARIZONA_ADSP2_IRQ0 0xD41 911#define ARIZONA_ADSP2_IRQ0 0xD41
907#define ARIZONA_AOD_WKUP_AND_TRIG 0xD50 912#define ARIZONA_AOD_WKUP_AND_TRIG 0xD50
@@ -4691,14 +4696,14 @@
4691/* 4696/*
4692 * R3330 (0xD02) - Interrupt Status 3 4697 * R3330 (0xD02) - Interrupt Status 3
4693 */ 4698 */
4694#define ARIZONA_SPK_SHUTDOWN_WARN_EINT1 0x8000 /* SPK_SHUTDOWN_WARN_EINT1 */ 4699#define ARIZONA_SPK_OVERHEAT_WARN_EINT1 0x8000 /* SPK_OVERHEAT_WARN_EINT1 */
4695#define ARIZONA_SPK_SHUTDOWN_WARN_EINT1_MASK 0x8000 /* SPK_SHUTDOWN_WARN_EINT1 */ 4700#define ARIZONA_SPK_OVERHEAT_WARN_EINT1_MASK 0x8000 /* SPK_OVERHEAD_WARN_EINT1 */
4696#define ARIZONA_SPK_SHUTDOWN_WARN_EINT1_SHIFT 15 /* SPK_SHUTDOWN_WARN_EINT1 */ 4701#define ARIZONA_SPK_OVERHEAT_WARN_EINT1_SHIFT 15 /* SPK_OVERHEAT_WARN_EINT1 */
4697#define ARIZONA_SPK_SHUTDOWN_WARN_EINT1_WIDTH 1 /* SPK_SHUTDOWN_WARN_EINT1 */ 4702#define ARIZONA_SPK_OVERHEAT_WARN_EINT1_WIDTH 1 /* SPK_OVERHEAT_WARN_EINT1 */
4698#define ARIZONA_SPK_SHUTDOWN_EINT1 0x4000 /* SPK_SHUTDOWN_EINT1 */ 4703#define ARIZONA_SPK_OVERHEAT_EINT1 0x4000 /* SPK_OVERHEAT_EINT1 */
4699#define ARIZONA_SPK_SHUTDOWN_EINT1_MASK 0x4000 /* SPK_SHUTDOWN_EINT1 */ 4704#define ARIZONA_SPK_OVERHEAT_EINT1_MASK 0x4000 /* SPK_OVERHEAT_EINT1 */
4700#define ARIZONA_SPK_SHUTDOWN_EINT1_SHIFT 14 /* SPK_SHUTDOWN_EINT1 */ 4705#define ARIZONA_SPK_OVERHEAT_EINT1_SHIFT 14 /* SPK_OVERHEAT_EINT1 */
4701#define ARIZONA_SPK_SHUTDOWN_EINT1_WIDTH 1 /* SPK_SHUTDOWN_EINT1 */ 4706#define ARIZONA_SPK_OVERHEAT_EINT1_WIDTH 1 /* SPK_OVERHEAT_EINT1 */
4702#define ARIZONA_HPDET_EINT1 0x2000 /* HPDET_EINT1 */ 4707#define ARIZONA_HPDET_EINT1 0x2000 /* HPDET_EINT1 */
4703#define ARIZONA_HPDET_EINT1_MASK 0x2000 /* HPDET_EINT1 */ 4708#define ARIZONA_HPDET_EINT1_MASK 0x2000 /* HPDET_EINT1 */
4704#define ARIZONA_HPDET_EINT1_SHIFT 13 /* HPDET_EINT1 */ 4709#define ARIZONA_HPDET_EINT1_SHIFT 13 /* HPDET_EINT1 */
@@ -4795,6 +4800,77 @@
4795#define ARIZONA_ISRC2_CFG_ERR_EINT1_MASK 0x0040 /* ISRC2_CFG_ERR_EINT1 */ 4800#define ARIZONA_ISRC2_CFG_ERR_EINT1_MASK 0x0040 /* ISRC2_CFG_ERR_EINT1 */
4796#define ARIZONA_ISRC2_CFG_ERR_EINT1_SHIFT 6 /* ISRC2_CFG_ERR_EINT1 */ 4801#define ARIZONA_ISRC2_CFG_ERR_EINT1_SHIFT 6 /* ISRC2_CFG_ERR_EINT1 */
4797#define ARIZONA_ISRC2_CFG_ERR_EINT1_WIDTH 1 /* ISRC2_CFG_ERR_EINT1 */ 4802#define ARIZONA_ISRC2_CFG_ERR_EINT1_WIDTH 1 /* ISRC2_CFG_ERR_EINT1 */
4803#define ARIZONA_HP3R_DONE_EINT1 0x0020 /* HP3R_DONE_EINT1 */
4804#define ARIZONA_HP3R_DONE_EINT1_MASK 0x0020 /* HP3R_DONE_EINT1 */
4805#define ARIZONA_HP3R_DONE_EINT1_SHIFT 5 /* HP3R_DONE_EINT1 */
4806#define ARIZONA_HP3R_DONE_EINT1_WIDTH 1 /* HP3R_DONE_EINT1 */
4807#define ARIZONA_HP3L_DONE_EINT1 0x0010 /* HP3L_DONE_EINT1 */
4808#define ARIZONA_HP3L_DONE_EINT1_MASK 0x0010 /* HP3L_DONE_EINT1 */
4809#define ARIZONA_HP3L_DONE_EINT1_SHIFT 4 /* HP3L_DONE_EINT1 */
4810#define ARIZONA_HP3L_DONE_EINT1_WIDTH 1 /* HP3L_DONE_EINT1 */
4811#define ARIZONA_HP2R_DONE_EINT1 0x0008 /* HP2R_DONE_EINT1 */
4812#define ARIZONA_HP2R_DONE_EINT1_MASK 0x0008 /* HP2R_DONE_EINT1 */
4813#define ARIZONA_HP2R_DONE_EINT1_SHIFT 3 /* HP2R_DONE_EINT1 */
4814#define ARIZONA_HP2R_DONE_EINT1_WIDTH 1 /* HP2R_DONE_EINT1 */
4815#define ARIZONA_HP2L_DONE_EINT1 0x0004 /* HP2L_DONE_EINT1 */
4816#define ARIZONA_HP2L_DONE_EINT1_MASK 0x0004 /* HP2L_DONE_EINT1 */
4817#define ARIZONA_HP2L_DONE_EINT1_SHIFT 2 /* HP2L_DONE_EINT1 */
4818#define ARIZONA_HP2L_DONE_EINT1_WIDTH 1 /* HP2L_DONE_EINT1 */
4819#define ARIZONA_HP1R_DONE_EINT1 0x0002 /* HP1R_DONE_EINT1 */
4820#define ARIZONA_HP1R_DONE_EINT1_MASK 0x0002 /* HP1R_DONE_EINT1 */
4821#define ARIZONA_HP1R_DONE_EINT1_SHIFT 1 /* HP1R_DONE_EINT1 */
4822#define ARIZONA_HP1R_DONE_EINT1_WIDTH 1 /* HP1R_DONE_EINT1 */
4823#define ARIZONA_HP1L_DONE_EINT1 0x0001 /* HP1L_DONE_EINT1 */
4824#define ARIZONA_HP1L_DONE_EINT1_MASK 0x0001 /* HP1L_DONE_EINT1 */
4825#define ARIZONA_HP1L_DONE_EINT1_SHIFT 0 /* HP1L_DONE_EINT1 */
4826#define ARIZONA_HP1L_DONE_EINT1_WIDTH 1 /* HP1L_DONE_EINT1 */
4827
4828/*
4829 * R3331 (0xD03) - Interrupt Status 4 (Alternate layout)
4830 *
4831 * Alternate layout used on later devices, note only fields that have moved
4832 * are specified
4833 */
4834#define ARIZONA_V2_AIF3_ERR_EINT1 0x8000 /* AIF3_ERR_EINT1 */
4835#define ARIZONA_V2_AIF3_ERR_EINT1_MASK 0x8000 /* AIF3_ERR_EINT1 */
4836#define ARIZONA_V2_AIF3_ERR_EINT1_SHIFT 15 /* AIF3_ERR_EINT1 */
4837#define ARIZONA_V2_AIF3_ERR_EINT1_WIDTH 1 /* AIF3_ERR_EINT1 */
4838#define ARIZONA_V2_AIF2_ERR_EINT1 0x4000 /* AIF2_ERR_EINT1 */
4839#define ARIZONA_V2_AIF2_ERR_EINT1_MASK 0x4000 /* AIF2_ERR_EINT1 */
4840#define ARIZONA_V2_AIF2_ERR_EINT1_SHIFT 14 /* AIF2_ERR_EINT1 */
4841#define ARIZONA_V2_AIF2_ERR_EINT1_WIDTH 1 /* AIF2_ERR_EINT1 */
4842#define ARIZONA_V2_AIF1_ERR_EINT1 0x2000 /* AIF1_ERR_EINT1 */
4843#define ARIZONA_V2_AIF1_ERR_EINT1_MASK 0x2000 /* AIF1_ERR_EINT1 */
4844#define ARIZONA_V2_AIF1_ERR_EINT1_SHIFT 13 /* AIF1_ERR_EINT1 */
4845#define ARIZONA_V2_AIF1_ERR_EINT1_WIDTH 1 /* AIF1_ERR_EINT1 */
4846#define ARIZONA_V2_CTRLIF_ERR_EINT1 0x1000 /* CTRLIF_ERR_EINT1 */
4847#define ARIZONA_V2_CTRLIF_ERR_EINT1_MASK 0x1000 /* CTRLIF_ERR_EINT1 */
4848#define ARIZONA_V2_CTRLIF_ERR_EINT1_SHIFT 12 /* CTRLIF_ERR_EINT1 */
4849#define ARIZONA_V2_CTRLIF_ERR_EINT1_WIDTH 1 /* CTRLIF_ERR_EINT1 */
4850#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT1 0x0800 /* MIXER_DROPPED_SAMPLE_EINT1 */
4851#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT1_MASK 0x0800 /* MIXER_DROPPED_SAMPLE_EINT1 */
4852#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT1_SHIFT 11 /* MIXER_DROPPED_SAMPLE_EINT1 */
4853#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT1_WIDTH 1 /* MIXER_DROPPED_SAMPLE_EINT1 */
4854#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT1 0x0400 /* ASYNC_CLK_ENA_LOW_EINT1 */
4855#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT1_MASK 0x0400 /* ASYNC_CLK_ENA_LOW_EINT1 */
4856#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT1_SHIFT 10 /* ASYNC_CLK_ENA_LOW_EINT1 */
4857#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT1_WIDTH 1 /* ASYNC_CLK_ENA_LOW_EINT1 */
4858#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT1 0x0200 /* SYSCLK_ENA_LOW_EINT1 */
4859#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT1_MASK 0x0200 /* SYSCLK_ENA_LOW_EINT1 */
4860#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT1_SHIFT 9 /* SYSCLK_ENA_LOW_EINT1 */
4861#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT1_WIDTH 1 /* SYSCLK_ENA_LOW_EINT1 */
4862#define ARIZONA_V2_ISRC1_CFG_ERR_EINT1 0x0100 /* ISRC1_CFG_ERR_EINT1 */
4863#define ARIZONA_V2_ISRC1_CFG_ERR_EINT1_MASK 0x0100 /* ISRC1_CFG_ERR_EINT1 */
4864#define ARIZONA_V2_ISRC1_CFG_ERR_EINT1_SHIFT 8 /* ISRC1_CFG_ERR_EINT1 */
4865#define ARIZONA_V2_ISRC1_CFG_ERR_EINT1_WIDTH 1 /* ISRC1_CFG_ERR_EINT1 */
4866#define ARIZONA_V2_ISRC2_CFG_ERR_EINT1 0x0080 /* ISRC2_CFG_ERR_EINT1 */
4867#define ARIZONA_V2_ISRC2_CFG_ERR_EINT1_MASK 0x0080 /* ISRC2_CFG_ERR_EINT1 */
4868#define ARIZONA_V2_ISRC2_CFG_ERR_EINT1_SHIFT 7 /* ISRC2_CFG_ERR_EINT1 */
4869#define ARIZONA_V2_ISRC2_CFG_ERR_EINT1_WIDTH 1 /* ISRC2_CFG_ERR_EINT1 */
4870#define ARIZONA_V2_ISRC3_CFG_ERR_EINT1 0x0040 /* ISRC3_CFG_ERR_EINT1 */
4871#define ARIZONA_V2_ISRC3_CFG_ERR_EINT1_MASK 0x0040 /* ISRC3_CFG_ERR_EINT1 */
4872#define ARIZONA_V2_ISRC3_CFG_ERR_EINT1_SHIFT 6 /* ISRC3_CFG_ERR_EINT1 */
4873#define ARIZONA_V2_ISRC3_CFG_ERR_EINT1_WIDTH 1 /* ISRC3_CFG_ERR_EINT1 */
4798 4874
4799/* 4875/*
4800 * R3332 (0xD04) - Interrupt Status 5 4876 * R3332 (0xD04) - Interrupt Status 5
@@ -4821,6 +4897,85 @@
4821#define ARIZONA_FLL1_CLOCK_OK_EINT1_WIDTH 1 /* FLL1_CLOCK_OK_EINT1 */ 4897#define ARIZONA_FLL1_CLOCK_OK_EINT1_WIDTH 1 /* FLL1_CLOCK_OK_EINT1 */
4822 4898
4823/* 4899/*
4900 * R3332 (0xD05) - Interrupt Status 5 (Alternate layout)
4901 *
4902 * Alternate layout used on later devices, note only fields that have moved
4903 * are specified
4904 */
4905#define ARIZONA_V2_ASRC_CFG_ERR_EINT1 0x0008 /* ASRC_CFG_ERR_EINT1 */
4906#define ARIZONA_V2_ASRC_CFG_ERR_EINT1_MASK 0x0008 /* ASRC_CFG_ERR_EINT1 */
4907#define ARIZONA_V2_ASRC_CFG_ERR_EINT1_SHIFT 3 /* ASRC_CFG_ERR_EINT1 */
4908#define ARIZONA_V2_ASRC_CFG_ERR_EINT1_WIDTH 1 /* ASRC_CFG_ERR_EINT1 */
4909
4910/*
4911 * R3333 (0xD05) - Interrupt Status 6
4912 */
4913#define ARIZONA_DSP_SHARED_WR_COLL_EINT1 0x8000 /* DSP_SHARED_WR_COLL_EINT1 */
4914#define ARIZONA_DSP_SHARED_WR_COLL_EINT1_MASK 0x8000 /* DSP_SHARED_WR_COLL_EINT1 */
4915#define ARIZONA_DSP_SHARED_WR_COLL_EINT1_SHIFT 15 /* DSP_SHARED_WR_COLL_EINT1 */
4916#define ARIZONA_DSP_SHARED_WR_COLL_EINT1_WIDTH 1 /* DSP_SHARED_WR_COLL_EINT1 */
4917#define ARIZONA_SPK_SHUTDOWN_EINT1 0x4000 /* SPK_SHUTDOWN_EINT1 */
4918#define ARIZONA_SPK_SHUTDOWN_EINT1_MASK 0x4000 /* SPK_SHUTDOWN_EINT1 */
4919#define ARIZONA_SPK_SHUTDOWN_EINT1_SHIFT 14 /* SPK_SHUTDOWN_EINT1 */
4920#define ARIZONA_SPK_SHUTDOWN_EINT1_WIDTH 1 /* SPK_SHUTDOWN_EINT1 */
4921#define ARIZONA_SPK1R_SHORT_EINT1 0x2000 /* SPK1R_SHORT_EINT1 */
4922#define ARIZONA_SPK1R_SHORT_EINT1_MASK 0x2000 /* SPK1R_SHORT_EINT1 */
4923#define ARIZONA_SPK1R_SHORT_EINT1_SHIFT 13 /* SPK1R_SHORT_EINT1 */
4924#define ARIZONA_SPK1R_SHORT_EINT1_WIDTH 1 /* SPK1R_SHORT_EINT1 */
4925#define ARIZONA_SPK1L_SHORT_EINT1 0x1000 /* SPK1L_SHORT_EINT1 */
4926#define ARIZONA_SPK1L_SHORT_EINT1_MASK 0x1000 /* SPK1L_SHORT_EINT1 */
4927#define ARIZONA_SPK1L_SHORT_EINT1_SHIFT 12 /* SPK1L_SHORT_EINT1 */
4928#define ARIZONA_SPK1L_SHORT_EINT1_WIDTH 1 /* SPK1L_SHORT_EINT1 */
4929#define ARIZONA_HP3R_SC_NEG_EINT1 0x0800 /* HP3R_SC_NEG_EINT1 */
4930#define ARIZONA_HP3R_SC_NEG_EINT1_MASK 0x0800 /* HP3R_SC_NEG_EINT1 */
4931#define ARIZONA_HP3R_SC_NEG_EINT1_SHIFT 11 /* HP3R_SC_NEG_EINT1 */
4932#define ARIZONA_HP3R_SC_NEG_EINT1_WIDTH 1 /* HP3R_SC_NEG_EINT1 */
4933#define ARIZONA_HP3R_SC_POS_EINT1 0x0400 /* HP3R_SC_POS_EINT1 */
4934#define ARIZONA_HP3R_SC_POS_EINT1_MASK 0x0400 /* HP3R_SC_POS_EINT1 */
4935#define ARIZONA_HP3R_SC_POS_EINT1_SHIFT 10 /* HP3R_SC_POS_EINT1 */
4936#define ARIZONA_HP3R_SC_POS_EINT1_WIDTH 1 /* HP3R_SC_POS_EINT1 */
4937#define ARIZONA_HP3L_SC_NEG_EINT1 0x0200 /* HP3L_SC_NEG_EINT1 */
4938#define ARIZONA_HP3L_SC_NEG_EINT1_MASK 0x0200 /* HP3L_SC_NEG_EINT1 */
4939#define ARIZONA_HP3L_SC_NEG_EINT1_SHIFT 9 /* HP3L_SC_NEG_EINT1 */
4940#define ARIZONA_HP3L_SC_NEG_EINT1_WIDTH 1 /* HP3L_SC_NEG_EINT1 */
4941#define ARIZONA_HP3L_SC_POS_EINT1 0x0100 /* HP3L_SC_POS_EINT1 */
4942#define ARIZONA_HP3L_SC_POS_EINT1_MASK 0x0100 /* HP3L_SC_POS_EINT1 */
4943#define ARIZONA_HP3L_SC_POS_EINT1_SHIFT 8 /* HP3L_SC_POS_EINT1 */
4944#define ARIZONA_HP3L_SC_POS_EINT1_WIDTH 1 /* HP3L_SC_POS_EINT1 */
4945#define ARIZONA_HP2R_SC_NEG_EINT1 0x0080 /* HP2R_SC_NEG_EINT1 */
4946#define ARIZONA_HP2R_SC_NEG_EINT1_MASK 0x0080 /* HP2R_SC_NEG_EINT1 */
4947#define ARIZONA_HP2R_SC_NEG_EINT1_SHIFT 7 /* HP2R_SC_NEG_EINT1 */
4948#define ARIZONA_HP2R_SC_NEG_EINT1_WIDTH 1 /* HP2R_SC_NEG_EINT1 */
4949#define ARIZONA_HP2R_SC_POS_EINT1 0x0040 /* HP2R_SC_POS_EINT1 */
4950#define ARIZONA_HP2R_SC_POS_EINT1_MASK 0x0040 /* HP2R_SC_POS_EINT1 */
4951#define ARIZONA_HP2R_SC_POS_EINT1_SHIFT 6 /* HP2R_SC_POS_EINT1 */
4952#define ARIZONA_HP2R_SC_POS_EINT1_WIDTH 1 /* HP2R_SC_POS_EINT1 */
4953#define ARIZONA_HP2L_SC_NEG_EINT1 0x0020 /* HP2L_SC_NEG_EINT1 */
4954#define ARIZONA_HP2L_SC_NEG_EINT1_MASK 0x0020 /* HP2L_SC_NEG_EINT1 */
4955#define ARIZONA_HP2L_SC_NEG_EINT1_SHIFT 5 /* HP2L_SC_NEG_EINT1 */
4956#define ARIZONA_HP2L_SC_NEG_EINT1_WIDTH 1 /* HP2L_SC_NEG_EINT1 */
4957#define ARIZONA_HP2L_SC_POS_EINT1 0x0010 /* HP2L_SC_POS_EINT1 */
4958#define ARIZONA_HP2L_SC_POS_EINT1_MASK 0x0010 /* HP2L_SC_POS_EINT1 */
4959#define ARIZONA_HP2L_SC_POS_EINT1_SHIFT 4 /* HP2L_SC_POS_EINT1 */
4960#define ARIZONA_HP2L_SC_POS_EINT1_WIDTH 1 /* HP2L_SC_POS_EINT1 */
4961#define ARIZONA_HP1R_SC_NEG_EINT1 0x0008 /* HP1R_SC_NEG_EINT1 */
4962#define ARIZONA_HP1R_SC_NEG_EINT1_MASK 0x0008 /* HP1R_SC_NEG_EINT1 */
4963#define ARIZONA_HP1R_SC_NEG_EINT1_SHIFT 3 /* HP1R_SC_NEG_EINT1 */
4964#define ARIZONA_HP1R_SC_NEG_EINT1_WIDTH 1 /* HP1R_SC_NEG_EINT1 */
4965#define ARIZONA_HP1R_SC_POS_EINT1 0x0004 /* HP1R_SC_POS_EINT1 */
4966#define ARIZONA_HP1R_SC_POS_EINT1_MASK 0x0004 /* HP1R_SC_POS_EINT1 */
4967#define ARIZONA_HP1R_SC_POS_EINT1_SHIFT 2 /* HP1R_SC_POS_EINT1 */
4968#define ARIZONA_HP1R_SC_POS_EINT1_WIDTH 1 /* HP1R_SC_POS_EINT1 */
4969#define ARIZONA_HP1L_SC_NEG_EINT1 0x0002 /* HP1L_SC_NEG_EINT1 */
4970#define ARIZONA_HP1L_SC_NEG_EINT1_MASK 0x0002 /* HP1L_SC_NEG_EINT1 */
4971#define ARIZONA_HP1L_SC_NEG_EINT1_SHIFT 1 /* HP1L_SC_NEG_EINT1 */
4972#define ARIZONA_HP1L_SC_NEG_EINT1_WIDTH 1 /* HP1L_SC_NEG_EINT1 */
4973#define ARIZONA_HP1L_SC_POS_EINT1 0x0001 /* HP1L_SC_POS_EINT1 */
4974#define ARIZONA_HP1L_SC_POS_EINT1_MASK 0x0001 /* HP1L_SC_POS_EINT1 */
4975#define ARIZONA_HP1L_SC_POS_EINT1_SHIFT 0 /* HP1L_SC_POS_EINT1 */
4976#define ARIZONA_HP1L_SC_POS_EINT1_WIDTH 1 /* HP1L_SC_POS_EINT1 */
4977
4978/*
4824 * R3336 (0xD08) - Interrupt Status 1 Mask 4979 * R3336 (0xD08) - Interrupt Status 1 Mask
4825 */ 4980 */
4826#define ARIZONA_IM_GP4_EINT1 0x0008 /* IM_GP4_EINT1 */ 4981#define ARIZONA_IM_GP4_EINT1 0x0008 /* IM_GP4_EINT1 */
@@ -4859,14 +5014,14 @@
4859/* 5014/*
4860 * R3338 (0xD0A) - Interrupt Status 3 Mask 5015 * R3338 (0xD0A) - Interrupt Status 3 Mask
4861 */ 5016 */
4862#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT1 0x8000 /* IM_SPK_SHUTDOWN_WARN_EINT1 */ 5017#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT1 0x8000 /* IM_SPK_OVERHEAT_WARN_EINT1 */
4863#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT1_MASK 0x8000 /* IM_SPK_SHUTDOWN_WARN_EINT1 */ 5018#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT1_MASK 0x8000 /* IM_SPK_OVERHEAT_WARN_EINT1 */
4864#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT1_SHIFT 15 /* IM_SPK_SHUTDOWN_WARN_EINT1 */ 5019#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT1_SHIFT 15 /* IM_SPK_OVERHEAT_WARN_EINT1 */
4865#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT1_WIDTH 1 /* IM_SPK_SHUTDOWN_WARN_EINT1 */ 5020#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT1_WIDTH 1 /* IM_SPK_OVERHEAT_WARN_EINT1 */
4866#define ARIZONA_IM_SPK_SHUTDOWN_EINT1 0x4000 /* IM_SPK_SHUTDOWN_EINT1 */ 5021#define ARIZONA_IM_SPK_OVERHEAT_EINT1 0x4000 /* IM_SPK_OVERHEAT_EINT1 */
4867#define ARIZONA_IM_SPK_SHUTDOWN_EINT1_MASK 0x4000 /* IM_SPK_SHUTDOWN_EINT1 */ 5022#define ARIZONA_IM_SPK_OVERHEAT_EINT1_MASK 0x4000 /* IM_SPK_OVERHEAT_EINT1 */
4868#define ARIZONA_IM_SPK_SHUTDOWN_EINT1_SHIFT 14 /* IM_SPK_SHUTDOWN_EINT1 */ 5023#define ARIZONA_IM_SPK_OVERHEAT_EINT1_SHIFT 14 /* IM_SPK_OVERHEAT_EINT1 */
4869#define ARIZONA_IM_SPK_SHUTDOWN_EINT1_WIDTH 1 /* IM_SPK_SHUTDOWN_EINT1 */ 5024#define ARIZONA_IM_SPK_OVERHEAT_EINT1_WIDTH 1 /* IM_SPK_OVERHEAT_EINT1 */
4870#define ARIZONA_IM_HPDET_EINT1 0x2000 /* IM_HPDET_EINT1 */ 5025#define ARIZONA_IM_HPDET_EINT1 0x2000 /* IM_HPDET_EINT1 */
4871#define ARIZONA_IM_HPDET_EINT1_MASK 0x2000 /* IM_HPDET_EINT1 */ 5026#define ARIZONA_IM_HPDET_EINT1_MASK 0x2000 /* IM_HPDET_EINT1 */
4872#define ARIZONA_IM_HPDET_EINT1_SHIFT 13 /* IM_HPDET_EINT1 */ 5027#define ARIZONA_IM_HPDET_EINT1_SHIFT 13 /* IM_HPDET_EINT1 */
@@ -4963,6 +5118,77 @@
4963#define ARIZONA_IM_ISRC2_CFG_ERR_EINT1_MASK 0x0040 /* IM_ISRC2_CFG_ERR_EINT1 */ 5118#define ARIZONA_IM_ISRC2_CFG_ERR_EINT1_MASK 0x0040 /* IM_ISRC2_CFG_ERR_EINT1 */
4964#define ARIZONA_IM_ISRC2_CFG_ERR_EINT1_SHIFT 6 /* IM_ISRC2_CFG_ERR_EINT1 */ 5119#define ARIZONA_IM_ISRC2_CFG_ERR_EINT1_SHIFT 6 /* IM_ISRC2_CFG_ERR_EINT1 */
4965#define ARIZONA_IM_ISRC2_CFG_ERR_EINT1_WIDTH 1 /* IM_ISRC2_CFG_ERR_EINT1 */ 5120#define ARIZONA_IM_ISRC2_CFG_ERR_EINT1_WIDTH 1 /* IM_ISRC2_CFG_ERR_EINT1 */
5121#define ARIZONA_IM_HP3R_DONE_EINT1 0x0020 /* IM_HP3R_DONE_EINT1 */
5122#define ARIZONA_IM_HP3R_DONE_EINT1_MASK 0x0020 /* IM_HP3R_DONE_EINT1 */
5123#define ARIZONA_IM_HP3R_DONE_EINT1_SHIFT 5 /* IM_HP3R_DONE_EINT1 */
5124#define ARIZONA_IM_HP3R_DONE_EINT1_WIDTH 1 /* IM_HP3R_DONE_EINT1 */
5125#define ARIZONA_IM_HP3L_DONE_EINT1 0x0010 /* IM_HP3L_DONE_EINT1 */
5126#define ARIZONA_IM_HP3L_DONE_EINT1_MASK 0x0010 /* IM_HP3L_DONE_EINT1 */
5127#define ARIZONA_IM_HP3L_DONE_EINT1_SHIFT 4 /* IM_HP3L_DONE_EINT1 */
5128#define ARIZONA_IM_HP3L_DONE_EINT1_WIDTH 1 /* IM_HP3L_DONE_EINT1 */
5129#define ARIZONA_IM_HP2R_DONE_EINT1 0x0008 /* IM_HP2R_DONE_EINT1 */
5130#define ARIZONA_IM_HP2R_DONE_EINT1_MASK 0x0008 /* IM_HP2R_DONE_EINT1 */
5131#define ARIZONA_IM_HP2R_DONE_EINT1_SHIFT 3 /* IM_HP2R_DONE_EINT1 */
5132#define ARIZONA_IM_HP2R_DONE_EINT1_WIDTH 1 /* IM_HP2R_DONE_EINT1 */
5133#define ARIZONA_IM_HP2L_DONE_EINT1 0x0004 /* IM_HP2L_DONE_EINT1 */
5134#define ARIZONA_IM_HP2L_DONE_EINT1_MASK 0x0004 /* IM_HP2L_DONE_EINT1 */
5135#define ARIZONA_IM_HP2L_DONE_EINT1_SHIFT 2 /* IM_HP2L_DONE_EINT1 */
5136#define ARIZONA_IM_HP2L_DONE_EINT1_WIDTH 1 /* IM_HP2L_DONE_EINT1 */
5137#define ARIZONA_IM_HP1R_DONE_EINT1 0x0002 /* IM_HP1R_DONE_EINT1 */
5138#define ARIZONA_IM_HP1R_DONE_EINT1_MASK 0x0002 /* IM_HP1R_DONE_EINT1 */
5139#define ARIZONA_IM_HP1R_DONE_EINT1_SHIFT 1 /* IM_HP1R_DONE_EINT1 */
5140#define ARIZONA_IM_HP1R_DONE_EINT1_WIDTH 1 /* IM_HP1R_DONE_EINT1 */
5141#define ARIZONA_IM_HP1L_DONE_EINT1 0x0001 /* IM_HP1L_DONE_EINT1 */
5142#define ARIZONA_IM_HP1L_DONE_EINT1_MASK 0x0001 /* IM_HP1L_DONE_EINT1 */
5143#define ARIZONA_IM_HP1L_DONE_EINT1_SHIFT 0 /* IM_HP1L_DONE_EINT1 */
5144#define ARIZONA_IM_HP1L_DONE_EINT1_WIDTH 1 /* IM_HP1L_DONE_EINT1 */
5145
5146/*
5147 * R3339 (0xD0B) - Interrupt Status 4 Mask (Alternate layout)
5148 *
5149 * Alternate layout used on later devices, note only fields that have moved
5150 * are specified
5151 */
5152#define ARIZONA_V2_IM_AIF3_ERR_EINT1 0x8000 /* IM_AIF3_ERR_EINT1 */
5153#define ARIZONA_V2_IM_AIF3_ERR_EINT1_MASK 0x8000 /* IM_AIF3_ERR_EINT1 */
5154#define ARIZONA_V2_IM_AIF3_ERR_EINT1_SHIFT 15 /* IM_AIF3_ERR_EINT1 */
5155#define ARIZONA_V2_IM_AIF3_ERR_EINT1_WIDTH 1 /* IM_AIF3_ERR_EINT1 */
5156#define ARIZONA_V2_IM_AIF2_ERR_EINT1 0x4000 /* IM_AIF2_ERR_EINT1 */
5157#define ARIZONA_V2_IM_AIF2_ERR_EINT1_MASK 0x4000 /* IM_AIF2_ERR_EINT1 */
5158#define ARIZONA_V2_IM_AIF2_ERR_EINT1_SHIFT 14 /* IM_AIF2_ERR_EINT1 */
5159#define ARIZONA_V2_IM_AIF2_ERR_EINT1_WIDTH 1 /* IM_AIF2_ERR_EINT1 */
5160#define ARIZONA_V2_IM_AIF1_ERR_EINT1 0x2000 /* IM_AIF1_ERR_EINT1 */
5161#define ARIZONA_V2_IM_AIF1_ERR_EINT1_MASK 0x2000 /* IM_AIF1_ERR_EINT1 */
5162#define ARIZONA_V2_IM_AIF1_ERR_EINT1_SHIFT 13 /* IM_AIF1_ERR_EINT1 */
5163#define ARIZONA_V2_IM_AIF1_ERR_EINT1_WIDTH 1 /* IM_AIF1_ERR_EINT1 */
5164#define ARIZONA_V2_IM_CTRLIF_ERR_EINT1 0x1000 /* IM_CTRLIF_ERR_EINT1 */
5165#define ARIZONA_V2_IM_CTRLIF_ERR_EINT1_MASK 0x1000 /* IM_CTRLIF_ERR_EINT1 */
5166#define ARIZONA_V2_IM_CTRLIF_ERR_EINT1_SHIFT 12 /* IM_CTRLIF_ERR_EINT1 */
5167#define ARIZONA_V2_IM_CTRLIF_ERR_EINT1_WIDTH 1 /* IM_CTRLIF_ERR_EINT1 */
5168#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT1 0x0800 /* IM_MIXER_DROPPED_SAMPLE_EINT1 */
5169#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT1_MASK 0x0800 /* IM_MIXER_DROPPED_SAMPLE_EINT1 */
5170#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT1_SHIFT 11 /* IM_MIXER_DROPPED_SAMPLE_EINT1 */
5171#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT1_WIDTH 1 /* IM_MIXER_DROPPED_SAMPLE_EINT1 */
5172#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT1 0x0400 /* IM_ASYNC_CLK_ENA_LOW_EINT1 */
5173#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT1_MASK 0x0400 /* IM_ASYNC_CLK_ENA_LOW_EINT1 */
5174#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT1_SHIFT 10 /* IM_ASYNC_CLK_ENA_LOW_EINT1 */
5175#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT1_WIDTH 1 /* IM_ASYNC_CLK_ENA_LOW_EINT1 */
5176#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT1 0x0200 /* IM_SYSCLK_ENA_LOW_EINT1 */
5177#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT1_MASK 0x0200 /* IM_SYSCLK_ENA_LOW_EINT1 */
5178#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT1_SHIFT 9 /* IM_SYSCLK_ENA_LOW_EINT1 */
5179#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT1_WIDTH 1 /* IM_SYSCLK_ENA_LOW_EINT1 */
5180#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT1 0x0100 /* IM_ISRC1_CFG_ERR_EINT1 */
5181#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT1_MASK 0x0100 /* IM_ISRC1_CFG_ERR_EINT1 */
5182#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT1_SHIFT 8 /* IM_ISRC1_CFG_ERR_EINT1 */
5183#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT1_WIDTH 1 /* IM_ISRC1_CFG_ERR_EINT1 */
5184#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT1 0x0080 /* IM_ISRC2_CFG_ERR_EINT1 */
5185#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT1_MASK 0x0080 /* IM_ISRC2_CFG_ERR_EINT1 */
5186#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT1_SHIFT 7 /* IM_ISRC2_CFG_ERR_EINT1 */
5187#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT1_WIDTH 1 /* IM_ISRC2_CFG_ERR_EINT1 */
5188#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT1 0x0040 /* IM_ISRC3_CFG_ERR_EINT1 */
5189#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT1_MASK 0x0040 /* IM_ISRC3_CFG_ERR_EINT1 */
5190#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT1_SHIFT 6 /* IM_ISRC3_CFG_ERR_EINT1 */
5191#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT1_WIDTH 1 /* IM_ISRC3_CFG_ERR_EINT1 */
4966 5192
4967/* 5193/*
4968 * R3340 (0xD0C) - Interrupt Status 5 Mask 5194 * R3340 (0xD0C) - Interrupt Status 5 Mask
@@ -4989,6 +5215,85 @@
4989#define ARIZONA_IM_FLL1_CLOCK_OK_EINT1_WIDTH 1 /* IM_FLL1_CLOCK_OK_EINT1 */ 5215#define ARIZONA_IM_FLL1_CLOCK_OK_EINT1_WIDTH 1 /* IM_FLL1_CLOCK_OK_EINT1 */
4990 5216
4991/* 5217/*
5218 * R3340 (0xD0C) - Interrupt Status 5 Mask (Alternate layout)
5219 *
5220 * Alternate layout used on later devices, note only fields that have moved
5221 * are specified
5222 */
5223#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT1 0x0008 /* IM_ASRC_CFG_ERR_EINT1 */
5224#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT1_MASK 0x0008 /* IM_ASRC_CFG_ERR_EINT1 */
5225#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT1_SHIFT 3 /* IM_ASRC_CFG_ERR_EINT1 */
5226#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT1_WIDTH 1 /* IM_ASRC_CFG_ERR_EINT1 */
5227
5228/*
5229 * R3341 (0xD0D) - Interrupt Status 6 Mask
5230 */
5231#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT1 0x8000 /* IM_DSP_SHARED_WR_COLL_EINT1 */
5232#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT1_MASK 0x8000 /* IM_DSP_SHARED_WR_COLL_EINT1 */
5233#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT1_SHIFT 15 /* IM_DSP_SHARED_WR_COLL_EINT1 */
5234#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT1_WIDTH 1 /* IM_DSP_SHARED_WR_COLL_EINT1 */
5235#define ARIZONA_IM_SPK_SHUTDOWN_EINT1 0x4000 /* IM_SPK_SHUTDOWN_EINT1 */
5236#define ARIZONA_IM_SPK_SHUTDOWN_EINT1_MASK 0x4000 /* IM_SPK_SHUTDOWN_EINT1 */
5237#define ARIZONA_IM_SPK_SHUTDOWN_EINT1_SHIFT 14 /* IM_SPK_SHUTDOWN_EINT1 */
5238#define ARIZONA_IM_SPK_SHUTDOWN_EINT1_WIDTH 1 /* IM_SPK_SHUTDOWN_EINT1 */
5239#define ARIZONA_IM_SPK1R_SHORT_EINT1 0x2000 /* IM_SPK1R_SHORT_EINT1 */
5240#define ARIZONA_IM_SPK1R_SHORT_EINT1_MASK 0x2000 /* IM_SPK1R_SHORT_EINT1 */
5241#define ARIZONA_IM_SPK1R_SHORT_EINT1_SHIFT 13 /* IM_SPK1R_SHORT_EINT1 */
5242#define ARIZONA_IM_SPK1R_SHORT_EINT1_WIDTH 1 /* IM_SPK1R_SHORT_EINT1 */
5243#define ARIZONA_IM_SPK1L_SHORT_EINT1 0x1000 /* IM_SPK1L_SHORT_EINT1 */
5244#define ARIZONA_IM_SPK1L_SHORT_EINT1_MASK 0x1000 /* IM_SPK1L_SHORT_EINT1 */
5245#define ARIZONA_IM_SPK1L_SHORT_EINT1_SHIFT 12 /* IM_SPK1L_SHORT_EINT1 */
5246#define ARIZONA_IM_SPK1L_SHORT_EINT1_WIDTH 1 /* IM_SPK1L_SHORT_EINT1 */
5247#define ARIZONA_IM_HP3R_SC_NEG_EINT1 0x0800 /* IM_HP3R_SC_NEG_EINT1 */
5248#define ARIZONA_IM_HP3R_SC_NEG_EINT1_MASK 0x0800 /* IM_HP3R_SC_NEG_EINT1 */
5249#define ARIZONA_IM_HP3R_SC_NEG_EINT1_SHIFT 11 /* IM_HP3R_SC_NEG_EINT1 */
5250#define ARIZONA_IM_HP3R_SC_NEG_EINT1_WIDTH 1 /* IM_HP3R_SC_NEG_EINT1 */
5251#define ARIZONA_IM_HP3R_SC_POS_EINT1 0x0400 /* IM_HP3R_SC_POS_EINT1 */
5252#define ARIZONA_IM_HP3R_SC_POS_EINT1_MASK 0x0400 /* IM_HP3R_SC_POS_EINT1 */
5253#define ARIZONA_IM_HP3R_SC_POS_EINT1_SHIFT 10 /* IM_HP3R_SC_POS_EINT1 */
5254#define ARIZONA_IM_HP3R_SC_POS_EINT1_WIDTH 1 /* IM_HP3R_SC_POS_EINT1 */
5255#define ARIZONA_IM_HP3L_SC_NEG_EINT1 0x0200 /* IM_HP3L_SC_NEG_EINT1 */
5256#define ARIZONA_IM_HP3L_SC_NEG_EINT1_MASK 0x0200 /* IM_HP3L_SC_NEG_EINT1 */
5257#define ARIZONA_IM_HP3L_SC_NEG_EINT1_SHIFT 9 /* IM_HP3L_SC_NEG_EINT1 */
5258#define ARIZONA_IM_HP3L_SC_NEG_EINT1_WIDTH 1 /* IM_HP3L_SC_NEG_EINT1 */
5259#define ARIZONA_IM_HP3L_SC_POS_EINT1 0x0100 /* IM_HP3L_SC_POS_EINT1 */
5260#define ARIZONA_IM_HP3L_SC_POS_EINT1_MASK 0x0100 /* IM_HP3L_SC_POS_EINT1 */
5261#define ARIZONA_IM_HP3L_SC_POS_EINT1_SHIFT 8 /* IM_HP3L_SC_POS_EINT1 */
5262#define ARIZONA_IM_HP3L_SC_POS_EINT1_WIDTH 1 /* IM_HP3L_SC_POS_EINT1 */
5263#define ARIZONA_IM_HP2R_SC_NEG_EINT1 0x0080 /* IM_HP2R_SC_NEG_EINT1 */
5264#define ARIZONA_IM_HP2R_SC_NEG_EINT1_MASK 0x0080 /* IM_HP2R_SC_NEG_EINT1 */
5265#define ARIZONA_IM_HP2R_SC_NEG_EINT1_SHIFT 7 /* IM_HP2R_SC_NEG_EINT1 */
5266#define ARIZONA_IM_HP2R_SC_NEG_EINT1_WIDTH 1 /* IM_HP2R_SC_NEG_EINT1 */
5267#define ARIZONA_IM_HP2R_SC_POS_EINT1 0x0040 /* IM_HP2R_SC_POS_EINT1 */
5268#define ARIZONA_IM_HP2R_SC_POS_EINT1_MASK 0x0040 /* IM_HP2R_SC_POS_EINT1 */
5269#define ARIZONA_IM_HP2R_SC_POS_EINT1_SHIFT 6 /* IM_HP2R_SC_POS_EINT1 */
5270#define ARIZONA_IM_HP2R_SC_POS_EINT1_WIDTH 1 /* IM_HP2R_SC_POS_EINT1 */
5271#define ARIZONA_IM_HP2L_SC_NEG_EINT1 0x0020 /* IM_HP2L_SC_NEG_EINT1 */
5272#define ARIZONA_IM_HP2L_SC_NEG_EINT1_MASK 0x0020 /* IM_HP2L_SC_NEG_EINT1 */
5273#define ARIZONA_IM_HP2L_SC_NEG_EINT1_SHIFT 5 /* IM_HP2L_SC_NEG_EINT1 */
5274#define ARIZONA_IM_HP2L_SC_NEG_EINT1_WIDTH 1 /* IM_HP2L_SC_NEG_EINT1 */
5275#define ARIZONA_IM_HP2L_SC_POS_EINT1 0x0010 /* IM_HP2L_SC_POS_EINT1 */
5276#define ARIZONA_IM_HP2L_SC_POS_EINT1_MASK 0x0010 /* IM_HP2L_SC_POS_EINT1 */
5277#define ARIZONA_IM_HP2L_SC_POS_EINT1_SHIFT 4 /* IM_HP2L_SC_POS_EINT1 */
5278#define ARIZONA_IM_HP2L_SC_POS_EINT1_WIDTH 1 /* IM_HP2L_SC_POS_EINT1 */
5279#define ARIZONA_IM_HP1R_SC_NEG_EINT1 0x0008 /* IM_HP1R_SC_NEG_EINT1 */
5280#define ARIZONA_IM_HP1R_SC_NEG_EINT1_MASK 0x0008 /* IM_HP1R_SC_NEG_EINT1 */
5281#define ARIZONA_IM_HP1R_SC_NEG_EINT1_SHIFT 3 /* IM_HP1R_SC_NEG_EINT1 */
5282#define ARIZONA_IM_HP1R_SC_NEG_EINT1_WIDTH 1 /* IM_HP1R_SC_NEG_EINT1 */
5283#define ARIZONA_IM_HP1R_SC_POS_EINT1 0x0004 /* IM_HP1R_SC_POS_EINT1 */
5284#define ARIZONA_IM_HP1R_SC_POS_EINT1_MASK 0x0004 /* IM_HP1R_SC_POS_EINT1 */
5285#define ARIZONA_IM_HP1R_SC_POS_EINT1_SHIFT 2 /* IM_HP1R_SC_POS_EINT1 */
5286#define ARIZONA_IM_HP1R_SC_POS_EINT1_WIDTH 1 /* IM_HP1R_SC_POS_EINT1 */
5287#define ARIZONA_IM_HP1L_SC_NEG_EINT1 0x0002 /* IM_HP1L_SC_NEG_EINT1 */
5288#define ARIZONA_IM_HP1L_SC_NEG_EINT1_MASK 0x0002 /* IM_HP1L_SC_NEG_EINT1 */
5289#define ARIZONA_IM_HP1L_SC_NEG_EINT1_SHIFT 1 /* IM_HP1L_SC_NEG_EINT1 */
5290#define ARIZONA_IM_HP1L_SC_NEG_EINT1_WIDTH 1 /* IM_HP1L_SC_NEG_EINT1 */
5291#define ARIZONA_IM_HP1L_SC_POS_EINT1 0x0001 /* IM_HP1L_SC_POS_EINT1 */
5292#define ARIZONA_IM_HP1L_SC_POS_EINT1_MASK 0x0001 /* IM_HP1L_SC_POS_EINT1 */
5293#define ARIZONA_IM_HP1L_SC_POS_EINT1_SHIFT 0 /* IM_HP1L_SC_POS_EINT1 */
5294#define ARIZONA_IM_HP1L_SC_POS_EINT1_WIDTH 1 /* IM_HP1L_SC_POS_EINT1 */
5295
5296/*
4992 * R3343 (0xD0F) - Interrupt Control 5297 * R3343 (0xD0F) - Interrupt Control
4993 */ 5298 */
4994#define ARIZONA_IM_IRQ1 0x0001 /* IM_IRQ1 */ 5299#define ARIZONA_IM_IRQ1 0x0001 /* IM_IRQ1 */
@@ -5035,14 +5340,14 @@
5035/* 5340/*
5036 * R3346 (0xD12) - IRQ2 Status 3 5341 * R3346 (0xD12) - IRQ2 Status 3
5037 */ 5342 */
5038#define ARIZONA_SPK_SHUTDOWN_WARN_EINT2 0x8000 /* SPK_SHUTDOWN_WARN_EINT2 */ 5343#define ARIZONA_SPK_OVERHEAT_WARN_EINT2 0x8000 /* SPK_OVERHEAT_WARN_EINT2 */
5039#define ARIZONA_SPK_SHUTDOWN_WARN_EINT2_MASK 0x8000 /* SPK_SHUTDOWN_WARN_EINT2 */ 5344#define ARIZONA_SPK_OVERHEAT_WARN_EINT2_MASK 0x8000 /* SPK_OVERHEAT_WARN_EINT2 */
5040#define ARIZONA_SPK_SHUTDOWN_WARN_EINT2_SHIFT 15 /* SPK_SHUTDOWN_WARN_EINT2 */ 5345#define ARIZONA_SPK_OVERHEAT_WARN_EINT2_SHIFT 15 /* SPK_OVERHEAT_WARN_EINT2 */
5041#define ARIZONA_SPK_SHUTDOWN_WARN_EINT2_WIDTH 1 /* SPK_SHUTDOWN_WARN_EINT2 */ 5346#define ARIZONA_SPK_OVERHEAT_WARN_EINT2_WIDTH 1 /* SPK_OVERHEAT_WARN_EINT2 */
5042#define ARIZONA_SPK_SHUTDOWN_EINT2 0x4000 /* SPK_SHUTDOWN_EINT2 */ 5347#define ARIZONA_SPK_OVERHEAT_EINT2 0x4000 /* SPK_OVERHEAT_EINT2 */
5043#define ARIZONA_SPK_SHUTDOWN_EINT2_MASK 0x4000 /* SPK_SHUTDOWN_EINT2 */ 5348#define ARIZONA_SPK_OVERHEAT_EINT2_MASK 0x4000 /* SPK_OVERHEAT_EINT2 */
5044#define ARIZONA_SPK_SHUTDOWN_EINT2_SHIFT 14 /* SPK_SHUTDOWN_EINT2 */ 5349#define ARIZONA_SPK_OVERHEAT_EINT2_SHIFT 14 /* SPK_OVERHEAT_EINT2 */
5045#define ARIZONA_SPK_SHUTDOWN_EINT2_WIDTH 1 /* SPK_SHUTDOWN_EINT2 */ 5350#define ARIZONA_SPK_OVERHEAT_EINT2_WIDTH 1 /* SPK_OVERHEAT_EINT2 */
5046#define ARIZONA_HPDET_EINT2 0x2000 /* HPDET_EINT2 */ 5351#define ARIZONA_HPDET_EINT2 0x2000 /* HPDET_EINT2 */
5047#define ARIZONA_HPDET_EINT2_MASK 0x2000 /* HPDET_EINT2 */ 5352#define ARIZONA_HPDET_EINT2_MASK 0x2000 /* HPDET_EINT2 */
5048#define ARIZONA_HPDET_EINT2_SHIFT 13 /* HPDET_EINT2 */ 5353#define ARIZONA_HPDET_EINT2_SHIFT 13 /* HPDET_EINT2 */
@@ -5139,6 +5444,77 @@
5139#define ARIZONA_ISRC2_CFG_ERR_EINT2_MASK 0x0040 /* ISRC2_CFG_ERR_EINT2 */ 5444#define ARIZONA_ISRC2_CFG_ERR_EINT2_MASK 0x0040 /* ISRC2_CFG_ERR_EINT2 */
5140#define ARIZONA_ISRC2_CFG_ERR_EINT2_SHIFT 6 /* ISRC2_CFG_ERR_EINT2 */ 5445#define ARIZONA_ISRC2_CFG_ERR_EINT2_SHIFT 6 /* ISRC2_CFG_ERR_EINT2 */
5141#define ARIZONA_ISRC2_CFG_ERR_EINT2_WIDTH 1 /* ISRC2_CFG_ERR_EINT2 */ 5446#define ARIZONA_ISRC2_CFG_ERR_EINT2_WIDTH 1 /* ISRC2_CFG_ERR_EINT2 */
5447#define ARIZONA_HP3R_DONE_EINT2 0x0020 /* HP3R_DONE_EINT2 */
5448#define ARIZONA_HP3R_DONE_EINT2_MASK 0x0020 /* HP3R_DONE_EINT2 */
5449#define ARIZONA_HP3R_DONE_EINT2_SHIFT 5 /* HP3R_DONE_EINT2 */
5450#define ARIZONA_HP3R_DONE_EINT2_WIDTH 1 /* HP3R_DONE_EINT2 */
5451#define ARIZONA_HP3L_DONE_EINT2 0x0010 /* HP3L_DONE_EINT2 */
5452#define ARIZONA_HP3L_DONE_EINT2_MASK 0x0010 /* HP3L_DONE_EINT2 */
5453#define ARIZONA_HP3L_DONE_EINT2_SHIFT 4 /* HP3L_DONE_EINT2 */
5454#define ARIZONA_HP3L_DONE_EINT2_WIDTH 1 /* HP3L_DONE_EINT2 */
5455#define ARIZONA_HP2R_DONE_EINT2 0x0008 /* HP2R_DONE_EINT2 */
5456#define ARIZONA_HP2R_DONE_EINT2_MASK 0x0008 /* HP2R_DONE_EINT2 */
5457#define ARIZONA_HP2R_DONE_EINT2_SHIFT 3 /* HP2R_DONE_EINT2 */
5458#define ARIZONA_HP2R_DONE_EINT2_WIDTH 1 /* HP2R_DONE_EINT2 */
5459#define ARIZONA_HP2L_DONE_EINT2 0x0004 /* HP2L_DONE_EINT2 */
5460#define ARIZONA_HP2L_DONE_EINT2_MASK 0x0004 /* HP2L_DONE_EINT2 */
5461#define ARIZONA_HP2L_DONE_EINT2_SHIFT 2 /* HP2L_DONE_EINT2 */
5462#define ARIZONA_HP2L_DONE_EINT2_WIDTH 1 /* HP2L_DONE_EINT2 */
5463#define ARIZONA_HP1R_DONE_EINT2 0x0002 /* HP1R_DONE_EINT2 */
5464#define ARIZONA_HP1R_DONE_EINT2_MASK 0x0002 /* HP1R_DONE_EINT2 */
5465#define ARIZONA_HP1R_DONE_EINT2_SHIFT 1 /* HP1R_DONE_EINT2 */
5466#define ARIZONA_HP1R_DONE_EINT2_WIDTH 1 /* HP1R_DONE_EINT2 */
5467#define ARIZONA_HP1L_DONE_EINT2 0x0001 /* HP1L_DONE_EINT2 */
5468#define ARIZONA_HP1L_DONE_EINT2_MASK 0x0001 /* HP1L_DONE_EINT2 */
5469#define ARIZONA_HP1L_DONE_EINT2_SHIFT 0 /* HP1L_DONE_EINT2 */
5470#define ARIZONA_HP1L_DONE_EINT2_WIDTH 1 /* HP1L_DONE_EINT2 */
5471
5472/*
5473 * R3347 (0xD13) - IRQ2 Status 4 (Alternate layout)
5474 *
5475 * Alternate layout used on later devices, note only fields that have moved
5476 * are specified
5477 */
5478#define ARIZONA_V2_AIF3_ERR_EINT2 0x8000 /* AIF3_ERR_EINT2 */
5479#define ARIZONA_V2_AIF3_ERR_EINT2_MASK 0x8000 /* AIF3_ERR_EINT2 */
5480#define ARIZONA_V2_AIF3_ERR_EINT2_SHIFT 15 /* AIF3_ERR_EINT2 */
5481#define ARIZONA_V2_AIF3_ERR_EINT2_WIDTH 1 /* AIF3_ERR_EINT2 */
5482#define ARIZONA_V2_AIF2_ERR_EINT2 0x4000 /* AIF2_ERR_EINT2 */
5483#define ARIZONA_V2_AIF2_ERR_EINT2_MASK 0x4000 /* AIF2_ERR_EINT2 */
5484#define ARIZONA_V2_AIF2_ERR_EINT2_SHIFT 14 /* AIF2_ERR_EINT2 */
5485#define ARIZONA_V2_AIF2_ERR_EINT2_WIDTH 1 /* AIF2_ERR_EINT2 */
5486#define ARIZONA_V2_AIF1_ERR_EINT2 0x2000 /* AIF1_ERR_EINT2 */
5487#define ARIZONA_V2_AIF1_ERR_EINT2_MASK 0x2000 /* AIF1_ERR_EINT2 */
5488#define ARIZONA_V2_AIF1_ERR_EINT2_SHIFT 13 /* AIF1_ERR_EINT2 */
5489#define ARIZONA_V2_AIF1_ERR_EINT2_WIDTH 1 /* AIF1_ERR_EINT2 */
5490#define ARIZONA_V2_CTRLIF_ERR_EINT2 0x1000 /* CTRLIF_ERR_EINT2 */
5491#define ARIZONA_V2_CTRLIF_ERR_EINT2_MASK 0x1000 /* CTRLIF_ERR_EINT2 */
5492#define ARIZONA_V2_CTRLIF_ERR_EINT2_SHIFT 12 /* CTRLIF_ERR_EINT2 */
5493#define ARIZONA_V2_CTRLIF_ERR_EINT2_WIDTH 1 /* CTRLIF_ERR_EINT2 */
5494#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT2 0x0800 /* MIXER_DROPPED_SAMPLE_EINT2 */
5495#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT2_MASK 0x0800 /* MIXER_DROPPED_SAMPLE_EINT2 */
5496#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT2_SHIFT 11 /* MIXER_DROPPED_SAMPLE_EINT2 */
5497#define ARIZONA_V2_MIXER_DROPPED_SAMPLE_EINT2_WIDTH 1 /* MIXER_DROPPED_SAMPLE_EINT2 */
5498#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT2 0x0400 /* ASYNC_CLK_ENA_LOW_EINT2 */
5499#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT2_MASK 0x0400 /* ASYNC_CLK_ENA_LOW_EINT2 */
5500#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT2_SHIFT 10 /* ASYNC_CLK_ENA_LOW_EINT2 */
5501#define ARIZONA_V2_ASYNC_CLK_ENA_LOW_EINT2_WIDTH 1 /* ASYNC_CLK_ENA_LOW_EINT2 */
5502#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT2 0x0200 /* SYSCLK_ENA_LOW_EINT2 */
5503#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT2_MASK 0x0200 /* SYSCLK_ENA_LOW_EINT2 */
5504#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT2_SHIFT 9 /* SYSCLK_ENA_LOW_EINT2 */
5505#define ARIZONA_V2_SYSCLK_ENA_LOW_EINT2_WIDTH 1 /* SYSCLK_ENA_LOW_EINT2 */
5506#define ARIZONA_V2_ISRC1_CFG_ERR_EINT2 0x0100 /* ISRC1_CFG_ERR_EINT2 */
5507#define ARIZONA_V2_ISRC1_CFG_ERR_EINT2_MASK 0x0100 /* ISRC1_CFG_ERR_EINT2 */
5508#define ARIZONA_V2_ISRC1_CFG_ERR_EINT2_SHIFT 8 /* ISRC1_CFG_ERR_EINT2 */
5509#define ARIZONA_V2_ISRC1_CFG_ERR_EINT2_WIDTH 1 /* ISRC1_CFG_ERR_EINT2 */
5510#define ARIZONA_V2_ISRC2_CFG_ERR_EINT2 0x0080 /* ISRC2_CFG_ERR_EINT2 */
5511#define ARIZONA_V2_ISRC2_CFG_ERR_EINT2_MASK 0x0080 /* ISRC2_CFG_ERR_EINT2 */
5512#define ARIZONA_V2_ISRC2_CFG_ERR_EINT2_SHIFT 7 /* ISRC2_CFG_ERR_EINT2 */
5513#define ARIZONA_V2_ISRC2_CFG_ERR_EINT2_WIDTH 1 /* ISRC2_CFG_ERR_EINT2 */
5514#define ARIZONA_V2_ISRC3_CFG_ERR_EINT2 0x0040 /* ISRC3_CFG_ERR_EINT2 */
5515#define ARIZONA_V2_ISRC3_CFG_ERR_EINT2_MASK 0x0040 /* ISRC3_CFG_ERR_EINT2 */
5516#define ARIZONA_V2_ISRC3_CFG_ERR_EINT2_SHIFT 6 /* ISRC3_CFG_ERR_EINT2 */
5517#define ARIZONA_V2_ISRC3_CFG_ERR_EINT2_WIDTH 1 /* ISRC3_CFG_ERR_EINT2 */
5142 5518
5143/* 5519/*
5144 * R3348 (0xD14) - IRQ2 Status 5 5520 * R3348 (0xD14) - IRQ2 Status 5
@@ -5165,6 +5541,85 @@
5165#define ARIZONA_FLL1_CLOCK_OK_EINT2_WIDTH 1 /* FLL1_CLOCK_OK_EINT2 */ 5541#define ARIZONA_FLL1_CLOCK_OK_EINT2_WIDTH 1 /* FLL1_CLOCK_OK_EINT2 */
5166 5542
5167/* 5543/*
5544 * R3348 (0xD14) - IRQ2 Status 5 (Alternate layout)
5545 *
5546 * Alternate layout used on later devices, note only fields that have moved
5547 * are specified
5548 */
5549#define ARIZONA_V2_ASRC_CFG_ERR_EINT2 0x0008 /* ASRC_CFG_ERR_EINT2 */
5550#define ARIZONA_V2_ASRC_CFG_ERR_EINT2_MASK 0x0008 /* ASRC_CFG_ERR_EINT2 */
5551#define ARIZONA_V2_ASRC_CFG_ERR_EINT2_SHIFT 3 /* ASRC_CFG_ERR_EINT2 */
5552#define ARIZONA_V2_ASRC_CFG_ERR_EINT2_WIDTH 1 /* ASRC_CFG_ERR_EINT2 */
5553
5554/*
5555 * R3349 (0xD15) - IRQ2 Status 6
5556 */
5557#define ARIZONA_DSP_SHARED_WR_COLL_EINT2 0x8000 /* DSP_SHARED_WR_COLL_EINT2 */
5558#define ARIZONA_DSP_SHARED_WR_COLL_EINT2_MASK 0x8000 /* DSP_SHARED_WR_COLL_EINT2 */
5559#define ARIZONA_DSP_SHARED_WR_COLL_EINT2_SHIFT 15 /* DSP_SHARED_WR_COLL_EINT2 */
5560#define ARIZONA_DSP_SHARED_WR_COLL_EINT2_WIDTH 1 /* DSP_SHARED_WR_COLL_EINT2 */
5561#define ARIZONA_SPK_SHUTDOWN_EINT2 0x4000 /* SPK_SHUTDOWN_EINT2 */
5562#define ARIZONA_SPK_SHUTDOWN_EINT2_MASK 0x4000 /* SPK_SHUTDOWN_EINT2 */
5563#define ARIZONA_SPK_SHUTDOWN_EINT2_SHIFT 14 /* SPK_SHUTDOWN_EINT2 */
5564#define ARIZONA_SPK_SHUTDOWN_EINT2_WIDTH 1 /* SPK_SHUTDOWN_EINT2 */
5565#define ARIZONA_SPK1R_SHORT_EINT2 0x2000 /* SPK1R_SHORT_EINT2 */
5566#define ARIZONA_SPK1R_SHORT_EINT2_MASK 0x2000 /* SPK1R_SHORT_EINT2 */
5567#define ARIZONA_SPK1R_SHORT_EINT2_SHIFT 13 /* SPK1R_SHORT_EINT2 */
5568#define ARIZONA_SPK1R_SHORT_EINT2_WIDTH 1 /* SPK1R_SHORT_EINT2 */
5569#define ARIZONA_SPK1L_SHORT_EINT2 0x1000 /* SPK1L_SHORT_EINT2 */
5570#define ARIZONA_SPK1L_SHORT_EINT2_MASK 0x1000 /* SPK1L_SHORT_EINT2 */
5571#define ARIZONA_SPK1L_SHORT_EINT2_SHIFT 12 /* SPK1L_SHORT_EINT2 */
5572#define ARIZONA_SPK1L_SHORT_EINT2_WIDTH 1 /* SPK1L_SHORT_EINT2 */
5573#define ARIZONA_HP3R_SC_NEG_EINT2 0x0800 /* HP3R_SC_NEG_EINT2 */
5574#define ARIZONA_HP3R_SC_NEG_EINT2_MASK 0x0800 /* HP3R_SC_NEG_EINT2 */
5575#define ARIZONA_HP3R_SC_NEG_EINT2_SHIFT 11 /* HP3R_SC_NEG_EINT2 */
5576#define ARIZONA_HP3R_SC_NEG_EINT2_WIDTH 1 /* HP3R_SC_NEG_EINT2 */
5577#define ARIZONA_HP3R_SC_POS_EINT2 0x0400 /* HP3R_SC_POS_EINT2 */
5578#define ARIZONA_HP3R_SC_POS_EINT2_MASK 0x0400 /* HP3R_SC_POS_EINT2 */
5579#define ARIZONA_HP3R_SC_POS_EINT2_SHIFT 10 /* HP3R_SC_POS_EINT2 */
5580#define ARIZONA_HP3R_SC_POS_EINT2_WIDTH 1 /* HP3R_SC_POS_EINT2 */
5581#define ARIZONA_HP3L_SC_NEG_EINT2 0x0200 /* HP3L_SC_NEG_EINT2 */
5582#define ARIZONA_HP3L_SC_NEG_EINT2_MASK 0x0200 /* HP3L_SC_NEG_EINT2 */
5583#define ARIZONA_HP3L_SC_NEG_EINT2_SHIFT 9 /* HP3L_SC_NEG_EINT2 */
5584#define ARIZONA_HP3L_SC_NEG_EINT2_WIDTH 1 /* HP3L_SC_NEG_EINT2 */
5585#define ARIZONA_HP3L_SC_POS_EINT2 0x0100 /* HP3L_SC_POS_EINT2 */
5586#define ARIZONA_HP3L_SC_POS_EINT2_MASK 0x0100 /* HP3L_SC_POS_EINT2 */
5587#define ARIZONA_HP3L_SC_POS_EINT2_SHIFT 8 /* HP3L_SC_POS_EINT2 */
5588#define ARIZONA_HP3L_SC_POS_EINT2_WIDTH 1 /* HP3L_SC_POS_EINT2 */
5589#define ARIZONA_HP2R_SC_NEG_EINT2 0x0080 /* HP2R_SC_NEG_EINT2 */
5590#define ARIZONA_HP2R_SC_NEG_EINT2_MASK 0x0080 /* HP2R_SC_NEG_EINT2 */
5591#define ARIZONA_HP2R_SC_NEG_EINT2_SHIFT 7 /* HP2R_SC_NEG_EINT2 */
5592#define ARIZONA_HP2R_SC_NEG_EINT2_WIDTH 1 /* HP2R_SC_NEG_EINT2 */
5593#define ARIZONA_HP2R_SC_POS_EINT2 0x0040 /* HP2R_SC_POS_EINT2 */
5594#define ARIZONA_HP2R_SC_POS_EINT2_MASK 0x0040 /* HP2R_SC_POS_EINT2 */
5595#define ARIZONA_HP2R_SC_POS_EINT2_SHIFT 6 /* HP2R_SC_POS_EINT2 */
5596#define ARIZONA_HP2R_SC_POS_EINT2_WIDTH 1 /* HP2R_SC_POS_EINT2 */
5597#define ARIZONA_HP2L_SC_NEG_EINT2 0x0020 /* HP2L_SC_NEG_EINT2 */
5598#define ARIZONA_HP2L_SC_NEG_EINT2_MASK 0x0020 /* HP2L_SC_NEG_EINT2 */
5599#define ARIZONA_HP2L_SC_NEG_EINT2_SHIFT 5 /* HP2L_SC_NEG_EINT2 */
5600#define ARIZONA_HP2L_SC_NEG_EINT2_WIDTH 1 /* HP2L_SC_NEG_EINT2 */
5601#define ARIZONA_HP2L_SC_POS_EINT2 0x0010 /* HP2L_SC_POS_EINT2 */
5602#define ARIZONA_HP2L_SC_POS_EINT2_MASK 0x0010 /* HP2L_SC_POS_EINT2 */
5603#define ARIZONA_HP2L_SC_POS_EINT2_SHIFT 4 /* HP2L_SC_POS_EINT2 */
5604#define ARIZONA_HP2L_SC_POS_EINT2_WIDTH 1 /* HP2L_SC_POS_EINT2 */
5605#define ARIZONA_HP1R_SC_NEG_EINT2 0x0008 /* HP1R_SC_NEG_EINT2 */
5606#define ARIZONA_HP1R_SC_NEG_EINT2_MASK 0x0008 /* HP1R_SC_NEG_EINT2 */
5607#define ARIZONA_HP1R_SC_NEG_EINT2_SHIFT 3 /* HP1R_SC_NEG_EINT2 */
5608#define ARIZONA_HP1R_SC_NEG_EINT2_WIDTH 1 /* HP1R_SC_NEG_EINT2 */
5609#define ARIZONA_HP1R_SC_POS_EINT2 0x0004 /* HP1R_SC_POS_EINT2 */
5610#define ARIZONA_HP1R_SC_POS_EINT2_MASK 0x0004 /* HP1R_SC_POS_EINT2 */
5611#define ARIZONA_HP1R_SC_POS_EINT2_SHIFT 2 /* HP1R_SC_POS_EINT2 */
5612#define ARIZONA_HP1R_SC_POS_EINT2_WIDTH 1 /* HP1R_SC_POS_EINT2 */
5613#define ARIZONA_HP1L_SC_NEG_EINT2 0x0002 /* HP1L_SC_NEG_EINT2 */
5614#define ARIZONA_HP1L_SC_NEG_EINT2_MASK 0x0002 /* HP1L_SC_NEG_EINT2 */
5615#define ARIZONA_HP1L_SC_NEG_EINT2_SHIFT 1 /* HP1L_SC_NEG_EINT2 */
5616#define ARIZONA_HP1L_SC_NEG_EINT2_WIDTH 1 /* HP1L_SC_NEG_EINT2 */
5617#define ARIZONA_HP1L_SC_POS_EINT2 0x0001 /* HP1L_SC_POS_EINT2 */
5618#define ARIZONA_HP1L_SC_POS_EINT2_MASK 0x0001 /* HP1L_SC_POS_EINT2 */
5619#define ARIZONA_HP1L_SC_POS_EINT2_SHIFT 0 /* HP1L_SC_POS_EINT2 */
5620#define ARIZONA_HP1L_SC_POS_EINT2_WIDTH 1 /* HP1L_SC_POS_EINT2 */
5621
5622/*
5168 * R3352 (0xD18) - IRQ2 Status 1 Mask 5623 * R3352 (0xD18) - IRQ2 Status 1 Mask
5169 */ 5624 */
5170#define ARIZONA_IM_GP4_EINT2 0x0008 /* IM_GP4_EINT2 */ 5625#define ARIZONA_IM_GP4_EINT2 0x0008 /* IM_GP4_EINT2 */
@@ -5203,14 +5658,14 @@
5203/* 5658/*
5204 * R3354 (0xD1A) - IRQ2 Status 3 Mask 5659 * R3354 (0xD1A) - IRQ2 Status 3 Mask
5205 */ 5660 */
5206#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT2 0x8000 /* IM_SPK_SHUTDOWN_WARN_EINT2 */ 5661#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT2 0x8000 /* IM_SPK_OVERHEAT_WARN_EINT2 */
5207#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT2_MASK 0x8000 /* IM_SPK_SHUTDOWN_WARN_EINT2 */ 5662#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT2_MASK 0x8000 /* IM_SPK_OVERHEAT_WARN_EINT2 */
5208#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT2_SHIFT 15 /* IM_SPK_SHUTDOWN_WARN_EINT2 */ 5663#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT2_SHIFT 15 /* IM_SPK_OVERHEAT_WARN_EINT2 */
5209#define ARIZONA_IM_SPK_SHUTDOWN_WARN_EINT2_WIDTH 1 /* IM_SPK_SHUTDOWN_WARN_EINT2 */ 5664#define ARIZONA_IM_SPK_OVERHEAT_WARN_EINT2_WIDTH 1 /* IM_SPK_OVERHEAT_WARN_EINT2 */
5210#define ARIZONA_IM_SPK_SHUTDOWN_EINT2 0x4000 /* IM_SPK_SHUTDOWN_EINT2 */ 5665#define ARIZONA_IM_SPK_OVERHEAT_EINT2 0x4000 /* IM_SPK_OVERHEAT_EINT2 */
5211#define ARIZONA_IM_SPK_SHUTDOWN_EINT2_MASK 0x4000 /* IM_SPK_SHUTDOWN_EINT2 */ 5666#define ARIZONA_IM_SPK_OVERHEAT_EINT2_MASK 0x4000 /* IM_SPK_OVERHEAT_EINT2 */
5212#define ARIZONA_IM_SPK_SHUTDOWN_EINT2_SHIFT 14 /* IM_SPK_SHUTDOWN_EINT2 */ 5667#define ARIZONA_IM_SPK_OVERHEAT_EINT2_SHIFT 14 /* IM_SPK_OVERHEAT_EINT2 */
5213#define ARIZONA_IM_SPK_SHUTDOWN_EINT2_WIDTH 1 /* IM_SPK_SHUTDOWN_EINT2 */ 5668#define ARIZONA_IM_SPK_OVERHEAT_EINT2_WIDTH 1 /* IM_SPK_OVERHEAT_EINT2 */
5214#define ARIZONA_IM_HPDET_EINT2 0x2000 /* IM_HPDET_EINT2 */ 5669#define ARIZONA_IM_HPDET_EINT2 0x2000 /* IM_HPDET_EINT2 */
5215#define ARIZONA_IM_HPDET_EINT2_MASK 0x2000 /* IM_HPDET_EINT2 */ 5670#define ARIZONA_IM_HPDET_EINT2_MASK 0x2000 /* IM_HPDET_EINT2 */
5216#define ARIZONA_IM_HPDET_EINT2_SHIFT 13 /* IM_HPDET_EINT2 */ 5671#define ARIZONA_IM_HPDET_EINT2_SHIFT 13 /* IM_HPDET_EINT2 */
@@ -5307,6 +5762,77 @@
5307#define ARIZONA_IM_ISRC2_CFG_ERR_EINT2_MASK 0x0040 /* IM_ISRC2_CFG_ERR_EINT2 */ 5762#define ARIZONA_IM_ISRC2_CFG_ERR_EINT2_MASK 0x0040 /* IM_ISRC2_CFG_ERR_EINT2 */
5308#define ARIZONA_IM_ISRC2_CFG_ERR_EINT2_SHIFT 6 /* IM_ISRC2_CFG_ERR_EINT2 */ 5763#define ARIZONA_IM_ISRC2_CFG_ERR_EINT2_SHIFT 6 /* IM_ISRC2_CFG_ERR_EINT2 */
5309#define ARIZONA_IM_ISRC2_CFG_ERR_EINT2_WIDTH 1 /* IM_ISRC2_CFG_ERR_EINT2 */ 5764#define ARIZONA_IM_ISRC2_CFG_ERR_EINT2_WIDTH 1 /* IM_ISRC2_CFG_ERR_EINT2 */
5765#define ARIZONA_IM_HP3R_DONE_EINT2 0x0020 /* IM_HP3R_DONE_EINT2 */
5766#define ARIZONA_IM_HP3R_DONE_EINT2_MASK 0x0020 /* IM_HP3R_DONE_EINT2 */
5767#define ARIZONA_IM_HP3R_DONE_EINT2_SHIFT 5 /* IM_HP3R_DONE_EINT2 */
5768#define ARIZONA_IM_HP3R_DONE_EINT2_WIDTH 1 /* IM_HP3R_DONE_EINT2 */
5769#define ARIZONA_IM_HP3L_DONE_EINT2 0x0010 /* IM_HP3L_DONE_EINT2 */
5770#define ARIZONA_IM_HP3L_DONE_EINT2_MASK 0x0010 /* IM_HP3L_DONE_EINT2 */
5771#define ARIZONA_IM_HP3L_DONE_EINT2_SHIFT 4 /* IM_HP3L_DONE_EINT2 */
5772#define ARIZONA_IM_HP3L_DONE_EINT2_WIDTH 1 /* IM_HP3L_DONE_EINT2 */
5773#define ARIZONA_IM_HP2R_DONE_EINT2 0x0008 /* IM_HP2R_DONE_EINT2 */
5774#define ARIZONA_IM_HP2R_DONE_EINT2_MASK 0x0008 /* IM_HP2R_DONE_EINT2 */
5775#define ARIZONA_IM_HP2R_DONE_EINT2_SHIFT 3 /* IM_HP2R_DONE_EINT2 */
5776#define ARIZONA_IM_HP2R_DONE_EINT2_WIDTH 1 /* IM_HP2R_DONE_EINT2 */
5777#define ARIZONA_IM_HP2L_DONE_EINT2 0x0004 /* IM_HP2L_DONE_EINT2 */
5778#define ARIZONA_IM_HP2L_DONE_EINT2_MASK 0x0004 /* IM_HP2L_DONE_EINT2 */
5779#define ARIZONA_IM_HP2L_DONE_EINT2_SHIFT 2 /* IM_HP2L_DONE_EINT2 */
5780#define ARIZONA_IM_HP2L_DONE_EINT2_WIDTH 1 /* IM_HP2L_DONE_EINT2 */
5781#define ARIZONA_IM_HP1R_DONE_EINT2 0x0002 /* IM_HP1R_DONE_EINT2 */
5782#define ARIZONA_IM_HP1R_DONE_EINT2_MASK 0x0002 /* IM_HP1R_DONE_EINT2 */
5783#define ARIZONA_IM_HP1R_DONE_EINT2_SHIFT 1 /* IM_HP1R_DONE_EINT2 */
5784#define ARIZONA_IM_HP1R_DONE_EINT2_WIDTH 1 /* IM_HP1R_DONE_EINT2 */
5785#define ARIZONA_IM_HP1L_DONE_EINT2 0x0001 /* IM_HP1L_DONE_EINT2 */
5786#define ARIZONA_IM_HP1L_DONE_EINT2_MASK 0x0001 /* IM_HP1L_DONE_EINT2 */
5787#define ARIZONA_IM_HP1L_DONE_EINT2_SHIFT 0 /* IM_HP1L_DONE_EINT2 */
5788#define ARIZONA_IM_HP1L_DONE_EINT2_WIDTH 1 /* IM_HP1L_DONE_EINT2 */
5789
5790/*
5791 * R3355 (0xD1B) - IRQ2 Status 4 Mask (Alternate layout)
5792 *
5793 * Alternate layout used on later devices, note only fields that have moved
5794 * are specified
5795 */
5796#define ARIZONA_V2_IM_AIF3_ERR_EINT2 0x8000 /* IM_AIF3_ERR_EINT2 */
5797#define ARIZONA_V2_IM_AIF3_ERR_EINT2_MASK 0x8000 /* IM_AIF3_ERR_EINT2 */
5798#define ARIZONA_V2_IM_AIF3_ERR_EINT2_SHIFT 15 /* IM_AIF3_ERR_EINT2 */
5799#define ARIZONA_V2_IM_AIF3_ERR_EINT2_WIDTH 1 /* IM_AIF3_ERR_EINT2 */
5800#define ARIZONA_V2_IM_AIF2_ERR_EINT2 0x4000 /* IM_AIF2_ERR_EINT2 */
5801#define ARIZONA_V2_IM_AIF2_ERR_EINT2_MASK 0x4000 /* IM_AIF2_ERR_EINT2 */
5802#define ARIZONA_V2_IM_AIF2_ERR_EINT2_SHIFT 14 /* IM_AIF2_ERR_EINT2 */
5803#define ARIZONA_V2_IM_AIF2_ERR_EINT2_WIDTH 1 /* IM_AIF2_ERR_EINT2 */
5804#define ARIZONA_V2_IM_AIF1_ERR_EINT2 0x2000 /* IM_AIF1_ERR_EINT2 */
5805#define ARIZONA_V2_IM_AIF1_ERR_EINT2_MASK 0x2000 /* IM_AIF1_ERR_EINT2 */
5806#define ARIZONA_V2_IM_AIF1_ERR_EINT2_SHIFT 13 /* IM_AIF1_ERR_EINT2 */
5807#define ARIZONA_V2_IM_AIF1_ERR_EINT2_WIDTH 1 /* IM_AIF1_ERR_EINT2 */
5808#define ARIZONA_V2_IM_CTRLIF_ERR_EINT2 0x1000 /* IM_CTRLIF_ERR_EINT2 */
5809#define ARIZONA_V2_IM_CTRLIF_ERR_EINT2_MASK 0x1000 /* IM_CTRLIF_ERR_EINT2 */
5810#define ARIZONA_V2_IM_CTRLIF_ERR_EINT2_SHIFT 12 /* IM_CTRLIF_ERR_EINT2 */
5811#define ARIZONA_V2_IM_CTRLIF_ERR_EINT2_WIDTH 1 /* IM_CTRLIF_ERR_EINT2 */
5812#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT2 0x0800 /* IM_MIXER_DROPPED_SAMPLE_EINT2 */
5813#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT2_MASK 0x0800 /* IM_MIXER_DROPPED_SAMPLE_EINT2 */
5814#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT2_SHIFT 11 /* IM_MIXER_DROPPED_SAMPLE_EINT2 */
5815#define ARIZONA_V2_IM_MIXER_DROPPED_SAMPLE_EINT2_WIDTH 1 /* IM_MIXER_DROPPED_SAMPLE_EINT2 */
5816#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT2 0x0400 /* IM_ASYNC_CLK_ENA_LOW_EINT2 */
5817#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT2_MASK 0x0400 /* IM_ASYNC_CLK_ENA_LOW_EINT2 */
5818#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT2_SHIFT 10 /* IM_ASYNC_CLK_ENA_LOW_EINT2 */
5819#define ARIZONA_V2_IM_ASYNC_CLK_ENA_LOW_EINT2_WIDTH 1 /* IM_ASYNC_CLK_ENA_LOW_EINT2 */
5820#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT2 0x0200 /* IM_SYSCLK_ENA_LOW_EINT2 */
5821#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT2_MASK 0x0200 /* IM_SYSCLK_ENA_LOW_EINT2 */
5822#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT2_SHIFT 9 /* IM_SYSCLK_ENA_LOW_EINT2 */
5823#define ARIZONA_V2_IM_SYSCLK_ENA_LOW_EINT2_WIDTH 1 /* IM_SYSCLK_ENA_LOW_EINT2 */
5824#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT2 0x0100 /* IM_ISRC1_CFG_ERR_EINT2 */
5825#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT2_MASK 0x0100 /* IM_ISRC1_CFG_ERR_EINT2 */
5826#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT2_SHIFT 8 /* IM_ISRC1_CFG_ERR_EINT2 */
5827#define ARIZONA_V2_IM_ISRC1_CFG_ERR_EINT2_WIDTH 1 /* IM_ISRC1_CFG_ERR_EINT2 */
5828#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT2 0x0080 /* IM_ISRC2_CFG_ERR_EINT2 */
5829#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT2_MASK 0x0080 /* IM_ISRC2_CFG_ERR_EINT2 */
5830#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT2_SHIFT 7 /* IM_ISRC2_CFG_ERR_EINT2 */
5831#define ARIZONA_V2_IM_ISRC2_CFG_ERR_EINT2_WIDTH 1 /* IM_ISRC2_CFG_ERR_EINT2 */
5832#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT2 0x0040 /* IM_ISRC3_CFG_ERR_EINT2 */
5833#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT2_MASK 0x0040 /* IM_ISRC3_CFG_ERR_EINT2 */
5834#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT2_SHIFT 6 /* IM_ISRC3_CFG_ERR_EINT2 */
5835#define ARIZONA_V2_IM_ISRC3_CFG_ERR_EINT2_WIDTH 1 /* IM_ISRC3_CFG_ERR_EINT2 */
5310 5836
5311/* 5837/*
5312 * R3356 (0xD1C) - IRQ2 Status 5 Mask 5838 * R3356 (0xD1C) - IRQ2 Status 5 Mask
@@ -5334,6 +5860,85 @@
5334#define ARIZONA_IM_FLL1_CLOCK_OK_EINT2_WIDTH 1 /* IM_FLL1_CLOCK_OK_EINT2 */ 5860#define ARIZONA_IM_FLL1_CLOCK_OK_EINT2_WIDTH 1 /* IM_FLL1_CLOCK_OK_EINT2 */
5335 5861
5336/* 5862/*
5863 * R3340 (0xD0C) - Interrupt Status 5 Mask (Alternate layout)
5864 *
5865 * Alternate layout used on later devices, note only fields that have moved
5866 * are specified
5867 */
5868#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT2 0x0008 /* IM_ASRC_CFG_ERR_EINT2 */
5869#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT2_MASK 0x0008 /* IM_ASRC_CFG_ERR_EINT2 */
5870#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT2_SHIFT 3 /* IM_ASRC_CFG_ERR_EINT2 */
5871#define ARIZONA_V2_IM_ASRC_CFG_ERR_EINT2_WIDTH 1 /* IM_ASRC_CFG_ERR_EINT2 */
5872
5873/*
5874 * R3357 (0xD1D) - IRQ2 Status 6 Mask
5875 */
5876#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT2 0x8000 /* IM_DSP_SHARED_WR_COLL_EINT2 */
5877#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT2_MASK 0x8000 /* IM_DSP_SHARED_WR_COLL_EINT2 */
5878#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT2_SHIFT 15 /* IM_DSP_SHARED_WR_COLL_EINT2 */
5879#define ARIZONA_IM_DSP_SHARED_WR_COLL_EINT2_WIDTH 1 /* IM_DSP_SHARED_WR_COLL_EINT2 */
5880#define ARIZONA_IM_SPK_SHUTDOWN_EINT2 0x4000 /* IM_SPK_SHUTDOWN_EINT2 */
5881#define ARIZONA_IM_SPK_SHUTDOWN_EINT2_MASK 0x4000 /* IM_SPK_SHUTDOWN_EINT2 */
5882#define ARIZONA_IM_SPK_SHUTDOWN_EINT2_SHIFT 14 /* IM_SPK_SHUTDOWN_EINT2 */
5883#define ARIZONA_IM_SPK_SHUTDOWN_EINT2_WIDTH 1 /* IM_SPK_SHUTDOWN_EINT2 */
5884#define ARIZONA_IM_SPK1R_SHORT_EINT2 0x2000 /* IM_SPK1R_SHORT_EINT2 */
5885#define ARIZONA_IM_SPK1R_SHORT_EINT2_MASK 0x2000 /* IM_SPK1R_SHORT_EINT2 */
5886#define ARIZONA_IM_SPK1R_SHORT_EINT2_SHIFT 13 /* IM_SPK1R_SHORT_EINT2 */
5887#define ARIZONA_IM_SPK1R_SHORT_EINT2_WIDTH 1 /* IM_SPK1R_SHORT_EINT2 */
5888#define ARIZONA_IM_SPK1L_SHORT_EINT2 0x1000 /* IM_SPK1L_SHORT_EINT2 */
5889#define ARIZONA_IM_SPK1L_SHORT_EINT2_MASK 0x1000 /* IM_SPK1L_SHORT_EINT2 */
5890#define ARIZONA_IM_SPK1L_SHORT_EINT2_SHIFT 12 /* IM_SPK1L_SHORT_EINT2 */
5891#define ARIZONA_IM_SPK1L_SHORT_EINT2_WIDTH 1 /* IM_SPK1L_SHORT_EINT2 */
5892#define ARIZONA_IM_HP3R_SC_NEG_EINT2 0x0800 /* IM_HP3R_SC_NEG_EINT2 */
5893#define ARIZONA_IM_HP3R_SC_NEG_EINT2_MASK 0x0800 /* IM_HP3R_SC_NEG_EINT2 */
5894#define ARIZONA_IM_HP3R_SC_NEG_EINT2_SHIFT 11 /* IM_HP3R_SC_NEG_EINT2 */
5895#define ARIZONA_IM_HP3R_SC_NEG_EINT2_WIDTH 1 /* IM_HP3R_SC_NEG_EINT2 */
5896#define ARIZONA_IM_HP3R_SC_POS_EINT2 0x0400 /* IM_HP3R_SC_POS_EINT2 */
5897#define ARIZONA_IM_HP3R_SC_POS_EINT2_MASK 0x0400 /* IM_HP3R_SC_POS_EINT2 */
5898#define ARIZONA_IM_HP3R_SC_POS_EINT2_SHIFT 10 /* IM_HP3R_SC_POS_EINT2 */
5899#define ARIZONA_IM_HP3R_SC_POS_EINT2_WIDTH 1 /* IM_HP3R_SC_POS_EINT2 */
5900#define ARIZONA_IM_HP3L_SC_NEG_EINT2 0x0200 /* IM_HP3L_SC_NEG_EINT2 */
5901#define ARIZONA_IM_HP3L_SC_NEG_EINT2_MASK 0x0200 /* IM_HP3L_SC_NEG_EINT2 */
5902#define ARIZONA_IM_HP3L_SC_NEG_EINT2_SHIFT 9 /* IM_HP3L_SC_NEG_EINT2 */
5903#define ARIZONA_IM_HP3L_SC_NEG_EINT2_WIDTH 1 /* IM_HP3L_SC_NEG_EINT2 */
5904#define ARIZONA_IM_HP3L_SC_POS_EINT2 0x0100 /* IM_HP3L_SC_POS_EINT2 */
5905#define ARIZONA_IM_HP3L_SC_POS_EINT2_MASK 0x0100 /* IM_HP3L_SC_POS_EINT2 */
5906#define ARIZONA_IM_HP3L_SC_POS_EINT2_SHIFT 8 /* IM_HP3L_SC_POS_EINT2 */
5907#define ARIZONA_IM_HP3L_SC_POS_EINT2_WIDTH 1 /* IM_HP3L_SC_POS_EINT2 */
5908#define ARIZONA_IM_HP2R_SC_NEG_EINT2 0x0080 /* IM_HP2R_SC_NEG_EINT2 */
5909#define ARIZONA_IM_HP2R_SC_NEG_EINT2_MASK 0x0080 /* IM_HP2R_SC_NEG_EINT2 */
5910#define ARIZONA_IM_HP2R_SC_NEG_EINT2_SHIFT 7 /* IM_HP2R_SC_NEG_EINT2 */
5911#define ARIZONA_IM_HP2R_SC_NEG_EINT2_WIDTH 1 /* IM_HP2R_SC_NEG_EINT2 */
5912#define ARIZONA_IM_HP2R_SC_POS_EINT2 0x0040 /* IM_HP2R_SC_POS_EINT2 */
5913#define ARIZONA_IM_HP2R_SC_POS_EINT2_MASK 0x0040 /* IM_HP2R_SC_POS_EINT2 */
5914#define ARIZONA_IM_HP2R_SC_POS_EINT2_SHIFT 6 /* IM_HP2R_SC_POS_EINT2 */
5915#define ARIZONA_IM_HP2R_SC_POS_EINT2_WIDTH 1 /* IM_HP2R_SC_POS_EINT2 */
5916#define ARIZONA_IM_HP2L_SC_NEG_EINT2 0x0020 /* IM_HP2L_SC_NEG_EINT2 */
5917#define ARIZONA_IM_HP2L_SC_NEG_EINT2_MASK 0x0020 /* IM_HP2L_SC_NEG_EINT2 */
5918#define ARIZONA_IM_HP2L_SC_NEG_EINT2_SHIFT 5 /* IM_HP2L_SC_NEG_EINT2 */
5919#define ARIZONA_IM_HP2L_SC_NEG_EINT2_WIDTH 1 /* IM_HP2L_SC_NEG_EINT2 */
5920#define ARIZONA_IM_HP2L_SC_POS_EINT2 0x0010 /* IM_HP2L_SC_POS_EINT2 */
5921#define ARIZONA_IM_HP2L_SC_POS_EINT2_MASK 0x0010 /* IM_HP2L_SC_POS_EINT2 */
5922#define ARIZONA_IM_HP2L_SC_POS_EINT2_SHIFT 4 /* IM_HP2L_SC_POS_EINT2 */
5923#define ARIZONA_IM_HP2L_SC_POS_EINT2_WIDTH 1 /* IM_HP2L_SC_POS_EINT2 */
5924#define ARIZONA_IM_HP1R_SC_NEG_EINT2 0x0008 /* IM_HP1R_SC_NEG_EINT2 */
5925#define ARIZONA_IM_HP1R_SC_NEG_EINT2_MASK 0x0008 /* IM_HP1R_SC_NEG_EINT2 */
5926#define ARIZONA_IM_HP1R_SC_NEG_EINT2_SHIFT 3 /* IM_HP1R_SC_NEG_EINT2 */
5927#define ARIZONA_IM_HP1R_SC_NEG_EINT2_WIDTH 1 /* IM_HP1R_SC_NEG_EINT2 */
5928#define ARIZONA_IM_HP1R_SC_POS_EINT2 0x0004 /* IM_HP1R_SC_POS_EINT2 */
5929#define ARIZONA_IM_HP1R_SC_POS_EINT2_MASK 0x0004 /* IM_HP1R_SC_POS_EINT2 */
5930#define ARIZONA_IM_HP1R_SC_POS_EINT2_SHIFT 2 /* IM_HP1R_SC_POS_EINT2 */
5931#define ARIZONA_IM_HP1R_SC_POS_EINT2_WIDTH 1 /* IM_HP1R_SC_POS_EINT2 */
5932#define ARIZONA_IM_HP1L_SC_NEG_EINT2 0x0002 /* IM_HP1L_SC_NEG_EINT2 */
5933#define ARIZONA_IM_HP1L_SC_NEG_EINT2_MASK 0x0002 /* IM_HP1L_SC_NEG_EINT2 */
5934#define ARIZONA_IM_HP1L_SC_NEG_EINT2_SHIFT 1 /* IM_HP1L_SC_NEG_EINT2 */
5935#define ARIZONA_IM_HP1L_SC_NEG_EINT2_WIDTH 1 /* IM_HP1L_SC_NEG_EINT2 */
5936#define ARIZONA_IM_HP1L_SC_POS_EINT2 0x0001 /* IM_HP1L_SC_POS_EINT2 */
5937#define ARIZONA_IM_HP1L_SC_POS_EINT2_MASK 0x0001 /* IM_HP1L_SC_POS_EINT2 */
5938#define ARIZONA_IM_HP1L_SC_POS_EINT2_SHIFT 0 /* IM_HP1L_SC_POS_EINT2 */
5939#define ARIZONA_IM_HP1L_SC_POS_EINT2_WIDTH 1 /* IM_HP1L_SC_POS_EINT2 */
5940
5941/*
5337 * R3359 (0xD1F) - IRQ2 Control 5942 * R3359 (0xD1F) - IRQ2 Control
5338 */ 5943 */
5339#define ARIZONA_IM_IRQ2 0x0001 /* IM_IRQ2 */ 5944#define ARIZONA_IM_IRQ2 0x0001 /* IM_IRQ2 */
@@ -5360,14 +5965,14 @@
5360/* 5965/*
5361 * R3361 (0xD21) - Interrupt Raw Status 3 5966 * R3361 (0xD21) - Interrupt Raw Status 3
5362 */ 5967 */
5363#define ARIZONA_SPK_SHUTDOWN_WARN_STS 0x8000 /* SPK_SHUTDOWN_WARN_STS */ 5968#define ARIZONA_SPK_OVERHEAT_WARN_STS 0x8000 /* SPK_OVERHEAT_WARN_STS */
5364#define ARIZONA_SPK_SHUTDOWN_WARN_STS_MASK 0x8000 /* SPK_SHUTDOWN_WARN_STS */ 5969#define ARIZONA_SPK_OVERHEAT_WARN_STS_MASK 0x8000 /* SPK_OVERHEAT_WARN_STS */
5365#define ARIZONA_SPK_SHUTDOWN_WARN_STS_SHIFT 15 /* SPK_SHUTDOWN_WARN_STS */ 5970#define ARIZONA_SPK_OVERHEAT_WARN_STS_SHIFT 15 /* SPK_OVERHEAT_WARN_STS */
5366#define ARIZONA_SPK_SHUTDOWN_WARN_STS_WIDTH 1 /* SPK_SHUTDOWN_WARN_STS */ 5971#define ARIZONA_SPK_OVERHEAT_WARN_STS_WIDTH 1 /* SPK_OVERHEAT_WARN_STS */
5367#define ARIZONA_SPK_SHUTDOWN_STS 0x4000 /* SPK_SHUTDOWN_STS */ 5972#define ARIZONA_SPK_OVERHEAT_STS 0x4000 /* SPK_OVERHEAT_STS */
5368#define ARIZONA_SPK_SHUTDOWN_STS_MASK 0x4000 /* SPK_SHUTDOWN_STS */ 5973#define ARIZONA_SPK_OVERHEAT_STS_MASK 0x4000 /* SPK_OVERHEAT_STS */
5369#define ARIZONA_SPK_SHUTDOWN_STS_SHIFT 14 /* SPK_SHUTDOWN_STS */ 5974#define ARIZONA_SPK_OVERHEAT_STS_SHIFT 14 /* SPK_OVERHEAT_STS */
5370#define ARIZONA_SPK_SHUTDOWN_STS_WIDTH 1 /* SPK_SHUTDOWN_STS */ 5975#define ARIZONA_SPK_OVERHEAT_STS_WIDTH 1 /* SPK_OVERHEAT_STS */
5371#define ARIZONA_HPDET_STS 0x2000 /* HPDET_STS */ 5976#define ARIZONA_HPDET_STS 0x2000 /* HPDET_STS */
5372#define ARIZONA_HPDET_STS_MASK 0x2000 /* HPDET_STS */ 5977#define ARIZONA_HPDET_STS_MASK 0x2000 /* HPDET_STS */
5373#define ARIZONA_HPDET_STS_SHIFT 13 /* HPDET_STS */ 5978#define ARIZONA_HPDET_STS_SHIFT 13 /* HPDET_STS */
@@ -5464,6 +6069,30 @@
5464#define ARIZONA_ISRC2_CFG_ERR_STS_MASK 0x0040 /* ISRC2_CFG_ERR_STS */ 6069#define ARIZONA_ISRC2_CFG_ERR_STS_MASK 0x0040 /* ISRC2_CFG_ERR_STS */
5465#define ARIZONA_ISRC2_CFG_ERR_STS_SHIFT 6 /* ISRC2_CFG_ERR_STS */ 6070#define ARIZONA_ISRC2_CFG_ERR_STS_SHIFT 6 /* ISRC2_CFG_ERR_STS */
5466#define ARIZONA_ISRC2_CFG_ERR_STS_WIDTH 1 /* ISRC2_CFG_ERR_STS */ 6071#define ARIZONA_ISRC2_CFG_ERR_STS_WIDTH 1 /* ISRC2_CFG_ERR_STS */
6072#define ARIZONA_HP3R_DONE_STS 0x0020 /* HP3R_DONE_STS */
6073#define ARIZONA_HP3R_DONE_STS_MASK 0x0020 /* HP3R_DONE_STS */
6074#define ARIZONA_HP3R_DONE_STS_SHIFT 5 /* HP3R_DONE_STS */
6075#define ARIZONA_HP3R_DONE_STS_WIDTH 1 /* HP3R_DONE_STS */
6076#define ARIZONA_HP3L_DONE_STS 0x0010 /* HP3L_DONE_STS */
6077#define ARIZONA_HP3L_DONE_STS_MASK 0x0010 /* HP3L_DONE_STS */
6078#define ARIZONA_HP3L_DONE_STS_SHIFT 4 /* HP3L_DONE_STS */
6079#define ARIZONA_HP3L_DONE_STS_WIDTH 1 /* HP3L_DONE_STS */
6080#define ARIZONA_HP2R_DONE_STS 0x0008 /* HP2R_DONE_STS */
6081#define ARIZONA_HP2R_DONE_STS_MASK 0x0008 /* HP2R_DONE_STS */
6082#define ARIZONA_HP2R_DONE_STS_SHIFT 3 /* HP2R_DONE_STS */
6083#define ARIZONA_HP2R_DONE_STS_WIDTH 1 /* HP2R_DONE_STS */
6084#define ARIZONA_HP2L_DONE_STS 0x0004 /* HP2L_DONE_STS */
6085#define ARIZONA_HP2L_DONE_STS_MASK 0x0004 /* HP2L_DONE_STS */
6086#define ARIZONA_HP2L_DONE_STS_SHIFT 2 /* HP2L_DONE_STS */
6087#define ARIZONA_HP2L_DONE_STS_WIDTH 1 /* HP2L_DONE_STS */
6088#define ARIZONA_HP1R_DONE_STS 0x0002 /* HP1R_DONE_STS */
6089#define ARIZONA_HP1R_DONE_STS_MASK 0x0002 /* HP1R_DONE_STS */
6090#define ARIZONA_HP1R_DONE_STS_SHIFT 1 /* HP1R_DONE_STS */
6091#define ARIZONA_HP1R_DONE_STS_WIDTH 1 /* HP1R_DONE_STS */
6092#define ARIZONA_HP1L_DONE_STS 0x0001 /* HP1L_DONE_STS */
6093#define ARIZONA_HP1L_DONE_STS_MASK 0x0001 /* HP1L_DONE_STS */
6094#define ARIZONA_HP1L_DONE_STS_SHIFT 0 /* HP1L_DONE_STS */
6095#define ARIZONA_HP1L_DONE_STS_WIDTH 1 /* HP1L_DONE_STS */
5467 6096
5468/* 6097/*
5469 * R3363 (0xD23) - Interrupt Raw Status 5 6098 * R3363 (0xD23) - Interrupt Raw Status 5
@@ -5580,6 +6209,10 @@
5580#define ARIZONA_ADSP2_1_OVERCLOCKED_STS_MASK 0x0008 /* ADSP2_1_OVERCLOCKED_STS */ 6209#define ARIZONA_ADSP2_1_OVERCLOCKED_STS_MASK 0x0008 /* ADSP2_1_OVERCLOCKED_STS */
5581#define ARIZONA_ADSP2_1_OVERCLOCKED_STS_SHIFT 3 /* ADSP2_1_OVERCLOCKED_STS */ 6210#define ARIZONA_ADSP2_1_OVERCLOCKED_STS_SHIFT 3 /* ADSP2_1_OVERCLOCKED_STS */
5582#define ARIZONA_ADSP2_1_OVERCLOCKED_STS_WIDTH 1 /* ADSP2_1_OVERCLOCKED_STS */ 6211#define ARIZONA_ADSP2_1_OVERCLOCKED_STS_WIDTH 1 /* ADSP2_1_OVERCLOCKED_STS */
6212#define ARIZONA_ISRC3_OVERCLOCKED_STS 0x0004 /* ISRC3_OVERCLOCKED_STS */
6213#define ARIZONA_ISRC3_OVERCLOCKED_STS_MASK 0x0004 /* ISRC3_OVERCLOCKED_STS */
6214#define ARIZONA_ISRC3_OVERCLOCKED_STS_SHIFT 2 /* ISRC3_OVERCLOCKED_STS */
6215#define ARIZONA_ISRC3_OVERCLOCKED_STS_WIDTH 1 /* ISRC3_OVERCLOCKED_STS */
5583#define ARIZONA_ISRC2_OVERCLOCKED_STS 0x0002 /* ISRC2_OVERCLOCKED_STS */ 6216#define ARIZONA_ISRC2_OVERCLOCKED_STS 0x0002 /* ISRC2_OVERCLOCKED_STS */
5584#define ARIZONA_ISRC2_OVERCLOCKED_STS_MASK 0x0002 /* ISRC2_OVERCLOCKED_STS */ 6217#define ARIZONA_ISRC2_OVERCLOCKED_STS_MASK 0x0002 /* ISRC2_OVERCLOCKED_STS */
5585#define ARIZONA_ISRC2_OVERCLOCKED_STS_SHIFT 1 /* ISRC2_OVERCLOCKED_STS */ 6218#define ARIZONA_ISRC2_OVERCLOCKED_STS_SHIFT 1 /* ISRC2_OVERCLOCKED_STS */
@@ -5604,6 +6237,10 @@
5604#define ARIZONA_AIF1_UNDERCLOCKED_STS_MASK 0x0100 /* AIF1_UNDERCLOCKED_STS */ 6237#define ARIZONA_AIF1_UNDERCLOCKED_STS_MASK 0x0100 /* AIF1_UNDERCLOCKED_STS */
5605#define ARIZONA_AIF1_UNDERCLOCKED_STS_SHIFT 8 /* AIF1_UNDERCLOCKED_STS */ 6238#define ARIZONA_AIF1_UNDERCLOCKED_STS_SHIFT 8 /* AIF1_UNDERCLOCKED_STS */
5606#define ARIZONA_AIF1_UNDERCLOCKED_STS_WIDTH 1 /* AIF1_UNDERCLOCKED_STS */ 6239#define ARIZONA_AIF1_UNDERCLOCKED_STS_WIDTH 1 /* AIF1_UNDERCLOCKED_STS */
6240#define ARIZONA_ISRC3_UNDERCLOCKED_STS 0x0080 /* ISRC3_UNDERCLOCKED_STS */
6241#define ARIZONA_ISRC3_UNDERCLOCKED_STS_MASK 0x0080 /* ISRC3_UNDERCLOCKED_STS */
6242#define ARIZONA_ISRC3_UNDERCLOCKED_STS_SHIFT 7 /* ISRC3_UNDERCLOCKED_STS */
6243#define ARIZONA_ISRC3_UNDERCLOCKED_STS_WIDTH 1 /* ISRC3_UNDERCLOCKED_STS */
5607#define ARIZONA_ISRC2_UNDERCLOCKED_STS 0x0040 /* ISRC2_UNDERCLOCKED_STS */ 6244#define ARIZONA_ISRC2_UNDERCLOCKED_STS 0x0040 /* ISRC2_UNDERCLOCKED_STS */
5608#define ARIZONA_ISRC2_UNDERCLOCKED_STS_MASK 0x0040 /* ISRC2_UNDERCLOCKED_STS */ 6245#define ARIZONA_ISRC2_UNDERCLOCKED_STS_MASK 0x0040 /* ISRC2_UNDERCLOCKED_STS */
5609#define ARIZONA_ISRC2_UNDERCLOCKED_STS_SHIFT 6 /* ISRC2_UNDERCLOCKED_STS */ 6246#define ARIZONA_ISRC2_UNDERCLOCKED_STS_SHIFT 6 /* ISRC2_UNDERCLOCKED_STS */
@@ -5634,6 +6271,74 @@
5634#define ARIZONA_MIXER_UNDERCLOCKED_STS_WIDTH 1 /* MIXER_UNDERCLOCKED_STS */ 6271#define ARIZONA_MIXER_UNDERCLOCKED_STS_WIDTH 1 /* MIXER_UNDERCLOCKED_STS */
5635 6272
5636/* 6273/*
6274 * R3368 (0xD28) - Interrupt Raw Status 9
6275 */
6276#define ARIZONA_DSP_SHARED_WR_COLL_STS 0x8000 /* DSP_SHARED_WR_COLL_STS */
6277#define ARIZONA_DSP_SHARED_WR_COLL_STS_MASK 0x8000 /* DSP_SHARED_WR_COLL_STS */
6278#define ARIZONA_DSP_SHARED_WR_COLL_STS_SHIFT 15 /* DSP_SHARED_WR_COLL_STS */
6279#define ARIZONA_DSP_SHARED_WR_COLL_STS_WIDTH 1 /* DSP_SHARED_WR_COLL_STS */
6280#define ARIZONA_SPK_SHUTDOWN_STS 0x4000 /* SPK_SHUTDOWN_STS */
6281#define ARIZONA_SPK_SHUTDOWN_STS_MASK 0x4000 /* SPK_SHUTDOWN_STS */
6282#define ARIZONA_SPK_SHUTDOWN_STS_SHIFT 14 /* SPK_SHUTDOWN_STS */
6283#define ARIZONA_SPK_SHUTDOWN_STS_WIDTH 1 /* SPK_SHUTDOWN_STS */
6284#define ARIZONA_SPK1R_SHORT_STS 0x2000 /* SPK1R_SHORT_STS */
6285#define ARIZONA_SPK1R_SHORT_STS_MASK 0x2000 /* SPK1R_SHORT_STS */
6286#define ARIZONA_SPK1R_SHORT_STS_SHIFT 13 /* SPK1R_SHORT_STS */
6287#define ARIZONA_SPK1R_SHORT_STS_WIDTH 1 /* SPK1R_SHORT_STS */
6288#define ARIZONA_SPK1L_SHORT_STS 0x1000 /* SPK1L_SHORT_STS */
6289#define ARIZONA_SPK1L_SHORT_STS_MASK 0x1000 /* SPK1L_SHORT_STS */
6290#define ARIZONA_SPK1L_SHORT_STS_SHIFT 12 /* SPK1L_SHORT_STS */
6291#define ARIZONA_SPK1L_SHORT_STS_WIDTH 1 /* SPK1L_SHORT_STS */
6292#define ARIZONA_HP3R_SC_NEG_STS 0x0800 /* HP3R_SC_NEG_STS */
6293#define ARIZONA_HP3R_SC_NEG_STS_MASK 0x0800 /* HP3R_SC_NEG_STS */
6294#define ARIZONA_HP3R_SC_NEG_STS_SHIFT 11 /* HP3R_SC_NEG_STS */
6295#define ARIZONA_HP3R_SC_NEG_STS_WIDTH 1 /* HP3R_SC_NEG_STS */
6296#define ARIZONA_HP3R_SC_POS_STS 0x0400 /* HP3R_SC_POS_STS */
6297#define ARIZONA_HP3R_SC_POS_STS_MASK 0x0400 /* HP3R_SC_POS_STS */
6298#define ARIZONA_HP3R_SC_POS_STS_SHIFT 10 /* HP3R_SC_POS_STS */
6299#define ARIZONA_HP3R_SC_POS_STS_WIDTH 1 /* HP3R_SC_POS_STS */
6300#define ARIZONA_HP3L_SC_NEG_STS 0x0200 /* HP3L_SC_NEG_STS */
6301#define ARIZONA_HP3L_SC_NEG_STS_MASK 0x0200 /* HP3L_SC_NEG_STS */
6302#define ARIZONA_HP3L_SC_NEG_STS_SHIFT 9 /* HP3L_SC_NEG_STS */
6303#define ARIZONA_HP3L_SC_NEG_STS_WIDTH 1 /* HP3L_SC_NEG_STS */
6304#define ARIZONA_HP3L_SC_POS_STS 0x0100 /* HP3L_SC_POS_STS */
6305#define ARIZONA_HP3L_SC_POS_STS_MASK 0x0100 /* HP3L_SC_POS_STS */
6306#define ARIZONA_HP3L_SC_POS_STS_SHIFT 8 /* HP3L_SC_POS_STS */
6307#define ARIZONA_HP3L_SC_POS_STS_WIDTH 1 /* HP3L_SC_POS_STS */
6308#define ARIZONA_HP2R_SC_NEG_STS 0x0080 /* HP2R_SC_NEG_STS */
6309#define ARIZONA_HP2R_SC_NEG_STS_MASK 0x0080 /* HP2R_SC_NEG_STS */
6310#define ARIZONA_HP2R_SC_NEG_STS_SHIFT 7 /* HP2R_SC_NEG_STS */
6311#define ARIZONA_HP2R_SC_NEG_STS_WIDTH 1 /* HP2R_SC_NEG_STS */
6312#define ARIZONA_HP2R_SC_POS_STS 0x0040 /* HP2R_SC_POS_STS */
6313#define ARIZONA_HP2R_SC_POS_STS_MASK 0x0040 /* HP2R_SC_POS_STS */
6314#define ARIZONA_HP2R_SC_POS_STS_SHIFT 6 /* HP2R_SC_POS_STS */
6315#define ARIZONA_HP2R_SC_POS_STS_WIDTH 1 /* HP2R_SC_POS_STS */
6316#define ARIZONA_HP2L_SC_NEG_STS 0x0020 /* HP2L_SC_NEG_STS */
6317#define ARIZONA_HP2L_SC_NEG_STS_MASK 0x0020 /* HP2L_SC_NEG_STS */
6318#define ARIZONA_HP2L_SC_NEG_STS_SHIFT 5 /* HP2L_SC_NEG_STS */
6319#define ARIZONA_HP2L_SC_NEG_STS_WIDTH 1 /* HP2L_SC_NEG_STS */
6320#define ARIZONA_HP2L_SC_POS_STS 0x0010 /* HP2L_SC_POS_STS */
6321#define ARIZONA_HP2L_SC_POS_STS_MASK 0x0010 /* HP2L_SC_POS_STS */
6322#define ARIZONA_HP2L_SC_POS_STS_SHIFT 4 /* HP2L_SC_POS_STS */
6323#define ARIZONA_HP2L_SC_POS_STS_WIDTH 1 /* HP2L_SC_POS_STS */
6324#define ARIZONA_HP1R_SC_NEG_STS 0x0008 /* HP1R_SC_NEG_STS */
6325#define ARIZONA_HP1R_SC_NEG_STS_MASK 0x0008 /* HP1R_SC_NEG_STS */
6326#define ARIZONA_HP1R_SC_NEG_STS_SHIFT 3 /* HP1R_SC_NEG_STS */
6327#define ARIZONA_HP1R_SC_NEG_STS_WIDTH 1 /* HP1R_SC_NEG_STS */
6328#define ARIZONA_HP1R_SC_POS_STS 0x0004 /* HP1R_SC_POS_STS */
6329#define ARIZONA_HP1R_SC_POS_STS_MASK 0x0004 /* HP1R_SC_POS_STS */
6330#define ARIZONA_HP1R_SC_POS_STS_SHIFT 2 /* HP1R_SC_POS_STS */
6331#define ARIZONA_HP1R_SC_POS_STS_WIDTH 1 /* HP1R_SC_POS_STS */
6332#define ARIZONA_HP1L_SC_NEG_STS 0x0002 /* HP1L_SC_NEG_STS */
6333#define ARIZONA_HP1L_SC_NEG_STS_MASK 0x0002 /* HP1L_SC_NEG_STS */
6334#define ARIZONA_HP1L_SC_NEG_STS_SHIFT 1 /* HP1L_SC_NEG_STS */
6335#define ARIZONA_HP1L_SC_NEG_STS_WIDTH 1 /* HP1L_SC_NEG_STS */
6336#define ARIZONA_HP1L_SC_POS_STS 0x0001 /* HP1L_SC_POS_STS */
6337#define ARIZONA_HP1L_SC_POS_STS_MASK 0x0001 /* HP1L_SC_POS_STS */
6338#define ARIZONA_HP1L_SC_POS_STS_SHIFT 0 /* HP1L_SC_POS_STS */
6339#define ARIZONA_HP1L_SC_POS_STS_WIDTH 1 /* HP1L_SC_POS_STS */
6340
6341/*
5637 * R3392 (0xD40) - IRQ Pin Status 6342 * R3392 (0xD40) - IRQ Pin Status
5638 */ 6343 */
5639#define ARIZONA_IRQ2_STS 0x0002 /* IRQ2_STS */ 6344#define ARIZONA_IRQ2_STS 0x0002 /* IRQ2_STS */
diff --git a/include/linux/mfd/cros_ec.h b/include/linux/mfd/cros_ec.h
index 887ef4f7bef7..fcbe9d129a9d 100644
--- a/include/linux/mfd/cros_ec.h
+++ b/include/linux/mfd/cros_ec.h
@@ -16,7 +16,9 @@
16#ifndef __LINUX_MFD_CROS_EC_H 16#ifndef __LINUX_MFD_CROS_EC_H
17#define __LINUX_MFD_CROS_EC_H 17#define __LINUX_MFD_CROS_EC_H
18 18
19#include <linux/notifier.h>
19#include <linux/mfd/cros_ec_commands.h> 20#include <linux/mfd/cros_ec_commands.h>
21#include <linux/mutex.h>
20 22
21/* 23/*
22 * Command interface between EC and AP, for LPC, I2C and SPI interfaces. 24 * Command interface between EC and AP, for LPC, I2C and SPI interfaces.
@@ -33,83 +35,76 @@ enum {
33 EC_MSG_TX_PROTO_BYTES, 35 EC_MSG_TX_PROTO_BYTES,
34}; 36};
35 37
36/** 38/*
37 * struct cros_ec_msg - A message sent to the EC, and its reply
38 *
39 * @version: Command version number (often 0) 39 * @version: Command version number (often 0)
40 * @cmd: Command to send (EC_CMD_...) 40 * @command: Command to send (EC_CMD_...)
41 * @out_buf: Outgoing payload (to EC) 41 * @outdata: Outgoing data to EC
42 * @outlen: Outgoing length 42 * @outsize: Outgoing length in bytes
43 * @in_buf: Incoming payload (from EC) 43 * @indata: Where to put the incoming data from EC
44 * @in_len: Incoming length 44 * @insize: Max number of bytes to accept from EC
45 * @result: EC's response to the command (separate from communication failure)
45 */ 46 */
46struct cros_ec_msg { 47struct cros_ec_command {
47 u8 version; 48 uint32_t version;
48 u8 cmd; 49 uint32_t command;
49 uint8_t *out_buf; 50 uint8_t *outdata;
50 int out_len; 51 uint32_t outsize;
51 uint8_t *in_buf; 52 uint8_t *indata;
52 int in_len; 53 uint32_t insize;
54 uint32_t result;
53}; 55};
54 56
55/** 57/**
56 * struct cros_ec_device - Information about a ChromeOS EC device 58 * struct cros_ec_device - Information about a ChromeOS EC device
57 * 59 *
58 * @name: Name of this EC interface 60 * @ec_name: name of EC device (e.g. 'chromeos-ec')
61 * @phys_name: name of physical comms layer (e.g. 'i2c-4')
62 * @dev: Device pointer
63 * @was_wake_device: true if this device was set to wake the system from
64 * sleep at the last suspend
65 * @cmd_xfer: send command to EC and get response
66 * Returns the number of bytes received if the communication succeeded, but
67 * that doesn't mean the EC was happy with the command. The caller
68 * should check msg.result for the EC's result code.
69 *
59 * @priv: Private data 70 * @priv: Private data
60 * @irq: Interrupt to use 71 * @irq: Interrupt to use
61 * @din: input buffer (from EC) 72 * @din: input buffer (for data from EC)
62 * @dout: output buffer (to EC) 73 * @dout: output buffer (for data to EC)
63 * \note 74 * \note
64 * These two buffers will always be dword-aligned and include enough 75 * These two buffers will always be dword-aligned and include enough
65 * space for up to 7 word-alignment bytes also, so we can ensure that 76 * space for up to 7 word-alignment bytes also, so we can ensure that
66 * the body of the message is always dword-aligned (64-bit). 77 * the body of the message is always dword-aligned (64-bit).
67 *
68 * We use this alignment to keep ARM and x86 happy. Probably word 78 * We use this alignment to keep ARM and x86 happy. Probably word
69 * alignment would be OK, there might be a small performance advantage 79 * alignment would be OK, there might be a small performance advantage
70 * to using dword. 80 * to using dword.
71 * @din_size: size of din buffer 81 * @din_size: size of din buffer to allocate (zero to use static din)
72 * @dout_size: size of dout buffer 82 * @dout_size: size of dout buffer to allocate (zero to use static dout)
73 * @command_send: send a command
74 * @command_recv: receive a command
75 * @ec_name: name of EC device (e.g. 'chromeos-ec')
76 * @phys_name: name of physical comms layer (e.g. 'i2c-4')
77 * @parent: pointer to parent device (e.g. i2c or spi device) 83 * @parent: pointer to parent device (e.g. i2c or spi device)
78 * @dev: Device pointer
79 * dev_lock: Lock to prevent concurrent access
80 * @wake_enabled: true if this device can wake the system from sleep 84 * @wake_enabled: true if this device can wake the system from sleep
81 * @was_wake_device: true if this device was set to wake the system from 85 * @lock: one transaction at a time
82 * sleep at the last suspend
83 * @event_notifier: interrupt event notifier for transport devices
84 */ 86 */
85struct cros_ec_device { 87struct cros_ec_device {
86 const char *name; 88
89 /* These are used by other drivers that want to talk to the EC */
90 const char *ec_name;
91 const char *phys_name;
92 struct device *dev;
93 bool was_wake_device;
94 struct class *cros_class;
95 int (*cmd_xfer)(struct cros_ec_device *ec,
96 struct cros_ec_command *msg);
97
98 /* These are used to implement the platform-specific interface */
87 void *priv; 99 void *priv;
88 int irq; 100 int irq;
89 uint8_t *din; 101 uint8_t *din;
90 uint8_t *dout; 102 uint8_t *dout;
91 int din_size; 103 int din_size;
92 int dout_size; 104 int dout_size;
93 int (*command_send)(struct cros_ec_device *ec,
94 uint16_t cmd, void *out_buf, int out_len);
95 int (*command_recv)(struct cros_ec_device *ec,
96 uint16_t cmd, void *in_buf, int in_len);
97 int (*command_sendrecv)(struct cros_ec_device *ec,
98 uint16_t cmd, void *out_buf, int out_len,
99 void *in_buf, int in_len);
100 int (*command_xfer)(struct cros_ec_device *ec,
101 struct cros_ec_msg *msg);
102
103 const char *ec_name;
104 const char *phys_name;
105 struct device *parent; 105 struct device *parent;
106
107 /* These are --private-- fields - do not assign */
108 struct device *dev;
109 struct mutex dev_lock;
110 bool wake_enabled; 106 bool wake_enabled;
111 bool was_wake_device; 107 struct mutex lock;
112 struct blocking_notifier_head event_notifier;
113}; 108};
114 109
115/** 110/**
@@ -143,13 +138,24 @@ int cros_ec_resume(struct cros_ec_device *ec_dev);
143 * @msg: Message to write 138 * @msg: Message to write
144 */ 139 */
145int cros_ec_prepare_tx(struct cros_ec_device *ec_dev, 140int cros_ec_prepare_tx(struct cros_ec_device *ec_dev,
146 struct cros_ec_msg *msg); 141 struct cros_ec_command *msg);
142
143/**
144 * cros_ec_check_result - Check ec_msg->result
145 *
146 * This is used by ChromeOS EC drivers to check the ec_msg->result for
147 * errors and to warn about them.
148 *
149 * @ec_dev: EC device
150 * @msg: Message to check
151 */
152int cros_ec_check_result(struct cros_ec_device *ec_dev,
153 struct cros_ec_command *msg);
147 154
148/** 155/**
149 * cros_ec_remove - Remove a ChromeOS EC 156 * cros_ec_remove - Remove a ChromeOS EC
150 * 157 *
151 * Call this to deregister a ChromeOS EC. After this you should call 158 * Call this to deregister a ChromeOS EC, then clean up any private data.
152 * cros_ec_free().
153 * 159 *
154 * @ec_dev: Device to register 160 * @ec_dev: Device to register
155 * @return 0 if ok, -ve on error 161 * @return 0 if ok, -ve on error
diff --git a/include/linux/mfd/da9063/core.h b/include/linux/mfd/da9063/core.h
index 00a9aac5d1e8..b92a3262f8f6 100644
--- a/include/linux/mfd/da9063/core.h
+++ b/include/linux/mfd/da9063/core.h
@@ -34,7 +34,8 @@ enum da9063_models {
34}; 34};
35 35
36enum da9063_variant_codes { 36enum da9063_variant_codes {
37 PMIC_DA9063_BB = 0x5 37 PMIC_DA9063_AD = 0x3,
38 PMIC_DA9063_BB = 0x5,
38}; 39};
39 40
40/* Interrupts */ 41/* Interrupts */
diff --git a/include/linux/mfd/da9063/registers.h b/include/linux/mfd/da9063/registers.h
index 09a85c699da1..2e0ba6d5fbc3 100644
--- a/include/linux/mfd/da9063/registers.h
+++ b/include/linux/mfd/da9063/registers.h
@@ -104,16 +104,27 @@
104#define DA9063_REG_COUNT_D 0x43 104#define DA9063_REG_COUNT_D 0x43
105#define DA9063_REG_COUNT_MO 0x44 105#define DA9063_REG_COUNT_MO 0x44
106#define DA9063_REG_COUNT_Y 0x45 106#define DA9063_REG_COUNT_Y 0x45
107#define DA9063_REG_ALARM_S 0x46 107
108#define DA9063_REG_ALARM_MI 0x47 108#define DA9063_AD_REG_ALARM_MI 0x46
109#define DA9063_REG_ALARM_H 0x48 109#define DA9063_AD_REG_ALARM_H 0x47
110#define DA9063_REG_ALARM_D 0x49 110#define DA9063_AD_REG_ALARM_D 0x48
111#define DA9063_REG_ALARM_MO 0x4A 111#define DA9063_AD_REG_ALARM_MO 0x49
112#define DA9063_REG_ALARM_Y 0x4B 112#define DA9063_AD_REG_ALARM_Y 0x4A
113#define DA9063_REG_SECOND_A 0x4C 113#define DA9063_AD_REG_SECOND_A 0x4B
114#define DA9063_REG_SECOND_B 0x4D 114#define DA9063_AD_REG_SECOND_B 0x4C
115#define DA9063_REG_SECOND_C 0x4E 115#define DA9063_AD_REG_SECOND_C 0x4D
116#define DA9063_REG_SECOND_D 0x4F 116#define DA9063_AD_REG_SECOND_D 0x4E
117
118#define DA9063_BB_REG_ALARM_S 0x46
119#define DA9063_BB_REG_ALARM_MI 0x47
120#define DA9063_BB_REG_ALARM_H 0x48
121#define DA9063_BB_REG_ALARM_D 0x49
122#define DA9063_BB_REG_ALARM_MO 0x4A
123#define DA9063_BB_REG_ALARM_Y 0x4B
124#define DA9063_BB_REG_SECOND_A 0x4C
125#define DA9063_BB_REG_SECOND_B 0x4D
126#define DA9063_BB_REG_SECOND_C 0x4E
127#define DA9063_BB_REG_SECOND_D 0x4F
117 128
118/* Sequencer Control Registers */ 129/* Sequencer Control Registers */
119#define DA9063_REG_SEQ 0x81 130#define DA9063_REG_SEQ 0x81
@@ -223,37 +234,67 @@
223#define DA9063_REG_CONFIG_J 0x10F 234#define DA9063_REG_CONFIG_J 0x10F
224#define DA9063_REG_CONFIG_K 0x110 235#define DA9063_REG_CONFIG_K 0x110
225#define DA9063_REG_CONFIG_L 0x111 236#define DA9063_REG_CONFIG_L 0x111
226#define DA9063_REG_CONFIG_M 0x112 237
227#define DA9063_REG_CONFIG_N 0x113 238#define DA9063_AD_REG_MON_REG_1 0x112
228 239#define DA9063_AD_REG_MON_REG_2 0x113
229#define DA9063_REG_MON_REG_1 0x114 240#define DA9063_AD_REG_MON_REG_3 0x114
230#define DA9063_REG_MON_REG_2 0x115 241#define DA9063_AD_REG_MON_REG_4 0x115
231#define DA9063_REG_MON_REG_3 0x116 242#define DA9063_AD_REG_MON_REG_5 0x116
232#define DA9063_REG_MON_REG_4 0x117 243#define DA9063_AD_REG_MON_REG_6 0x117
233#define DA9063_REG_MON_REG_5 0x11E 244#define DA9063_AD_REG_TRIM_CLDR 0x118
234#define DA9063_REG_MON_REG_6 0x11F 245
235#define DA9063_REG_TRIM_CLDR 0x120 246#define DA9063_AD_REG_GP_ID_0 0x119
247#define DA9063_AD_REG_GP_ID_1 0x11A
248#define DA9063_AD_REG_GP_ID_2 0x11B
249#define DA9063_AD_REG_GP_ID_3 0x11C
250#define DA9063_AD_REG_GP_ID_4 0x11D
251#define DA9063_AD_REG_GP_ID_5 0x11E
252#define DA9063_AD_REG_GP_ID_6 0x11F
253#define DA9063_AD_REG_GP_ID_7 0x120
254#define DA9063_AD_REG_GP_ID_8 0x121
255#define DA9063_AD_REG_GP_ID_9 0x122
256#define DA9063_AD_REG_GP_ID_10 0x123
257#define DA9063_AD_REG_GP_ID_11 0x124
258#define DA9063_AD_REG_GP_ID_12 0x125
259#define DA9063_AD_REG_GP_ID_13 0x126
260#define DA9063_AD_REG_GP_ID_14 0x127
261#define DA9063_AD_REG_GP_ID_15 0x128
262#define DA9063_AD_REG_GP_ID_16 0x129
263#define DA9063_AD_REG_GP_ID_17 0x12A
264#define DA9063_AD_REG_GP_ID_18 0x12B
265#define DA9063_AD_REG_GP_ID_19 0x12C
266
267#define DA9063_BB_REG_CONFIG_M 0x112
268#define DA9063_BB_REG_CONFIG_N 0x113
269
270#define DA9063_BB_REG_MON_REG_1 0x114
271#define DA9063_BB_REG_MON_REG_2 0x115
272#define DA9063_BB_REG_MON_REG_3 0x116
273#define DA9063_BB_REG_MON_REG_4 0x117
274#define DA9063_BB_REG_MON_REG_5 0x11E
275#define DA9063_BB_REG_MON_REG_6 0x11F
276#define DA9063_BB_REG_TRIM_CLDR 0x120
236/* General Purpose Registers */ 277/* General Purpose Registers */
237#define DA9063_REG_GP_ID_0 0x121 278#define DA9063_BB_REG_GP_ID_0 0x121
238#define DA9063_REG_GP_ID_1 0x122 279#define DA9063_BB_REG_GP_ID_1 0x122
239#define DA9063_REG_GP_ID_2 0x123 280#define DA9063_BB_REG_GP_ID_2 0x123
240#define DA9063_REG_GP_ID_3 0x124 281#define DA9063_BB_REG_GP_ID_3 0x124
241#define DA9063_REG_GP_ID_4 0x125 282#define DA9063_BB_REG_GP_ID_4 0x125
242#define DA9063_REG_GP_ID_5 0x126 283#define DA9063_BB_REG_GP_ID_5 0x126
243#define DA9063_REG_GP_ID_6 0x127 284#define DA9063_BB_REG_GP_ID_6 0x127
244#define DA9063_REG_GP_ID_7 0x128 285#define DA9063_BB_REG_GP_ID_7 0x128
245#define DA9063_REG_GP_ID_8 0x129 286#define DA9063_BB_REG_GP_ID_8 0x129
246#define DA9063_REG_GP_ID_9 0x12A 287#define DA9063_BB_REG_GP_ID_9 0x12A
247#define DA9063_REG_GP_ID_10 0x12B 288#define DA9063_BB_REG_GP_ID_10 0x12B
248#define DA9063_REG_GP_ID_11 0x12C 289#define DA9063_BB_REG_GP_ID_11 0x12C
249#define DA9063_REG_GP_ID_12 0x12D 290#define DA9063_BB_REG_GP_ID_12 0x12D
250#define DA9063_REG_GP_ID_13 0x12E 291#define DA9063_BB_REG_GP_ID_13 0x12E
251#define DA9063_REG_GP_ID_14 0x12F 292#define DA9063_BB_REG_GP_ID_14 0x12F
252#define DA9063_REG_GP_ID_15 0x130 293#define DA9063_BB_REG_GP_ID_15 0x130
253#define DA9063_REG_GP_ID_16 0x131 294#define DA9063_BB_REG_GP_ID_16 0x131
254#define DA9063_REG_GP_ID_17 0x132 295#define DA9063_BB_REG_GP_ID_17 0x132
255#define DA9063_REG_GP_ID_18 0x133 296#define DA9063_BB_REG_GP_ID_18 0x133
256#define DA9063_REG_GP_ID_19 0x134 297#define DA9063_BB_REG_GP_ID_19 0x134
257 298
258/* Chip ID and variant */ 299/* Chip ID and variant */
259#define DA9063_REG_CHIP_ID 0x181 300#define DA9063_REG_CHIP_ID 0x181
@@ -404,10 +445,10 @@
404/* DA9063_REG_CONTROL_B (addr=0x0F) */ 445/* DA9063_REG_CONTROL_B (addr=0x0F) */
405#define DA9063_CHG_SEL 0x01 446#define DA9063_CHG_SEL 0x01
406#define DA9063_WATCHDOG_PD 0x02 447#define DA9063_WATCHDOG_PD 0x02
407#define DA9063_RESET_BLINKING 0x04 448#define DA9063_BB_RESET_BLINKING 0x04
408#define DA9063_NRES_MODE 0x08 449#define DA9063_NRES_MODE 0x08
409#define DA9063_NONKEY_LOCK 0x10 450#define DA9063_NONKEY_LOCK 0x10
410#define DA9063_BUCK_SLOWSTART 0x80 451#define DA9063_BB_BUCK_SLOWSTART 0x80
411 452
412/* DA9063_REG_CONTROL_C (addr=0x10) */ 453/* DA9063_REG_CONTROL_C (addr=0x10) */
413#define DA9063_DEBOUNCING_MASK 0x07 454#define DA9063_DEBOUNCING_MASK 0x07
@@ -467,7 +508,7 @@
467#define DA9063_GPADC_PAUSE 0x02 508#define DA9063_GPADC_PAUSE 0x02
468#define DA9063_PMIF_DIS 0x04 509#define DA9063_PMIF_DIS 0x04
469#define DA9063_HS2WIRE_DIS 0x08 510#define DA9063_HS2WIRE_DIS 0x08
470#define DA9063_CLDR_PAUSE 0x10 511#define DA9063_BB_CLDR_PAUSE 0x10
471#define DA9063_BBAT_DIS 0x20 512#define DA9063_BBAT_DIS 0x20
472#define DA9063_OUT_32K_PAUSE 0x40 513#define DA9063_OUT_32K_PAUSE 0x40
473#define DA9063_PMCONT_DIS 0x80 514#define DA9063_PMCONT_DIS 0x80
@@ -844,7 +885,7 @@
844#define DA9063_MONITOR 0x40 885#define DA9063_MONITOR 0x40
845 886
846/* DA9063_REG_ALARM_S (addr=0x46) */ 887/* DA9063_REG_ALARM_S (addr=0x46) */
847#define DA9063_ALARM_S_MASK 0x3F 888#define DA9063_BB_ALARM_S_MASK 0x3F
848#define DA9063_ALARM_STATUS_ALARM 0x80 889#define DA9063_ALARM_STATUS_ALARM 0x80
849#define DA9063_ALARM_STATUS_TICK 0x40 890#define DA9063_ALARM_STATUS_TICK 0x40
850/* DA9063_REG_ALARM_MI (addr=0x47) */ 891/* DA9063_REG_ALARM_MI (addr=0x47) */
diff --git a/include/linux/mfd/intel_soc_pmic.h b/include/linux/mfd/intel_soc_pmic.h
new file mode 100644
index 000000000000..abcbfcf32d10
--- /dev/null
+++ b/include/linux/mfd/intel_soc_pmic.h
@@ -0,0 +1,30 @@
1/*
2 * intel_soc_pmic.h - Intel SoC PMIC Driver
3 *
4 * Copyright (C) 2012-2014 Intel Corporation. All rights reserved.
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License version
8 * 2 as published by the Free Software Foundation.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * Author: Yang, Bin <bin.yang@intel.com>
16 * Author: Zhu, Lejun <lejun.zhu@linux.intel.com>
17 */
18
19#ifndef __INTEL_SOC_PMIC_H__
20#define __INTEL_SOC_PMIC_H__
21
22#include <linux/regmap.h>
23
24struct intel_soc_pmic {
25 int irq;
26 struct regmap *regmap;
27 struct regmap_irq_chip_data *irq_chip_data;
28};
29
30#endif /* __INTEL_SOC_PMIC_H__ */
diff --git a/include/linux/mfd/max77686-private.h b/include/linux/mfd/max77686-private.h
index 8c75a9c8dfab..960b92ad450d 100644
--- a/include/linux/mfd/max77686-private.h
+++ b/include/linux/mfd/max77686-private.h
@@ -1,5 +1,5 @@
1/* 1/*
2 * max77686-private.h - Voltage regulator driver for the Maxim 77686 2 * max77686-private.h - Voltage regulator driver for the Maxim 77686/802
3 * 3 *
4 * Copyright (C) 2012 Samsung Electrnoics 4 * Copyright (C) 2012 Samsung Electrnoics
5 * Chiwoong Byun <woong.byun@samsung.com> 5 * Chiwoong Byun <woong.byun@samsung.com>
@@ -28,6 +28,7 @@
28 28
29#define MAX77686_REG_INVALID (0xff) 29#define MAX77686_REG_INVALID (0xff)
30 30
31/* MAX77686 PMIC registers */
31enum max77686_pmic_reg { 32enum max77686_pmic_reg {
32 MAX77686_REG_DEVICE_ID = 0x00, 33 MAX77686_REG_DEVICE_ID = 0x00,
33 MAX77686_REG_INTSRC = 0x01, 34 MAX77686_REG_INTSRC = 0x01,
@@ -181,8 +182,209 @@ enum max77686_rtc_reg {
181 MAX77686_ALARM2_DATE = 0x1B, 182 MAX77686_ALARM2_DATE = 0x1B,
182}; 183};
183 184
184#define MAX77686_IRQSRC_PMIC (0) 185/* MAX77802 PMIC registers */
185#define MAX77686_IRQSRC_RTC (1 << 0) 186enum max77802_pmic_reg {
187 MAX77802_REG_DEVICE_ID = 0x00,
188 MAX77802_REG_INTSRC = 0x01,
189 MAX77802_REG_INT1 = 0x02,
190 MAX77802_REG_INT2 = 0x03,
191
192 MAX77802_REG_INT1MSK = 0x04,
193 MAX77802_REG_INT2MSK = 0x05,
194
195 MAX77802_REG_STATUS1 = 0x06,
196 MAX77802_REG_STATUS2 = 0x07,
197
198 MAX77802_REG_PWRON = 0x08,
199 /* Reserved: 0x09 */
200 MAX77802_REG_MRSTB = 0x0A,
201 MAX77802_REG_EPWRHOLD = 0x0B,
202 /* Reserved: 0x0C-0x0D */
203 MAX77802_REG_BOOSTCTRL = 0x0E,
204 MAX77802_REG_BOOSTOUT = 0x0F,
205
206 MAX77802_REG_BUCK1CTRL = 0x10,
207 MAX77802_REG_BUCK1DVS1 = 0x11,
208 MAX77802_REG_BUCK1DVS2 = 0x12,
209 MAX77802_REG_BUCK1DVS3 = 0x13,
210 MAX77802_REG_BUCK1DVS4 = 0x14,
211 MAX77802_REG_BUCK1DVS5 = 0x15,
212 MAX77802_REG_BUCK1DVS6 = 0x16,
213 MAX77802_REG_BUCK1DVS7 = 0x17,
214 MAX77802_REG_BUCK1DVS8 = 0x18,
215 /* Reserved: 0x19 */
216 MAX77802_REG_BUCK2CTRL1 = 0x1A,
217 MAX77802_REG_BUCK2CTRL2 = 0x1B,
218 MAX77802_REG_BUCK2PHTRAN = 0x1C,
219 MAX77802_REG_BUCK2DVS1 = 0x1D,
220 MAX77802_REG_BUCK2DVS2 = 0x1E,
221 MAX77802_REG_BUCK2DVS3 = 0x1F,
222 MAX77802_REG_BUCK2DVS4 = 0x20,
223 MAX77802_REG_BUCK2DVS5 = 0x21,
224 MAX77802_REG_BUCK2DVS6 = 0x22,
225 MAX77802_REG_BUCK2DVS7 = 0x23,
226 MAX77802_REG_BUCK2DVS8 = 0x24,
227 /* Reserved: 0x25-0x26 */
228 MAX77802_REG_BUCK3CTRL1 = 0x27,
229 MAX77802_REG_BUCK3DVS1 = 0x28,
230 MAX77802_REG_BUCK3DVS2 = 0x29,
231 MAX77802_REG_BUCK3DVS3 = 0x2A,
232 MAX77802_REG_BUCK3DVS4 = 0x2B,
233 MAX77802_REG_BUCK3DVS5 = 0x2C,
234 MAX77802_REG_BUCK3DVS6 = 0x2D,
235 MAX77802_REG_BUCK3DVS7 = 0x2E,
236 MAX77802_REG_BUCK3DVS8 = 0x2F,
237 /* Reserved: 0x30-0x36 */
238 MAX77802_REG_BUCK4CTRL1 = 0x37,
239 MAX77802_REG_BUCK4DVS1 = 0x38,
240 MAX77802_REG_BUCK4DVS2 = 0x39,
241 MAX77802_REG_BUCK4DVS3 = 0x3A,
242 MAX77802_REG_BUCK4DVS4 = 0x3B,
243 MAX77802_REG_BUCK4DVS5 = 0x3C,
244 MAX77802_REG_BUCK4DVS6 = 0x3D,
245 MAX77802_REG_BUCK4DVS7 = 0x3E,
246 MAX77802_REG_BUCK4DVS8 = 0x3F,
247 /* Reserved: 0x40 */
248 MAX77802_REG_BUCK5CTRL = 0x41,
249 MAX77802_REG_BUCK5OUT = 0x42,
250 /* Reserved: 0x43 */
251 MAX77802_REG_BUCK6CTRL = 0x44,
252 MAX77802_REG_BUCK6DVS1 = 0x45,
253 MAX77802_REG_BUCK6DVS2 = 0x46,
254 MAX77802_REG_BUCK6DVS3 = 0x47,
255 MAX77802_REG_BUCK6DVS4 = 0x48,
256 MAX77802_REG_BUCK6DVS5 = 0x49,
257 MAX77802_REG_BUCK6DVS6 = 0x4A,
258 MAX77802_REG_BUCK6DVS7 = 0x4B,
259 MAX77802_REG_BUCK6DVS8 = 0x4C,
260 /* Reserved: 0x4D */
261 MAX77802_REG_BUCK7CTRL = 0x4E,
262 MAX77802_REG_BUCK7OUT = 0x4F,
263 /* Reserved: 0x50 */
264 MAX77802_REG_BUCK8CTRL = 0x51,
265 MAX77802_REG_BUCK8OUT = 0x52,
266 /* Reserved: 0x53 */
267 MAX77802_REG_BUCK9CTRL = 0x54,
268 MAX77802_REG_BUCK9OUT = 0x55,
269 /* Reserved: 0x56 */
270 MAX77802_REG_BUCK10CTRL = 0x57,
271 MAX77802_REG_BUCK10OUT = 0x58,
272
273 /* Reserved: 0x59-0x5F */
274
275 MAX77802_REG_LDO1CTRL1 = 0x60,
276 MAX77802_REG_LDO2CTRL1 = 0x61,
277 MAX77802_REG_LDO3CTRL1 = 0x62,
278 MAX77802_REG_LDO4CTRL1 = 0x63,
279 MAX77802_REG_LDO5CTRL1 = 0x64,
280 MAX77802_REG_LDO6CTRL1 = 0x65,
281 MAX77802_REG_LDO7CTRL1 = 0x66,
282 MAX77802_REG_LDO8CTRL1 = 0x67,
283 MAX77802_REG_LDO9CTRL1 = 0x68,
284 MAX77802_REG_LDO10CTRL1 = 0x69,
285 MAX77802_REG_LDO11CTRL1 = 0x6A,
286 MAX77802_REG_LDO12CTRL1 = 0x6B,
287 MAX77802_REG_LDO13CTRL1 = 0x6C,
288 MAX77802_REG_LDO14CTRL1 = 0x6D,
289 MAX77802_REG_LDO15CTRL1 = 0x6E,
290 /* Reserved: 0x6F */
291 MAX77802_REG_LDO17CTRL1 = 0x70,
292 MAX77802_REG_LDO18CTRL1 = 0x71,
293 MAX77802_REG_LDO19CTRL1 = 0x72,
294 MAX77802_REG_LDO20CTRL1 = 0x73,
295 MAX77802_REG_LDO21CTRL1 = 0x74,
296 MAX77802_REG_LDO22CTRL1 = 0x75,
297 MAX77802_REG_LDO23CTRL1 = 0x76,
298 MAX77802_REG_LDO24CTRL1 = 0x77,
299 MAX77802_REG_LDO25CTRL1 = 0x78,
300 MAX77802_REG_LDO26CTRL1 = 0x79,
301 MAX77802_REG_LDO27CTRL1 = 0x7A,
302 MAX77802_REG_LDO28CTRL1 = 0x7B,
303 MAX77802_REG_LDO29CTRL1 = 0x7C,
304 MAX77802_REG_LDO30CTRL1 = 0x7D,
305 /* Reserved: 0x7E */
306 MAX77802_REG_LDO32CTRL1 = 0x7F,
307 MAX77802_REG_LDO33CTRL1 = 0x80,
308 MAX77802_REG_LDO34CTRL1 = 0x81,
309 MAX77802_REG_LDO35CTRL1 = 0x82,
310 /* Reserved: 0x83-0x8F */
311 MAX77802_REG_LDO1CTRL2 = 0x90,
312 MAX77802_REG_LDO2CTRL2 = 0x91,
313 MAX77802_REG_LDO3CTRL2 = 0x92,
314 MAX77802_REG_LDO4CTRL2 = 0x93,
315 MAX77802_REG_LDO5CTRL2 = 0x94,
316 MAX77802_REG_LDO6CTRL2 = 0x95,
317 MAX77802_REG_LDO7CTRL2 = 0x96,
318 MAX77802_REG_LDO8CTRL2 = 0x97,
319 MAX77802_REG_LDO9CTRL2 = 0x98,
320 MAX77802_REG_LDO10CTRL2 = 0x99,
321 MAX77802_REG_LDO11CTRL2 = 0x9A,
322 MAX77802_REG_LDO12CTRL2 = 0x9B,
323 MAX77802_REG_LDO13CTRL2 = 0x9C,
324 MAX77802_REG_LDO14CTRL2 = 0x9D,
325 MAX77802_REG_LDO15CTRL2 = 0x9E,
326 /* Reserved: 0x9F */
327 MAX77802_REG_LDO17CTRL2 = 0xA0,
328 MAX77802_REG_LDO18CTRL2 = 0xA1,
329 MAX77802_REG_LDO19CTRL2 = 0xA2,
330 MAX77802_REG_LDO20CTRL2 = 0xA3,
331 MAX77802_REG_LDO21CTRL2 = 0xA4,
332 MAX77802_REG_LDO22CTRL2 = 0xA5,
333 MAX77802_REG_LDO23CTRL2 = 0xA6,
334 MAX77802_REG_LDO24CTRL2 = 0xA7,
335 MAX77802_REG_LDO25CTRL2 = 0xA8,
336 MAX77802_REG_LDO26CTRL2 = 0xA9,
337 MAX77802_REG_LDO27CTRL2 = 0xAA,
338 MAX77802_REG_LDO28CTRL2 = 0xAB,
339 MAX77802_REG_LDO29CTRL2 = 0xAC,
340 MAX77802_REG_LDO30CTRL2 = 0xAD,
341 /* Reserved: 0xAE */
342 MAX77802_REG_LDO32CTRL2 = 0xAF,
343 MAX77802_REG_LDO33CTRL2 = 0xB0,
344 MAX77802_REG_LDO34CTRL2 = 0xB1,
345 MAX77802_REG_LDO35CTRL2 = 0xB2,
346 /* Reserved: 0xB3 */
347
348 MAX77802_REG_BBAT_CHG = 0xB4,
349 MAX77802_REG_32KHZ = 0xB5,
350
351 MAX77802_REG_PMIC_END = 0xB6,
352};
353
354enum max77802_rtc_reg {
355 MAX77802_RTC_INT = 0xC0,
356 MAX77802_RTC_INTM = 0xC1,
357 MAX77802_RTC_CONTROLM = 0xC2,
358 MAX77802_RTC_CONTROL = 0xC3,
359 MAX77802_RTC_UPDATE0 = 0xC4,
360 MAX77802_RTC_UPDATE1 = 0xC5,
361 MAX77802_WTSR_SMPL_CNTL = 0xC6,
362 MAX77802_RTC_SEC = 0xC7,
363 MAX77802_RTC_MIN = 0xC8,
364 MAX77802_RTC_HOUR = 0xC9,
365 MAX77802_RTC_WEEKDAY = 0xCA,
366 MAX77802_RTC_MONTH = 0xCB,
367 MAX77802_RTC_YEAR = 0xCC,
368 MAX77802_RTC_DATE = 0xCD,
369 MAX77802_RTC_AE1 = 0xCE,
370 MAX77802_ALARM1_SEC = 0xCF,
371 MAX77802_ALARM1_MIN = 0xD0,
372 MAX77802_ALARM1_HOUR = 0xD1,
373 MAX77802_ALARM1_WEEKDAY = 0xD2,
374 MAX77802_ALARM1_MONTH = 0xD3,
375 MAX77802_ALARM1_YEAR = 0xD4,
376 MAX77802_ALARM1_DATE = 0xD5,
377 MAX77802_RTC_AE2 = 0xD6,
378 MAX77802_ALARM2_SEC = 0xD7,
379 MAX77802_ALARM2_MIN = 0xD8,
380 MAX77802_ALARM2_HOUR = 0xD9,
381 MAX77802_ALARM2_WEEKDAY = 0xDA,
382 MAX77802_ALARM2_MONTH = 0xDB,
383 MAX77802_ALARM2_YEAR = 0xDC,
384 MAX77802_ALARM2_DATE = 0xDD,
385
386 MAX77802_RTC_END = 0xDF,
387};
186 388
187enum max77686_irq_source { 389enum max77686_irq_source {
188 PMIC_INT1 = 0, 390 PMIC_INT1 = 0,
@@ -205,30 +407,46 @@ enum max77686_irq {
205 MAX77686_PMICIRQ_140C, 407 MAX77686_PMICIRQ_140C,
206 MAX77686_PMICIRQ_120C, 408 MAX77686_PMICIRQ_120C,
207 409
208 MAX77686_RTCIRQ_RTC60S, 410 MAX77686_RTCIRQ_RTC60S = 0,
209 MAX77686_RTCIRQ_RTCA1, 411 MAX77686_RTCIRQ_RTCA1,
210 MAX77686_RTCIRQ_RTCA2, 412 MAX77686_RTCIRQ_RTCA2,
211 MAX77686_RTCIRQ_SMPL, 413 MAX77686_RTCIRQ_SMPL,
212 MAX77686_RTCIRQ_RTC1S, 414 MAX77686_RTCIRQ_RTC1S,
213 MAX77686_RTCIRQ_WTSR, 415 MAX77686_RTCIRQ_WTSR,
214
215 MAX77686_IRQ_NR,
216}; 416};
217 417
418#define MAX77686_INT1_PWRONF_MSK BIT(0)
419#define MAX77686_INT1_PWRONR_MSK BIT(1)
420#define MAX77686_INT1_JIGONBF_MSK BIT(2)
421#define MAX77686_INT1_JIGONBR_MSK BIT(3)
422#define MAX77686_INT1_ACOKBF_MSK BIT(4)
423#define MAX77686_INT1_ACOKBR_MSK BIT(5)
424#define MAX77686_INT1_ONKEY1S_MSK BIT(6)
425#define MAX77686_INT1_MRSTB_MSK BIT(7)
426
427#define MAX77686_INT2_140C_MSK BIT(0)
428#define MAX77686_INT2_120C_MSK BIT(1)
429
430#define MAX77686_RTCINT_RTC60S_MSK BIT(0)
431#define MAX77686_RTCINT_RTCA1_MSK BIT(1)
432#define MAX77686_RTCINT_RTCA2_MSK BIT(2)
433#define MAX77686_RTCINT_SMPL_MSK BIT(3)
434#define MAX77686_RTCINT_RTC1S_MSK BIT(4)
435#define MAX77686_RTCINT_WTSR_MSK BIT(5)
436
218struct max77686_dev { 437struct max77686_dev {
219 struct device *dev; 438 struct device *dev;
220 struct i2c_client *i2c; /* 0xcc / PMIC, Battery Control, and FLASH */ 439 struct i2c_client *i2c; /* 0xcc / PMIC, Battery Control, and FLASH */
221 struct i2c_client *rtc; /* slave addr 0x0c */ 440 struct i2c_client *rtc; /* slave addr 0x0c */
222 441
223 int type; 442 unsigned long type;
224 443
225 struct regmap *regmap; /* regmap for mfd */ 444 struct regmap *regmap; /* regmap for mfd */
226 struct regmap *rtc_regmap; /* regmap for rtc */ 445 struct regmap *rtc_regmap; /* regmap for rtc */
227 446 struct regmap_irq_chip_data *irq_data;
228 struct irq_domain *irq_domain; 447 struct regmap_irq_chip_data *rtc_irq_data;
229 448
230 int irq; 449 int irq;
231 int irq_gpio;
232 bool wakeup; 450 bool wakeup;
233 struct mutex irqlock; 451 struct mutex irqlock;
234 int irq_masks_cur[MAX77686_IRQ_GROUP_NR]; 452 int irq_masks_cur[MAX77686_IRQ_GROUP_NR];
@@ -237,6 +455,7 @@ struct max77686_dev {
237 455
238enum max77686_types { 456enum max77686_types {
239 TYPE_MAX77686, 457 TYPE_MAX77686,
458 TYPE_MAX77802,
240}; 459};
241 460
242extern int max77686_irq_init(struct max77686_dev *max77686); 461extern int max77686_irq_init(struct max77686_dev *max77686);
diff --git a/include/linux/mfd/max77686.h b/include/linux/mfd/max77686.h
index 46c0f320ed76..7e6dc4b2b795 100644
--- a/include/linux/mfd/max77686.h
+++ b/include/linux/mfd/max77686.h
@@ -1,5 +1,5 @@
1/* 1/*
2 * max77686.h - Driver for the Maxim 77686 2 * max77686.h - Driver for the Maxim 77686/802
3 * 3 *
4 * Copyright (C) 2012 Samsung Electrnoics 4 * Copyright (C) 2012 Samsung Electrnoics
5 * Chiwoong Byun <woong.byun@samsung.com> 5 * Chiwoong Byun <woong.byun@samsung.com>
@@ -71,6 +71,54 @@ enum max77686_regulators {
71 MAX77686_REG_MAX, 71 MAX77686_REG_MAX,
72}; 72};
73 73
74/* MAX77802 regulator IDs */
75enum max77802_regulators {
76 MAX77802_BUCK1 = 0,
77 MAX77802_BUCK2,
78 MAX77802_BUCK3,
79 MAX77802_BUCK4,
80 MAX77802_BUCK5,
81 MAX77802_BUCK6,
82 MAX77802_BUCK7,
83 MAX77802_BUCK8,
84 MAX77802_BUCK9,
85 MAX77802_BUCK10,
86 MAX77802_LDO1,
87 MAX77802_LDO2,
88 MAX77802_LDO3,
89 MAX77802_LDO4,
90 MAX77802_LDO5,
91 MAX77802_LDO6,
92 MAX77802_LDO7,
93 MAX77802_LDO8,
94 MAX77802_LDO9,
95 MAX77802_LDO10,
96 MAX77802_LDO11,
97 MAX77802_LDO12,
98 MAX77802_LDO13,
99 MAX77802_LDO14,
100 MAX77802_LDO15,
101 MAX77802_LDO17,
102 MAX77802_LDO18,
103 MAX77802_LDO19,
104 MAX77802_LDO20,
105 MAX77802_LDO21,
106 MAX77802_LDO23,
107 MAX77802_LDO24,
108 MAX77802_LDO25,
109 MAX77802_LDO26,
110 MAX77802_LDO27,
111 MAX77802_LDO28,
112 MAX77802_LDO29,
113 MAX77802_LDO30,
114 MAX77802_LDO32,
115 MAX77802_LDO33,
116 MAX77802_LDO34,
117 MAX77802_LDO35,
118
119 MAX77802_REG_MAX,
120};
121
74struct max77686_regulator_data { 122struct max77686_regulator_data {
75 int id; 123 int id;
76 struct regulator_init_data *initdata; 124 struct regulator_init_data *initdata;
@@ -83,14 +131,19 @@ enum max77686_opmode {
83 MAX77686_OPMODE_STANDBY, 131 MAX77686_OPMODE_STANDBY,
84}; 132};
85 133
134enum max77802_opmode {
135 MAX77802_OPMODE_OFF,
136 MAX77802_OPMODE_STANDBY,
137 MAX77802_OPMODE_LP,
138 MAX77802_OPMODE_NORMAL,
139};
140
86struct max77686_opmode_data { 141struct max77686_opmode_data {
87 int id; 142 int id;
88 int mode; 143 int mode;
89}; 144};
90 145
91struct max77686_platform_data { 146struct max77686_platform_data {
92 /* IRQ */
93 int irq_gpio;
94 int ono; 147 int ono;
95 int wakeup; 148 int wakeup;
96 149
diff --git a/include/linux/mfd/mc13783.h b/include/linux/mfd/mc13783.h
index a8eeda773a7b..4ff6137d8d67 100644
--- a/include/linux/mfd/mc13783.h
+++ b/include/linux/mfd/mc13783.h
@@ -86,6 +86,5 @@
86#define MC13783_IRQ_HSL 43 86#define MC13783_IRQ_HSL 43
87#define MC13783_IRQ_ALSPTH 44 87#define MC13783_IRQ_ALSPTH 44
88#define MC13783_IRQ_AHSSHORT 45 88#define MC13783_IRQ_AHSSHORT 45
89#define MC13783_NUM_IRQ MC13XXX_NUM_IRQ
90 89
91#endif /* ifndef __LINUX_MFD_MC13783_H */ 90#endif /* ifndef __LINUX_MFD_MC13783_H */
diff --git a/include/linux/mfd/mc13xxx.h b/include/linux/mfd/mc13xxx.h
index d63b1d309106..638222e43e48 100644
--- a/include/linux/mfd/mc13xxx.h
+++ b/include/linux/mfd/mc13xxx.h
@@ -23,15 +23,10 @@ int mc13xxx_reg_rmw(struct mc13xxx *mc13xxx, unsigned int offset,
23 23
24int mc13xxx_irq_request(struct mc13xxx *mc13xxx, int irq, 24int mc13xxx_irq_request(struct mc13xxx *mc13xxx, int irq,
25 irq_handler_t handler, const char *name, void *dev); 25 irq_handler_t handler, const char *name, void *dev);
26int mc13xxx_irq_request_nounmask(struct mc13xxx *mc13xxx, int irq,
27 irq_handler_t handler, const char *name, void *dev);
28int mc13xxx_irq_free(struct mc13xxx *mc13xxx, int irq, void *dev); 26int mc13xxx_irq_free(struct mc13xxx *mc13xxx, int irq, void *dev);
29 27
30int mc13xxx_irq_mask(struct mc13xxx *mc13xxx, int irq);
31int mc13xxx_irq_unmask(struct mc13xxx *mc13xxx, int irq);
32int mc13xxx_irq_status(struct mc13xxx *mc13xxx, int irq, 28int mc13xxx_irq_status(struct mc13xxx *mc13xxx, int irq,
33 int *enabled, int *pending); 29 int *enabled, int *pending);
34int mc13xxx_irq_ack(struct mc13xxx *mc13xxx, int irq);
35 30
36int mc13xxx_get_flags(struct mc13xxx *mc13xxx); 31int mc13xxx_get_flags(struct mc13xxx *mc13xxx);
37 32
@@ -39,6 +34,22 @@ int mc13xxx_adc_do_conversion(struct mc13xxx *mc13xxx,
39 unsigned int mode, unsigned int channel, 34 unsigned int mode, unsigned int channel,
40 u8 ato, bool atox, unsigned int *sample); 35 u8 ato, bool atox, unsigned int *sample);
41 36
37/* Deprecated calls */
38static inline int mc13xxx_irq_ack(struct mc13xxx *mc13xxx, int irq)
39{
40 return 0;
41}
42
43static inline int mc13xxx_irq_request_nounmask(struct mc13xxx *mc13xxx, int irq,
44 irq_handler_t handler,
45 const char *name, void *dev)
46{
47 return mc13xxx_irq_request(mc13xxx, irq, handler, name, dev);
48}
49
50int mc13xxx_irq_mask(struct mc13xxx *mc13xxx, int irq);
51int mc13xxx_irq_unmask(struct mc13xxx *mc13xxx, int irq);
52
42#define MC13783_AUDIO_RX0 36 53#define MC13783_AUDIO_RX0 36
43#define MC13783_AUDIO_RX1 37 54#define MC13783_AUDIO_RX1 37
44#define MC13783_AUDIO_TX 38 55#define MC13783_AUDIO_TX 38
@@ -68,8 +79,6 @@ int mc13xxx_adc_do_conversion(struct mc13xxx *mc13xxx,
68#define MC13XXX_IRQ_THWARNH 37 79#define MC13XXX_IRQ_THWARNH 37
69#define MC13XXX_IRQ_CLK 38 80#define MC13XXX_IRQ_CLK 38
70 81
71#define MC13XXX_NUM_IRQ 46
72
73struct regulator_init_data; 82struct regulator_init_data;
74 83
75struct mc13xxx_regulator_init_data { 84struct mc13xxx_regulator_init_data {
diff --git a/include/linux/mfd/rtsx_pci.h b/include/linux/mfd/rtsx_pci.h
index a3835976f7c6..74346d5e7899 100644
--- a/include/linux/mfd/rtsx_pci.h
+++ b/include/linux/mfd/rtsx_pci.h
@@ -943,6 +943,12 @@ void rtsx_pci_send_cmd_no_wait(struct rtsx_pcr *pcr);
943int rtsx_pci_send_cmd(struct rtsx_pcr *pcr, int timeout); 943int rtsx_pci_send_cmd(struct rtsx_pcr *pcr, int timeout);
944int rtsx_pci_transfer_data(struct rtsx_pcr *pcr, struct scatterlist *sglist, 944int rtsx_pci_transfer_data(struct rtsx_pcr *pcr, struct scatterlist *sglist,
945 int num_sg, bool read, int timeout); 945 int num_sg, bool read, int timeout);
946int rtsx_pci_dma_map_sg(struct rtsx_pcr *pcr, struct scatterlist *sglist,
947 int num_sg, bool read);
948void rtsx_pci_dma_unmap_sg(struct rtsx_pcr *pcr, struct scatterlist *sglist,
949 int num_sg, bool read);
950int rtsx_pci_dma_transfer(struct rtsx_pcr *pcr, struct scatterlist *sglist,
951 int count, bool read, int timeout);
946int rtsx_pci_read_ppbuf(struct rtsx_pcr *pcr, u8 *buf, int buf_len); 952int rtsx_pci_read_ppbuf(struct rtsx_pcr *pcr, u8 *buf, int buf_len);
947int rtsx_pci_write_ppbuf(struct rtsx_pcr *pcr, u8 *buf, int buf_len); 953int rtsx_pci_write_ppbuf(struct rtsx_pcr *pcr, u8 *buf, int buf_len);
948int rtsx_pci_card_pull_ctl_enable(struct rtsx_pcr *pcr, int card); 954int rtsx_pci_card_pull_ctl_enable(struct rtsx_pcr *pcr, int card);
diff --git a/include/linux/mfd/samsung/core.h b/include/linux/mfd/samsung/core.h
index 47d84242940b..b5f73de81aad 100644
--- a/include/linux/mfd/samsung/core.h
+++ b/include/linux/mfd/samsung/core.h
@@ -21,6 +21,7 @@ enum sec_device_type {
21 S2MPA01, 21 S2MPA01,
22 S2MPS11X, 22 S2MPS11X,
23 S2MPS14X, 23 S2MPS14X,
24 S2MPU02,
24}; 25};
25 26
26/** 27/**
diff --git a/include/linux/mfd/samsung/irq.h b/include/linux/mfd/samsung/irq.h
index 1224f447356b..f35af7361b60 100644
--- a/include/linux/mfd/samsung/irq.h
+++ b/include/linux/mfd/samsung/irq.h
@@ -129,6 +129,30 @@ enum s2mps14_irq {
129 S2MPS14_IRQ_NR, 129 S2MPS14_IRQ_NR,
130}; 130};
131 131
132enum s2mpu02_irq {
133 S2MPU02_IRQ_PWRONF,
134 S2MPU02_IRQ_PWRONR,
135 S2MPU02_IRQ_JIGONBF,
136 S2MPU02_IRQ_JIGONBR,
137 S2MPU02_IRQ_ACOKBF,
138 S2MPU02_IRQ_ACOKBR,
139 S2MPU02_IRQ_PWRON1S,
140 S2MPU02_IRQ_MRB,
141
142 S2MPU02_IRQ_RTC60S,
143 S2MPU02_IRQ_RTCA1,
144 S2MPU02_IRQ_RTCA0,
145 S2MPU02_IRQ_SMPL,
146 S2MPU02_IRQ_RTC1S,
147 S2MPU02_IRQ_WTSR,
148
149 S2MPU02_IRQ_INT120C,
150 S2MPU02_IRQ_INT140C,
151 S2MPU02_IRQ_TSD,
152
153 S2MPU02_IRQ_NR,
154};
155
132/* Masks for interrupts are the same as in s2mps11 */ 156/* Masks for interrupts are the same as in s2mps11 */
133#define S2MPS14_IRQ_TSD_MASK (1 << 2) 157#define S2MPS14_IRQ_TSD_MASK (1 << 2)
134 158
diff --git a/include/linux/mfd/samsung/s2mpu02.h b/include/linux/mfd/samsung/s2mpu02.h
new file mode 100644
index 000000000000..47ae9bc583a7
--- /dev/null
+++ b/include/linux/mfd/samsung/s2mpu02.h
@@ -0,0 +1,201 @@
1/*
2 * s2mpu02.h
3 *
4 * Copyright (c) 2014 Samsung Electronics Co., Ltd
5 * http://www.samsung.com
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the
9 * Free Software Foundation; either version 2 of the License, or (at your
10 * option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 */
18
19#ifndef __LINUX_MFD_S2MPU02_H
20#define __LINUX_MFD_S2MPU02_H
21
22/* S2MPU02 registers */
23enum S2MPU02_reg {
24 S2MPU02_REG_ID,
25 S2MPU02_REG_INT1,
26 S2MPU02_REG_INT2,
27 S2MPU02_REG_INT3,
28 S2MPU02_REG_INT1M,
29 S2MPU02_REG_INT2M,
30 S2MPU02_REG_INT3M,
31 S2MPU02_REG_ST1,
32 S2MPU02_REG_ST2,
33 S2MPU02_REG_PWRONSRC,
34 S2MPU02_REG_OFFSRC,
35 S2MPU02_REG_BU_CHG,
36 S2MPU02_REG_RTCCTRL,
37 S2MPU02_REG_PMCTRL1,
38 S2MPU02_REG_RSVD1,
39 S2MPU02_REG_RSVD2,
40 S2MPU02_REG_RSVD3,
41 S2MPU02_REG_RSVD4,
42 S2MPU02_REG_RSVD5,
43 S2MPU02_REG_RSVD6,
44 S2MPU02_REG_RSVD7,
45 S2MPU02_REG_WRSTEN,
46 S2MPU02_REG_RSVD8,
47 S2MPU02_REG_RSVD9,
48 S2MPU02_REG_RSVD10,
49 S2MPU02_REG_B1CTRL1,
50 S2MPU02_REG_B1CTRL2,
51 S2MPU02_REG_B2CTRL1,
52 S2MPU02_REG_B2CTRL2,
53 S2MPU02_REG_B3CTRL1,
54 S2MPU02_REG_B3CTRL2,
55 S2MPU02_REG_B4CTRL1,
56 S2MPU02_REG_B4CTRL2,
57 S2MPU02_REG_B5CTRL1,
58 S2MPU02_REG_B5CTRL2,
59 S2MPU02_REG_B5CTRL3,
60 S2MPU02_REG_B5CTRL4,
61 S2MPU02_REG_B5CTRL5,
62 S2MPU02_REG_B6CTRL1,
63 S2MPU02_REG_B6CTRL2,
64 S2MPU02_REG_B7CTRL1,
65 S2MPU02_REG_B7CTRL2,
66 S2MPU02_REG_RAMP1,
67 S2MPU02_REG_RAMP2,
68 S2MPU02_REG_L1CTRL,
69 S2MPU02_REG_L2CTRL1,
70 S2MPU02_REG_L2CTRL2,
71 S2MPU02_REG_L2CTRL3,
72 S2MPU02_REG_L2CTRL4,
73 S2MPU02_REG_L3CTRL,
74 S2MPU02_REG_L4CTRL,
75 S2MPU02_REG_L5CTRL,
76 S2MPU02_REG_L6CTRL,
77 S2MPU02_REG_L7CTRL,
78 S2MPU02_REG_L8CTRL,
79 S2MPU02_REG_L9CTRL,
80 S2MPU02_REG_L10CTRL,
81 S2MPU02_REG_L11CTRL,
82 S2MPU02_REG_L12CTRL,
83 S2MPU02_REG_L13CTRL,
84 S2MPU02_REG_L14CTRL,
85 S2MPU02_REG_L15CTRL,
86 S2MPU02_REG_L16CTRL,
87 S2MPU02_REG_L17CTRL,
88 S2MPU02_REG_L18CTRL,
89 S2MPU02_REG_L19CTRL,
90 S2MPU02_REG_L20CTRL,
91 S2MPU02_REG_L21CTRL,
92 S2MPU02_REG_L22CTRL,
93 S2MPU02_REG_L23CTRL,
94 S2MPU02_REG_L24CTRL,
95 S2MPU02_REG_L25CTRL,
96 S2MPU02_REG_L26CTRL,
97 S2MPU02_REG_L27CTRL,
98 S2MPU02_REG_L28CTRL,
99 S2MPU02_REG_LDODSCH1,
100 S2MPU02_REG_LDODSCH2,
101 S2MPU02_REG_LDODSCH3,
102 S2MPU02_REG_LDODSCH4,
103 S2MPU02_REG_SELMIF,
104 S2MPU02_REG_RSVD11,
105 S2MPU02_REG_RSVD12,
106 S2MPU02_REG_RSVD13,
107 S2MPU02_REG_DVSSEL,
108 S2MPU02_REG_DVSPTR,
109 S2MPU02_REG_DVSDATA,
110};
111
112/* S2MPU02 regulator ids */
113enum S2MPU02_regulators {
114 S2MPU02_LDO1,
115 S2MPU02_LDO2,
116 S2MPU02_LDO3,
117 S2MPU02_LDO4,
118 S2MPU02_LDO5,
119 S2MPU02_LDO6,
120 S2MPU02_LDO7,
121 S2MPU02_LDO8,
122 S2MPU02_LDO9,
123 S2MPU02_LDO10,
124 S2MPU02_LDO11,
125 S2MPU02_LDO12,
126 S2MPU02_LDO13,
127 S2MPU02_LDO14,
128 S2MPU02_LDO15,
129 S2MPU02_LDO16,
130 S2MPU02_LDO17,
131 S2MPU02_LDO18,
132 S2MPU02_LDO19,
133 S2MPU02_LDO20,
134 S2MPU02_LDO21,
135 S2MPU02_LDO22,
136 S2MPU02_LDO23,
137 S2MPU02_LDO24,
138 S2MPU02_LDO25,
139 S2MPU02_LDO26,
140 S2MPU02_LDO27,
141 S2MPU02_LDO28,
142 S2MPU02_BUCK1,
143 S2MPU02_BUCK2,
144 S2MPU02_BUCK3,
145 S2MPU02_BUCK4,
146 S2MPU02_BUCK5,
147 S2MPU02_BUCK6,
148 S2MPU02_BUCK7,
149
150 S2MPU02_REGULATOR_MAX,
151};
152
153/* Regulator constraints for BUCKx */
154#define S2MPU02_BUCK1234_MIN_600MV 600000
155#define S2MPU02_BUCK5_MIN_1081_25MV 1081250
156#define S2MPU02_BUCK6_MIN_1700MV 1700000
157#define S2MPU02_BUCK7_MIN_900MV 900000
158
159#define S2MPU02_BUCK1234_STEP_6_25MV 6250
160#define S2MPU02_BUCK5_STEP_6_25MV 6250
161#define S2MPU02_BUCK6_STEP_2_50MV 2500
162#define S2MPU02_BUCK7_STEP_6_25MV 6250
163
164#define S2MPU02_BUCK1234_START_SEL 0x00
165#define S2MPU02_BUCK5_START_SEL 0x4D
166#define S2MPU02_BUCK6_START_SEL 0x28
167#define S2MPU02_BUCK7_START_SEL 0x30
168
169#define S2MPU02_BUCK_RAMP_DELAY 12500
170
171/* Regulator constraints for different types of LDOx */
172#define S2MPU02_LDO_MIN_900MV 900000
173#define S2MPU02_LDO_MIN_1050MV 1050000
174#define S2MPU02_LDO_MIN_1600MV 1600000
175#define S2MPU02_LDO_STEP_12_5MV 12500
176#define S2MPU02_LDO_STEP_25MV 25000
177#define S2MPU02_LDO_STEP_50MV 50000
178
179#define S2MPU02_LDO_GROUP1_START_SEL 0x8
180#define S2MPU02_LDO_GROUP2_START_SEL 0xA
181#define S2MPU02_LDO_GROUP3_START_SEL 0x10
182
183#define S2MPU02_LDO_VSEL_MASK 0x3F
184#define S2MPU02_BUCK_VSEL_MASK 0xFF
185#define S2MPU02_ENABLE_MASK (0x03 << S2MPU02_ENABLE_SHIFT)
186#define S2MPU02_ENABLE_SHIFT 6
187
188/* On/Off controlled by PWREN */
189#define S2MPU02_ENABLE_SUSPEND (0x01 << S2MPU02_ENABLE_SHIFT)
190#define S2MPU02_DISABLE_SUSPEND (0x11 << S2MPU02_ENABLE_SHIFT)
191#define S2MPU02_LDO_N_VOLTAGES (S2MPU02_LDO_VSEL_MASK + 1)
192#define S2MPU02_BUCK_N_VOLTAGES (S2MPU02_BUCK_VSEL_MASK + 1)
193
194/* RAMP delay for BUCK1234*/
195#define S2MPU02_BUCK1_RAMP_SHIFT 6
196#define S2MPU02_BUCK2_RAMP_SHIFT 4
197#define S2MPU02_BUCK3_RAMP_SHIFT 2
198#define S2MPU02_BUCK4_RAMP_SHIFT 0
199#define S2MPU02_BUCK1234_RAMP_MASK 0x3
200
201#endif /* __LINUX_MFD_S2MPU02_H */
diff --git a/include/linux/mfd/tps65910.h b/include/linux/mfd/tps65910.h
index 16c2335c2856..6483a6fdce59 100644
--- a/include/linux/mfd/tps65910.h
+++ b/include/linux/mfd/tps65910.h
@@ -892,7 +892,7 @@ struct tps65910 {
892 struct device *dev; 892 struct device *dev;
893 struct i2c_client *i2c_client; 893 struct i2c_client *i2c_client;
894 struct regmap *regmap; 894 struct regmap *regmap;
895 unsigned int id; 895 unsigned long id;
896 896
897 /* Client devices */ 897 /* Client devices */
898 struct tps65910_pmic *pmic; 898 struct tps65910_pmic *pmic;