Commit Graph

7609 Commits

Author SHA1 Message Date
Russell King
2f68ffd11a Merge branch 'arm/clock-event' of git://git.pengutronix.de/git/ukl/linux-2.6 into devel-stable 2010-02-15 21:20:33 +00:00
Russell King
56012808f4 Merge branch 'for-rmk' of git://git.marvell.com/orion into devel-stable
Conflicts:
	arch/arm/Makefile
2010-02-15 21:20:18 +00:00
Uwe Kleine-König
f0d3ab4911 arm/mx2: define seperate imx_nand devices for imx21 and imx27
As the NFC controller has different addresses on imx21 and imx27 there
are two different devices needed if not relying on the overloaded cpp
macro NFC_BASE_ADDR.  So some cpp magic is added to minimize code
duplication.

As obviously these two defines need different names, the name of the old
device is #defined to the new one when building for only one of imx21 or
imx27.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-15 17:03:55 +01:00
Kuninori Morimoto
deded43508 ARM: mach-shmobile: intc-sh7372 tidyup
This patch is based on Rev 0.5 manual

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-15 13:43:43 +09:00
NISHIMOTO Hiroki
aa18ef609b ARM: mach-shmobile: G4EVM USBHS support
Add G4EVM platform data and a magic setup sequence to
initialize the r8a66597 block aka USBHS in sh7377.

Signed-off-by: NISHIMOTO Hiroki <nishimoto.hiroki@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-15 13:43:41 +09:00
NISHIMOTO Hiroki
276b4f623c ARM: mach-shmobile: sh7377 and G4EVM pinmux support
Add support for the sh 7377 pinmux using drivers/sh/pfc.c
and some LEDs on G4EVM.

Signed-off-by: NISHIMOTO Hiroki <nishimoto.hiroki@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-15 13:43:37 +09:00
Magnus Damm
3a7b802d1a ARM: mach-shmobile: G3EVM USBHS support
Add G3EVM platform data and a magic setup sequence to
initialize the r8a66597 block aka USBHS in sh7367.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-12 14:10:48 +09:00
Magnus Damm
7fdda6780a ARM: mach-shmobile: sh7367 and G3EVM pinmux support
Add support for the sh7367 pinmux using drivers/sh/pfc.c
and select serial console pins and some LEDs on G3EVM.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-12 14:10:47 +09:00
Aaro Koskinen
a6c7fdd293 OMAP: hsmmc: fix memory leak
The platform data allocated with kmalloc() will become unreachable once
the init is complete, so it should be freed. The problem was discovered
by kmemleak.

Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com>
Acked-by: Adrian Hunter <adrian.hunter@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-10 09:20:33 -08:00
Laurie Bradshaw
b2a731aa5c [ARM] orion5x: D-link DNS-323 revision A1 power LED
This patch fixes the power LED on DNS-323 revision A1, and adds timer
support for (hopefully) both A1 and B1 revisions.

Power LED on revision A1 is active low and also requires GPIO 4 to be
low to work.

Tested on my DNS-323 revision A1.

I have set the default trigger to timer as that replicates the
behaviour of the original firmware, userspace can change the trigger
at the end of the boot process providing a useful indication that
booting has completed.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-10 11:31:30 -05:00
Valentin Longchamp
e335c75cf3 mx31moboard: support for the smartbot baseboard
This baseboard is used on the handbot and eybot robots.

The sel gpios are used as enables and rst signals on smartbot, thus the
sel init is moved from mx31moboard file to board files.

Signed-off-by: Valentin Longchamp <valentin.longchamp@epfl.ch>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-10 11:11:56 +01:00
Valentin Longchamp
cda82f85c2 mx31moboard: make usbh2 enable gpio claim more atomic
It is more cosmetic than fixing a real problem, but the code looks
more logical like that

Signed-off-by: Valentin Longchamp <valentin.longchamp@epfl.ch>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-10 11:11:56 +01:00
Valentin Longchamp
f8594c283e mx31moboard: change initial reset status for robot microcontollers
We want the microcontrollers to be held in reset during kernel boot.

We also set the turretcam as the default camera since it is present on all
marxbots.

Signed-off-by: Valentin Longchamp <valentin.longchamp@epfl.ch>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-10 11:11:55 +01:00
Sascha Hauer
fed9b63ca5 Merge branch 'mx51-baseport-sascha' of git://kernel.ubuntu.com/amitk/mx51-upstream into mxc-master 2010-02-10 11:11:37 +01:00
Sascha Hauer
d2831d1f54 i.MX pcm043: Add AC97 sound support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-10 11:05:23 +01:00
Sascha Hauer
c8a6885f21 pca100: add sound support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-10 11:05:18 +01:00
Sascha Hauer
d9e557e5cb add ssi header file
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-10 11:05:13 +01:00
Simon Guinot
1afeea84bd [ARM] Kirkwood: define SATA LED for netspace_v2
This patch add a GPIO LED named "ns_v2:blue:sata" which can be used to
enable or disable SATA activity LED blinking.

Signed-off-by: Simon Guinot <sguinot@lacie.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-09 21:05:49 -05:00
Simon Guinot
ca9cea9399 [ARM] Kirkwood: add LaCie Internet Space v2 support
The Internet and Network Space v2 boards are very close. The only
difference is that there is no USB type B plug wired on the Internet
Space v2.

Signed-off-by: Simon Guinot <sguinot@lacie.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-09 20:54:49 -05:00
Simon Guinot
7a15726cb4 [ARM] Orion5x: enable SATA LED blinking for d2net
Signed-off-by: Simon Guinot <sguinot@lacie.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-09 20:49:01 -05:00
Simon Guinot
d74b96a73a [ARM] Orion5x: set valid GPIO inhibit power-off for d2net
This patch allow user-space to configure the switch power-off behaviour
via the gpiolib sysfs interface.

Signed-off-by: Simon Guinot <sguinot@lacie.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-09 20:45:04 -05:00
Amit Kucheria
51c23a04c3 mxc: Add mx51_defconfig
This config is used to test the base support for i.MX51 processors on the
Babbage board

Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
2010-02-09 18:32:18 +02:00
Amit Kucheria
b996b58303 mxc: Add support for the Babbage board (i.MX5)
Babbage is a reference board from Freescale for their i.MX51 SoC.

Add board definition, Kconfig and Makefiles to enable Freescale i.MX51
processor and Babbage board.

