]> git.karo-electronics.de Git - linux-beck.git/log
linux-beck.git
14 years agoOMAP4 clock: Support clk_set_parent
Rajendra Nayak [Wed, 19 May 2010 02:23:59 +0000 (20:23 -0600)]
OMAP4 clock: Support clk_set_parent

Remove the hack put in place while clock framework was still not in
place for OMAP4.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP4: PRCM: Add offset defines for all CM registers
Rajendra Nayak [Thu, 20 May 2010 18:31:12 +0000 (12:31 -0600)]
OMAP4: PRCM: Add offset defines for all CM registers

The cm44xx.h files only had absolute register address
defines for all CM registers.
This patch adds additional register offset defines for all the
registers, so they can be used with apis like cm_read_mod_*

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP4: PRCM: Add offset defines for all PRM registers
Rajendra Nayak [Thu, 20 May 2010 18:31:12 +0000 (12:31 -0600)]
OMAP4: PRCM: Add offset defines for all PRM registers

The prm44xx.h files only had absolute register address
defines for all PRM registers.
This patch adds additional register offset defines for all the
registers, so they can be used with apis like prm_read_mod_*

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP4: PRCM: Remove duplicate definition of base addresses
Benoit Cousson [Thu, 20 May 2010 18:31:12 +0000 (12:31 -0600)]
OMAP4: PRCM: Remove duplicate definition of base addresses

CM1, CM2, PRM, SCRM and MPU_PRCM are already defined in omap44xx.h

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
14 years agoOMAP4: PRM: Remove MPU internal code name and apply PRCM naming convention
Benoit Cousson [Thu, 20 May 2010 18:31:11 +0000 (12:31 -0600)]
OMAP4: PRM: Remove MPU internal code name and apply PRCM naming convention

The MPU subsystem was named based on internal code name (CHIRON).
This patch will remove all the occurences of the chiron name
are replace it with PRCM_MPU in order to differentiate
the MPU local PRCM to the global one.

Remove PDA_ from PRCM_MPU registers names to stick to the global
PRM naming convention.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
14 years agoOMAP4: CM: Remove non-functional registers in ES1.0
Benoit Cousson [Thu, 20 May 2010 18:31:11 +0000 (12:31 -0600)]
OMAP4: CM: Remove non-functional registers in ES1.0

The automatic HW restore from OFF mode is not functional at all in
OMAP4430 ES1.0.
Because of that, it will be extensively changed in the next Si revision,
and the compatibilty will not be maintained with ES1.0.

Remove the current XXX_RESTORE registers definition to avoid future
conflicts with the next Si revision.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
14 years agoOMAP: hwmod: Replace WARN by pr_warning for clockdomain check
Benoit Cousson [Thu, 20 May 2010 18:31:10 +0000 (12:31 -0600)]
OMAP: hwmod: Replace WARN by pr_warning for clockdomain check

Most of the clock nodes belong to a clock domain, but it is perfectly valid
to have clock without clock domain.
Root clocks for example does not belong to any clock domain.
Keep the warning but reduce the verbosity.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP: hwmod: Rename hwmod name for the MPU
Benoit Cousson [Thu, 20 May 2010 18:31:10 +0000 (12:31 -0600)]
OMAP: hwmod: Rename hwmod name for the MPU

In the lastest OMAP4 hwmod data file, the _hwmod was removed
in order to save some memory space and because it does not
bring a lot.

The same cleanup will be have to done for other hwmods in
OMAP2 & 3 data files.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
14 years agoOMAP: hwmod: Do not exit the iteration if one clock init failed
Benoit Cousson [Thu, 20 May 2010 18:31:10 +0000 (12:31 -0600)]
OMAP: hwmod: Do not exit the iteration if one clock init failed

During the _init_clocks phase, the iteration is stopped but the
status is still change from _HWMOD_STATE_REGISTERED to
_HWMOD_STATE_CLKS_INITED.
Since the _setup phase will be done nevertheless, it might be
better to keep initializing the others clocks nodes and just
keep the warning.
It is much easier to debug when a important number of clocks
name are wrong during the early debug phase of a new platform.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP: hwmod: Replace WARN by pr_warning if clock lookup failed
Benoit Cousson [Thu, 20 May 2010 18:31:09 +0000 (12:31 -0600)]
OMAP: hwmod: Replace WARN by pr_warning if clock lookup failed

The WARN is a little bit too verbose and is not providing
usefull information in that case.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP: hwmod: Remove IS_ERR check with omap_clk_get_by_name return value
Benoit Cousson [Thu, 20 May 2010 18:31:09 +0000 (12:31 -0600)]
OMAP: hwmod: Remove IS_ERR check with omap_clk_get_by_name return value

The previous clock API was returning a standard linux error code in
case of failure. This is not the case anymore with the new
omap_clk_get_by_name API. A NULL value means that the clock node
does not exist.
Replace all the IS_ERR check by a !clk check.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP: hwmod: Fix wrong pointer iteration in oh->slaves
Benoit Cousson [Thu, 20 May 2010 18:31:09 +0000 (12:31 -0600)]
OMAP: hwmod: Fix wrong pointer iteration in oh->slaves

The iteration is currently done on the omap_hwmod_ocp_if pointer
and not on the table pointer that reference them.
It worked most of the time because the structure are contiguous in
memory.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP4: hwmod: Replace OCPIF_HAS_IDLEST by HWMOD_NO_IDLEST
Benoit Cousson [Thu, 20 May 2010 18:31:09 +0000 (12:31 -0600)]
OMAP4: hwmod: Replace OCPIF_HAS_IDLEST by HWMOD_NO_IDLEST

Some initiator modules in OMAP2 & 3 does not have IDLEST bit,
in that case we cannot detect the module readiness by
polling that bit and must exist the function immediately
assuming that the module is ready.

The previous flag was affected to the OCP interface. While it is
technically true that the idlest is related to the L4 slave
interface of the module, the PRCM status belong to the module.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP4: hwmod & CM: Implement the omap4_cm_wait_module_ready function
Benoit Cousson [Thu, 20 May 2010 18:31:08 +0000 (12:31 -0600)]
OMAP4: hwmod & CM: Implement the omap4_cm_wait_module_ready function

