GitHub/exynos8895/android_kernel_samsung_universal8895.git
12 years agoMerge tag 'regulator-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie...
Arnd Bergmann [Sat, 24 Mar 2012 11:29:58 +0000 (11:29 +0000)]
Merge tag 'regulator-3.4' of git://git./linux/kernel/git/broonie/regulator into next/drivers

The pxa regulator branch removes the bq24022 driver, while a lot of
other regulator drivers got added in the regulator tree. This
resolves the trivial conflicts by merging in the regulator patches
that are already merged into v3.4.

Conflicts:
drivers/regulator/Kconfig
drivers/regulator/Makefile

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
12 years agoMerge branch 'next/fixes-non-critical' into next/drivers
Arnd Bergmann [Tue, 20 Mar 2012 22:42:24 +0000 (22:42 +0000)]
Merge branch 'next/fixes-non-critical' into next/drivers

Conflicts:
arch/arm/mach-lpc32xx/clock.c
arch/arm/mach-pxa/pxa25x.c
arch/arm/mach-pxa/pxa27x.c

The conflicts with pxa are non-obvious, we have multiple branches
adding and removing the same clock settings. According to
Haojian Zhuang, removing the sa1100 rtc dummy clock is the correct
fix here.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
12 years agoMerge branch 'imx/defconfig' into next/drivers
Arnd Bergmann [Tue, 20 Mar 2012 22:40:37 +0000 (22:40 +0000)]
Merge branch 'imx/defconfig' into next/drivers

Conflicts:
arch/arm/configs/imx_v6_v7_defconfig

Resolves one conflict with an earlier branch

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
12 years agoMerge branch 'fixes' into next/fixes-non-critical
Arnd Bergmann [Tue, 20 Mar 2012 09:34:37 +0000 (09:34 +0000)]
Merge branch 'fixes' into next/fixes-non-critical

The one fix didn't make the cut for 3.3, so we're putting it
into v3.4. Tony tells me "There are more patches needed to make
multiple smsc91x instances work, but we need to hear from people
with such boards first. Then those can be tagged for stable.",
so we don't mark this patch stable yet.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
12 years agoMerge tag 'topic/twl' into regulator-next
Mark Brown [Mon, 19 Mar 2012 17:17:32 +0000 (17:17 +0000)]
Merge tag 'topic/twl' into regulator-next

TWL specific changes, cross-merged with OMAP due to arch/arm wanting to
use the new ability to override the voltage set and get operations to
support the in-CPU voltage management.  The other changes are minor
fixes, the addition of a few new regulators and device tree support.

12 years agoMerge remote-tracking branch 'regulator/topic/supply' into regulator-next
Mark Brown [Sun, 18 Mar 2012 21:39:19 +0000 (21:39 +0000)]
Merge remote-tracking branch 'regulator/topic/supply' into regulator-next

12 years agoMerge remote-tracking branches 'regulator/topic/devm' and 'regulator/topic/stub'...
Mark Brown [Sun, 18 Mar 2012 21:38:28 +0000 (21:38 +0000)]
Merge remote-tracking branches 'regulator/topic/devm' and 'regulator/topic/stub' into regulator-next

12 years agoMerge remote-tracking branch 'regulator/topic/stub' into regulator-next
Mark Brown [Sun, 18 Mar 2012 21:38:20 +0000 (21:38 +0000)]
Merge remote-tracking branch 'regulator/topic/stub' into regulator-next

12 years agoMerge remote-tracking branch 'regulator/topic/drivers' into regulator-next
Mark Brown [Sun, 18 Mar 2012 21:37:37 +0000 (21:37 +0000)]
Merge remote-tracking branch 'regulator/topic/drivers' into regulator-next

12 years agoregulator: Fix up a confusing dev_warn when DT lookup fails
Rajendra Nayak [Fri, 16 Mar 2012 10:20:21 +0000 (15:50 +0530)]
regulator: Fix up a confusing dev_warn when DT lookup fails

of_parse_phandle() returns NULL either if the property name
itself does not exist or if it (exists and) does not
reference a valid phandle.
Giving out a warn like the one below (that the property references
an invalid phandle) can be confusing when the property itself
does not exist in the node.
Fix it with a more sensible message and make it a dev_dbg instead
of a dev_warn.

Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoMerge branch 'fixes' of git://gitorious.org/linux-davinci/linux-davinci into next...
Arnd Bergmann [Thu, 15 Mar 2012 15:50:27 +0000 (15:50 +0000)]
Merge branch 'fixes' of git://gitorious.org/linux-davinci/linux-davinci into next/fixes-non-critical

* 'fixes' of git://gitorious.org/linux-davinci/linux-davinci: (2 commits)
  ARM: davinci: DA850: move da850_register_pm to .init.text
  ARM: davinci: cpufreq: fix compiler warning

(update to v3.3-rc7)

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
12 years agoMerge tag 'imx25-iomux-ds' of git://git.pengutronix.de/git/imx/linux-2.6 into next...
Arnd Bergmann [Thu, 15 Mar 2012 13:49:36 +0000 (13:49 +0000)]
Merge tag 'imx25-iomux-ds' of git://git.pengutronix.de/git/imx/linux-2.6 into next/fixes-non-critical

* tag 'imx25-iomux-ds' of git://git.pengutronix.de/git/imx/linux-2.6:
   iomux-mx25.h slew rate adjusted for LCD __LD pins

(update to v3.3-rc6)

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
12 years agoregulator: Convert tps6507x to set_voltage_sel
Axel Lin [Mon, 12 Mar 2012 07:59:54 +0000 (15:59 +0800)]
regulator: Convert tps6507x to set_voltage_sel

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Refactor tps6507x to use one tps6507x_pmic_ops for all LDOs and DCDCs
Axel Lin [Mon, 12 Mar 2012 07:57:50 +0000 (15:57 +0800)]
regulator: Refactor tps6507x to use one tps6507x_pmic_ops for all LDOs and DCDCs

All the callback functions implementation for DCDCx and LDOx are very similar,
I think it is ok to use one tps6507x_pmic_ops for all LDOs and DCDCs.
This refactor removes a couple of duplicated code.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Make s5m8767_get_voltage_register always return correct register
Axel Lin [Sat, 10 Mar 2012 02:59:43 +0000 (10:59 +0800)]
regulator: Make s5m8767_get_voltage_register always return correct register