Boot tested on a Babbage2.5 board

Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
2010-02-09 18:32:17 +02:00
Amit Kucheria
a329b48c43 mxc: Core support for Freescale i.MX5 series
Add basic clock support, cpu identification, I/O mapping, interrupt
controller, serial port and ethernet.

Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
2010-02-09 18:32:16 +02:00
Amit Kucheria
438caa3f6c mxc: changes to common plat-mxc code to add support for i.MX5
Prepare for i.MX5 SoC code by adding the relevant macros to common plat-mxc
code.

Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
2010-02-09 18:32:10 +02:00
Sascha Hauer
0f3332c4fa mxc: refactor timer code to use timer versions
Refactor the timer code into version 1 and version 2.

Essentially there are 2 versions of the timer hardware on Freescale MXC
hardware. Version 1 is found on MX1/MXL, MX21 and MX27. Version 2 is found on
MX25, MX31, MX35, MX37, MX51, and future parts.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
2010-02-09 16:15:26 +02:00
Amit Kucheria
a003708ad4 mxc: TrustZone interrupt controller (TZIC) for Freescale i.MX5 family
Freescale i.MX51 processor uses a new interrupt controller. Add
driver for TrustZone Interrupt Controller

Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
2010-02-09 16:15:26 +02:00
Magnus Damm
e4e430c611 ARM: mach-shmobile: sh7372 INTCA support
Add support for the sh7372 INTCA hardware block.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-09 18:01:46 +09:00
Magnus Damm
6673be7380 ARM: mach-shmobile: sh7377 INTCA support
Add support for the sh7377 INTCA hardware block.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-09 18:01:44 +09:00
Magnus Damm
f8eef1305b ARM: mach-shmobile: sh7367 INTCA support
Add support for the sh7367 INTCA hardware block.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-09 18:01:42 +09:00
Magnus Damm
4ae04acb81 ARM: mach-shmobile: early console support using earlyprintk
Add support for early console to the SH-Mobile boards.

Simply perform an early platform probe for "earlyprintk"
to trigger the early serial console code in sh-sci.c.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-09 10:34:12 +09:00
Magnus Damm
62f60d6a37 ARM: mach-shmobile: optimize get_irqnr_preamble/and_base macros
Optimize the SH-Mobile interrupt assembly macros to avoid
reloading the INTFLGA register address in case of multiple
pending interrupts. Kindly pointed out by Russell King.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-09 10:31:11 +09:00
Uwe Kleine-König
58152a1690 arm/mx2/devices: use SoC-prefixed names where possible
There is only NFC_BASE_ADDR left which is defined differently for mx21
and mx27.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-08 11:47:03 +01:00
Uwe Kleine-König
69ddb48803 arm/mx2: use cpp magic to create imx-ssi devices
This makes the source shorter and easier to verify.  While at it switch
to use the SoC-prefixed constants.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-08 11:47:03 +01:00
Uwe Kleine-König
ccd0e42c82 arm/mx2: use cpp magic to create imx-mmc devices
This makes the source shorter and easier to verify.  While at it switch
to use the SoC-prefixed constants.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-08 11:47:02 +01:00
Uwe Kleine-König
9309b2ba54 arm/mx2: use cpp magic to create imx-i2c devices
This makes the source shorter and easier to verify.  While at it switch
to use the SoC-prefixed constants.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-08 11:47:01 +01:00
Uwe Kleine-König
2b84a3640f arm/mx2: use cpp magic to create imx_gpt devices
This makes the source shorter and easier to verify.  While at it switch
to use the SoC-prefixed constants.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-08 11:47:00 +01:00
Uwe Kleine-König
68c94b40b3 arm/mx2: use cpp magic to create spi_imx devices
This makes the source shorter and easier to verify.  While at it switch
to use the SoC-prefixed constants.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-08 11:47:00 +01:00
Magnus Damm
34bf0fc54a ARM: mach-shmobile: G3EVM, G4EVM and AP4EVB defconfigs
Add defconfigs for G3EVM, G4EVM and AP4EVB.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-08 12:54:19 +09:00
Magnus Damm
2b7eda63e4 ARM: mach-shmobile: SH-Mobile AP4 support.
This adds preliminary support for the SH7372 (SH-Mobile AP4) CPU and
the AP4EVB reference board.

Only timer, serial console and NOR flash are supported at this point.
Support for the interrupt controller, pinmux support, clock framework
and runtime pm will be submitted as feature patches on top of this.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-08 12:45:36 +09:00
Magnus Damm
f2aaf66df0 ARM: mach-shmobile: SH-Mobile G4 support.
This adds preliminary support for the SH7377 (SH-Mobile G4) CPU and
the G4EVM reference board.

Only timer, serial console and NOR flash are supported at this point.
Support for the interrupt controller, pinmux support, clock framework
and runtime pm will be submitted as feature patches on top of this.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-08 12:45:32 +09:00
Magnus Damm
c793c1b0c8 ARM: mach-shmobile: SH-Mobile G3 support.
This adds preliminary support for the SH-Mobile G-series.

The SH-Mobile G-series is a series of ARM/SH multi-core CPUs that aside
from the ARM MPU are primarily composed of existing SH IP blocks.

This includes initial support for the SH7367 (SH-Mobile G3) CPU and
the G3EVM reference board.

Only timer, serial console, and NOR flash are supported at this point.
Patches for the interrupt controller, pinmux support, clock framework
and runtime pm will be submitted as feature patches on top of this.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-08 12:44:11 +09:00
Nicolas Pitre
e233230f9c [ARM] orion5x: update defconfig
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-05 00:28:36 -05:00
Nicolas Pitre
f123560a07 [ARM] Kirkwood: update defconfig
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-05 00:27:08 -05:00
Nicolas Pitre
1961528959 [ARM] orion5x: fix some improper includes in Linkstation files
... and replace misuse of arch_reset() with arm_machine_restart().

Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-05 00:27:07 -05:00
Zhu Qingsen
2d18638ec0 [ARM] Orion: Add Buffalo Linkstation LS-HGL support
Signed-off-by: Zhu Qingsen <zhuqs@cn.fujitsu.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-05 00:27:06 -05:00
Alexander Clouter
b2fdb5660f [ARM] kirkwood: combine support for openrd base/client support
Inspired by the mach-ep93xx flattening work, there is really not
much difference between the OpenRD base and client board support
so they should be merged together.

