From: Linus Walleij Date: Sun, 13 Apr 2014 19:08:00 +0000 (+0100) Subject: iio: st_sensors: move regulator retrieveal to core X-Git-Tag: omap-for-v3.16/fixes-against-rc1~39^2~36^2~1228^2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ea7e586bdd331fd6fba2b6f9fd3777928c2814d8;p=pandora-kernel.git iio: st_sensors: move regulator retrieveal to core Currently the pressure sensor has code to retrieve and enable two regulators for Vdd and Vdd IO, but actually these voltage inputs are found on all of these ST sensors, so move the regulator handling to the core and make sure all the ST sensors call these functions on probe() and remove() to enable/disable power. Here also mover over to obtaining the regulator from the *parent* device of the IIO device, as the IIO device is created on-the-fly in this very subsystem it very unlikely evert have any regulators attached to it whatsoever. It is much more likely that the parent is a platform device, possibly instantiated from a device tree, which in turn have Vdd and Vdd IO supplied assigned to it. Cc: Lee Jones Cc: Denis CIOCCA Signed-off-by: Linus Walleij Signed-off-by: Jonathan Cameron --- Reading git-diff-tree failed