Check s5m8767->buck[2|3|4]_gpiodvs status in s5m8767_get_voltage_register
and return correct register accordingly.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: s5m8767: Check pdata->buck[2|3|4]_gpiodvs earlier
Axel Lin [Sat, 10 Mar 2012 00:43:02 +0000 (08:43 +0800)]
regulator: s5m8767: Check pdata->buck[2|3|4]_gpiodvs earlier

If we need to ensure only one of the buck[2|3|4]_gpiodvs can be specificed,
check them earlier.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps65910: Provide settling time for DCDC voltage change
Laxman Dewangan [Wed, 14 Mar 2012 07:30:58 +0000 (13:00 +0530)]
regulator: tps65910: Provide settling time for DCDC voltage change

Settling time is require when there is dcdc rail's voltage change.
Returning proper delay time for dcdc voltage change to settle down
the output voltage to new value.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Add Anatop regulator driver
Ying-Chun Liu (PaulLiu) [Wed, 14 Mar 2012 02:29:12 +0000 (10:29 +0800)]
regulator: Add Anatop regulator driver

Anatop is an integrated regulator inside i.MX6 SoC.
There are 3 digital regulators which controls PU, CORE (ARM), and SOC.
And 3 analog regulators which controls 1P1, 2P5, 3P0 (USB).
This patch adds the Anatop regulator driver.

Signed-off-by: Nancy Chen <Nancy.Chen@freescale.com>
Signed-off-by: Ying-Chun Liu (PaulLiu) <paul.liu@linaro.org>
Acked-by: Shawn Guo <shawn.guo@linaro.org>
Reviewed-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Simplify implementation of tps65912_get_voltage_dcdc
Axel Lin [Wed, 14 Mar 2012 02:20:01 +0000 (10:20 +0800)]
regulator: Simplify implementation of tps65912_get_voltage_dcdc

Call tps65912_get_sel_register instead of duplicating the same code.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Use tps65912_set_voltage_sel for both DCDCx and LDOx
Axel Lin [Wed, 14 Mar 2012 02:18:45 +0000 (10:18 +0800)]
regulator: Use tps65912_set_voltage_sel for both DCDCx and LDOx

commit 42b5ef "regulator: tps65912: Use simple equations to get register address"
uses tps65912_get_sel_register to replace tps65912_get_dcdc_sel_register
and tps65912_get_ldo_sel_register.

Now tps65912_set_voltage_dcdc_sel and tps65912_set_voltage_ldo_sel has exactly
the same implementation. Merge them to tps65912_set_voltage_sel function.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps65910: Provide settling time for enabling rails
Laxman Dewangan [Tue, 13 Mar 2012 06:05:20 +0000 (11:35 +0530)]
regulator: tps65910: Provide settling time for enabling rails

There is settling time for each rails when it is switched to
ON. Implementing enable time for returning proper settling time
of regulator rails when it is enabled.
Filling the on-time for each rail as per tps65910/tps65911
datasheets.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoMerge branch 'next/devel-samsung-dma' of git://git.kernel.org/pub/scm/linux/kernel...
Olof Johansson [Tue, 13 Mar 2012 23:22:20 +0000 (16:22 -0700)]
Merge branch 'next/devel-samsung-dma' of git://git./linux/kernel/git/kgene/linux-samsung into next/drivers

* 'next/devel-samsung-dma' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung:
  ARM: EXYNOS: add support DMA for EXYNOS4X12 SoC
  ARM: EXYNOS: Add apb_pclk clkdev entry for mdma1
  ARM: EXYNOS: Enable MDMA driver
  (includes dependent base of samsung/cleanup-exynos-clock)

12 years agoMerge branch 'next/devel-samsung-mmc' of git://git.kernel.org/pub/scm/linux/kernel...
Olof Johansson [Tue, 13 Mar 2012 23:20:12 +0000 (16:20 -0700)]
Merge branch 'next/devel-samsung-mmc' of git://git./linux/kernel/git/kgene/linux-samsung into next/drivers

* 'next/devel-samsung-mmc' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung:
  ARM: SAMSUNG: change the name from s3c-sdhci to exynos4-sdhci
  mmc: sdhci-s3c: add platform data for the second capability
  ARM: SAMSUNG: support the second capability for samsung-soc

12 years agoregulator: max8925: Use DIV_ROUND_UP macro
Axel Lin [Tue, 13 Mar 2012 08:09:28 +0000 (16:09 +0800)]
regulator: max8925: Use DIV_ROUND_UP macro

Use DIV_ROUND_UP macro for better readability.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps65912: Use simple equations to get register address
Axel Lin [Mon, 12 Mar 2012 22:40:48 +0000 (06:40 +0800)]
regulator: tps65912: Use simple equations to get register address

The address of ctrl and sel registers can be calculated by simple equations.
This patch simplifies the implementation in tps65912_get_ctrl_register and
implements tps65912_get_sel_register to replace tps65912_get_dcdc_sel_register
and tps65912_get_ldo_sel_register.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Fix the logic of tps65910_get_mode
Axel Lin [Mon, 12 Mar 2012 23:15:27 +0000 (07:15 +0800)]
regulator: Fix the logic of tps65910_get_mode

We actually clear LDO_ST_ON_BIT for standby mode in tps65910_set_mode.
Fix the logic in tps65910_get_mode.

Supply state (EEPROM bits):
ST[1:0] = 00 : Off
ST[1:0] = 01 : On high power (ACTIVE)
ST[1:0] = 10 : Off
ST[1:0] = 11 : On low power (SLEEP)

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoMerge branch 'fix-smsc911x-regulator' of git://git.kernel.org/pub/scm/linux/kernel...
Olof Johansson [Tue, 13 Mar 2012 22:49:00 +0000 (15:49 -0700)]
Merge branch 'fix-smsc911x-regulator' of git://git./linux/kernel/git/tmlind/linux-omap into fixes

From Tony Lindgren:

"Here's one more kernel panic fix that I dropped from last weeks
fixes as it was still being discussed.