The return of the omap4_cm_wait_module_ready function is checked
in order to avoid accessing the sysconfig register if the module is
not in the correct state.
In that case the _setup will exit without trying to reset
using sysconfig.
For the moment a warning is printed. A proper management of fclk
and module reset will have to be done in order to init correctly
the problematic IPs listed below.

  <4>omap_hwmod: ivahd: cannot be enabled (3)
  <4>omap_hwmod: iss: cannot be enabled (3)
  <4>omap_hwmod: tesla: cannot be enabled (3)
  <4>omap_hwmod: sdma: cannot be enabled (3)
  <4>omap_hwmod: sl2: cannot be enabled (3)
  <4>omap_hwmod: sad2d: cannot be enabled (3)
  <4>omap_hwmod: ducati: cannot be enabled (3)

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP: CM: Move MAX_MODULE_READY_TIME to cm.h
Benoit Cousson [Thu, 20 May 2010 18:31:08 +0000 (12:31 -0600)]
OMAP: CM: Move MAX_MODULE_READY_TIME to cm.h

The maximum timeout to wait for the PRCM to request that a module
exit idle or reach functionnal state is common to OMAP2/3/4 SoCs,
so, move it to the chip family-common cm.h include file.

Reduce the timeout from 20 ms to 2 ms.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP4: hwmod: Replace module & device offsets by absolute clkctrl address
Benoit Cousson [Thu, 20 May 2010 18:31:08 +0000 (12:31 -0600)]
OMAP4: hwmod: Replace module & device offsets by absolute clkctrl address

Accessing the clkctrl register using offset of module & device is hard
to do in OMAP4 due to the way the CM1, CM2, PRM and PRCM_MPU are located
in the address space. There is no common base address anymore for all the
CM registers.
The easiest way to handle that on OMAP4 is to provide the absolute address
of the XXX_CLKCTRL register per hwmod.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
14 years agoOMAP clock: resolve old checkpatch and CodingStyle issues with plat-omap/clock.c
Paul Walmsley [Wed, 19 May 2010 00:40:26 +0000 (18:40 -0600)]
OMAP clock: resolve old checkpatch and CodingStyle issues with plat-omap/clock.c

Clean up comment style, remove unnecessary includes, and resolve some
checkpatch warnings in plat-omap/clock.c.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP3 clock: remove unnecessary duplicate of dpll4_m2_ck, added for 36xx
Paul Walmsley [Wed, 19 May 2010 00:40:26 +0000 (18:40 -0600)]
OMAP3 clock: remove unnecessary duplicate of dpll4_m2_ck, added for 36xx

Commit 678bc9a2eabb7f444ef8ad1cfc5ef394e2bd8bf2 split dpll4_m2_ck,
creating a 34xx and a 36xx variant, to handle the additional 16
divider steps provided on the 36xx.  This in turn required dynamic
rewriting of the clock tree during initialization, which is
undesirable.  All this seems to be unnecessary, though, since the
additional 16 divider steps can simply be marked with RATE_IN_36XX.
This patch does so and re-merges the affected structures.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Vishwanath Sripathy <vishwanath.bs@ti.com>
14 years agoOMAP3 clock: rename RATE_IN_343X, RATE_IN_3430ES2 to match reality
Paul Walmsley [Wed, 19 May 2010 00:40:25 +0000 (18:40 -0600)]
OMAP3 clock: rename RATE_IN_343X, RATE_IN_3430ES2 to match reality

Rename the RATE_IN_343X clksel_rate.rate flag to be RATE_IN_3XXX, to reflect
that these rates are valid on all OMAP3 platforms, not just 343X.

Also rename the RATE_IN_OMAP3430ES2 clksel_rate.rate flag to be
RATE_IN_OMAP3430ES2PLUS, to reflect that these flags are valid on all
OMAP3 platforms after 3430ES2.

This patch should not result in any functional changes.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Ranjith Lohithakshan <ranjithl@ti.com>
14 years agoOMAP2+ clock: clean up clkt_clksel.c
Paul Walmsley [Wed, 19 May 2010 00:40:24 +0000 (18:40 -0600)]
OMAP2+ clock: clean up clkt_clksel.c

This patch cleans up arch/arm/mach-omap2/clkt_clksel.c.  It:

- makes several functions static that are not called outside the file;

- adds documentation;

- makes some code paths easier to read (hopefully), by breaking up
  compound statements and removing redundant checks;

- converts some pr_err()s that indicate clock tree data problems into WARN()s,
  so they are more likely to be noticed;

- and moves omap2_clk_round_rate() back into mach-omap2/clock.c, its proper
  home, since it is not clksel-specific.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP2+ clock: remove DEFAULT_RATE clksel_rate flag
Paul Walmsley [Wed, 19 May 2010 00:40:24 +0000 (18:40 -0600)]
OMAP2+ clock: remove DEFAULT_RATE clksel_rate flag

The DEFAULT_RATE clksel_rate flag is essentially useless.  It was set
on some of the lowest divisors, which, when switching to a much
higher-rate parent, could have potentially resulted in rates that
exceeded the hardware specifications for downstream clocks in the
window between the clk_set_parent(), and a subsequent clk_set_rate().
It seems much safer to just remove the flag and always use the highest
available divisor (resulting in the lowest possible rate) after the
switch, and this patch does so.

Ideally, it would be best to first attempt to switch to a divisor that
matches the clock's rate with the previous parent, if at all possible.
But that is a project for some other day or some other person.  The
parent changing code is rarely used.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoOMAP3: PM: PM_MPUGRPSEL writes should use GRPSEL macros, not EN macros
Paul Walmsley [Wed, 19 May 2010 00:40:23 +0000 (18:40 -0600)]
OMAP3: PM: PM_MPUGRPSEL writes should use GRPSEL macros, not EN macros

Writes to the PM_*GRPSEL registers should use _GRPSEL_ macros, not _EN_ macros,
to match the TRM and guard against inadvertent error.  This patch should
not cause any functional change.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
Cc: Jouni Högander <jouni.hogander@nokia.com>
14 years agoOMAP2+ PRCM: convert remaining PRCM macros to the _SHIFT/_MASK suffixes
Paul Walmsley [Wed, 19 May 2010 00:40:23 +0000 (18:40 -0600)]
OMAP2+ PRCM: convert remaining PRCM macros to the _SHIFT/_MASK suffixes

