[ifxmips] many more code cleanups for checkpatch.pl, most flagged as errors
[openwrt.git] / target / linux / s3c24xx / patches-2.6.24 / 1306--lis302dl-refactor-and-cleanup.patch.patch
1 From 3318a7cb3165a33046e122294e1878e3bd6555d8 Mon Sep 17 00:00:00 2001
2 From: Simon Kagstrom <simon.kagstrom@gmail.com>
3 Date: Thu, 16 Oct 2008 01:19:20 +0100
4 Subject: [PATCH] : lis302dl-refactor-and-cleanup.patch
5
6 Some code refactoring.
7
8 From: Simon Kagstrom <simon.kagstrom@gmail.com>
9
10 Re-added __reg_read and __reg_write and re-indent the code according to
11 these. Move some input-related functions to get a more "logical" order,
12 e.g., in the future we might want to support clicks again and call these
13 from read_sample. Removed unused function pointer in the structure
14
15 Signed-off-by: Simon Kagstrom <simon.kagstrom@gmail.com>
16 ---
17 drivers/input/misc/lis302dl.c | 260 ++++++++++++++++++++---------------------
18 include/linux/lis302dl.h | 1 -
19 2 files changed, 125 insertions(+), 136 deletions(-)
20
21 diff --git a/drivers/input/misc/lis302dl.c b/drivers/input/misc/lis302dl.c
22 index 1013f4a..300918d 100644
23 --- a/drivers/input/misc/lis302dl.c
24 +++ b/drivers/input/misc/lis302dl.c
25 @@ -43,19 +43,58 @@
26
27 #include <linux/lis302dl.h>
28
29 +/* Utility functions */
30 +static u8 __reg_read(struct lis302dl_info *lis, u8 reg)
31 +{
32 + return (lis->pdata->lis302dl_bitbang_reg_read)(lis, reg);
33 +}
34
35 +static void __reg_write(struct lis302dl_info *lis, u8 reg, u8 val)
36 +{
37 + (lis->pdata->lis302dl_bitbang_reg_write)(lis, reg, val);
38 +}
39
40 static void __reg_set_bit_mask(struct lis302dl_info *lis, u8 reg, u8 mask,
41 - u8 val)
42 + u8 val)
43 {
44 u_int8_t tmp;
45
46 val &= mask;
47
48 - tmp = (lis->pdata->lis302dl_bitbang_reg_read)(lis, reg);
49 + tmp = __reg_read(lis, reg);
50 tmp &= ~mask;
51 tmp |= val;
52 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, reg, tmp);
53 + __reg_write(lis, reg, tmp);
54 +}
55 +
56 +static int __ms_to_duration(struct lis302dl_info *lis, int ms)
57 +{
58 + u8 r = __reg_read(lis, LIS302DL_REG_CTRL1);
59 +
60 + /* If we have 400 ms sampling rate, the stepping is 2.5 ms,
61 + * on 100 ms the stepping is 10ms */
62 + if (r & LIS302DL_CTRL1_DR) {
63 + /* Too large */
64 + if (ms > 637)
65 + return -1;
66 +
67 + return (ms * 10) / 25;
68 + }
69 +
70 + /* Too large value */
71 + if (ms > 2550)
72 + return -1;
73 + return ms / 10;
74 +}
75 +
76 +static int __duration_to_ms(struct lis302dl_info *lis, int duration)
77 +{
78 + u8 r = __reg_read(lis, LIS302DL_REG_CTRL1);
79 +
80 + if (r & LIS302DL_CTRL1_DR)
81 + return (duration * 25) / 10;
82 +
83 + return duration * 10;
84 }
85
86 /* interrupt handling related */
87 @@ -69,30 +108,6 @@ enum lis302dl_intmode {
88 LIS302DL_INTMODE_CLICK = 0x07,
89 };
90
91 -#define MG_PER_SAMPLE 18
92 -
93 -static void lis302dl_bitbang_read_sample(struct lis302dl_info *lis)
94 -{
95 - u8 data = 0xc0 | LIS302DL_REG_OUT_X; /* read, autoincrement */
96 - u8 read[5];
97 - unsigned long flags;
98 -
99 - local_irq_save(flags);
100 -
101 - (lis->pdata->lis302dl_bitbang)(lis, &data, 1, &read[0], 5);
102 -
103 - local_irq_restore(flags);
104 -
105 - input_report_rel(lis->input_dev, REL_X, MG_PER_SAMPLE * (s8)read[0]);
106 - input_report_rel(lis->input_dev, REL_Y, MG_PER_SAMPLE * (s8)read[2]);
107 - input_report_rel(lis->input_dev, REL_Z, MG_PER_SAMPLE * (s8)read[4]);
108 -
109 - input_sync(lis->input_dev);
110 -
111 - /* Reset the HP filter */
112 - (lis->pdata->lis302dl_bitbang_reg_read)(lis,
113 - LIS302DL_REG_HP_FILTER_RESET);
114 -}
115
116 static void __lis302dl_int_mode(struct device *dev, int int_pin,
117 enum lis302dl_intmode mode)
118 @@ -110,6 +125,7 @@ static void __lis302dl_int_mode(struct device *dev, int int_pin,
119 BUG();
120 }
121 }
122 +
123 #if 0
124 static void _report_btn_single(struct input_dev *inp, int btn)
125 {
126 @@ -130,6 +146,29 @@ static void _report_btn_double(struct input_dev *inp, int btn)
127 }
128 #endif
129
130 +#define MG_PER_SAMPLE 18
131 +
132 +static void lis302dl_bitbang_read_sample(struct lis302dl_info *lis)
133 +{
134 + u8 data = 0xc0 | LIS302DL_REG_OUT_X; /* read, autoincrement */
135 + u8 read[5];
136 + unsigned long flags;
137 +
138 + local_irq_save(flags);
139 +
140 + (lis->pdata->lis302dl_bitbang)(lis, &data, 1, &read[0], 5);
141 +
142 + local_irq_restore(flags);
143 +
144 + input_report_rel(lis->input_dev, REL_X, MG_PER_SAMPLE * (s8)read[0]);
145 + input_report_rel(lis->input_dev, REL_Y, MG_PER_SAMPLE * (s8)read[2]);
146 + input_report_rel(lis->input_dev, REL_Z, MG_PER_SAMPLE * (s8)read[4]);
147 +
148 + input_sync(lis->input_dev);
149 +
150 + /* Reset the HP filter */
151 + __reg_read(lis, LIS302DL_REG_HP_FILTER_RESET);
152 +}
153
154 static irqreturn_t lis302dl_interrupt(int irq, void *_lis)
155 {
156 @@ -149,8 +188,7 @@ static ssize_t show_rate(struct device *dev, struct device_attribute *attr,
157 unsigned long flags;
158
159 local_irq_save(flags);
160 - ctrl1 = (lis->pdata->lis302dl_bitbang_reg_read)
161 - (lis, LIS302DL_REG_CTRL1);
162 + ctrl1 = __reg_read(lis, LIS302DL_REG_CTRL1);
163 local_irq_restore(flags);
164
165 return sprintf(buf, "%d\n", ctrl1 & LIS302DL_CTRL1_DR ? 400 : 100);
166 @@ -185,8 +223,7 @@ static ssize_t show_scale(struct device *dev, struct device_attribute *attr,
167 unsigned long flags;
168
169 local_irq_save(flags);
170 - ctrl1 = (lis->pdata->lis302dl_bitbang_reg_read)(lis,
171 - LIS302DL_REG_CTRL1);
172 + ctrl1 = __reg_read(lis, LIS302DL_REG_CTRL1);
173 local_irq_restore(flags);
174
175 return sprintf(buf, "%s\n", ctrl1 & LIS302DL_CTRL1_FS ? "9.2" : "2.3");
176 @@ -236,8 +273,7 @@ static ssize_t set_threshold(struct device *dev, struct device_attribute *attr,
177 /* Set the threshold and write it out if the device is used */
178 lis->threshold = val;
179 if (lis->flags & LIS302DL_F_INPUT_OPEN)
180 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
181 - LIS302DL_REG_FF_WU_THS_1, lis->threshold);
182 + __reg_write(lis, LIS302DL_REG_FF_WU_THS_1, lis->threshold);
183
184 return count;
185 }
186 @@ -256,7 +292,7 @@ static ssize_t lis302dl_dump(struct device *dev, struct device_attribute *attr,
187 local_irq_save(flags);
188
189 for (n = 0; n < sizeof(reg); n++)
190 - reg[n] = (lis->pdata->lis302dl_bitbang_reg_read)(lis, n);
191 + reg[n] = __reg_read(lis, n);
192
193 local_irq_restore(flags);
194
195 @@ -271,36 +307,6 @@ static ssize_t lis302dl_dump(struct device *dev, struct device_attribute *attr,
196 }
197 static DEVICE_ATTR(dump, S_IRUGO, lis302dl_dump, NULL);
198
199 -static int __freefall_ms_to_duration(struct lis302dl_info *lis, int ms)
200 -{
201 - u8 r = (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_CTRL1);
202 -
203 - /* If we have 400 ms sampling rate, the stepping is 2.5 ms,
204 - * on 100 ms the stepping is 10ms */
205 - if (r & LIS302DL_CTRL1_DR) {
206 - /* Too large */
207 - if (ms > 637)
208 - return -1;
209 -
210 - return (ms * 10) / 25;
211 - }
212 -
213 - /* Too large value */
214 - if (ms > 2550)
215 - return -1;
216 - return ms / 10;
217 -}
218 -
219 -static int __freefall_duration_to_ms(struct lis302dl_info *lis, int duration)
220 -{
221 - u8 r = (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_CTRL1);
222 -
223 - if (r & LIS302DL_CTRL1_DR)
224 - return (duration * 25) / 10;
225 -
226 - return duration * 10;
227 -}
228 -
229 /* Configure freefall/wakeup interrupts */
230 static ssize_t set_freefall_common(int which, struct device *dev,
231 struct device_attribute *attr, const char *buf, size_t count)
232 @@ -342,9 +348,9 @@ static ssize_t set_freefall_common(int which, struct device *dev,
233 LIS302DL_INTMODE_DATA_READY);
234 lis->flags &= ~(flag_mask | LIS302DL_F_IRQ_WAKE);
235
236 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, r_cfg, 0);
237 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, r_ths, 0);
238 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, r_duration, 0);
239 + __reg_write(lis, r_cfg, 0);
240 + __reg_write(lis, r_ths, 0);
241 + __reg_write(lis, r_duration, 0);
242
243 /* Power off unless the input subsystem is using the device */
244 if (!(lis->flags & LIS302DL_F_INPUT_OPEN))
245 @@ -361,7 +367,7 @@ static ssize_t set_freefall_common(int which, struct device *dev,
246 return -EINVAL;
247
248 local_irq_save(flags);
249 - duration = __freefall_ms_to_duration(lis, ms);
250 + duration = __ms_to_duration(lis, ms);
251 local_irq_save(flags);
252
253 if (duration < 0)
254 @@ -382,13 +388,12 @@ static ssize_t set_freefall_common(int which, struct device *dev,
255 /* Setup the configuration registers */
256 local_irq_save(flags);
257 /* First zero to get to a known state */
258 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, r_cfg, 0);
259 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, r_cfg,
260 + __reg_write(lis, r_cfg, 0);
261 + __reg_write(lis, r_cfg,
262 (and_events ? LIS302DL_FFWUCFG_AOI : 0) |
263 x_lo | x_hi | y_lo | y_hi | z_lo | z_hi);
264 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, r_ths,
265 - threshold & ~LIS302DL_FFWUTHS_DCRM);
266 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, r_duration, duration);
267 + __reg_write(lis, r_ths, threshold & ~LIS302DL_FFWUTHS_DCRM);
268 + __reg_write(lis, r_duration, duration);
269
270 /* Route the interrupt for wakeup */
271 __lis302dl_int_mode(lis->dev, which, intmode);
272 @@ -443,12 +448,12 @@ static ssize_t show_freefall_common(int which, struct device *dev,
273 }
274
275 local_irq_save(flags);
276 - config = (lis->pdata->lis302dl_bitbang_reg_read)(lis, r_cfg);
277 - threshold = (lis->pdata->lis302dl_bitbang_reg_read)(lis, r_ths);
278 - duration = (lis->pdata->lis302dl_bitbang_reg_read)(lis, r_duration);
279 - r4 = (lis->pdata->lis302dl_bitbang_reg_read)(lis, r_src);
280 - r5 = (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_CTRL3);
281 - ms = __freefall_duration_to_ms(lis, duration);
282 + config = __reg_read(lis, r_cfg);
283 + threshold = __reg_read(lis, r_ths);
284 + duration = __reg_read(lis, r_duration);
285 + r4 = __reg_read(lis, r_src);
286 + r5 = __reg_read(lis, LIS302DL_REG_CTRL3);
287 + ms = __duration_to_ms(lis, duration);
288 local_irq_restore(flags);
289
290 /* All events off? */
291 @@ -519,18 +524,14 @@ static int lis302dl_input_open(struct input_dev *inp)
292 /* make sure we're powered up and generate data ready */
293 __reg_set_bit_mask(lis, LIS302DL_REG_CTRL1, ctrl1, ctrl1);
294
295 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL2,
296 + __reg_write(lis, LIS302DL_REG_CTRL2,
297 ctrl2);
298 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
299 - LIS302DL_REG_FF_WU_THS_1, lis->threshold);
300 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
301 - LIS302DL_REG_FF_WU_DURATION_1, 0);
302 + __reg_write(lis, LIS302DL_REG_FF_WU_THS_1, lis->threshold);
303 + __reg_write(lis, LIS302DL_REG_FF_WU_DURATION_1, 0);
304
305 /* Clear the HP filter "starting point" */
306 - (lis->pdata->lis302dl_bitbang_reg_read)(lis,
307 - LIS302DL_REG_HP_FILTER_RESET);
308 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
309 - LIS302DL_REG_FF_WU_CFG_1, LIS302DL_FFWUCFG_XHIE |
310 + __reg_read(lis, LIS302DL_REG_HP_FILTER_RESET);
311 + __reg_write(lis, LIS302DL_REG_FF_WU_CFG_1, LIS302DL_FFWUCFG_XHIE |
312 LIS302DL_FFWUCFG_YHIE | LIS302DL_FFWUCFG_ZHIE);
313
314 lis->flags |= LIS302DL_F_INPUT_OPEN;
315 @@ -576,11 +577,11 @@ static int __lis302dl_reset_device(struct lis302dl_info *lis)
316 {
317 int timeout = 10;
318
319 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL2,
320 - LIS302DL_CTRL2_BOOT | LIS302DL_CTRL2_FDS);
321 + __reg_write(lis, LIS302DL_REG_CTRL2,
322 + LIS302DL_CTRL2_BOOT | LIS302DL_CTRL2_FDS);
323
324 - while (((lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_CTRL2)
325 - & LIS302DL_CTRL2_BOOT) && (timeout--))
326 + while ((__reg_read(lis, LIS302DL_REG_CTRL2)
327 + & LIS302DL_CTRL2_BOOT) && (timeout--))
328 mdelay(1);
329
330 return !!(timeout < 0);
331 @@ -609,8 +610,7 @@ static int __devinit lis302dl_probe(struct platform_device *pdev)
332 /* Configure our IO */
333 (lis->pdata->lis302dl_suspend_io)(lis, 1);
334
335 - wai = (lis->pdata->lis302dl_bitbang_reg_read)(lis,
336 - LIS302DL_REG_WHO_AM_I);
337 + wai = __reg_read(lis, LIS302DL_REG_WHO_AM_I);
338 if (wai != LIS302DL_WHO_AM_I_MAGIC) {
339 dev_err(lis->dev, "unknown who_am_i signature 0x%02x\n", wai);
340 dev_set_drvdata(lis->dev, NULL);
341 @@ -659,46 +659,38 @@ static int __devinit lis302dl_probe(struct platform_device *pdev)
342 dev_err(lis->dev, "device BOOT reload failed\n");
343
344 /* force us powered */
345 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL1,
346 - LIS302DL_CTRL1_PD |
347 - LIS302DL_CTRL1_Xen |
348 - LIS302DL_CTRL1_Yen |
349 - LIS302DL_CTRL1_Zen);
350 + __reg_write(lis, LIS302DL_REG_CTRL1, LIS302DL_CTRL1_PD |
351 + LIS302DL_CTRL1_Xen |
352 + LIS302DL_CTRL1_Yen |
353 + LIS302DL_CTRL1_Zen);
354 mdelay(1);
355
356 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL2, 0);
357 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL3,
358 - LIS302DL_CTRL3_PP_OD | LIS302DL_CTRL3_IHL);
359 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
360 - LIS302DL_REG_FF_WU_THS_1, 0x0);
361 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
362 - LIS302DL_REG_FF_WU_DURATION_1, 0x00);
363 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
364 - LIS302DL_REG_FF_WU_CFG_1, 0x0);
365 + __reg_write(lis, LIS302DL_REG_CTRL2, 0);
366 + __reg_write(lis, LIS302DL_REG_CTRL3,
367 + LIS302DL_CTRL3_PP_OD | LIS302DL_CTRL3_IHL);
368 + __reg_write(lis, LIS302DL_REG_FF_WU_THS_1, 0x0);
369 + __reg_write(lis, LIS302DL_REG_FF_WU_DURATION_1, 0x00);
370 + __reg_write(lis, LIS302DL_REG_FF_WU_CFG_1, 0x0);
371
372 /* start off in powered down mode; we power up when someone opens us */
373 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL1,
374 - LIS302DL_CTRL1_Xen |
375 - LIS302DL_CTRL1_Yen |
376 - LIS302DL_CTRL1_Zen);
377 + __reg_write(lis, LIS302DL_REG_CTRL1, LIS302DL_CTRL1_Xen |
378 + LIS302DL_CTRL1_Yen | LIS302DL_CTRL1_Zen);
379
380 if (pdata->open_drain)
381 /* switch interrupt to open collector, active-low */
382 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
383 - LIS302DL_REG_CTRL3, LIS302DL_CTRL3_PP_OD |
384 - LIS302DL_CTRL3_IHL);
385 + __reg_write(lis, LIS302DL_REG_CTRL3,
386 + LIS302DL_CTRL3_PP_OD | LIS302DL_CTRL3_IHL);
387 else
388 /* push-pull, active-low */
389 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
390 - LIS302DL_REG_CTRL3, LIS302DL_CTRL3_IHL);
391 + __reg_write(lis, LIS302DL_REG_CTRL3, LIS302DL_CTRL3_IHL);
392
393 __lis302dl_int_mode(lis->dev, 1, LIS302DL_INTMODE_FF_WU_12);
394 __lis302dl_int_mode(lis->dev, 2, LIS302DL_INTMODE_FF_WU_12);
395
396 - (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_STATUS);
397 - (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_FF_WU_SRC_1);
398 - (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_FF_WU_SRC_2);
399 - (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_CLICK_SRC);
400 + __reg_read(lis, LIS302DL_REG_STATUS);
401 + __reg_read(lis, LIS302DL_REG_FF_WU_SRC_1);
402 + __reg_read(lis, LIS302DL_REG_FF_WU_SRC_2);
403 + __reg_read(lis, LIS302DL_REG_CLICK_SRC);
404
405 dev_info(lis->dev, "Found %s\n", pdata->name);
406
407 @@ -733,9 +725,9 @@ static int __devexit lis302dl_remove(struct platform_device *pdev)
408
409 /* Reset and power down the device */
410 local_irq_save(flags);
411 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL3, 0x00);
412 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL2, 0x00);
413 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL1, 0x00);
414 + __reg_write(lis, LIS302DL_REG_CTRL3, 0x00);
415 + __reg_write(lis, LIS302DL_REG_CTRL2, 0x00);
416 + __reg_write(lis, LIS302DL_REG_CTRL1, 0x00);
417 local_irq_restore(flags);
418
419 /* Cleanup resources */
420 @@ -798,13 +790,12 @@ static int lis302dl_suspend(struct platform_device *pdev, pm_message_t state)
421 /* save registers */
422 for (n = 0; n < ARRAY_SIZE(regs_to_save); n++)
423 lis->regs[regs_to_save[n]] =
424 - (lis->pdata->lis302dl_bitbang_reg_read)(lis,
425 - regs_to_save[n]);
426 + __reg_read(lis, regs_to_save[n]);
427
428 /* power down */
429 - tmp = (lis->pdata->lis302dl_bitbang_reg_read)(lis, LIS302DL_REG_CTRL1);
430 + tmp = __reg_read(lis, LIS302DL_REG_CTRL1);
431 tmp &= ~LIS302DL_CTRL1_PD;
432 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL1, tmp);
433 + __reg_write(lis, LIS302DL_REG_CTRL1, tmp);
434
435 /* place our IO to the device in sleep-compatible states */
436 (lis->pdata->lis302dl_suspend_io)(lis, 0);
437 @@ -830,11 +821,11 @@ static int lis302dl_resume(struct platform_device *pdev)
438 (lis->pdata->lis302dl_suspend_io)(lis, 1);
439
440 /* resume from powerdown first! */
441 - (lis->pdata->lis302dl_bitbang_reg_write)(lis, LIS302DL_REG_CTRL1,
442 - LIS302DL_CTRL1_PD |
443 - LIS302DL_CTRL1_Xen |
444 - LIS302DL_CTRL1_Yen |
445 - LIS302DL_CTRL1_Zen);
446 + __reg_write(lis, LIS302DL_REG_CTRL1,
447 + LIS302DL_CTRL1_PD |
448 + LIS302DL_CTRL1_Xen |
449 + LIS302DL_CTRL1_Yen |
450 + LIS302DL_CTRL1_Zen);
451 mdelay(1);
452
453 if (__lis302dl_reset_device(lis))
454 @@ -847,8 +838,7 @@ static int lis302dl_resume(struct platform_device *pdev)
455
456 /* restore registers after resume */
457 for (n = 0; n < ARRAY_SIZE(regs_to_save); n++)
458 - (lis->pdata->lis302dl_bitbang_reg_write)(lis,
459 - regs_to_save[n], lis->regs[regs_to_save[n]]);
460 + __reg_write(lis, regs_to_save[n], lis->regs[regs_to_save[n]]);
461
462 local_irq_restore(flags);
463 enable_irq(lis->pdata->interrupt);
464 diff --git a/include/linux/lis302dl.h b/include/linux/lis302dl.h
465 index f3f994d..a756f55 100644
466 --- a/include/linux/lis302dl.h
467 +++ b/include/linux/lis302dl.h
468 @@ -18,7 +18,6 @@ struct lis302dl_platform_data {
469 int interrupt;
470 void (*lis302dl_bitbang)(struct lis302dl_info *lis, u8 *tx,
471 int tx_bytes, u8 *rx, int rx_bytes);
472 - void (*lis302dl_bitbang_read_sample)(struct lis302dl_info *);
473 void (*lis302dl_suspend_io)(struct lis302dl_info *, int resuming);
474 int (*lis302dl_bitbang_reg_read)(struct lis302dl_info *, u8 reg);
475 void (*lis302dl_bitbang_reg_write)(struct lis302dl_info *, u8 reg,
476 --
477 1.5.6.5
478
This page took 0.074747 seconds and 5 git commands to generate.