regulator: palmas: Simplify code by using pointer to palmas_reg_info
authorNishanth Menon <nm@ti.com>
Mon, 30 Jun 2014 15:57:36 +0000 (10:57 -0500)
committerMark Brown <broonie@linaro.org>
Thu, 3 Jul 2014 14:25:55 +0000 (15:25 +0100)
Palmas register information is part of the ddata pointer which is used
through out the code by indexing off the driver data array. Instead,
just do the indexing once and use the pointer to further reference
structure fields.

This simplifies code and prevents errors by accessing wrong variables.

Signed-off-by: Nishanth Menon <nm@ti.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Keerthy <j-keerthy@ti.com>
Signed-off-by: Mark Brown <broonie@linaro.org>

No differences found