Fix all of the remaining PRCM register shift/bitmask macros that did not
use the _SHIFT/_MASK suffixes to use them.  This makes the use of these
macros consistent.  It is intended to reduce error, as code can be inspected
visually by reviewers to ensure that bitshifts and bitmasks are used in
the appropriate places.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3 PRCM: convert OMAP3 PRCM macros to the _SHIFT/_MASK suffixes
Paul Walmsley [Wed, 19 May 2010 00:47:24 +0000 (18:47 -0600)]
OMAP3 PRCM: convert OMAP3 PRCM macros to the _SHIFT/_MASK suffixes

Fix all of the remaining OMAP3 PRCM register shift/bitmask macros that
did not use the _SHIFT/_MASK suffixes to use them.  This makes the use
of these macros consistent.  It is intended to reduce error, as code
can be inspected visually by reviewers to ensure that bitshifts and
bitmasks are used in the appropriate places.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP2 PRCM: convert OMAP2 PRCM macros to the _SHIFT/_MASK suffixes
Paul Walmsley [Thu, 20 May 2010 18:31:04 +0000 (12:31 -0600)]
OMAP2 PRCM: convert OMAP2 PRCM macros to the _SHIFT/_MASK suffixes

Fix all of the remaining OMAP2 PRCM register shift/bitmask macros that
did not use the _SHIFT/_MASK suffixes to use them.  This makes the use
of these macros consistent.  It is intended to reduce error, as code
can be inspected visually by reviewers to ensure that bitshifts and
bitmasks are used in the appropriate places.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP1 clock: fix section mismatch on clk_init
Felipe Balbi [Thu, 20 May 2010 18:31:04 +0000 (12:31 -0600)]
OMAP1 clock: fix section mismatch on clk_init

remove the section annotation from omap1_clk_disable_unused()
to kill the section mismatch warning.

Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
14 years agoAM3517: rename the i2c boardinfo to make it more readable
stanley.miao [Thu, 13 May 2010 12:39:29 +0000 (12:39 +0000)]
AM3517: rename the i2c boardinfo to make it more readable

There are three i2c buses on am3517, and each i2c bus has several devices
on it, so we can't name the i2c boardinfo structures with one of these
devices. In order to make it more readable, now rename these three boardinfo
structures based on i2c indexes.

Signed-off-by: Stanley.Miao <stanley.miao@windriver.com>
Acked-By: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: GPIO: Fix OMAP4 GPIO reg access issues
Charulatha V [Fri, 14 May 2010 19:05:27 +0000 (12:05 -0700)]
omap: GPIO: Fix OMAP4 GPIO reg access issues

Access to some of the OMAP4 GPIO registers are not properly handled.
This patch fixes it.

This patch is tested on 3430SDP and 4430SDP boards

Signed-off-by: Charulatha V <charu@ti.com>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap4: Move SOC specific code from board file
Santosh Shilimkar [Fri, 14 May 2010 19:05:26 +0000 (12:05 -0700)]
omap4: Move SOC specific code from board file

This patch moves OMAP4 soc specific code from 4430sdp board file.
The change is necessary so that newer board support can be added
with minimal changes. This will be also problematic for
multi-board, multi-omap builds.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoOMAP4: Networking: Defconfig Support
Abraham Arce [Fri, 14 May 2010 19:05:26 +0000 (12:05 -0700)]
OMAP4: Networking: Defconfig Support

Enable KS8851 SPI support +

 Networking Support
  - Packet Socket
  - TCP/IP

 Network Filesystems
  - NFS Client
  - Root Filesystem on NFS

Signed-off-by: Abraham Arce <x0066660@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoOMAP4: Ethernet: KS8851 Board Support
Abraham Arce [Fri, 14 May 2010 19:05:26 +0000 (12:05 -0700)]
OMAP4: Ethernet: KS8851 Board Support

Enable Micrel KS8851 SPI network chip for OMAP4430

Signed-off-by: Abraham Arce <x0066660@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoOMAP4: SPI: Fix Driver Kconfig
Syed Rafiuddin [Fri, 14 May 2010 19:05:25 +0000 (12:05 -0700)]
OMAP4: SPI: Fix Driver Kconfig

Change dependency to ARCH_OMAP2PLUS to allow systems based on
omap24xx, omap34xx or omap44xx

Cc: spi-devel-general@lists.sourceforge.net
Signed-off-by: Syed Rafiuddin <rafiuddin.syed@ti.com>
Signed-off-by: Abraham Arce <x0066660@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: hsmmc: fix the hsmmc driver for am3517
stanley.miao [Thu, 13 May 2010 12:39:31 +0000 (12:39 +0000)]
omap: hsmmc: fix the hsmmc driver for am3517

AM3517 don't have the register OMAP343X_CONTROL_PBIAS_LITE and the regulators
like "vmmc", so we set a noop "set_power" function for it.

Signed-off-by: Stanley.Miao <stanley.miao@windriver.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: init the gpio pinmux for mmc
stanley.miao [Thu, 13 May 2010 12:39:30 +0000 (12:39 +0000)]
omap: init the gpio pinmux for mmc

There is two gpio for mmc use, one is for card detecting, another is
used for checking write protect. Intialize its pinmux in case the bootloader
doesn't set it.

Signed-off-by: Stanley.Miao <stanley.miao@windriver.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: DMA: Fix multi-line comments
manjugk manjugk [Fri, 14 May 2010 19:05:25 +0000 (12:05 -0700)]
omap: DMA: Fix multi-line comments

Multi line comments are fixed as per CodingStyle
guidelines.

Cc: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Manjunatha GK <manjugk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoOMAP2/3/4: DMA: disable channel interrupts in omap_init_dma()
Mika Westerberg [Fri, 14 May 2010 19:05:25 +0000 (12:05 -0700)]
OMAP2/3/4: DMA: disable channel interrupts in omap_init_dma()