Signed-off-by: Alexander Clouter <alex@digriz.org.uk>
Acked-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: Nicolas Pitre <nico@fluxnic.net>
2010-02-05 00:27:04 -05:00
H Hartley Sweeten
639b9be60e mach-dove/common.c: remove unnecessary (void *) casts
The (void *) cast is not needed when setting dev.platform_data to the
address of the data. Remove the casts.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-05 00:27:03 -05:00
H Hartley Sweeten
3e3e65fc42 mach-kirkwood/common.c: remove unnecessary (void *) casts
The (void *) cast is not needed when setting dev.platform_data to the
address of the data. Remove the casts.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-04 21:29:27 -05:00
H Hartley Sweeten
ef4a6777cf mach-orion5x/common.c: remove unnecessary (void *) casts
The (void *) cast is not needed when setting dev.platform_data to the
address of the data. Remove the casts.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-04 21:10:54 -05:00
Linus Torvalds
fc76be434d Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
  ARM: Fix wrong register in proc-arm6_7.S data abort handler
  ARM: 5909/1: ARM: Correct the FPSCR bits setting when raising exceptions
  ARM: 5904/1: ARM: Always generate the IT instruction when compiling for Thumb-2
  ARM: 5907/1: ARM: Fix the reset on the RealView PBX Development board
  mx35: add a missing comma in a pad definition
  mx25: make the FEC AHB clk secondary of the IPG
  mx25: fix time accounting
  mx25: properly initialize clocks
  mx25: remove unused mx25_clocks_init() argument
  i.MX25: implement secondary clocks for uarts and fec
  i.MX25: Allow secondary clocks in DEFINE_CLOCK
  ARM: MX3: Fixed typo in declared enum type name.
  MXC: Add AUDMUXv2 register decode to debugfs
  mx31ads: Provide an IRQ range to the WM835x on the 1133-EV1 module
  mx31ads: Provide a name for EXPIO interrupt chip
  mx31ads: Allow enable/disable of switchable supplies
2010-02-04 16:09:01 -08:00
Sascha Hauer
cb2dc111b1 i.MX27 pca100: Add USB support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-04 21:28:12 +01:00
Sascha Hauer
ee14373cdc i.MX31 pcm037: Add USB support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-04 21:28:06 +01:00
Sascha Hauer
773f206b2f i.MX27 pcm038: Add USB support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-04 17:29:35 +01:00
Sascha Hauer
eee7c497d2 i.MX27 pca100: Add USB support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-04 17:29:34 +01:00
Sascha Hauer
d186f04c17 i.MX35: Add USB control register access support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Cc: Daniel Mack <daniel@caiaq.de>
2010-02-04 17:29:30 +01:00
Sascha Hauer
9cf945cbef i.MX27: Add USB control register access support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Cc: Daniel Mack <daniel@caiaq.de>
2010-02-04 15:56:34 +01:00
Sascha Hauer
84ab80616b i.MX ehci platform support: Some fixes
- The SIC mask is only 2bits wide, not 4
- MX31_OTG_PM_BIT and MX31_H1_PM_BIT use negative logic
- clear MX31_H1_DT_BIT and MX31_H2_DT_BIT so that they can be cleared,
  not only set.
