aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLee Jones <lee.jones@linaro.org>2012-06-20 08:56:38 -0400
committerSamuel Ortiz <sameo@linux.intel.com>2012-07-08 18:16:08 -0400
commit822672a7b496e724f879af703693f342e2215163 (patch)
treeb4b53d7f455a9835aa8083a031df322d97ae1579
parent06e589efa5b75e6a38a8e8b9c6cd774b5f679cdc (diff)
mfd: Generically describe interactions with the DB8500 PRCMU
There is only one method used to communicate with the DB8500 PRCMU, via I2C. Now this can be assumed, there is no requirement to specify the protocol in the function name. This patch removes protocol specifics and uses a more generic naming convention. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
-rw-r--r--drivers/mfd/ab8500-core.c12
-rw-r--r--drivers/mfd/ab8500-debugfs.c6
2 files changed, 9 insertions, 9 deletions
diff --git a/drivers/mfd/ab8500-core.c b/drivers/mfd/ab8500-core.c
index f3af34596439..a19f520e2c72 100644
--- a/drivers/mfd/ab8500-core.c
+++ b/drivers/mfd/ab8500-core.c
@@ -141,7 +141,7 @@ static const char ab8500_version_str[][7] = {
141 [AB8500_VERSION_AB8540] = "AB8540", 141 [AB8500_VERSION_AB8540] = "AB8540",
142}; 142};
143 143
144static int ab8500_i2c_write(struct ab8500 *ab8500, u16 addr, u8 data) 144static int ab8500_prcmu_write(struct ab8500 *ab8500, u16 addr, u8 data)
145{ 145{
146 int ret; 146 int ret;
147 147
@@ -151,7 +151,7 @@ static int ab8500_i2c_write(struct ab8500 *ab8500, u16 addr, u8 data)
151 return ret; 151 return ret;
152} 152}
153 153
154static int ab8500_i2c_write_masked(struct ab8500 *ab8500, u16 addr, u8 mask, 154static int ab8500_prcmu_write_masked(struct ab8500 *ab8500, u16 addr, u8 mask,
155 u8 data) 155 u8 data)
156{ 156{
157 int ret; 157 int ret;
@@ -163,7 +163,7 @@ static int ab8500_i2c_write_masked(struct ab8500 *ab8500, u16 addr, u8 mask,
163 return ret; 163 return ret;
164} 164}
165 165
166static int ab8500_i2c_read(struct ab8500 *ab8500, u16 addr) 166static int ab8500_prcmu_read(struct ab8500 *ab8500, u16 addr)
167{ 167{
168 int ret; 168 int ret;
169 u8 data; 169 u8 data;
@@ -1267,9 +1267,9 @@ static int __devinit ab8500_probe(struct platform_device *pdev)
1267 1267
1268 ab8500->irq = resource->start; 1268 ab8500->irq = resource->start;
1269 1269
1270 ab8500->read = ab8500_i2c_read; 1270 ab8500->read = ab8500_prcmu_read;
1271 ab8500->write = ab8500_i2c_write; 1271 ab8500->write = ab8500_prcmu_write;
1272 ab8500->write_masked = ab8500_i2c_write_masked; 1272 ab8500->write_masked = ab8500_prcmu_write_masked;
1273 1273
1274 mutex_init(&ab8500->lock); 1274 mutex_init(&ab8500->lock);
1275 mutex_init(&ab8500->irq_lock); 1275 mutex_init(&ab8500->irq_lock);
diff --git a/drivers/mfd/ab8500-debugfs.c b/drivers/mfd/ab8500-debugfs.c
index 50c4c89ab220..361de52aefe5 100644
--- a/drivers/mfd/ab8500-debugfs.c
+++ b/drivers/mfd/ab8500-debugfs.c
@@ -31,12 +31,12 @@ struct ab8500_reg_range {
31}; 31};
32 32
33/** 33/**
34 * struct ab8500_i2c_ranges 34 * struct ab8500_prcmu_ranges
35 * @num_ranges: the number of ranges in the list 35 * @num_ranges: the number of ranges in the list
36 * @bankid: bank identifier 36 * @bankid: bank identifier
37 * @range: the list of register ranges 37 * @range: the list of register ranges
38 */ 38 */
39struct ab8500_i2c_ranges { 39struct ab8500_prcmu_ranges {
40 u8 num_ranges; 40 u8 num_ranges;
41 u8 bankid; 41 u8 bankid;
42 const struct ab8500_reg_range *range; 42 const struct ab8500_reg_range *range;
@@ -47,7 +47,7 @@ struct ab8500_i2c_ranges {
47 47
48#define AB8500_REV_REG 0x80 48#define AB8500_REV_REG 0x80
49 49
50static struct ab8500_i2c_ranges debug_ranges[AB8500_NUM_BANKS] = { 50static struct ab8500_prcmu_ranges debug_ranges[AB8500_NUM_BANKS] = {
51 [0x0] = { 51 [0x0] = {
52 .num_ranges = 0, 52 .num_ranges = 0,
53 .range = 0, 53 .range = 0,