If we are softbooting another kernel using kexec, DMA controller state is not
known when we are performing omap_init_dma(). It is possible that some DMA
channels are already active. For example after kexec we get:

<4>IRQ 0020 for non-allocated DMAchannel 5
<4>IRQ 0020 for non-allocated DMAchannel 5
<4>IRQ 0020 for non-allocated DMAchannel 5
<4>IRQ 0020 for non-allocated DMAchannel 5
<4>IRQ 0020 for non-allocated DMAchannel 5

To prevent any weird things happening, we disable all channel interrupts during
init.

Signed-off-by: Mika Westerberg <ext-mika.1.westerberg@nokia.com>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoMerge branch 'v2.6.34-rc7.iommu' of git://gitorious.org/~doyu/lk/mainline into omap...
Tony Lindgren [Thu, 20 May 2010 18:14:28 +0000 (11:14 -0700)]
Merge branch 'v2.6.34-rc7.iommu' of git://gitorious.org/~doyu/lk/mainline into omap-for-linus

14 years agoOMAP: RX51: Add "vdds_sdi" supply voltage for SDI
Roger Quadros [Wed, 12 May 2010 08:48:47 +0000 (11:48 +0300)]
OMAP: RX51: Add "vdds_sdi" supply voltage for SDI

The SDI Display subsystem needs access to the vdds_sdi supply
regulator. This is TWL4030's VAUX1 supply on RX-51.

Signed-off-by: Roger Quadros <roger.quadros@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
14 years agoMerge branch 'pm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux...
Tony Lindgren [Thu, 20 May 2010 18:11:44 +0000 (11:11 -0700)]
Merge branch 'pm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-omap-pm into omap-for-linus

14 years agoMerge branch 'gpio-2.6.35' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman...
Tony Lindgren [Thu, 20 May 2010 18:07:34 +0000 (11:07 -0700)]
Merge branch 'gpio-2.6.35' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-omap-pm into omap-for-linus

14 years agoMerge branch 'omap-boards' into omap-for-linus
Tony Lindgren [Thu, 20 May 2010 18:07:23 +0000 (11:07 -0700)]
Merge branch 'omap-boards' into omap-for-linus

14 years agoOMAP1: Amstrad Delta: modify defconfig for external keyboardsupport
Janusz Krzysztofik [Thu, 20 May 2010 18:02:43 +0000 (11:02 -0700)]
OMAP1: Amstrad Delta: modify defconfig for external keyboardsupport

The patch adds a CONFIG directive required for supporting the Amstrad Delta
connected external keyboard by default.

Created and tested against linux-omap master,
commit 104a77440f05430f29f9d3f4ecb88c1536819585 dated 2010-04-27.

Works on top of PATCH v4 4/5(7), "input: serio: add support for Amstrad Delta
serial keyboard port".

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoAM35x: fix UI card EHCI port and LCD dependency
Ajay Kumar Gupta [Mon, 10 May 2010 21:29:19 +0000 (14:29 -0700)]
AM35x: fix UI card EHCI port and LCD dependency

EHCI port on UI card and LCD share two pins (GPIO 181 and 182) thus
they have to be mutually exclusive.

Signed-off-by: Ajay Kumar Gupta <ajay.gupta@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: rx51: Add supplies for the tlv320aic3x codec driver
Jarkko Nikula [Mon, 10 May 2010 21:29:19 +0000 (14:29 -0700)]
omap: rx51: Add supplies for the tlv320aic3x codec driver

Upcoming change to tlv320aic3x codec driver require four supplies.
Implement this by connecting analogic supplies to TWL4030 VMMC2 and digital
supplies to TWL4030 VIO.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Cc: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: rx51: Add i2c2 board_info with tlv320aic3x
Jarkko Nikula [Mon, 10 May 2010 21:29:18 +0000 (14:29 -0700)]
omap: rx51: Add i2c2 board_info with tlv320aic3x

This makes possible to probe the audio codec and add another i2c2
components in the future.

Fix also indentation for the first omap_register_i2c_bus.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: rx51: Change the TWL4030 VMMC2 voltage constraints andsupply name
Jarkko Nikula [Mon, 10 May 2010 21:29:18 +0000 (14:29 -0700)]
omap: rx51: Change the TWL4030 VMMC2 voltage constraints andsupply name

I believe the VMMC2 constraints must be the same than with VAUX3. Older
boards are using TWL4030 VMMC2 supply for internal MMC whereas newer are
using VAUX3 that has more limited constraints defined in this same file.

More over, the VMMC2 supply is used also for analog audio domain and the
miminum analog voltage of the TLV320AIC34 codec is 2.7 V.

To combine these two facts, the patch changes supply name to V28_A as the
newer boards register VMMC2_30 for VAUX3 and uses the same constraints than
VAUX3 since those constraints are ok for the TLV320AIC34.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Cc: Adrian Hunter <adrian.hunter@nokia.com>
Cc: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: Overo: Add support for second ethernet port
Steve Sakoman [Mon, 10 May 2010 21:29:18 +0000 (14:29 -0700)]
omap: Overo: Add support for second ethernet port

Some Overo add-on boards include a second ethernet port.  This patch
adds support for that second port.

Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoAM3517: defconfig update to enable EMAC support
Sriram [Mon, 10 May 2010 21:29:18 +0000 (14:29 -0700)]
AM3517: defconfig update to enable EMAC support

Update the default configuration for AM3517EVM to enable
support for EMAC peripheral.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoOMAP3: clock data: Update name string for EMAC clocks
Sriram [Mon, 10 May 2010 21:29:17 +0000 (14:29 -0700)]
OMAP3: clock data: Update name string for EMAC clocks

The emac driver currently uses Davinci clock names for the module and phy
clocks. Updated the omap3xxx_clks table to match the names
used by the Davinci emac driver.

Note that eventually the EMAC clocks should be renamed to be generic.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
[tony@atomide.com: updated patch description to match the patch]
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoAM35xx: Platform specific hookup for EMAC module
Sriram [Mon, 10 May 2010 21:29:17 +0000 (14:29 -0700)]
AM35xx: Platform specific hookup for EMAC module