This is a fix for the regression caused by fixing an earlier
regression for smsc911x fixed regulators :(

Turns out that we have more than one smsc911x on some boards,
and the earlier fix causes a kernel panic for board trying to
register second smsc911x instance, even if the second smsc911x
is on an add-on board that is not connected.

Note that the boards with second smsc911x will also need to be
patched later on to provide their own regulators."

* 'fix-smsc911x-regulator' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: OMAP2+: gpmc-smsc911x: only register regulator for first instance

12 years agoiomux-mx25.h slew rate adjusted for LCD __LD pins
Mehnert [Tue, 13 Mar 2012 11:13:51 +0000 (12:13 +0100)]
iomux-mx25.h slew rate adjusted for LCD __LD pins

For some reason (sadly i don't identifying the patch right now)
two LCD data lines configured PAD_CTL_SRE_SLOW (wrong slew rate)
since Kernel 3.1. MX25_PAD_GPIO_E__LD16 and MX25_PAD_GPIO_F__LD17
This results in an fauly behaviour and strange color effects.

To ensure that all LCD data pins configured with the proper slew rate,
this patch changes to IOMUX define of all LCD __LDxx pins to PAD_CTL_SRE_FAST.

This problem may affect other mx25 platforms like mx25pdk. Sadly i can't test
it. Of course this problem shouldn't occur when you done your LCD muxing
correctly in the bootloader.

Best regards,
Torsten

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
12 years agoARM: davinci: DA850: move da850_register_pm to .init.text
Uwe Kleine-König [Wed, 7 Mar 2012 22:03:56 +0000 (23:03 +0100)]
ARM: davinci: DA850: move da850_register_pm to .init.text

All callers (board-mityomapl138.c and board-da850-evm.c) use it in
__init functions only.

This fixes:

WARNING: vmlinux.o(.text+0xd664): Section mismatch in reference from the function da850_register_pm() to the function .init.text:da8xx_get_mem_ctlr()
The function da850_register_pm() references
the function __init da8xx_get_mem_ctlr().
This is often because da850_register_pm lacks a __init
annotation or the annotation of da8xx_get_mem_ctlr is wrong.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
12 years agoARM: davinci: cpufreq: fix compiler warning
Uwe Kleine-König [Thu, 8 Mar 2012 19:36:44 +0000 (20:36 +0100)]
ARM: davinci: cpufreq: fix compiler warning

This fixes:
arch/arm/mach-davinci/cpufreq.c: In function davinci_target:
arch/arm/mach-davinci/cpufreq.c:98: warning: passing argument 2 of dev_printk from incompatible pointer type

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
12 years agoregulator: Merge tps65217_pmic_ldo234_ops and tps65217_pmic_dcdc_ops to tps65217_pmic_ops
Axel Lin [Mon, 12 Mar 2012 04:11:46 +0000 (12:11 +0800)]
regulator: Merge tps65217_pmic_ldo234_ops and tps65217_pmic_dcdc_ops to tps65217_pmic_ops

Most callback functions implementation for tps65217_pmic_ldo234_ops and
tps65217_pmic_dcdc_ops are the same except the rid range checking.

This patch uses tps65217_pmic_ops for all DCDCx, LDO2, LDO3, and LDO4.
And rework tps65217_pmic_set_voltage to make it can be called for
DCDCx, LDO2, LDO3, and LDO4.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Use DIV_ROUND_CLOSEST in wm8350_isink_get_current
Axel Lin [Mon, 12 Mar 2012 02:17:56 +0000 (10:17 +0800)]
regulator: Use DIV_ROUND_CLOSEST in wm8350_isink_get_current

DIV_ROUND_CLOSEST performs the computation (x + d/2)/d with better readability.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Use array to store dcdc_range settings for tps65912
Axel Lin [Thu, 8 Mar 2012 23:05:41 +0000 (07:05 +0800)]
regulator: Use array to store dcdc_range settings for tps65912

Then we can use the regulator id as array index to access the array.
This change makes the code simpler.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Rename s5m8767_convert_voltage to s5m8767_convert_voltage_to_sel
Axel Lin [Fri, 9 Mar 2012 03:31:08 +0000 (11:31 +0800)]
regulator: Rename s5m8767_convert_voltage to s5m8767_convert_voltage_to_sel

This function finds the smallest voltage that falls within the specified range,
and then returns the selector. This rename makes the intention more clear.

Also remove unneeded local variables min_vol and max_vol in s5m8767_set_voltage
and s5m8767_set_voltage_buck.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps6524x: Remove unneeded comment for N_REGULATORS
Axel Lin [Fri, 9 Mar 2012 03:37:30 +0000 (11:37 +0800)]
regulator: tps6524x: Remove unneeded comment for N_REGULATORS

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Rename set_voltage_sel callback function name to *_sel
Axel Lin [Fri, 9 Mar 2012 02:22:20 +0000 (10:22 +0800)]
regulator: Rename set_voltage_sel callback function name to *_sel

This change improves readability.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Fix s5m8767_set_voltage_time_sel calculation value
Sangbeom Kim [Fri, 9 Mar 2012 07:28:10 +0000 (16:28 +0900)]
regulator: Fix s5m8767_set_voltage_time_sel calculation value

In the s5m8767_set_voltage_time_sel function, divisor unit is wrong.
ramp_delay is usec unit. So 1000 should be multiplied.

Signed-off-by: Sangbeom Kim <sbkim73@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps6586x: fix typo in debug message
Thierry Reding [Thu, 8 Mar 2012 14:51:24 +0000 (15:51 +0100)]
regulator: tps6586x: fix typo in debug message

Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps65910: Sleep off rails when ext sleep configured
Laxman Dewangan [Wed, 7 Mar 2012 12:51:49 +0000 (18:21 +0530)]
regulator: tps65910: Sleep off rails when ext sleep configured

Keep the rails OFF in sleep mode only when the rails are
controlled by external sleep control.
The devices tps65910 and tps65911, both has the sleep input.
The tps65911's sleep input is not same as tps65910's EN3 and hence
taking care of SLEEP input as separate external sleep control input.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Simplify the implementation of tps65912_get_voltage_dcdc
Axel Lin [Thu, 8 Mar 2012 04:07:37 +0000 (12:07 +0800)]
regulator: Simplify the implementation of tps65912_get_voltage_dcdc

Call tps65912_list_voltage_dcdc instead of duplicating the same code.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: max8649: Use DIV_ROUND_UP macro to calculate selector
Axel Lin [Thu, 8 Mar 2012 02:05:24 +0000 (10:05 +0800)]
regulator: max8649: Use DIV_ROUND_UP macro to calculate selector

Use DIV_ROUND_UP macro for better readability.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Silence error message in max8998_pmic_probe
Axel Lin [Wed, 7 Mar 2012 07:15:40 +0000 (15:15 +0800)]
regulator: Silence error message in max8998_pmic_probe

This looks like a mistakenly committed debug logging.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Remove unused i2c variable in s5m8767_pmic_probe
Axel Lin [Wed, 7 Mar 2012 02:02:12 +0000 (10:02 +0800)]
regulator: Remove unused i2c variable in s5m8767_pmic_probe

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps65217: Use DIV_ROUND_UP macro to calculate selector
Axel Lin [Tue, 6 Mar 2012 01:54:22 +0000 (09:54 +0800)]
regulator: tps65217: Use DIV_ROUND_UP macro to calculate selector

Use DIV_ROUND_UP macro for better readability.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: da903x: Use DIV_ROUND_UP macro to calculate selector
Axel Lin [Mon, 5 Mar 2012 22:54:40 +0000 (06:54 +0800)]
regulator: da903x: Use DIV_ROUND_UP macro to calculate selector

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: wm8400: Use DIV_ROUND_UP macro to calculate selector
Axel Lin [Tue, 6 Mar 2012 01:56:05 +0000 (09:56 +0800)]
regulator: wm8400: Use DIV_ROUND_UP macro to calculate selector

Use DIV_ROUND_UP macro for better readability.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator fixed: Do not report enumaratable voltages if there are none
Sascha Hauer [Sat, 3 Mar 2012 11:40:01 +0000 (12:40 +0100)]
regulator fixed: Do not report enumaratable voltages if there are none

If used as a dummy voltage provider the fixed regulator should
not set n_voltages to make the core accept the device.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: max8660: Use DIV_ROUND_UP macro to calculate selector
Axel Lin [Fri, 2 Mar 2012 08:23:39 +0000 (16:23 +0800)]
regulator: max8660: Use DIV_ROUND_UP macro to calculate selector

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: max1586: Use DIV_ROUND_UP macro to calculate selector
Axel Lin [Fri, 2 Mar 2012 08:22:01 +0000 (16:22 +0800)]
regulator: max1586: Use DIV_ROUND_UP macro to calculate selector

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: ad5398: Use DIV_ROUND_UP macro to calculate selector
Axel Lin [Fri, 2 Mar 2012 08:20:54 +0000 (16:20 +0800)]
regulator: ad5398: Use DIV_ROUND_UP macro to calculate selector

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Add a pointer to aat2870_data in struct aat2870_regulator
Axel Lin [Fri, 2 Mar 2012 01:28:44 +0000 (09:28 +0800)]
regulator: Add a pointer to aat2870_data in struct aat2870_regulator

The reason we add *pdev in struct aat2870_regulator is to use it
to get a pointer to struct aat2870_data.
Save a pointer to struct aat2870_data instead of pdev in struct
aat2870_regulator, this change makes the intention more clear.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Jin Park <jinyoungp@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Simplify the code to get selector in isl6271a_set_voltage
Axel Lin [Fri, 2 Mar 2012 01:19:02 +0000 (09:19 +0800)]
regulator: Simplify the code to get selector in isl6271a_set_voltage

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Kill max8998_get_ldo function
Axel Lin [Thu, 1 Mar 2012 01:27:29 +0000 (09:27 +0800)]
regulator: Kill max8998_get_ldo function

Use rdev_get_id() directly.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Kill max8997_get_rid function
Axel Lin [Thu, 1 Mar 2012 01:26:27 +0000 (09:26 +0800)]
regulator: Kill max8997_get_rid function

Use rdev_get_id() directly.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Fix n_voltage settings for pcf50633 regulator
Axel Lin [Wed, 29 Feb 2012 04:45:35 +0000 (12:45 +0800)]
regulator: Fix n_voltage settings for pcf50633 regulator

Current code has off-by-one n_voltage settings for AUTO/DOWN*/LDO* regulators.

Take ldo1 as example:
n_voltage should be (3.6 - 0.9) / 0.1 + 1 = 28

Table 76. LDO1OUT - LDO1 output voltage select register (address 2Dh) bit description[1]
Bit Symbol Access Description
4:0 ldo1_out R/W VO(prog) = 0.9 + ldo1_out × 0.1 V (max 3.6V); e.g.
00000 : 0.9 V
00001 : 1.0 V
11000 : 3.3 V
11011 : 3.6 V
11111 : 3.6 V

The n_voltage settings for HCLDO and MEMLDO are also wrong.
n_voltage for HCLDO and MEMLDO should be (3.6 - 0.9) / 0.1 + 1 = 28

Table 88. HCLDOOUT - HCLDO output voltage select register (addr. 39h) bit description[1]
Bit Symbol Access Description
4:0 hcldo_out R/W VO(prog) = 0.9 + hcldo_out × 0.1 V (max 3.6 V); e.g.
00000 : 0.9 V
00001 : 1.0 V
11011 : 3.6 V
11111 : 3.6 V

Table 62. MEMLDOOUT - MEMLDO o/p voltage select reg. (address 26h) bit description[1]
Bit Symbol Access Description
4:0 memldo_out R/W VO(prog) = 0.9 + memldo_out × 0.1 V; e.g.
00000: 0.9 V
00001: 1.0 V
11000 : 3.3 V
11011 : 3.6 V
11111 : 3.6 V

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Fix the logic of s5m8767_set_voltage_time_sel
Axel Lin [Fri, 24 Feb 2012 06:52:45 +0000 (14:52 +0800)]
regulator: Fix the logic of s5m8767_set_voltage_time_sel

This patch includes below fixes:
1. The mask variable is not used at all here, remove it.
2. We already have the new_sel and old_sel, simply returns the delay by:
  DIV_ROUND_UP(desc->step * (new_sel - old_sel), s5m8767->ramp_delay);

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: mc13783: bail out without platform data
Sascha Hauer [Wed, 29 Feb 2012 08:01:40 +0000 (09:01 +0100)]
regulator: mc13783: bail out without platform data

the platform data pointer is used without checking it. Bail out
in the driver instead of crashing the kernel.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Convert ab8499 to use get_voltage_sel()
Axel Lin [Fri, 24 Feb 2012 09:15:45 +0000 (17:15 +0800)]
regulator: Convert ab8499 to use get_voltage_sel()

This change is required to make ab8500_regulator_get_voltage_sel work.
The regulator core will call set_voltage_time_sel only when get_voltage_sel is
implemented.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Tested-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Sort Kconfig and Makefile entries
Axel Lin [Wed, 22 Feb 2012 01:29:16 +0000 (09:29 +0800)]
regulator: Sort Kconfig and Makefile entries

Sort Kconfig entries by company name/driver in alphabetical order.
Sort Makefile entries by alphabetical order.

In order to group all the Kconfig entries by company name,
this patch also adds company name to some Kconfig entries.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: Fix module desciption for tps65910 regulator
Axel Lin [Tue, 21 Feb 2012 02:14:55 +0000 (10:14 +0800)]
regulator: Fix module desciption for tps65910 regulator

Fix the module desciption and also update Kconfig to include supporting
tps65911 chip.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps65910: Correct VIO voltage configuration
Laxman Dewangan [Fri, 17 Feb 2012 13:26:11 +0000 (18:56 +0530)]
regulator: tps65910: Correct VIO voltage configuration

The VIO regulator register specify the voltage configuration
on bit3:2 of its register. And hence only these bits should
be modified when setting voltage and used when reading voltage
from register setting.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: wm8994: Convert to devm_kzalloc()
Mark Brown [Thu, 16 Feb 2012 07:12:17 +0000 (23:12 -0800)]
regulator: wm8994: Convert to devm_kzalloc()

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: tps62360: Remove pointless test for unsigned less than zero
Axel Lin [Tue, 7 Feb 2012 03:06:20 +0000 (11:06 +0800)]
regulator: tps62360: Remove pointless test for unsigned less than zero

The variable 'selector' is a 'unsigned int', so it can never be less than zero.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: s5m8767: Fix unused variable warning in probe()
Mark Brown [Mon, 6 Feb 2012 11:34:36 +0000 (11:34 +0000)]
regulator: s5m8767: Fix unused variable warning in probe()

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
12 years agomfd: twl-core: regulator configuration for twl6030 V1V8, V2V1 SMPS
Peter Ujfalusi [Tue, 28 Feb 2012 09:39:13 +0000 (15:09 +0530)]
mfd: twl-core: regulator configuration for twl6030 V1V8, V2V1 SMPS

To be able to attach consumers to these supplies from board
files we need to have regulator_init_data for them.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: twl-regulator: Add fixed LDO for V1V8, V2V1 supply
Peter Ujfalusi [Tue, 28 Feb 2012 09:39:12 +0000 (15:09 +0530)]
regulator: twl-regulator: Add fixed LDO for V1V8, V2V1 supply

V1V8 supply most common use is to provide VIO for the system.
V2V1 supply is used on SDP4430/PandaBoards to provide 2.1V to
twl6040, and also as an input to VCXIO_IN, VDAC_IN of twl6030.

Also update the bindings documentation with the new compatible
property for these additional LDOs.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: twl: adapt twl-regulator driver to dt
Rajendra Nayak [Tue, 28 Feb 2012 09:39:11 +0000 (15:09 +0530)]
regulator: twl: adapt twl-regulator driver to dt

Modify the twl regulator driver to extract the regulator_init_data from
device tree when passed, instead of getting it through platform_data
structures (on non-DT builds)

Also add documentation for TWL regulator specific bindings.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: twl6030: add support for vdd1, vdd2 and vdd3 regulators
Tero Kristo [Tue, 28 Feb 2012 09:39:10 +0000 (15:09 +0530)]
regulator: twl6030: add support for vdd1, vdd2 and vdd3 regulators

vdd1 and vdd2 are now common regulators for twl4030 and twl6030. Also
added vdd3 as a new regulator for twl6030. twl6030 vdd1...vdd3 smps
regulator voltages can only be controlled through the smartreflex
voltage channel, thus the support for the voltage_get and set is
minimal and requires external controller.

Signed-off-by: Tero Kristo <t-kristo@ti.com>
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: twl4030: add support for external voltage get/set
Tero Kristo [Thu, 16 Feb 2012 10:27:52 +0000 (12:27 +0200)]
regulator: twl4030: add support for external voltage get/set

This is needed for SMPS regulators, which use the OMAP voltage
processor for voltage get/set functions instead of the normal I2C
channel. For this purpose, regulator_init_data->driver_data contents
are expanded, it is now a struct which contains function pointers
for the set/get voltage operations, a data pointer for these, and
the previously used features bitmask.

Signed-off-by: Tero Kristo <t-kristo@ti.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com> [for the MFD part]
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoregulator: twl6030: Fix voltage selection logic
Laxman Dewangan [Fri, 3 Feb 2012 07:24:38 +0000 (12:54 +0530)]
regulator: twl6030: Fix voltage selection logic

The voltage selection logic for the twl6030 smps fails if
min:max is such that min < 1300mV and max > 1300mV although
this is in valid range for a regulator e.g. [x, 1350] where
x < 1300.
Fixing the voltage selection logic such that first it will
check for min_uV for a range and then calculated value will
be checked against max_uV.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
12 years agoARM: SAMSUNG: change the name from s3c-sdhci to exynos4-sdhci
Jaehoon Chung [Sat, 10 Mar 2012 11:59:50 +0000 (03:59 -0800)]
ARM: SAMSUNG: change the name from s3c-sdhci to exynos4-sdhci

Thomas Arbrahams's patchset have changed the device name in sdhci-s3c.c
(mmc: sdhci-s3c: Rework platform data and add device tree support)
But didn't change the regulator_consumer name.
So maybe didn't initialize the mmc/sd card for exynos4.

This patch is fixed that (based-on linux-samsung for-next branch)

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: kyungmin Park <kyungmin.park@samsung.com>
Reviewed-by: Thomas Abraham <thomas.abraham@linaro.org>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agommc: sdhci-s3c: add platform data for the second capability
Jaehoon Chung [Tue, 7 Feb 2012 06:59:01 +0000 (15:59 +0900)]
mmc: sdhci-s3c: add platform data for the second capability

This patch is added host_caps2 in sdhci-s3c.c
It's necessary that use the second capabilities.
And removed the duplicated host_caps.

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Acked-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: SAMSUNG: support the second capability for samsung-soc
Jaehoon Chung [Tue, 7 Feb 2012 06:59:01 +0000 (15:59 +0900)]
ARM: SAMSUNG: support the second capability for samsung-soc

In mmc, there are capabilities and use the host_caps.
That capability is expressed with bit[0:31].
But now..already filled the bit[0:31]...
so we need to denote with the other capability field.
(if we want to use the cache, powerclass, etc for eMMC..
 this field is necessary)

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Kyungmin Park <Kyungmin.park@samsung.com>
Acked-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: add support DMA for EXYNOS4X12 SoC
Boojin Kim [Wed, 15 Feb 2012 04:16:15 +0000 (13:16 +0900)]
ARM: EXYNOS: add support DMA for EXYNOS4X12 SoC

Signed-off-by: Boojin Kim <boojin.kim@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: Add apb_pclk clkdev entry for mdma1
Tushar Behera [Tue, 27 Dec 2011 05:42:50 +0000 (14:42 +0900)]
ARM: EXYNOS: Add apb_pclk clkdev entry for mdma1

Amba core assumes the pclk to be named as apb_pclk. During device probe,
it tries to get that clock and enable that. When PM_RUNTIME is enabled,
dma clock is not explicitly enabled in pl330_probe, which causes device
probe to fail. Adding a clkdev entry for apb_pclk for mdma1 fixes the
problem.

This patch fixes following runtime error.

dma-pl330 dma-pl330.2: PERIPH_ID 0x0, PCELL_ID 0x0 !
dma-pl330: probe of dma-pl330.2 failed with error -22

Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: Enable MDMA driver
Boojin Kim [Wed, 15 Feb 2012 04:15:12 +0000 (13:15 +0900)]
ARM: EXYNOS: Enable MDMA driver

This patch adds MDMA platform data and enables
MDMA for DMA memcpy operation for EXYNOS SoCs.

Signed-off-by: Boojin Kim <boojin.kim@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: Add clock register addresses for EXYNOS4X12 bus devfreq driver
MyungJoo Ham [Wed, 14 Dec 2011 11:12:46 +0000 (20:12 +0900)]
ARM: EXYNOS: Add clock register addresses for EXYNOS4X12 bus devfreq driver

EXYNOS4212/4412 memory bus devfreq driver requires some register
addresses that were not defined with EXYNOS4210 support.
This patch adds the required register addresses and shift/mask data.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: add clock registers for exynos4x12-cpufreq
Jaecheol Lee [Thu, 2 Feb 2012 03:31:01 +0000 (12:31 +0900)]
ARM: EXYNOS: add clock registers for exynos4x12-cpufreq

Signed-off-by: Jaecheol Lee <jc.lee@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoPM / devfreq: update the name of EXYNOS clock registers that were omitted
MyungJoo Ham [Fri, 9 Mar 2012 06:53:00 +0000 (15:53 +0900)]
PM / devfreq: update the name of EXYNOS clock registers that were omitted

In the commit, "PM / devfreq: update the name of EXYNOS clock register"
ommitted one register.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoPM / devfreq: update the name of EXYNOS clock register
Kukjin Kim [Sun, 22 Jan 2012 11:46:49 +0000 (20:46 +0900)]
PM / devfreq: update the name of EXYNOS clock register

According to replacing the name of EXYNOS clock registers,
this patch updates exynos4_bus.c file where it is used.

Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: change the prefix S5P_ to EXYNOS4_ for clock
Kukjin Kim [Fri, 9 Mar 2012 22:19:10 +0000 (14:19 -0800)]
ARM: EXYNOS: change the prefix S5P_ to EXYNOS4_ for clock

This patch changes prefix of the clk register from S5P_ to
EXYNOS4_ for new EXYNOS SoCs such as EXYNOS5 and adds prefix
exynos4_ on clk declarations.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: use static declaration on regarding clock
Kukjin Kim [Fri, 9 Mar 2012 22:06:13 +0000 (14:06 -0800)]
ARM: EXYNOS: use static declaration on regarding clock

This patch uses static declaration struct which is not
used in other file and re-arrange with group in header
file.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoARM: EXYNOS: replace clock.c for other new EXYNOS SoCs
Kukjin Kim [Fri, 9 Mar 2012 21:51:24 +0000 (13:51 -0800)]
ARM: EXYNOS: replace clock.c for other new EXYNOS SoCs

This patch changes the name of clock.c to clock-exynos4.c for other
EXYNOS series such as EXYNOS5. And since the header file of clock
is used only in arch/arm/mach-exynos, moves it in the local directory.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
12 years agoMerge branch 'next/cleanup-use-static' into next/cleanup-exynos-clock
Kukjin Kim [Sun, 11 Mar 2012 06:21:36 +0000 (22:21 -0800)]
Merge branch 'next/cleanup-use-static' into next/cleanup-exynos-clock

12 years agoLinux 3.3-rc7
Linus Torvalds [Sat, 10 Mar 2012 21:49:52 +0000 (13:49 -0800)]
Linux 3.3-rc7

12 years agoMerge branch 'sr' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap...
Olof Johansson [Sat, 10 Mar 2012 17:13:28 +0000 (09:13 -0800)]
Merge branch 'sr' of git://git./linux/kernel/git/tmlind/linux-omap into next/drivers

* 'sr' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: OMAP3+: SmartReflex: fix error handling
  ARM: OMAP3+: SmartReflex: fix the use of debugfs_create_* API
  ARM: OMAP3+: SmartReflex: micro-optimization for sanity check
  ARM: OMAP3+: SmartReflex: misc cleanups
  ARM: OMAP3+: SmartReflex: move late_initcall() closer to its argument
  ARM: OMAP3+: SmartReflex: add missing platform_set_drvdata()
  ARM: OMAP3+: hwmod: add SmartReflex IRQs
  ARM: OMAP3+: SmartReflex: clear ERRCONFIG_VPBOUNDINTST only on a need
  ARM: OMAP3+: SmartReflex: Fix status masking in ERRCONFIG register
  ARM: OMAP3+: SmartReflex: Add a shutdown hook
  ARM: OMAP3+: SmartReflex Class3: disable errorgen before disable VP
  ARM: OMAP3+: SmartReflex: fix err interrupt disable sequence
  ARM: OMAP3+: SmartReflex: use voltage domain name in device attributes
  ARM: OMAP2+: Fix devexit for smartreflex when CONFIG_HOTPLUG is not set
  ARM: OMAP2+: Fix zoom LCD backlight if TWL_CORE is not selected
  ARM: OMAP2+: Fix board_mux section type conflict when OMAP_MUX is not set
  ARM: OMAP2+: Fix OMAP_HDQ_BASE build error
  ARM: OMAP2+: Fix Kconfig dependencies for USB_ARCH_HAS_EHCI
  ARM: OMAP2+: I2C: always compile I2C reset code, even if I2C driver is not built

12 years agoMerge branch 'fixes-non-critical-part3' of git://git.kernel.org/pub/scm/linux/kernel...
Olof Johansson [Sat, 10 Mar 2012 16:56:58 +0000 (08:56 -0800)]
Merge branch 'fixes-non-critical-part3' of git://git./linux/kernel/git/tmlind/linux-omap into next/fixes-non-critical

* 'fixes-non-critical-part3' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: OMAP2+: Fix build for omap4 only builds with missing include of linux/bug.h
  ARM: OMAP2+: Fix section warnings for hsmmc_init_one

12 years agoaio: fix the "too late munmap()" race
Al Viro [Thu, 8 Mar 2012 17:51:19 +0000 (17:51 +0000)]
aio: fix the "too late munmap()" race

Current code has put_ioctx() called asynchronously from aio_fput_routine();
that's done *after* we have killed the request that used to pin ioctx,
so there's nothing to stop io_destroy() waiting in wait_for_all_aios()
from progressing.  As the result, we can end up with async call of
put_ioctx() being the last one and possibly happening during exit_mmap()
or elf_core_dump(), neither of which expects stray munmap() being done
to them...

We do need to prevent _freeing_ ioctx until aio_fput_routine() is done
with that, but that's all we care about - neither io_destroy() nor
exit_aio() will progress past wait_for_all_aios() until aio_fput_routine()
does really_put_req(), so the ioctx teardown won't be done until then
and we don't care about the contents of ioctx past that point.

Since actual freeing of these suckers is RCU-delayed, we don't need to
bump ioctx refcount when request goes into list for async removal.
All we need is rcu_read_lock held just over the ->ctx_lock-protected
area in aio_fput_routine().

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Reviewed-by: Jeff Moyer <jmoyer@redhat.com>
Acked-by: Benjamin LaHaise <bcrl@kvack.org>
Cc: stable@vger.kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoaio: fix io_setup/io_destroy race
Al Viro [Wed, 7 Mar 2012 05:16:35 +0000 (05:16 +0000)]
aio: fix io_setup/io_destroy race

Have ioctx_alloc() return an extra reference, so that caller would drop it
on success and not bother with re-grabbing it on failure exit.  The current
code is obviously broken - io_destroy() from another thread that managed
to guess the address io_setup() would've returned would free ioctx right
under us; gets especially interesting if aio_context_t * we pass to
io_setup() points to PROT_READ mapping, so put_user() fails and we end
up doing io_destroy() on kioctx another thread has just got freed...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Benjamin LaHaise <bcrl@kvack.org>
Reviewed-by: Jeff Moyer <jmoyer@redhat.com>
Cc: stable@vger.kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux...
Linus Torvalds [Sat, 10 Mar 2012 02:09:18 +0000 (18:09 -0800)]
Merge branch 'for-linus' of git://git./linux/kernel/git/mason/linux-btrfs

Pull btrfs updates from Chris Mason:
 "I have two additional and btrfs fixes in my for-linus branch.  One is
  a casting error that leads to memory corruption on i386 during scrub,
  and the other fixes a corner case in the backref walking code (also
  triggered by scrub)."

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
  Btrfs: fix casting error in scrub reada code
  btrfs: fix locking issues in find_parent_nodes()

12 years agomemcg: revert fix to mapcount check for this release
Hugh Dickins [Fri, 9 Mar 2012 21:37:32 +0000 (13:37 -0800)]
memcg: revert fix to mapcount check for this release

Respectfully revert commit e6ca7b89dc76 "memcg: fix mapcount check
in move charge code for anonymous page" for the 3.3 release, so that
it behaves exactly like releases 2.6.35 through 3.2 in this respect.

Horiguchi-san's commit is correct in itself, 1 makes much more sense
than 2 in that check; but it does not go far enough - swapcount
should be considered too - if we really want such a check at all.

We appear to have reached agreement now, and expect that 3.4 will
remove the mapcount check, but had better not make 3.3 different.

Signed-off-by: Hugh Dickins <hughd@google.com>
Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agox86: Derandom delay_tsc for 64 bit
Thomas Gleixner [Fri, 9 Mar 2012 19:55:10 +0000 (20:55 +0100)]
x86: Derandom delay_tsc for 64 bit

Commit f0fbf0abc093 ("x86: integrate delay functions") converted
delay_tsc() into a random delay generator for 64 bit.  The reason is
that it merged the mostly identical versions of delay_32.c and
delay_64.c.  Though the subtle difference of the result was:

 static void delay_tsc(unsigned long loops)
 {
- unsigned bclock, now;
+ unsigned long bclock, now;

Now the function uses rdtscl() which returns the lower 32bit of the
TSC. On 32bit that's not problematic as unsigned long is 32bit. On 64
bit this fails when the lower 32bit are close to wrap around when
bclock is read, because the following check

       if ((now - bclock) >= loops)
           break;

evaluated to true on 64bit for e.g. bclock = 0xffffffff and now = 0
because the unsigned long (now - bclock) of these values results in
0xffffffff00000001 which is definitely larger than the loops
value. That explains Tvortkos observation:

"Because I am seeing udelay(500) (_occasionally_) being short, and
 that by delaying for some duration between 0us (yep) and 491us."

Make those variables explicitely u32 again, so this works for both 32
and 64 bit.

Reported-by: Tvrtko Ursulin <tvrtko.ursulin@onelan.co.uk>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: stable@vger.kernel.org # >= 2.6.27
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoMerge tag 'sound-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound
Linus Torvalds [Fri, 9 Mar 2012 20:14:23 +0000 (12:14 -0800)]
Merge tag 'sound-fixes' of git://git./linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
 "Nothing exciting here: just a few regression fixes for HD-audio and
  ASoC, also the support of missing 32bit compat ioctl for HDSPM."

* tag 'sound-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
  ALSA: hdspm - Provide ioctl_compat
  ALSA: hda/realtek - Apply the coef-setup only to ALC269VB
  ALSA: hda - add quirk to detect CD input on Gigabyte EP45-DS3
  ASoC: neo1973: fix neo1973 wm8753 initialization

12 years agoMAINTAINERS: new git entry for arm/mach-msm
David Brown [Fri, 9 Mar 2012 19:39:32 +0000 (11:39 -0800)]
MAINTAINERS: new git entry for arm/mach-msm

The msm git tree moved to

  git://git.kernel.org/pub/scm/linux/kernel/git/davidb/linux-msm.git

Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoMerge tag 'for-linus' of git://linux-c6x.org/git/projects/linux-c6x-upstreaming
Linus Torvalds [Fri, 9 Mar 2012 15:27:38 +0000 (07:27 -0800)]
Merge tag 'for-linus' of git://linux-c6x.org/git/projects/linux-c6x-upstreaming

Pull C6X fix from Mark Salter:
 "Fix for C6X KSTK_EIP and KSTK_ESP macros."

* tag 'for-linus' of git://linux-c6x.org/git/projects/linux-c6x-upstreaming:
  C6X: fix KSTK_EIP and KSTK_ESP macros

12 years agoMerge tag 'iommu-fixes-v3.3-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Fri, 9 Mar 2012 15:26:25 +0000 (07:26 -0800)]
Merge tag 'iommu-fixes-v3.3-rc6' of git://git./linux/kernel/git/joro/iommu

Pull two IOMMU fixes from Joerg Roedel:
 "The first is an additional fix for the OMAP initialization order issue
  and the second patch fixes a possible section mismatch which can lead
  to a kernel crash in the AMD IOMMU driver when suspend/resume is used
  and the compiler has not inlined the iommu_set_device_table function."

* tag 'iommu-fixes-v3.3-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu:
  x86/amd: iommu_set_device_table() must not be __init
  ARM: OMAP: fix iommu, not mailbox

12 years agoMerge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux
Linus Torvalds [Fri, 9 Mar 2012 15:23:17 +0000 (07:23 -0800)]
Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux

Pull radeon drm stuff from Dave Airlie:
 "Just some radeon fixes, one is for an oops where we run out of ioremap
  space on some big hardware systems in 32-bit mode, stuff doesn't work
  properly but at least the machine will boot.

  One regression fix, and two bugs, one hw, one blit code."

* 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
  drm/radeon/kms: fix hdmi duallink checks
  drm/radeon/kms: set SX_MISC in the r6xx blit code (v2)
  drm/radeon: deal with errors from framebuffer init path.
  drm/radeon: fix a semaphore deadlock on pre cayman asics

12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Linus Torvalds [Fri, 9 Mar 2012 15:14:44 +0000 (07:14 -0800)]
Merge git://git./linux/kernel/git/davem/net

Pull networking from David Miller:

1) IPV4 routing metrics can become stale when routes are changed by the
   administrator, fix from Steffen Klassert.

2) atl1c does "val |= XXX;" where XXX is a bit number not a bit mask,
   fix by using set_bit.  From Dan Carpenter.

3) Memory accounting bug in carl9170 driver results in wedged TX queue.
   Fix from Nicolas Cavallari.

