aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/power/avs/rockchip-io-domain.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2017-08-25PM / AVS: rockchip-io: add io selectors and supplies for RV1108David Wu1-0/+38
This adds the necessary data for handling io voltage domains on the RV1108. Signed-off-by: David Wu <david.wu@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2017-06-28PM / AVS: rockchip-io: add io selectors and supplies for rk3228David Wu1-0/+14
This adds the necessary data for handling io voltage domains on the rk3228. Signed-off-by: David Wu <david.wu@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2017-03-12PM / AVS: rockchip-io: add io selectors and supplies for rk3328David Wu1-0/+41
This adds the necessary data for handling io voltage domains on the rk3328. As interesting tidbit, the rk3328 only contains one iodomain area in the regular General Register Files (GRF). Signed-off-by: David Wu <david.wu@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Reviewed-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2016-10-21PM / AVS: rockchip-io: make the log more consistentShawn Lin1-1/+1
When testing SD hotplug automatically, I got bunch of useless log like this: [ 588.357838] mmc0: card 0007 removed [ 589.492664] rockchip-iodomain ff770000.syscon:io-domains: Setting to 3300000 done [ 589.500698] vccio_sd: ramp_delay not set [ 589.504817] rockchip-iodomain ff770000.syscon:io-domains: Setting to 3300000 done [ 589.669705] rockchip-iodomain ff770000.syscon:io-domains: Setting to 3300000 done [ 589.677593] vccio_sd: ramp_delay not set [ 589.681581] rockchip-iodomain ff770000.syscon:io-domains: Setting to 1800000 done [ 590.032820] dwmmc_rockchip ff0c0000.dwmmc: Successfully tuned phase to 140 [ 590.039725] mmc0: new ultra high speed SDR50 SDHC card at address 0007 [ 590.046641] mmcblk0: mmc0:0007 SD32G 29.3 GiB [ 590.052163] mmcblk0: p1 Moreover the code is intent to print the 'uV' for debug but later print it using dev_info. It looks more like to me that it should be the real intention of the code. Anyway, let's mark this verbose log as debug message. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2016-04-26PM / AVS: rockchip-io: make io-domains a child of the GRFHeiko Stuebner1-1/+9
IO-domain handling is part of the general register files, so should live under the grf directly. This change allows the grf to be a simple-mfd and the io-domains fetching the syscon regmap from that parent-node. The old binding is of course preserved, though deprecated. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Kevin Hilman <khilman@baylibre.com> Tested-by: David Wu <david.wu@rock-chips.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2016-03-25Fix permissions of drivers/power/avs/rockchip-io-domain.cRafael J. Wysocki1-0/+0
The permissions of this file were modified by commit (f447671b9e4f PM / AVS: rockchip-io: add io selectors and supplies for rk3399) by mistake, so fix them. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2016-03-23PM / AVS: rockchip-io: add io selectors and supplies for rk3399David Wu1-0/+58
This adds the necessary data for handling io voltage domains on the rk3399. As interesting tidbit, the rk3399 contains two separate iodomain areas. One in the regular General Register Files (GRF) and one in PMUGRF in the pmu power domain. Signed-off-by: David Wu <david.wu@rock-chips.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2015-10-14PM / AVS: rockchip-io: Fix module autoload for OF platform driverLuis de Bethencourt1-0/+1
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Kevin Hilman <khilman@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2015-08-08PM / AVS: rockchip-io: add io selectors and supplies for rk3368Heiko Stuebner1-0/+59
This adds the necessary data for handling io voltage domains on the rk3368. As interesting tidbit, the rk3368 contains two separate iodomain areas. One in the regular General Register Files (GRF) and one in PMUGRF in the pmu power domain. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Kevin Hilman <khilman@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2014-09-25PM / AVS: rockchip-io: add driver handling Rockchip io domainsHeiko Stübner1-0/+351
IO domain voltages on some Rockchip SoCs are variable but need to be kept in sync between the regulators and the SoC using a special register. A specific example using rk3288: - If the regulator hooked up to a pin like SDMMC0_VDD is 3.3V then bit 7 of GRF_IO_VSEL needs to be 0. If the regulator hooked up to that same pin is 1.8V then bit 7 of GRF_IO_VSEL needs to be 1. Said another way, this driver simply handles keeping bits in the SoC's general register file (GRF) in sync with the actual value of a voltage hooked up to the pins. Note that this driver specifically doesn't include: - any logic for deciding what voltage we should set regulators to - any logic for deciding whether regulators (or internal SoC blocks) should have power or not have power If there were some other software that had the smarts of making decisions about regulators, it would work in conjunction with this driver. When that other software adjusted a regulator's voltage then this driver would handle telling the SoC about it. A good example is vqmmc for SD. In that case the dw_mmc driver simply is told about a regulator. It changes the regulator between 3.3V and 1.8V at the right time. This driver notices the change and makes sure that the SoC is on the same page. Signed-off-by: Heiko Stübner <heiko@sntech.de> Signed-off-by: Doug Anderson <dianders@chromium.org> Reviewed-by: Santosh Shilimkar <santosh.shilimkar@ti.com> [khilman: fix compiler warnings] Signed-off-by: Kevin Hilman <khilman@linaro.org>