Modified AM35xx EVM init sequence to handle EMAC
initialization.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoAM35xx EMAC: define submodule offsets
Sriram [Mon, 10 May 2010 21:29:17 +0000 (14:29 -0700)]
AM35xx EMAC: define submodule offsets

Define offsets for EMAC sub modules.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agocan: ti_hecc: Enable CAN support on AM3517
Sriram [Mon, 10 May 2010 21:29:16 +0000 (14:29 -0700)]
can: ti_hecc: Enable CAN support on AM3517

Modify the default kernel configuration on AM3517 to enable CAN.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agocan: ti_hecc: board specific hookup on AM3517EVM
Sriram [Mon, 10 May 2010 21:29:16 +0000 (14:29 -0700)]
can: ti_hecc: board specific hookup on AM3517EVM

Add board specific hookup for TI HECC driver on
AM3517 EVM

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: Devkit8000: Update default configuration
Thomas Weber [Mon, 10 May 2010 21:29:16 +0000 (14:29 -0700)]
omap: Devkit8000: Update default configuration

This patch updates the new default configuration for the Devkit8000.

Signed-off-by: Thomas Weber <weber@corscience.de>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap: Devkit8000: Add mux initialization
Thomas Weber [Mon, 10 May 2010 21:29:16 +0000 (14:29 -0700)]
omap: Devkit8000: Add mux initialization

Initialize multiplexed pins with correct mode.

Signed-off-by: Thomas Weber <weber@corscience.de>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap2: select ARCH_OMAP_OTG for OMAP2430 SDP
Viral Mehta [Mon, 10 May 2010 21:29:15 +0000 (14:29 -0700)]
omap2: select ARCH_OMAP_OTG for OMAP2430 SDP

Configuration for OMAP2430 should select ARCH_OMAP_OTG just like
it is done for OMAP2420

Signed-off-by: Viral Mehta <viral.mehta@lntinfotech.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap2: Add OHCI USB platform init for 2430 SDP
Viral Mehta [Mon, 10 May 2010 21:29:15 +0000 (14:29 -0700)]
omap2: Add OHCI USB platform init for 2430 SDP

Add platform init code for OHCI USB on OMAP2430 SDP

Signed-off-by: Viral Mehta <viral.mehta@lntinfotech.com>
[tony@atomide.com: Updated subject to mention the board name]
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap2: Add I2C bus 1 initialisation for 2430sdp
Viral Mehta [Mon, 10 May 2010 21:29:15 +0000 (14:29 -0700)]
omap2: Add I2C bus 1 initialisation for 2430sdp

Initialize isp1301 FS USB transceiver and
add I2C bus1 initialization code for OMAP2430 SDP

Signed-off-by: Viral Mehta <viral.mehta@lntinfotech.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap1: amsdelta: defconfig updates
Janusz Krzysztofik [Mon, 10 May 2010 21:29:14 +0000 (14:29 -0700)]
omap1: amsdelta: defconfig updates

The patch provides the following ams_delta_defconfig updates:
- explicitly select preemptable RCU,
- replace outdated CONFIG_LBD and CONFIG_LSF options with CONFIG_LBDAF,
- activate support for LCD contrast setting (new in 2.6.34),
- turn off verbose bug reporting for smaller kernel.

Created and tested against linux-2.6.34-rc3.

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoomap iommu: Reject unaligned addresses at setting page table entry
Hiroshi DOYU [Thu, 6 May 2010 15:24:04 +0000 (18:24 +0300)]
omap iommu: Reject unaligned addresses at setting page table entry

This rejects unaligned device virtual address('da') and physical
address('pa') and informs error to caller when a page table entry is
set. Otherwise, a wrong address can be used by IO device.

Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Cc: Hari Kanigeri <h-kanigeri2@ti.com>
14 years agoomap iommu: Exit iteration if no possibility of available area
Hiroshi DOYU [Thu, 6 May 2010 14:09:25 +0000 (17:09 +0300)]
omap iommu: Exit iteration if no possibility of available area

Searching avaialable spaces should be stopped as soon as it turns out
that there's no possibility with the rest of it.

Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
14 years agoomap iommu: Insert a gap page between IOVMAs against override
Hiroshi DOYU [Thu, 6 May 2010 13:10:18 +0000 (16:10 +0300)]
omap iommu: Insert a gap page between IOVMAs against override

Inserting a gap page between IOVMAs could detect an override on other
IOVMA with iommu fault. This was originally suggested by Sakari Ailus
and based on the work and comment by David Cohen.

Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Cc: David Cohen <david.cohen@nokia.com>
Cc: Sakari Ailus <Sakari.Ailus@nokia.com>
14 years agoomap iommu: Make CONFIG_OMAP_IOMMU_DEBUG selectable
Hiroshi DOYU [Tue, 4 May 2010 11:52:17 +0000 (14:52 +0300)]
omap iommu: Make CONFIG_OMAP_IOMMU_DEBUG selectable

This CONFIG_OMAP_IOMMU_DEBUG option cannot be selected because it's
not visible on menu. Make this option selectable.

Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
14 years agoomap iommu: Introduce iteration macro for iotlb entry scan
Hiroshi DOYU [Tue, 27 Apr 2010 05:37:12 +0000 (05:37 +0000)]
omap iommu: Introduce iteration macro for iotlb entry scan

There are some places to scan iotlb entries. This iteration macro
could make these code a bit simpler with proceeding iotlb entries
transparently.

Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Tested-by: Hari Kanigeri <h-kanigeri2@ti.com>
14 years agoomap iommu: add TLB preservation support
Kanigeri, Hari [Thu, 22 Apr 2010 23:26:11 +0000 (23:26 +0000)]
omap iommu: add TLB preservation support

This patch adds TLB preservation support to IOMMU module

Signed-off-by: Hari Kanigeri <h-kanigeri2@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
14 years agoomap iommu: missing check for TLB valid entry
Kanigeri, Hari [Thu, 22 Apr 2010 23:26:10 +0000 (23:26 +0000)]
omap iommu: missing check for TLB valid entry

Added the missing TLB valid entry setting for cam register

Signed-off-by: Hari Kanigeri <h-kanigeri2@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
14 years agoomap iommu: support for OMAP4
Kanigeri, Hari [Thu, 22 Apr 2010 23:26:09 +0000 (23:26 +0000)]
omap iommu: support for OMAP4