4) iwlwifi accidently uses "sizeof(ptr)" instead of "sizeof(*ptr)", fix
   from Johannes Berg.

5) Openvswitch doesn't honor dp_ifindex when doing vport lookups, fix
   from Ben Pfaff.

6) ehea conversion to 64-bit stats lost multicast and rx_errors
   accounting, fix from Eric Dumazet.

7) Bridge state transition logging in br_stp_disable_port() is busted,
   it's emitted at the wrong time and the message is in the wrong tense,
   fix from Paulius Zaleckas.

8) mlx4 device erroneously invokes the queue resize firmware operation
   twice, fix from Jack Morgenstein.

9) Fix deadlock in usbnet, need to drop lock when invoking usb_unlink_urb()
   otherwise we recurse into taking it again.  Fix from Sebastian Siewior.

10) hyperv network driver uses the wrong driver name string, fix from
    Haiyang Zhang.

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net:
  net/hyperv: Use the built-in macro KBUILD_MODNAME for this driver
  net/usbnet: avoid recursive locking in usbnet_stop()
  route: Remove redirect_genid
  inetpeer: Invalidate the inetpeer tree along with the routing cache
  mlx4_core: fix bug in modify_cq wrapper for resize flow.
  atl1c: set ATL1C_WORK_EVENT_RESET bit correctly
  bridge: fix state reporting when port is disabled
  bridge: br_log_state() s/entering/entered/
  ehea: restore multicast and rx_errors fields
  openvswitch: Fix checksum update for actions on UDP packets.
  openvswitch: Honor dp_ifindex, when specified, for vport lookup by name.
  iwlwifi: fix wowlan suspend
  mwifiex: reset encryption mode flag before association
  carl9170: fix frame delivery if sta is in powersave mode
  carl9170: Fix memory accounting when sta is in power-save mode.