- return -EINVAL if called with an invalid controller number

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Cc: Daniel Mack <daniel@caiaq.de>
2010-02-04 15:56:34 +01:00
Sascha Hauer
9fd96bbb6a Merge branch 'imx/master' of git://git.pengutronix.de/git/ukl/linux-2.6 into mxc-master 2010-02-04 11:18:09 +01:00
Roel Kluin
5c17ef878f MX1/MX2: -EINVAL overwritten in second iteration in mxc_gpio_setup_multiple_pins()
Due to the `ret = gpio_request()' below in the loop, the initial -EINVAL value
of ret is overwritten.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-04 09:33:10 +01:00
Tony Lindgren
301fe8eeee omap: Disable serial port autoidle by default
Currently the omap serial clocks are autoidled after 5 seconds.
However, this causes lost characters on the serial ports. As this
is considered non-standard behaviour for Linux, disable the timeout.

Note that this will also cause blocking of any deeper omap sleep
states.

To enable the autoidling of the serial ports, do something like
this for each serial port:

# echo 5 > /sys/devices/platform/serial8250.0/sleep_timeout
# echo 5 > /sys/devices/platform/serial8250.1/sleep_timeout
...

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Marek Skuczynski
0825cc8a6f omap: Fix access to already released memory in clk_debugfs_register_one()
I have found an access to already released memory in
clk_debugfs_register_one() function.

Signed-off-by: Marek Skuczynski <mareksk7@gmail.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Tony Lindgren
78737ae1b0 omap: Fix arch/arm/mach-omap2/mux.c: Off by one error
David Binderman ran the sourceforge tool cppcheck over the source code of the
new Linux kernel 2.6.33-rc6:

[./arm/mach-omap2/mux.c:492]: (error) Buffer access out-of-bounds

13 characters + 1 digit + 1 zero byte is more than 14 characters.

Also add a comment on mode0 name length in case new omaps
start using longer names.

Reported-by: David Binderman <dcb314@hotmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Tony Lindgren
9ecef43320 omap: Fix 3630 mux errors
3630 has more mux signals than 34xx. The additional pins
exist in omap36xx_cbp_subset, but are not initialized
as the superset is missing these offsets. This causes
the following errors during the boot:

mux: Unknown entry offset 0x236
mux: Unknown entry offset 0x22e
mux: Unknown entry offset 0x1ec
mux: Unknown entry offset 0x1ee
mux: Unknown entry offset 0x1f4
mux: Unknown entry offset 0x1f6
mux: Unknown entry offset 0x1f8
mux: Unknown entry offset 0x1fa
mux: Unknown entry offset 0x1fc
mux: Unknown entry offset 0x22a
mux: Unknown entry offset 0x226
mux: Unknown entry offset 0x230
mux: Unknown entry offset 0x22c
mux: Unknown entry offset 0x228

Fix this by adding the missing offsets to omap3 superset.
Note that additionally the uninitialized pins need to be
skipped on 34xx.

Based on an earlier patch by Allen Pais <allen.pais@ti.com>.

Reported-by: Allen Pais <allen.pais@ti.com>
Signed-off-by: Allen Pais <allen.pais@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Kevin Hilman
8d08436d78 OMAP2/3: GPMC: ensure valid clock pointer
Ensure valid clock pointer during GPMC init.  Fixes compiler
warning about potential use of uninitialized variable.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Kevin Hilman
74005a2b11 OMAP2/3: IRQ: ensure valid base address
Ensure valid base address during IRQ init.  Fixes compiler warning
about potential use of uninitialized variable.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Sriram
9af915da20 ARCH OMAP : enable ARCH_HAS_HOLES_MEMORYMODEL for OMAP
OMAP platforms(like OMAP3530) include DSP or other co-processors
for media acceleration. when carving out memory for the
accelerators we can end up creating a hole in the memory map
of sort:
<kernel memory><hole(memory for accelerator)><kernel memory>

To handle such a memory configuration ARCH_HAS_HOLES_MEMORYMODEL
has to be enabled. For further information refer discussion at:
http://www.mail-archive.com/linux-omap@vger.kernel.org/msg15262.html.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Tony Lindgren
faccbcfb63 omap: Remove old unused defines for OMAP_32KSYNCT_BASE
Remove old unused defines for OMAP_32KSYNCT_BASE

Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-03 08:48:06 -08:00
Russell King
4aba098c8d ARM: Fix wrong register in proc-arm6_7.S data abort handler
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-03 15:48:03 +00:00
Uwe Kleine-König
e27bf72465 imx/mx25: rename files defining a machine to mach-$mach.c
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-02 09:08:03 +01:00
Uwe Kleine-König
34101237d9 imx: define per SOC ..._PHYS_OFFSET and use these in favour of PHYS_OFFSET
This is a further step in allowing to build a kernel image for more
than one imx SOC.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-02 09:07:59 +01:00
Uwe Kleine-König
7fc06d8c24 imx2x: convert serial.c to use soc-prefixed constants
This makes the file compilable for a kernel that supports both imx21 and
imx27.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-02 09:07:58 +01:00
Uwe Kleine-König
08f9bf167c mxc91231: redefine MXC91231_IO_ADDRESS using IMX_IO_ADDRESS
This simplifies the macro and makes is similar to the other
..._IO_ADDRESS macros defined for imx SOCs.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-02 09:07:56 +01:00
Uwe Kleine-König
9ea07ec05e mxc91231: use MXC91231_IO_ADDRESS instead of MXC91231_AIPS1_IO_ADDRESS
Apart from MXC91231_IO_ADDRESS itself this was the only usage of
MXC91231_AIPS1_IO_ADDRESS.  Now MXC91231_IO_ADDRESS can be recoded with
IMX_IO_ADDRESS and all helper macros can go away.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Cc: Sascha Hauer <kernel@pengutronix.de>
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Daniel Schaeffer <daniel.schaeffer@timesys.com>
Cc: Alberto Panizzo <maramaopercheseimorto@gmail.com>
Cc: Ivo Clarysse <ivo.clarysse@gmail.com>
2010-02-02 09:07:55 +01:00
Uwe Kleine-König
8ac5b7c5ec imx: WARN in clk_disable if the clock isn't enabled
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Cc: Sascha Hauer <kernel@pengutronix.de>
Cc: Russell King <linux@arm.linux.org.uk>
2010-02-02 09:07:11 +01:00
Russell King
0b7d5170dc Merge branch 'for-rmk' of git://git.pengutronix.de/git/imx/linux-2.6 2010-02-01 20:06:40 +00:00
Catalin Marinas
dbead40580 ARM: 5909/1: ARM: Correct the FPSCR bits setting when raising exceptions
Commit c98929c07a removed the clearing of the FPSCR[31:28] bits from the
vfp_raise_exceptions() function and the new bits are or'ed with the old
FPSCR bits leading to unexpected results (the original commit was
referring to the cumulative bits - FPSCR[4:0]).

Reported-by: Tom Hameenanttila <tmhameen@marvell.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-01 20:05:09 +00:00
Catalin Marinas
c540b9ff0f ARM: 5904/1: ARM: Always generate the IT instruction when compiling for Thumb-2
Current behaviour is to generate the IT instruction only for Thumb-2
code. However, the kernel helpers in entry-armv.S are compiled to ARM in
a unified syntax file (if THUMB2_KERNEL). Recent compilers warn about
missing IT instruction in unified assembly syntax files. The patch
changes the "-mimplicit-it" gas option to "always".

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-01-30 16:13:23 +00:00
Colin Tuckley
df2e615a3b ARM: 5907/1: ARM: Fix the reset on the RealView PBX Development board
Signed-off-by: Colin Tuckley <colin.tuckley@arm.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-01-30 16:12:40 +00:00
Uwe Kleine-König
66ac2f28b6 mx25: deprecate UART1_BASE_ADDR and UART2_BASE_ADDR
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-01-30 13:34:11 +01:00
Uwe Kleine-König
7d58289fc3 mx1: prefix SOC specific defines with MX1_ and deprecate old names
The old names are defined only if the cpp symbol
IMX_NEEDS_DEPRECATED_SYMBOLS exists, which is defined (for now) for all
files below arch/arm/mach-mx1.

This was done earlier for mx2 and mx3, too.

USBD_INT0 is for now defined unconditionally to prevent breaking
drivers/usb/gadget/imx_udc.

While at it use IMX_IO_ADDRESS to define MX1_IO_ADDRESS which
adds a cast to the IO_ADDRESS macro fixing many warnings like

	arch/arm/mach-mx1/generic.c:51: warning: passing argument 1 of 'mxc_init_irq' makes pointer from integer without a cast

.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-01-30 13:34:01 +01:00
Uwe Kleine-König
9198bcd39f omap: define _toggle_gpio_edge_triggering only for OMAP1
The only usage of _toggle_gpio_edge_triggering is in
an #ifdef CONFIG_ARCH_OMAP1 block, so only provide it if
CONFIG_ARCH_OMAP1 is defined, too.

This fixes a compiler warning:

	arch/arm/plat-omap/gpio.c:758: warning: '_toggle_gpio_edge_triggering' defined but not used

when compiling for ARCH_OMAP2, ARCH_OMAP3 or ARCH_OMAP4.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-01-29 14:20:05 -08:00
Baruch Siach
1eaa4f2762 mx25pdk: platform code for the DryIce RTC module
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-29 10:43:21 +01:00
Baruch Siach
dcbabbc1fc mx25: add support for the DryIce rtc
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-29 10:43:21 +01:00
Sascha Hauer
4cb73288b1 Merge branch 'mxc-rc' into mxc-master 2010-01-29 10:43:17 +01:00
Uwe Kleine-König
66ddfc62ca mx35: add a missing comma in a pad definition
Reported-by: Tim Sander <tstone@vlsi.informatik.tu-darmstadt.de>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-29 09:36:56 +01:00
Russell King
ba45d52574 [ARM] Update mach-types
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-01-28 22:17:45 +00:00
Russell King
0b6c135ea9 Merge branch 'fix' of git://git.kernel.org/pub/scm/linux/kernel/git/ycmiao/pxa-linux-2.6 2010-01-28 21:59:58 +00:00
Russell King
00e4acb1e2 Merge branch 'for-rmk' of git://git.marvell.com/orion 2010-01-27 22:16:05 +00:00
Russell King
a814290e17 Merge branch 'for-rmk/samsung3' of git://git.fluff.org/bjdooks/linux into devel-stable 2010-01-27 22:11:32 +00:00
Vladimir Zapolskiy
70c91a3849 ARM: IMX31: configure pins iomux for SDHC setup on litekit board.
This patch adds SDHC support, and corrects current pins setup.
Added irq handling on card removal.

Signed-off-by: Vladimir Zapolskiy <vzapolskiy@gmail.com>
Cc: Daniel Mack <daniel@caiaq.de>
Cc: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:56:54 +01:00
Uwe Kleine-König
4e41db871e mx2/mx3: debug-macro.S needs deprecated symbols
This fixes:

	arch/arm/kernel/debug.S:147: Error: constant expression expected -- `ldrne r3,=(((UART1_BASE_ADDR)-AIPI_BASE_ADDR)+AIPI_BASE_ADDR_VIRT)'
	arch/arm/kernel/debug.S:163: Error: constant expression expected -- `ldrne r3,=(((UART1_BASE_ADDR)-AIPI_BASE_ADDR)+AIPI_BASE_ADDR_VIRT)'

when compiling for mx2 with CONFIG_DEBUG_LL=y.  A similar error exists
on mx3 and is fixed by this commit, too.

These were introduced by aae7019382.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:55:52 +01:00
Baruch Siach
1c57402374 mx25: make the FEC AHB clk secondary of the IPG
This makes the FEC clock configuration consistent with the UART one.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:54:41 +01:00
Baruch Siach
faed40665d mx25: fix time accounting
The gpt_clk rate function doesn't consider the PER divider. This causes a
significant drift in time accounting. Fix this by introducing the correct rate
calculation function.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:54:06 +01:00
Baruch Siach
828df43f13 mx25: properly initialize clocks
This patch disables all unnecessary clock in mx25_clocks_init() to make a clean
start, the same as is being done for the rest of the i.MX chips.

This patch was tested on i.MX25 PDK.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:54:06 +01:00
Baruch Siach
fadc095622 mx25: remove unused mx25_clocks_init() argument
The fref is needless on mx25 since the reference clock is fixed at 24MHz.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:54:06 +01:00
Sascha Hauer
4cd3f96cd4 i.MX25: implement secondary clocks for uarts and fec
For uarts and fec need two clocks, implement it using the secondary clock
field in struct clk.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:52:45 +01:00
Sascha Hauer
9611a9b6f6 i.MX25: Allow secondary clocks in DEFINE_CLOCK
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-26 18:52:40 +01:00
Linus Torvalds
4f4e65d248 Merge branch 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6
* 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6: (25 commits)
  OMAP2/3: DMTIMER: Clear pending interrupts when stopping a timer
  PM debug: Fix warning when no CONFIG_DEBUG_FS
  OMAP3: PM: DSS PM_WKEN to refill DMA
  OMAP: timekeeping: time should not stop during suspend
  OMAP3: PM: Force write last pad config register into save area
  OMAP: omap3_pm_get_suspend_state() error ignored in pwrdm_suspend_get()
  OMAP3: PM: Enable wake-up from McBSP2, 3 and 4 modules
  OMAP3: PM debug: fix build error when !CONFIG_DEBUG_FS
  OMAP3: PM: Removing redundant and potentially dangerous PRCM configration
  OMAP3: Fixed ARM aux ctrl register save/restore
  OMAP3: CPUidle: Fixed timer resolution
  OMAP3: PM: Remove duplicate code blocks
  OMAP3: PM: Disable interrupt controller AUTOIDLE before WFI
  OMAP3: PM: Enable system control module autoidle
  OMAP3: PM: Ack pending interrupts before entering suspend
  omap: Enable GPMC clock in gpmc_init
  OMAP1 clock: fix for "BUG: spinlock lockup on CPU#0"
  OMAP4: clocks: Fix the clksel_rate struct DPLL divs
  OMAP4: PRCM: Fix the base address for CHIRONSS reg defines
  OMAP: dma_chan[lch_head].flag & OMAP_DMA_ACTIVE tested twice in omap_dma_unlink_lch()
  ...
2010-01-25 18:56:12 -08:00
Ben Dooks
ab5d97db1c ARM: SAMSUNG: Fix bad use of __initdata for s3c_register_clocks()
Functions should be marked __init, not __initdata.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-26 09:50:04 +09:00
Maurus Cuelenaere
f6b56704f7 ARM: SAMSUNG: Fix null pointer dereference in ADC driver
ARM: SAMSUNG: Fix null pointer dereference in ADC driver

Use struct adc_device instead of relying on client (which could be
NULL) when checking for SoC type.

Signed-off-by: Maurus Cuelenaere <mcuelenaere@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-26 09:50:03 +09:00
Thomas Abraham
d85127319c ARM: S5PV210: Add serial port support
This patch adds UART serial port support for S5PV210.

Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-26 09:50:01 +09:00
Erik Benada
cf11052a95 [ARM] orion5x: D-link DNS-323 rev. B1 power-off
This patch fixes power LED blinking and power-off on DNS-323 rev. B1.

GPIO pin 3 has to be set to 1 to stop power LED blinking and to allow the LED to be controlled via leds-gpio. This pin has to be also set to 1 for power-off to work.
To power-off the rev. B1 machine, pin 8 has to be set to 1 and then set to 0 to do actual power-off.

Tested on my DNS-323 rev. B1

Signed-off-by: Erik Benada <erikbenada@yahoo.ca>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-01-24 22:17:51 -05:00
Uwe Kleine-König
a602f0f2f0 arm/{pxa,sa1100,nomadik}: Don't disable irqs in set_next_event and set_mode
These functions are called with irqs already off.  This commit removes
the calls to raw_local_irq_save and raw_local_irq_restore on platforms
that don't have to use a shared interrupt for their timekeeping.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-01-22 17:04:52 +01:00
Uwe Kleine-König
501d70383a arm/at91: Don't disable irqs in set_next_event and set_mode callbacks
on AT91 the timer irq is shared, so the handler might be entered without
irqs being disabled.  Though this should not happen as the timer irq is
registered early, there have been some reports on the mailing list.

To make debugging that problem easier next time it pops up a
WARN_ON_ONCE is added to the handler if irqs are not off.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-01-22 17:04:39 +01:00
Tero Kristo
5c3db36bf6 OMAP2/3: DMTIMER: Clear pending interrupts when stopping a timer
OMAP GP timers keep running for a few cycles after they are stopped,
which can cause the timer to expire and generate an interrupt. The
pending interrupt will prevent e.g. OMAP from entering suspend, thus
we ack it manually.  Only applicable on OMAP2/3/4.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-01-21 18:30:10 -08:00
Linus Torvalds
298a4c3a57 Merge branch 'for-linus/samsung' of git://git.fluff.org/bjdooks/linux
* 'for-linus/samsung' of git://git.fluff.org/bjdooks/linux:
  hmt: adjust for new pwm_backlight->notify prototype
2010-01-21 17:33:23 -08:00
Peter Korsgaard
1619ce1114 hmt: adjust for new pwm_backlight->notify prototype
Commit cfc38999f (backlight: Pass device through notify callback)
added a struct device argument to the notify callback, but didn't
update the user of it in mach-hmt.c

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-22 09:58:17 +09:00
Linus Torvalds
def2052922 Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
  ARM: 5888/1: arm: Update comments in cacheflush.h and remove unnecessary V6 and V7 comments
  ARM: 5886/1: arm: Fix cpu_proc_fin() for proc-v7.S and make kexec work
  ARM: 5885/1: arm: Flush TLB entries in setup_mm_for_reboot()
  ARM: 5884/1: arm: Fix DCC console for v7
  ARM: 5883/1: Revert "disable NX support for OABI-supporting kernels"
  ARM: 5882/1: ARM: Fix uncompress code compile for different defines of flush(void)
  ARM: fix badly placed mach/plat entries in Kconfig & Makefile
2010-01-21 07:15:10 -08:00
Vladimir Zapolskiy
71318da9d2 ARM: MX3: Fixed typo in declared enum type name.
To distinguish between mx31lite and mx31lilly boards better to use
different enum types.

Signed-off-by: Vladimir Zapolskiy <vzapolskiy@gmail.com>
Acked-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-01-21 14:36:39 +01:00
Ben Dooks
0647aee035 ARM: S5P6440: Add HSMMC and OTG base addresses to map.h
Add the HSOTG and HSMMC block addresses to the map.h file.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 19:17:33 +09:00
Ben Dooks
75497d96b2 ARM: S3C64XX: Tidy up common code in s3c64xx_spi_set_info()
The s3c64xx_spi_set_info() sets one of two platform data structures depending
on which controller is being specified. Change to taking a pointer to the
relevant platform data structure and then having one set of code to place
the data into the area being pointed to.

Cc: Jassi Brar <jassi.brar@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 14:24:52 +09:00
Maurus Cuelenaere
bd548e5ef2 ARM: S3C64XX: Fix typo in s3c-hsotg platform data
ARM: S3C64XX: Fix typo in s3c-hsotg platform data

Signed-off-by: Maurus Cuelenaere <mcuelenaere@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:55:16 +09:00
Mark Brown
46f2b478b2 ARM: SAMSUNG: Staticise gpiolib implementation functions
They are not exported, they are referenced via vtables.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:55:15 +09:00
Mark Brown
8dcdd6e6bb ARM: S3C64XX: Staticise audio platform data
It's not exported.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:55:15 +09:00
Mark Brown
1c24522c05 ARM: S3C64XX: Fix dev-audio build
As reported when the patch was posted commit 71269364 ("ARM: S3C64XX:
Add I2S resources in platform code") uses pin names for the IISv4
data output pins which are not present in mainline, causing dev-audio
to fail to build. Fix this by using the defines which are actually
present in the kernel source.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:55:15 +09:00
Mark Brown
9fca878623 ARM: SMDK6410: Set up interrupt range for WM835x on 1190-EV1 PMIC board
The WM835x driver won't actually use this yet but it will in the
future when the changes converting it to genirq are merged.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:55:15 +09:00
Ben Dooks
8005745d6e ARM: SAMSUNG: Move pm-check.c to plat-samsung
Move the pm-check.c file to plat-samsung for all Samsung SoC users, and
update Kconfig names to make them SAMSUNG_ instead of S3C2410_

Sed expresions used to make the change:

    s/S3C2410_PM_DEBUG/SAMSUNG_PM_DEBUG/g
    s/S3C2410_PM_CHECK/SAMSUNG_PM_CHECK/g

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:45:58 +09:00
Ben Dooks
106cc6aa73 ARM: SAMSUNG: Move pmw.c to plat-samsung
Move the PWM driver support to plat-samsung, as these PWM blocks are
close enough across the current range to be supported by this driver.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:45:57 +09:00
Ben Dooks
6890556c14 ARM: SAMSUNG: Move more support into plat-samsung
Move header files which are not likely to be touched in
any further support addition out of plat-s3c's include
directory into plat-samsung.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-21 13:45:51 +09:00
Tony Lindgren
b2d959173f Merge branch 'omap-fixes' into omap-fixes-for-linus 2010-01-20 18:21:01 -08:00
Tony Lindgren
ccaae273c3 Merge branch 'pm-fixes' of master.kernel.org:/pub/scm/linux/kernel/git/khilman/linux-omap-pm into omap-fixes-for-linus 2010-01-20 18:20:47 -08:00
Sergio Aguirre
6b34f9d4e6 PM debug: Fix warning when no CONFIG_DEBUG_FS
Fix following warning when CONFIG_DEBUG_FS wasn't selected:

arch/arm/mach-omap2/pm-debug.c:57: warning: 'pm_dbg_init' declared 'static' but never defined

Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:10 -08:00
Subramani Venkatesh
b92c5721d2 OMAP3: PM: DSS PM_WKEN to refill DMA
Currently, DSS does not wakeup when there is a DMA request.  DSS wake
up event must be enabled so that the DMA request to refill the FIFO
will wake up the CORE domain.

Signed-off-by: Subramani Venkatesh <subramani.venkatesh@windriver.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:09 -08:00
Kevin Hilman
d92cfcbe39 OMAP: timekeeping: time should not stop during suspend
During suspend, the kernel timekeeping subsystem is shut down.  Before
suspend and upon resume, it uses a weak function
read_persistent_clock() to determine the amount of time that elapsed
during suspend.

This function was not implemented on OMAP, so from the timekeeping
subsystem perspective (and thus userspace as well) it appeared that no
time elapsed during suspend.

This patch uses the 32k sync timer as a the persistent clock.

NOTE: This does *NOT* fully handle wrapping of the 32k sync timer, so
      more than one wrapping of the 32k sync timer during suspend may
      cause problems.  Also note there are not interrupts when the 32k
      sync timer wraps, so something else has to be done.

Reported-by: Jon Hunter <jon-hunter@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:08 -08:00
Tero Kristo
dccaad8950 OMAP3: PM: Force write last pad config register into save area
Due to OMAP3 erratas 1.157, 1.185 the save of the last pad register
(ETK_D14 and ETK_D15) can fail sometimes when there is simultaneous
OCP access to the SCM register area. Fixed by writing the last
register to the save area.

Also, optimized the delay loop for the HW save to include an udelay(1),
which limits the number of unnecessary HW accesses to SCM register area
during the save.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Acked-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Anand Gadiyar <gadiyar@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:07 -08:00
Roel Kluin
61b17d972f OMAP: omap3_pm_get_suspend_state() error ignored in pwrdm_suspend_get()
val is an u64 pointer, we need an int to check the error.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:07 -08:00
Peter Ujfalusi
e3d9329640 OMAP3: PM: Enable wake-up from McBSP2, 3 and 4 modules
Wake-up from McBSP ports are needed, especially when the THRESHOLD
dma mode is in use for audio playback.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:06 -08:00
Manjunatha GK
ae559d8769 OMAP3: PM debug: fix build error when !CONFIG_DEBUG_FS
The PM debug code fails to build on when CONFIG_DEBUG_FS is not
enabled.

Build error log:
arch/arm/mach-omap2/built-in.o: In function `omap_sram_idle':
arch/arm/mach-omap2/pm34xx.c:449: undefined reference to `pm_dbg_regset_save'
arch/arm/mach-omap2/pm34xx.c:460: undefined reference to `pm_dbg_regset_save'
arch/arm/mach-omap2/built-in.o: In function `configure_vc':
arch/arm/mach-omap2/pm34xx.c:1237: undefined reference to `pm_dbg_regset_init'
arch/arm/mach-omap2/pm34xx.c:1238: undefined reference to `pm_dbg_regset_init'
make: *** [.tmp_vmlinux1] Error 1

This patch fixes the above errors.

Kernel booting is tested on omap zoom2 and zoom3 boards.

Signed-off-by: Manjunatha GK <manjugk@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:05 -08:00
Sripathy, Vishwanath
8640425b26 OMAP3: PM: Removing redundant and potentially dangerous PRCM configration
As part of Core domain context restoration while coming out of off mode
there are some registers being restored which are not required to be restored.
ROM code will have restored them already. Overwriting some of them can have
potential side effect. Eg: CM_CLKEN_PLL register should not be written while dpll is locked.
Tested on OMAP 3430 SDP for suspend/resume and off mode with sleep_while_idle enabled.

Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:04 -08:00
Tero Kristo
a087cad92c OMAP3: Fixed ARM aux ctrl register save/restore
Current value is stored on SDRAM and it is written back during wakeup.
Previously a static value of 0x72 was written there.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Acked-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:03 -08:00
Tero Kristo
afbcf6197d OMAP3: CPUidle: Fixed timer resolution
Previously used u32 as temporary data storage that wraps around at 4.294s.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:02 -08:00
Sanjeev Premi
a174e609b5 OMAP3: PM: Remove duplicate code blocks
This patch removes code blocks that are repeated
in function prcm_setup_regs().

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:01 -08:00
Tero Kristo
f18cc2ff5e OMAP3: PM: Disable interrupt controller AUTOIDLE before WFI
OMAP interrupt controller goes to unknown state when there is right
combination of l3,l4 sleep/wake-up transitions, l4 autoidle in
interrupt controller and some interrupt. When this happens, interrupts
are not delivered to ARM anymore and ARM will remain in WFI (wait for
interrupt) until interrupt controller is forced to wake-up
(i.e. lauterbach).

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:16:00 -08:00
Tero Kristo
b296c8118b OMAP3: PM: Enable system control module autoidle
Enable the auto-idle feature of the SCM block to save some additional
power.

Signed-off-by: Mika Westerberg <ext-mika.1.westerberg@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:15:59 -08:00
Tero Kristo
2bbe3af3f1 OMAP3: PM: Ack pending interrupts before entering suspend
Suspending drivers may still generate interrupts just before their suspend is
completed. Any pending interrupts here will prevent sleep.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-01-20 18:15:58 -08:00
Olof Johansson
1daa8c1d75 omap: Enable GPMC clock in gpmc_init
Don't assume that gpmc_l3_clk is on, enable it before touching
configuration registers.

Note that the current code assumes that this clock is always
enabled. We are already setting smart idle and L3 autogating
for GPMC clock in gpmc_init.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-01-20 17:25:31 -08:00
Paul Walmsley
af022fafa8 OMAP1 clock: fix for "BUG: spinlock lockup on CPU#0"
Commit 52650505fb caused clock initialization
to fail on OMAP1 with "BUG: spinlock lockup on CPU#0" -- this is because
omap1_select_table_rate() and omap1_round_to_table_rate() call clk_get_rate()
with the clockfw spinlock held.  Fix by accessing the rate directly from
the internal clock framework functions.

Thanks to Tony Lindgren <tony@atomide.com> for reporting and testing the fix.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Tony Lindgren <tony@atomide.com>
2010-01-20 13:35:28 -07:00
Rajendra Nayak
ecbb065947 OMAP4: clocks: Fix the clksel_rate struct DPLL divs
For all DPLL's the valid dividers are same as the values
to be programmed in the register. 0 is an invalid value.
The changes are generated by updating the script which autogenerates
the file modifed in the patch.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-01-20 13:35:28 -07:00
Rajendra Nayak
0324f59fc9 OMAP4: PRCM: Fix the base address for CHIRONSS reg defines
The CHIRONSS has its own local PRCM module and the register defines
need to use the CHIRONSS base and not the PRM base.
The changes are generated by updating the script which autogenerates
the file modifed in the patch.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-01-20 13:35:27 -07:00
Roel Kluin
247421fda7 OMAP: dma_chan[lch_head].flag & OMAP_DMA_ACTIVE tested twice in omap_dma_unlink_lch()
The same flag and bits were tested twice.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-01-19 18:17:38 -08:00
Tony Lindgren
e9acb9b64d omap3: Fix cpu detection
We need to set the omap_chip.oc carefully for the clocks to work.

To fix this, set the omap_chip.oc in omap3_check_features() based
on the CONTROL_IDCODE and silicon revision registers.

Also add handling for 34xx es3.1.2 as es3.1 for now.

Fixes booting on at least overo board.

Based on an earlier patch by Paul Walmsley <paul@pwsan.com>.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-01-19 18:17:36 -08:00
Tony Lindgren
d4bb72e50a omap: Fix functions for dynamic remuxing of pins
Make the omap_mux_read and write available for board code,
and rename omap_mux_set_board_signals into omap_mux_write_array.
Also add the related prototypes and comments into mux.h.

In some cases we want to change the signals dynamically,
mostly for power management.

Note that we cannot use the signal names as they are set
__init to save memory.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-01-19 18:17:35 -08:00
Tony Lindgren
2cb0c54f3a omap: Fix cmdline muxing
Looks like cmdline muxing got broken at some point when we
decided to limit muxing to __init code. Currently omap_mux_entry
list is not yet initialized when we try to initialize cmdline
muxing.

Fix this by calling omap_mux_init_list() before calling
omap_mux_set_cmdline_signals().

Reported-by: Philip Balister <philip@balister.org>
Tested-by: Philip Balister <philip@balister.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-01-19 18:17:07 -08:00
Russell King
6468e3b187 OMAP3: clock: Remove unnecessarily .init initializers from OMAP3 clocks
The first thing that omap2_init_clksel_parent() does is check for
a non-zero .clksel field in the struct clk.  Therefore, it is
pointless calling this function on clocks where the clksel field
is unset.

Remove init calls to omap2_init_clksel_parent() on clocks without
a clksel field.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-01-19 17:30:52 -07:00
Thara Gopinath
883edfdd58 OMAP3: hwmod: Adding flag to prevent caching of sysconfig register.
In the current implementation the sysconfig value is read into
 _sysc_cache once and an actual update to the sysconfig register
happens only if the new value paased is differnt from the one in _sysc_cache.
_sysc_cache is updated only if _HWMOD_SYSCONFIG_LOADED is not set.
This can lead to the follwing issue if off mode is enabled in modules
which employs "always-retore" mechanism of context save and restore.

        a. The module sets the sysconfig register through omap_device_enable.
           Here _sysc_cache is updated with the value written to the sysconfig
           register and left.
        b. The power domain containig the module enters off mode and the
           module context is lost.
        c. The module in use becomes active and calls omap_device_enable to
           enable itself. Here a read of sysconfig register does not happen
           as _HWMOD_SYSCONFIG_LOADED flag is set. The value to be written
           to the sysconfig register will be same as the one written in step a.
           Since _sysc_cache reflects the previous written value an update
           of the sysconfig register does not happen.
This means in modules which employs "always-restore" mechanism
after off , the sysconfig regsiters will never get updated.

This patch introduces a flag SYSC_NO_CACHE which if set ensures that the
sysconfig register is always read into _sysc_cache before an update is
attempted.

This flags need to be set only by modules which does not do a context save
but re-initializes the registers every time the module is accessed. This
includes modules like i2c, smartreflex etc.

Signed-off-by: Thara Gopinath <thara@ti.com>
[paul@pwsan.com: tweaked to apply on a different head, added flag comment]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-01-19 17:30:51 -07:00
Tony Lindgren
2045124ffd ARM: 5888/1: arm: Update comments in cacheflush.h and remove unnecessary V6 and V7 comments
The comments in cacheflush.h should follow what's in
struct cpu_cache_fns. The comments for V6 and V7 are
unnecessary.

Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-01-19 23:11:56 +00:00
Tony Lindgren
1f667c690b ARM: 5886/1: arm: Fix cpu_proc_fin() for proc-v7.S and make kexec work
The comments in arm_machine_restart() suggest that cpu_proc_fin()
will clean and disable cache and turn off interrupts. This does
not seem to be implemented for proc-v7.S, implement it the same
way as for proc-v6.S.

This also makes kexec work for v7. Note that a related TLB and
branch traget flush patch is also needed to avoid kexec
"crc error".

Note that there are still some issues that seem to be related
to L2 cache being on and causing occasional uncompress "crc error"
with kexec. Anyways, this gets kexec mostly working on V7 for now.

Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-01-19 20:23:17 +00:00
Tony Lindgren
ad3e6c0b1f ARM: 5885/1: arm: Flush TLB entries in setup_mm_for_reboot()
We need to do that if we tinker with the MMU entries.

This fixes the occasional bug with kexec where the new
fails to uncompress with "crc error". Most likely at
least kexec on v6 and v7 need this fix.

Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-01-19 20:23:17 +00:00
Tony Lindgren
200b7a8dc0 ARM: 5884/1: arm: Fix DCC console for v7
Without this patch arch/arm/compressed/head.S defaults to generic
DCC code that does not work for v7.

For more information on the v7 DCC, see Cortex-A8 TRM
"12.11.1 Debug communications channel".

To use it with post 2.6.33-rc1 or later, you need to have:

CONFIG_DEBUG_LL=y
ONFIG_DEBUG_ICEDCC=y
CONFIG_EARLY_PRINTK=y

Earlier kernels need commit 93fd03a8c6
backported.

Tested on omap3430.

Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-01-19 20:23:16 +00:00