This patch provides the iommu support for OMAP4 co-processors.

Signed-off-by: Hari Kanigeri <h-kanigeri2@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
14 years agoomap iommu: renamed omap3-iommu to omap-iommu
Kanigeri, Hari [Thu, 22 Apr 2010 23:26:08 +0000 (23:26 +0000)]
omap iommu: renamed omap3-iommu to omap-iommu

This patch includes changes to omap3-iommu.c file to make it generic
for all OMAPs. Renamed omap3-iommu.c to omap-iommu.c

[Hiroshi DOYU: Remove unnecessary "iommu-y" in Makefile]

Signed-off-by: Hari Kanigeri <h-kanigeri2@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
14 years agoOMAP: GPIO: remove duplicate debugfs interface
Kevin Hilman [Mon, 14 Dec 2009 23:14:51 +0000 (15:14 -0800)]
OMAP: GPIO: remove duplicate debugfs interface

The generic gpiolib provides a debugfs interface to GPIOs which
provides identical (but nicer looking) data as the OMAP specific one.

This patch completely drops the OMAP specific interface
(/debug/omap_gpio) in favor of using the generic one (/debug/gpio.)

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: GPIO: Removed a couple of unneeded registers from context save/restore
Tero Kristo [Mon, 3 May 2010 22:53:57 +0000 (15:53 -0700)]
OMAP3: GPIO: Removed a couple of unneeded registers from context save/restore

setwkuena and setdataout are covered already by wake_en and dataout fields.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: GPIO: disable GPIO debounce clocks on idle
Kevin Hilman [Tue, 27 Jan 2009 19:15:34 +0000 (11:15 -0800)]
OMAP3: GPIO: disable GPIO debounce clocks on idle

Ensure GPIO debounce clocks are disabled when idle.  Otherwise,
clocks will prevent PER powerdomain from entering retention.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP2/3: GPIO: generalize prepare for idle
Kevin Hilman [Tue, 27 Jan 2009 19:09:24 +0000 (11:09 -0800)]
OMAP2/3: GPIO: generalize prepare for idle

Currently, the GPIO 'prepare' hook is only called when going to
off-mode, while the function is called 'prepare_for_retention.'  This
patch renames the function to 'prepare_for_idle' and calls it for any
powersate != PWRDM_POWER_ON passing in the powerstate.

The hook itself is then responsible for doing various preparation
based on the powerstate.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: GPIO: Only enable WAKEUPEN for edge detection GPIOs
Chunqiu Wang [Wed, 24 Jun 2009 17:13:39 +0000 (17:13 +0000)]
OMAP3: GPIO: Only enable WAKEUPEN for edge detection GPIOs

According to the GPIO 'Wakeup and Interrupt' section of the TRM[1],
wake-up requests can only be generated on edge transitions.

Also for OMAP3, only edge GPIOs may lose interrupts when PER enters
RET/OFF state, this is addressed by gpio prepare|resume idle functions

[1] Section 25.5.3.1 OMAP34xx_ES3.1_TRM_V_Q

Signed-off-by: Chunqiu Wang <cqwang@motorola.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: GPIO fixes for off-mode
Tero Kristo [Mon, 22 Dec 2008 12:27:12 +0000 (14:27 +0200)]
OMAP3: GPIO fixes for off-mode

Off mode is now using the omap2 retention fix code for scanning GPIOs
during off-mode transitions. All the *non_wakeup_gpios variables
are now used for off-mode transition tracking on OMAP3. This patch fixes
cases where GPIO state changes are missed during off-mode.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: PM: Remove PER wakeup dependency on CORE.
Mike Chan [Mon, 3 May 2010 23:04:07 +0000 (16:04 -0700)]
OMAP3: PM: Remove PER wakeup dependency on CORE.

We can remove this wakeup dependency since now, when
GPIO2-6 are enabled for IO-pad wakeup, PER domain is gauranteed
to be awake or be woken up to service.

The previous dependency did not handle all corner cases. Since there
was no sleep dependency between CORE and PER domains, if PER enters
RET and CORE is ON, PER will not be active for GPIO handling.

Signed-off-by: Mike Chan <mike@android.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: PM: Enable IO / IO-CHAIN wakeups for PER
Mike Chan [Mon, 3 May 2010 23:04:06 +0000 (16:04 -0700)]
OMAP3: PM: Enable IO / IO-CHAIN wakeups for PER

IO events can also come from GPIO modules, which reside in the PER domain.
It is possible for the PER to enter RET while CORE is still in ON.
If GPIO 2-6 are enabled for IO-pad wakeups, the PER domain will not
wakeup in this case, unless we enable it.

Signed-off-by: Mike Chan <mike@android.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: PM: Enable wakeup from ads7846 touchscreen
Ranjith Lohithakshan [Sat, 8 May 2010 07:09:21 +0000 (12:39 +0530)]
OMAP3: PM: Enable wakeup from ads7846 touchscreen

This  patch enables the wakeup capabilities of ads7846 touchscreen driver.
ads7846 driver can now wakeup the system from suspend on OMAP3430 EVM
and SDP boards.

The earlier approach of enabling wakeup on the touchscreen GPIO pin during
board level mux init is removed. Instead the wakeup flag in
ads7846_platform_data is enabled. Based on the flag, the ads7846 driver
will do an enable_irq_wake which will eventually call into the OMAP GPIO
layer and will enable the wakeup capability on the GPIO pin.

Signed-off-by: Ranjith Lohithakshan <ranjithl@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3EVM: Update pad configuration for wakeup enabled pads
Ranjith Lohithakshan [Mon, 3 May 2010 11:37:51 +0000 (17:07 +0530)]
OMAP3EVM: Update pad configuration for wakeup enabled pads

OMAP3530 TRM section 7.4.4.4.2 requires OFFOUTENABLE to be set (active low)
if wakeup capabilities are enabled on a pad. During OFF mode testing
on OMAP3530 EVM, it was observed that the device was not residing in
the OFF state. The device enters into the OFF state and immediately exits
from that state as if an IO wakeup event has occured. The issue was traced
down to the pad configuration of wkaeup enabled pad's.