12 years agoMerge tag 'fixes-urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc
Linus Torvalds [Fri, 9 Mar 2012 01:32:42 +0000 (17:32 -0800)]
Merge tag 'fixes-urgent' of git://git./linux/kernel/git/arm/arm-soc

Pull last minute fixes from Olof Johansson:
 "One samsung build fix due to a mis-applied patch, and a small set of
  OMAP fixes.  This should be the last from arm-soc for 3.3, hopefully."

* tag 'fixes-urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
  ARM: S3C2440: Fixed build error for s3c244x
  ARM: OMAP2+: Fix module build errors with CONFIG_OMAP4_ERRATA_I688
  ARM: OMAP: id: Add missing break statement in omap3xxx_check_revision
  ARM: OMAP2+: Remove apply_uV constraints for fixed regulator
  ARM: OMAP: irqs: Fix NR_IRQS value to handle PRCM interrupts

12 years agoMerge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
Linus Torvalds [Fri, 9 Mar 2012 01:25:17 +0000 (17:25 -0800)]
Merge tag 'for-linus' of git://git./linux/kernel/git/broonie/regulator

Pull regulator fix from Mark Brown:
 "Another small, clear fix in a specific driver."

* tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator:
  regulator: tps65910: Configure correct value for VDDCTRL vout reg