Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 365055
b: refs/heads/master
c: da0b0c4
h: refs/heads/master
i:
  365053: df6b09f
  365051: 5cb2ade
  365047: 7fd37c7
  365039: 238eb09
  365023: 7152b0b
  364991: 2bc8aaa
  364927: e52b62c
  364799: f421e71
  364543: 0e4ad2a
v: v3
  • Loading branch information
Lee Jones authored and Mark Brown committed Mar 29, 2013
1 parent f5ad84b commit 12caa9c
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 41a06aa738ad889cf96f56024ddf84ecf4a18a6f
refs/heads/master: da0b0c47dcfd92317e2ece4c3434e1f82b55cf8a
10 changes: 10 additions & 0 deletions trunk/drivers/regulator/ab8500.c
Original file line number Diff line number Diff line change
Expand Up @@ -911,6 +911,11 @@ static int ab8500_regulator_probe(struct platform_device *pdev)
return -EINVAL;
}

/* initialize debug (initial state is recorded with this call) */
err = ab8500_regulator_debug_init(pdev);
if (err)
return err;

/* initialize registers */
for (i = 0; i < pdata->num_reg_init; i++) {
int id, mask, value;
Expand Down Expand Up @@ -961,6 +966,11 @@ static int ab8500_regulator_remove(struct platform_device *pdev)
if (err)
return err;

/* remove regulator debug */
err = ab8500_regulator_debug_exit(pdev);
if (err)
return err;

return 0;
}

Expand Down
14 changes: 14 additions & 0 deletions trunk/include/linux/regulator/ab8500.h
Original file line number Diff line number Diff line change
Expand Up @@ -178,4 +178,18 @@ inline int ab8500_ext_regulator_exit(struct platform_device *pdev)
}
#endif

#ifdef CONFIG_REGULATOR_AB8500_DEBUG
int ab8500_regulator_debug_init(struct platform_device *pdev);
int ab8500_regulator_debug_exit(struct platform_device *pdev);
#else
static inline int ab8500_regulator_debug_init(struct platform_device *pdev)
{
return 0;
}
static inline int ab8500_regulator_debug_exit(struct platform_device *pdev)
{
return 0;
}
#endif

#endif

0 comments on commit 12caa9c

Please sign in to comment.