Signed-off-by: Ranjith Lohithakshan <ranjithl@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: PM: Add milliseconds interface to suspend wakeup timer
Ari Kauppi [Tue, 23 Mar 2010 07:04:59 +0000 (09:04 +0200)]
OMAP3: PM: Add milliseconds interface to suspend wakeup timer

Millisecond resolution is possible and there are use cases for it
(automatic testing).

Seconds-based interface is preserved for compatibility.

Signed-off-by: Ari Kauppi <Ext-Ari.Kauppi@nokia.com>
Reviewed-by: Phil Carmody <ext-phil.2.carmody@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP3: PRCM interrupt: only check and clear enabled PRCM IRQs
Kevin Hilman [Mon, 26 Apr 2010 21:59:09 +0000 (14:59 -0700)]
OMAP3: PRCM interrupt: only check and clear enabled PRCM IRQs

While handling PRCM IRQs, mask out interrupts that are not enabled in
PRM_IRQENABLE_MPU.  If these are not masked out, non-enabled
interrupts are caught, a WARN() is printed due to no 'handler' and the
events are cleared.  In addition to being noisy, this can also
interfere with independent polling of this register by SR/VP code.

This was noticed using SmartReflex transitions which cause the VPx_*
interrupts to be handled since they are set in PRM_IRQSTATUS_MPU even
but not enabled in PRM_IRQENABLE_MPU.

Acked-by: Mike Turquette <mturquette@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
14 years agoOMAP2/3: Add V4L2 DSS driver support in device.c
Vaibhav Hiremath [Mon, 10 May 2010 21:29:14 +0000 (14:29 -0700)]
OMAP2/3: Add V4L2 DSS driver support in device.c

Add V4L2 DSS driver support in device.c

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
14 years agoLinux 2.6.34-rc7
Linus Torvalds [Mon, 10 May 2010 01:36:28 +0000 (18:36 -0700)]
Linux 2.6.34-rc7

