regulator: Fix display of null constraints for regulators
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Thu, 11 Feb 2010 19:20:48 +0000 (19:20 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 23 Feb 2010 15:37:49 +0000 (07:37 -0800)
commitbb0d31fbf221f50a44ba5d59dfcf54bbf128ac2b
tree9c5f0ca56eb3651b64cb37ad04e21334b478712e
parenta20bc629020fc785f75f6c7051795b5a12b0e932
regulator: Fix display of null constraints for regulators

commit 973e9a2795b3b41d8408a0bb6f87b783c5efc88a upstream.

If the regulator constraints are empty and there is no voltage
reported then nothing will be added to the text displayed for the
constraints, leading to random stack data being printed. This is
unlikely to happen for practical regulators since most will at
least report a voltage but should still be fixed.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/regulator/core.c