diff options
author | Steve Twiss <stwiss.opensource@diasemi.com> | 2015-10-08 11:17:51 -0400 |
---|---|---|
committer | Lee Jones <lee.jones@linaro.org> | 2015-10-30 13:19:49 -0400 |
commit | 0386af30d3d99d942dd68a8c64beb4f03958e74f (patch) | |
tree | cb1d24f7695a0e7730bce158e5fc3f36a0f2cca3 | |
parent | 5c41f11c625e6860b00e58c237dd03a89a8beccc (diff) |
mfd: da9053: Addition of extra registers for GPIOs 8-13
Definitions for GPIO registers 8, 9, 10, 11, 12 and 13 are added into
the register header file.
- DA9052_GPIO_8_9_REG 25
- DA9052_GPIO_10_11_REG 26
- DA9052_GPIO_12_13_REG 27
A modification is also made to the MFD core code to define these registers
as readable and writable. The functions for da9052_reg_readable() and
da9052_reg_writeable() have had their case statements altered to include
these new registers.
Signed-off-by: Steve Twiss <stwiss.opensource@diasemi.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
-rw-r--r-- | drivers/mfd/da9052-core.c | 6 | ||||
-rw-r--r-- | include/linux/mfd/da9052/reg.h | 3 |
2 files changed, 9 insertions, 0 deletions
diff --git a/drivers/mfd/da9052-core.c b/drivers/mfd/da9052-core.c index 46e3840c7a37..c0bf68a3e614 100644 --- a/drivers/mfd/da9052-core.c +++ b/drivers/mfd/da9052-core.c | |||
@@ -51,6 +51,9 @@ static bool da9052_reg_readable(struct device *dev, unsigned int reg) | |||
51 | case DA9052_GPIO_2_3_REG: | 51 | case DA9052_GPIO_2_3_REG: |
52 | case DA9052_GPIO_4_5_REG: | 52 | case DA9052_GPIO_4_5_REG: |
53 | case DA9052_GPIO_6_7_REG: | 53 | case DA9052_GPIO_6_7_REG: |
54 | case DA9052_GPIO_8_9_REG: | ||
55 | case DA9052_GPIO_10_11_REG: | ||
56 | case DA9052_GPIO_12_13_REG: | ||
54 | case DA9052_GPIO_14_15_REG: | 57 | case DA9052_GPIO_14_15_REG: |
55 | case DA9052_ID_0_1_REG: | 58 | case DA9052_ID_0_1_REG: |
56 | case DA9052_ID_2_3_REG: | 59 | case DA9052_ID_2_3_REG: |
@@ -178,6 +181,9 @@ static bool da9052_reg_writeable(struct device *dev, unsigned int reg) | |||
178 | case DA9052_GPIO_2_3_REG: | 181 | case DA9052_GPIO_2_3_REG: |
179 | case DA9052_GPIO_4_5_REG: | 182 | case DA9052_GPIO_4_5_REG: |
180 | case DA9052_GPIO_6_7_REG: | 183 | case DA9052_GPIO_6_7_REG: |
184 | case DA9052_GPIO_8_9_REG: | ||
185 | case DA9052_GPIO_10_11_REG: | ||
186 | case DA9052_GPIO_12_13_REG: | ||
181 | case DA9052_GPIO_14_15_REG: | 187 | case DA9052_GPIO_14_15_REG: |
182 | case DA9052_ID_0_1_REG: | 188 | case DA9052_ID_0_1_REG: |
183 | case DA9052_ID_2_3_REG: | 189 | case DA9052_ID_2_3_REG: |
diff --git a/include/linux/mfd/da9052/reg.h b/include/linux/mfd/da9052/reg.h index c4dd3a8add21..5010f978725c 100644 --- a/include/linux/mfd/da9052/reg.h +++ b/include/linux/mfd/da9052/reg.h | |||
@@ -65,6 +65,9 @@ | |||
65 | #define DA9052_GPIO_2_3_REG 22 | 65 | #define DA9052_GPIO_2_3_REG 22 |
66 | #define DA9052_GPIO_4_5_REG 23 | 66 | #define DA9052_GPIO_4_5_REG 23 |
67 | #define DA9052_GPIO_6_7_REG 24 | 67 | #define DA9052_GPIO_6_7_REG 24 |
68 | #define DA9052_GPIO_8_9_REG 25 | ||
69 | #define DA9052_GPIO_10_11_REG 26 | ||
70 | #define DA9052_GPIO_12_13_REG 27 | ||
68 | #define DA9052_GPIO_14_15_REG 28 | 71 | #define DA9052_GPIO_14_15_REG 28 |
69 | 72 | ||
70 | /* POWER SEQUENCER CONTROL REGISTERS */ | 73 | /* POWER SEQUENCER CONTROL REGISTERS */ |