14 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6
Linus Torvalds [Mon, 10 May 2010 01:35:53 +0000 (18:35 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
  [SCSI] Retry commands with UNIT_ATTENTION sense codes to fix ext3/ext4 I/O error
  [SCSI] Enable retries for SYNCRONIZE_CACHE commands to fix I/O error
  [SCSI] scsi_debug: virtual_gb ignores sector_size
  [SCSI] libiscsi: regression: fix header digest errors
  [SCSI] fix locking around blk_abort_request()
  [SCSI] advansys: fix narrow board error path

14 years agocpuidle: Fix incorrect optimization
Arjan van de Ven [Sat, 8 May 2010 22:47:37 +0000 (15:47 -0700)]
cpuidle: Fix incorrect optimization

commit 672917dcc78 ("cpuidle: menu governor: reduce latency on exit")
added an optimization, where the analysis on the past idle period moved
from the end of idle, to the beginning of the new idle.

Unfortunately, this optimization had a bug where it zeroed one key
variable for new use, that is needed for the analysis.  The fix is
simple, zero the variable after doing the work from the previous idle.

During the audit of the code that found this issue, another issue was
also found; the ->measured_us data structure member is never set, a
local variable is always used instead.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Cc: Corrado Zoccolo <czoccolo@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
14 years agoMerge branch 'for-linus' of git://neil.brown.name/md
Linus Torvalds [Fri, 7 May 2010 21:11:40 +0000 (14:11 -0700)]
Merge branch 'for-linus' of git://neil.brown.name/md

* 'for-linus' of git://neil.brown.name/md:
  md: restore ability of spare drives to spin down.
  md/raid6: Fix raid-6 read-error correction in degraded state

14 years agoMerge branch 'urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
Linus Torvalds [Fri, 7 May 2010 21:11:09 +0000 (14:11 -0700)]
Merge branch 'urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6

* 'urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6:
  pcmcia: fix compilation after 16bit state locking changes
  pcmcia: order userspace suspend and resume requests
  pcmcia: avoid pccard_validate_cis failure in resume callpath

14 years agoMerge branch 'for-linus' of git://git.kernel.dk/linux-2.6-block
Linus Torvalds [Fri, 7 May 2010 21:07:20 +0000 (14:07 -0700)]
Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-block

* 'for-linus' of git://git.kernel.dk/linux-2.6-block:
  blk-cgroup: Fix an RCU warning in blkiocg_create()
  blk-cgroup: Fix RCU correctness warning in cfq_init_queue()
  drbd: don't expose failed local READ to upper layers

14 years agoMerge branch 'drm-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied...
Linus Torvalds [Fri, 7 May 2010 21:02:01 +0000 (14:02 -0700)]
Merge branch 'drm-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6

* 'drm-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
  drm/ttm: Remove the ttm_bo_block_reservation() function.
  drm/ttm: Remove some leftover debug messages.
  drm/radeon: async event synchronization for drmWaitVblank

14 years agovirtio: initialize earlier
Stijn Tintel [Fri, 7 May 2010 04:58:34 +0000 (14:28 +0930)]
virtio: initialize earlier

Move initialization of the virtio framework before the initialization of
mtd, so that block2mtd can be used on virtio-based block devices.

Addresses https://bugzilla.kernel.org/show_bug.cgi?id=15644

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
14 years agoMerge branch 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6
Linus Torvalds [Fri, 7 May 2010 20:59:48 +0000 (13:59 -0700)]
Merge branch 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6

* 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6:
  NFS: Fix RCU issues in the NFSv4 delegation code
  NFSv4: Fix the locking in nfs_inode_reclaim_delegation()

14 years agoMerge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux...
Linus Torvalds [Fri, 7 May 2010 20:59:22 +0000 (13:59 -0700)]
Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6

* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
  ACPI: sleep: init_set_sci_en_on_resume for Dell Studio 155x
  ACPI: fix acpi_hest_firmware_first_pci() caused oops
  sbshc: acpi_device_class "smbus_host_controller" too long
  power_meter: acpi_device_class "power_meter_resource" too long
  acpi_pad: "processor_aggregator" name too long
  PNP: don't check for conflicts with bridge windows
  ACPI: DMI init_set_sci_en_on_resume for multiple Lenovo ThinkPads
  PNPACPI: compute Address Space length rather than using _LEN
  ACPI: silence kmemcheck false positive

14 years agoMerge branch 'v4l_for_2.6.34' of git://git.kernel.org/pub/scm/linux/kernel/git/mcheha...
Linus Torvalds [Fri, 7 May 2010 20:58:56 +0000 (13:58 -0700)]
Merge branch 'v4l_for_2.6.34' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6

* 'v4l_for_2.6.34' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6:
  V4L/DVB: pxa_camera: move fifo reset direct before dma start
  V4L/DVB: video: testing unsigned for less than 0
  V4L/DVB: mx1-camera: compile fix
  V4L/DVB: budget: Oops: "BUG: unable to handle kernel NULL pointer  dereference"
  V4L/DVB: ngene: Workaround for stuck DiSEqC pin
  V4L/DVB: saa7146: fix regression of the av7110/budget-av driver
  V4L/DVB: v4l: fix config dependencies: mxb and saa7191 are V4L2 drivers, not V4L1
  V4L/DVB: feature-removal: announce videotext.h removal
  V4L/DVB: V4L - vpfe capture - fix for kernel crash
  V4L/DVB: gspca: make usb id 0461:0815 get handled by the right driver
  V4L/DVB: gspca - stv06xx: Remove the 046d:08da from the stv06xx driver
  V4L/DVB: gspca - sn9c20x: Correct onstack wait_queue_head declaration
  V4L/DVB: saa7146: fix up bytesperline if it is an impossible value
  V4L/DVB: V4L: vpfe_capture - free ccdc_lock when memory allocation fails
  V4L/DVB: V4L - Makfile:Removed duplicate entry of davinci
  V4L/DVB: omap24xxcam: potential buffer overflow

14 years agoMerge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Fri, 7 May 2010 20:58:21 +0000 (13:58 -0700)]
Merge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  rcu: create rcu_my_thread_group_empty() wrapper
  memcg: css_id() must be called under rcu_read_lock()
  cgroup: Check task_lock in task_subsys_state()
  sched: Fix an RCU warning in print_task()
  cgroup: Fix an RCU warning in alloc_css_id()
  cgroup: Fix an RCU warning in cgroup_path()
  KEYS: Fix an RCU warning in the reading of user keys
  KEYS: Fix an RCU warning

14 years agomd: restore ability of spare drives to spin down.
NeilBrown [Fri, 7 May 2010 09:44:26 +0000 (19:44 +1000)]
md: restore ability of spare drives to spin down.

Some time ago we stopped the clean/active metadata updates
from being written to a 'spare' device in most cases so that
it could spin down and say spun down.  Device failure/removal
etc are still recorded on spares.

However commit 51d5668cb2e3fd1827a55 broke this 50% of the time,
depending on whether the event count is even or odd.
The change log entry said:

   This means that the alignment between 'odd/even' and
    'clean/dirty' might take a little longer to attain,

how ever the code makes no attempt to create that alignment, so it
could take arbitrarily long.

So when we find that clean/dirty is not aligned with odd/even,
force a second metadata-update immediately.  There are already cases
where a second metadata-update is needed immediately (e.g. when a
device fails during the metadata update).  We just piggy-back on that.

Reported-by: Joe Bryant <tenminjoe@yahoo.com>
Signed-off-by: NeilBrown <neilb@suse.de>
Cc: stable@kernel.org
14 years agomd/raid6: Fix raid-6 read-error correction in degraded state
Gabriele A. Trombetti [Wed, 28 Apr 2010 01:51:17 +0000 (11:51 +1000)]
md/raid6: Fix raid-6 read-error correction in degraded state

Fix: Raid-6 was not trying to correct a read-error when in
singly-degraded state and was instead dropping one more device, going to
doubly-degraded state. This patch fixes this behaviour.

Tested-by: Janos Haar <janos.haar@netcenter.hu>
Signed-off-by: Gabriele A. Trombetti <g.trombetti.lkrnl1213@logicschema.com>
Reported-by: Janos Haar <janos.haar@netcenter.hu>
Signed-off-by: NeilBrown <neilb@suse.de>
Cc: stable@kernel.org
14 years agoblk-cgroup: Fix an RCU warning in blkiocg_create()
Li Zefan [Fri, 7 May 2010 06:57:00 +0000 (08:57 +0200)]
blk-cgroup: Fix an RCU warning in blkiocg_create()

with CONFIG_PROVE_RCU=y, a warning can be triggered:

  # mount -t cgroup -o blkio xxx /mnt
  # mkdir /mnt/subgroup

...
kernel/cgroup.c:4442 invoked rcu_dereference_check() without protection!
...

To fix this, we avoid caling css_depth() here, which is a bit simpler
than the original code.

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Acked-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
14 years agoMerge branches 'bugzilla-14337', 'bugzilla-14998', 'bugzilla-15407', 'bugzilla-15903...
Len Brown [Fri, 7 May 2010 02:04:31 +0000 (22:04 -0400)]
Merge branches 'bugzilla-14337', 'bugzilla-14998', 'bugzilla-15407', 'bugzilla-15903' and 'misc-2.6.34' into release

14 years agodrm/ttm: Remove the ttm_bo_block_reservation() function.
Thomas Hellstrom [Wed, 28 Apr 2010 09:33:25 +0000 (11:33 +0200)]
drm/ttm: Remove the ttm_bo_block_reservation() function.

It's unused and buggy in its current form, since it can place a bo
in the reserved state without removing it from lru lists.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agodrm/ttm: Remove some leftover debug messages.
Thomas Hellstrom [Wed, 28 Apr 2010 09:33:24 +0000 (11:33 +0200)]
drm/ttm: Remove some leftover debug messages.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agodrm/radeon: async event synchronization for drmWaitVblank
Jerome Glisse [Thu, 6 May 2010 16:52:14 +0000 (18:52 +0200)]
drm/radeon: async event synchronization for drmWaitVblank

Bring radeon up to speed with the async event synchronization for
drmWaitVblank. See c9a9c5e02aedc1a2815877b0268f886d2640b771 for
more information. Without this patch event never get delivered
to userspace client.

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>