Commit Graph

8180 Commits

Author SHA1 Message Date
Linus Walleij b87108a772 DMAENGINE: COH 901 318 descriptor pool refactoring
This centralize some spread-out initialization of descriptors into
one function and cleans up the error paths.

Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
2010-03-02 14:17:20 -07:00
Linus Torvalds 3a5b27bf6f Merge branch 'for-linus' of git://gitorious.org/linux-omap-dss2/linux
* 'for-linus' of git://gitorious.org/linux-omap-dss2/linux: (49 commits)
  OMAP: DSS2: Taal: Fix TE when resuming
  OMAP: DSS2: Taal: Fix ESD check
  OMAP: DSS2: OMAPFB: Constify some function parameters
  OMAP: DSS2: OMAPFB: install omapfb.h
  OMAP: DSS2: DSI: add error prints
  OMAP: DSS2: TPO-TD03MTEA1: fix function names
  OMAP: DSS2: DSI: add dsi_vc_dcs_read_2() helper
  OMAP: DSS2: OMAPFB: Remove FB_OMAP2_FORCE_AUTO_UPDATE
  OMAP: DSS2: DSI: remove external TE support
  OMAP: DSS2: move timing functions
  OMAP: DSS2: move set/get_wss()
  OMAP: DSS2: move enable/disable/suspend/resume
  OMAP: DSS2: move update() and sync()
  OMAP: DSS2: move set/get_update_mode()
  OMAP: DSS2: move enable/get_te()
  OMAP: DSS2: move get_recommended_bpp()
  OMAP: DSS2: move get_resolution()
  OMAP: DSS2: move enable/disable_channel to overlay manager
  OMAP: DSS2: move wait_vsync()
  OMAP: DSS2: move get/set_rotate()
  ...
2010-03-02 10:41:26 -08:00
Linus Torvalds 5057bfaff8 Merge branch 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6
* 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6: (214 commits)
  omap2: Initialize Menelaus and MMC for N8X0
  AM3517 EVM: correct typo - tca6416 mispelt as tca6516
  AM3517 EVM: Enable I2C support
  AM35x: Enable OMAP_MUX in defconfig
  AM35x: Add missing GPIO mux config for EHCI port
  Zoom3: Defconfig update
  omap: i2c: Fix muxing for command line enabled bus
  OMAP4: clock: Remove clock hacks from timer-gp.c
  OMAP4: clock: Add dummy clock nodes for interface clocks
  OMAP4: clock: Rename leaf clock nodes to end with a _ick or _fck
  OMAP2+ clock: revise omap2_clk_{disable,enable}()
  OMAP2/3 clock: combine OMAP2 & 3 boot-time MPU rate change code
  OMAP clockdomain: if no autodeps exist, don't try to add or remove them
  OMAP hwmod: add hwmod class support
  OMAP hwmod: convert header files with static allocations into C files
  OMAP hwmod: convert hwmod to use hardware clock names rather than clkdev dev+con
  OMAP clock: add omap_clk_get_by_name() for use by OMAP hwmod core code
  OMAP3: clock: add capability to change rate of dpll4_m5_ck_3630
  OMAP4 clock: drop the ALWAYS_ENABLED clock flag
  OMAP clock: drop RATE_FIXED clock flag
  ...
2010-03-02 10:34:25 -08:00
Eric Miao 62c132a800 [ARM] pxa: fix typo in mxm8x10.h
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 10:24:14 +08:00
Daniel Mack 31436bbe8f [ARM] pxa/raumfeld: set GPIO drive bits for LED pins
Set GPIO bits to pull the pins connected to LEDs for lower power mode.
We want all LEDs off when devices are in suspend.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:59 +08:00
Marc Zyngier 438a22fe26 [ARM] pxa/zeus: Add support for mcp2515 CAN bus
Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:59 +08:00
Marc Zyngier fcfdc67ff2 [ARM] pxa/zeus: Add support for onboard max6369 watchdog
Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:59 +08:00
Marc Zyngier 90ac0dfd9f [ARM] pxa/zeus: Add Eurotech as the manufacturer
Signed-off-by: Amit Walambe <amit.walambe@eurotech.com>
Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:59 +08:00
Marc Zyngier 7ff27dfa6e [ARM] pxa/zeus: Correct the USB host initialisation flags
Signed-off-by: Amit Walambe <amit.walambe@eurotech.com>
Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:58 +08:00
Marc Zyngier 662b0836a6 [ARM] pxa/zeus: Allow usage of 8250-compatible UART in uncompress
Zeus console port is wired to a 8250-compatible device (pxa UARTs are
reserved to other uses). This patch allows such a configuration in the
uncompress sequence.

Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:58 +08:00
Eric Miao c95efee133 [ARM] pxa: refactor uncompress.h for non-PXA uarts
The original patch came from Marc Zyngier where support of 8250-compatible
UART is required to show the uncompress information. Modified a little bit
here, including changes below:

1. #include <mach/regs-uart.h> is actually not necessary
2. introduced uart_{read,write}() for different base and shift
3. introduced uart_is_enabled() and assumed enabled always for
   non-PXA uarts

Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
Acked-by: Marc Zyngier <maz@misterjones.org>
2010-03-02 07:40:58 +08:00
Eric Miao 2029e5643a [ARM] mmp2: fix incorrect calling of chip->mask_ack() for 2nd level cascaded IRQs
The irq_chip is not yet registered, so no default irq_chip.mask_ack(),
which we have to handle it correctly manually here.

Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:57 +08:00
Haojian Zhuang df0c382436 [ARM] mmp2: add handling on PMIC IRQ
Since PMIC INT pin is a special pin of CPU, the status of PMIC INT pin needs
to be cleared after PMIC IRQ occured. Now append the clear operation in
irq chip handler.

Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:57 +08:00
Haojian Zhuang ce0ac42359 [ARM] mmp2: add support for board IRQs
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:57 +08:00
Haojian Zhuang 0913b86ff7 [ARM] mmp2: add missing ICU register definitions
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:57 +08:00
Haojian Zhuang 16144bfb83 [ARM] mmp2: add gpio initialization
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:56 +08:00
Haojian Zhuang 247b4592f3 [ARM] mmp2: add mfpr setting
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:56 +08:00
Haojian Zhuang 4e3b4da98e [ARM] mmp2: add mask function in irq-mmp2.c
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:56 +08:00
Haojian Zhuang e1cb7db2ef [ARM] mmp: support jasper development board
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:55 +08:00
Haojian Zhuang ccffb1ad1f [ARM] mmp: add default configuration for MMP2
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:55 +08:00
Haojian Zhuang 2f7e8faef5 [ARM] mmp: add support for Marvell MMP2
Marvell MMP2 (aka ARMADA610) is a SoC based on PJ4 core. It's
ARMv6 compatible.  Support basic interrupt handler and timer,
and basic support for MMP2 based FLINT platform.

Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:55 +08:00
Eric Miao 978da5bcdb [ARM] mmp: rename irq.c to irq-pxa168.c to allow other SoC IRQ chips
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:54 +08:00
Haojian Zhuang e6dac5e1b6 [ARM] mmp: update pxa168_defconfig and include avengers lite support
Signed-off-by: Gavin Gu <gavin.gu@marvell.com>
Signed-off-by: Jing Xiang <jxiang@marvell.com>
Signed-off-by: Jack Ren <jack.ren@marvell.com>
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:54 +08:00
Haojian Zhuang 9896de72d2 [ARM] mmp: avengers lite (pxa168) board bring up
Signed-off-by: Gavin Gu <gavin.gu@marvell.com>
Signed-off-by: Jing Xiang <jxiang@marvell.com>
Signed-off-by: Jack Ren <jack.ren@marvell.com>
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:53 +08:00
Stefan Schmidt 0925e2f0fc [ARM] pxa/imote2: Remove redundant pin entry for nCS.
Also remove a trailing whitespace while being there.

Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:53 +08:00
Stefan Schmidt d496936f95 [ARM] pxa/imote2: Add defconfig for the imote2 platform.
Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:53 +08:00
Eric Miao a056bef455 [ARM] pxa: introduce PXA_SSP_LEGACY for legacy SSP API
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:52 +08:00
Stefan Schmidt 98acdbe4cf [ARM] pxa: define zeus_power_off() only when CONFIG_PM enabled
Add some safety check for CONFIG_PM around zeus_power_off(). Without
it linking can fail like this:

arch/arm/mach-pxa/built-in.o: In function `zeus_power_off':
e800.c:(.text+0x2bc8): undefined reference to `pxa27x_cpu_suspend'

Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
Acked-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:52 +08:00
Stefan Schmidt cfab57e0e4 [ARM] pxa: enable check_scoop_reg() only if CONFIG_PM is set.
This function gets only called from scoop_suspend() and scoop_resume() which are
only built in if we have CONFIG_PM set. Make it the same for check_scoop_reg().

This fixes the following warning:
arch/arm/common/scoop.c:143: warning: ‘check_scoop_reg’ defined but not used

Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:52 +08:00
Edwin Peer 1f3b536be7 [ARM] pxa: add support for Embedian MXM-8x10
Signed-off-by: Edwin Peer <epeer@tmtservices.co.za>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:51 +08:00
Eric Miao 0dc726bb26 [ARM] pxa: move board board IRQ definitions out of irqs.h
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:51 +08:00
Eric Miao 19851c58e6 [ARM] sa1111: allow cascaded IRQs to be used by platforms
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:51 +08:00
Eric Miao ac609d266e [ARM] locomo: allow cascaded IRQ base to be specified by platforms
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:50 +08:00
Eric Miao 00dd8027b9 [ARM] locomo: remove unused IRQs and avoid unnecessary cascade
IRQ_LOCOMO_* are never used elsewhere, remove these definitions. As well
as the cascade of these IRQs. IRQ_LOCOMO_*_BASE changed to IRQ_LOCOMO_*.

IRQ_LOCOMO_LT and IRQ_LOCOMO_SPI are likely to be used in a same way as
IRQ_LOCOMO_KEY.

IRQ_LOCOMO_GPIO and the demultiplex handler should really be living
somewhere else.

Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:49 +08:00
Eric Miao da8065ac3e [ARM] locomo: avoid unnecessary cascaded keyboard IRQ
It is not necessary and is over-complicated for IRQ_LOCOMO_KEY to
be a cascaded IRQ of IRQ_LOCOMO_KEY_BASE. Removed and introduced
locomokbd_{open,close} for masking/unmasking of the keyboard IRQ.

Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:49 +08:00
Eric Miao efe7f8bda0 [ARM] sa1100: remove unreferenced IRQ definitions
These IRQ definitions related to LOCOMO are never referenced anywhere,
thus could be safely removed.

Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:49 +08:00
Eric Miao f69a6548c9 [ARM] pxa/tosa: make use of the matrix keypad driver
Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:48 +08:00
Eric Miao 96f6a13a6d [ARM] pxa/cm-x270: avoid direct access of GPIO/MFP registers
Cc: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:48 +08:00
Eric Miao c11b6a420b [ARM] pxa: add the missing AC97 pin configurations
Missing AC97 pin configurations are added where pxa_set_ac97_info() are
called for all pxa25x/pxa27x platforms. Where no exact configuration is
provided, use the default as in sound/arm/pxa2xx-ac97-lib.c

Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:48 +08:00
Eric Miao fb1bf8cd13 [ARM] pxa: introduce processor specific pxa27x_assert_ac97reset()
This is really pxa27x specific and should be kept in pxa27x.c. With this
newly introduced function, the original set_resetgpio_mode() is deprecated.

Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:47 +08:00
Eric Miao bedbda9717 [ARM] pxa: simplify the LCD pin configuration for pxa27x platforms
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:47 +08:00
Eric Miao 07bae6c321 [ARM] pxa: simplify the LCD pin configuration for pxa25x platforms
There are only limited possible LCD pin configurations for pxa25x
platforms, simplify this by macro.

Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:46 +08:00
Eric Miao 669cb51c6a [ARM] pxa: use chip->ack() instead of accessing GEDR directly
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2010-03-02 07:40:45 +08:00
Tony Lindgren d702d12167 Merge with mainline to remove plat-omap/Kconfig conflict
Conflicts:
	arch/arm/plat-omap/Kconfig
2010-03-01 14:19:05 -08:00
Linus Torvalds 13dda80e48 Merge branch 'davinci-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-davinci
* 'davinci-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-davinci: (40 commits)
  DaVinci DM365: Adding support for SPI EEPROM
  DaVinci DM365: Adding DM365 SPI support
  DaVinci DM355: Modifications to DM355 SPI support
  DaVinci: SPI: Adding header file for SPI support.
  davinci: dm646x: CDCE clocks: davinci_clk converted to clk_lookup
  davinci: clkdev cleanup: remove clk_lookup wrapper, use clkdev_add_table()
  DaVinci: DM365: Voice codec support for the DM365 SoC
  davinci: clock: let clk->set_rate function sleep
  Add SDA and SCL pin numbers to i2c platform data
  davinci: da8xx/omap-l1xx: Add EDMA platform data for da850/omap-l138
  davinci: build list of unused EDMA events dynamically
  davinci: Fix edma_alloc_channel api for EDMA_CHANNEL_ANY case
  davinci: Keep count of channel controllers on a platform
  davinci: Correct return value of edma_alloc_channel api
  davinci: add CDCE949 support on DM6467 EVM
  davinci: add support for CDCE949 clock synthesizer
  davinci: da850/omap-l138 EVM: register for suspend support
  davinci: da850/omap-l138: add support for SoC suspend
  davinci: add power management support
  DaVinci: DM365: Changing default queue for DM365.
  ...
2010-03-01 13:05:40 -08:00
Linus Torvalds 8724fdb53d Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (62 commits)
  Input: atkbd - release previously reserved keycodes 248 - 254
  Input: add KEY_WPS_BUTTON definition
  Input: ads7846 - add regulator support
  Input: winbond-cir - fix suspend/resume
  Input: gamecon - use pr_err() and friends
  Input: gamecon - constify some of the setup structures
  Input: gamecon - simplify pad type handling
  Input: gamecon - simplify coordinate calculation for PSX
  Input: gamecon - fix some formatting issues
  Input: gamecon - add rumble support for N64 pads
  Input: wacom - add device type to device name string
  Input: s3c24xx_ts - report touch only when stylus is down
  Input: s3c24xx_ts - re-enable IRQ on resume
  Input: wacom - constify product features data
  Input: wacom - use per-device instance of wacom_features
  Input: sh_keysc - enable building on SH-Mobile ARM
  Input: wacom - get features from driver info
  Input: rotary-encoder - set gpio direction for each requested gpio
  Input: sh_keysc - update the driver with mode 6
  Input: sh_keysc - switch to using bitmaps
  ...
2010-03-01 10:38:09 -08:00
Sandeep Paulraj 5f19daa16f DaVinci DM365: Adding support for SPI EEPROM
The DM365 Spectrum Digital EVM comes with an EEPROM
connected to SPI0.
This patch adds support for the SPI EEPROM.

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-03-01 10:20:24 -08:00
Sandeep Paulraj a3e13e89d6 DaVinci DM365: Adding DM365 SPI support
This patch adds SPI init for DM365.
It does the following
1) Initializes SPI0
2) Defines resources to be used by SPI0
3) Adds platform data for SPI0

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-03-01 10:20:24 -08:00
Sandeep Paulraj 15e865859a DaVinci DM355: Modifications to DM355 SPI support
This patch does the following

1) Minor change to the SPI clocks making it
similar to DM365.
2) Changing the interrupt used by SPI0
3) Adding EDMA resources that can be used by SPI0
4) Adding platform specific data.

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-03-01 10:20:23 -08:00
Sandeep Paulraj 8e2a0013c2 DaVinci: SPI: Adding header file for SPI support.
This patch adds "spi.h" header file that will be used by board and
architecture specific code.

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-03-01 10:20:22 -08:00
Kevin Hilman c564191b1c davinci: dm646x: CDCE clocks: davinci_clk converted to clk_lookup
Remove unneeded 'struct davinci_clk' wrapper around 'struct
clk_lookup' and use clk_lookup directly.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-03-01 10:19:58 -08:00
Linus Torvalds ac0f6f927d Merge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm: (100 commits)
  ARM: Eliminate decompressor -Dstatic= PIC hack
  ARM: 5958/1: ARM: U300: fix inverted clk round rate
  ARM: 5956/1: misplaced parentheses
  ARM: 5955/1: ep93xx: move timer defines into core.c and document
  ARM: 5954/1: ep93xx: move gpio interrupt support to gpio.c
  ARM: 5953/1: ep93xx: fix broken build of clock.c
  ARM: 5952/1: ARM: MM: Add ARM_L1_CACHE_SHIFT_6 for handle inside each ARCH Kconfig
  ARM: 5949/1: NUC900 add gpio virtual memory map
  ARM: 5948/1: Enable timer0 to time4 clock support for nuc910
  ARM: 5940/2: ARM: MMCI: remove custom DBG macro and printk
  ARM: make_coherent(): fix problems with highpte, part 2
  MM: Pass a PTE pointer to update_mmu_cache() rather than the PTE itself
  ARM: 5945/1: ep93xx: include correct irq.h in core.c
  ARM: 5933/1: amba-pl011: support hardware flow control
  ARM: 5930/1: Add PKMAP area description to memory.txt.
  ARM: 5929/1: Add checks to detect overlap of memory regions.
  ARM: 5928/1: Change type of VMALLOC_END to unsigned long.
  ARM: 5927/1: Make delimiters of DMA area globally visibly.
  ARM: 5926/1: Add "Virtual kernel memory..." printout.
  ARM: 5920/1: OMAP4: Enable L2 Cache
  ...

Fix up trivial conflict in arch/arm/mach-mx25/clock.c
2010-03-01 09:15:15 -08:00
Linus Torvalds 524df55725 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: (252 commits)
  ASoC: Check progress when reporting periods from i.MX FIQ handler
  ASoC: Remove a unused variables from i.MX FIQ runtime data
  ALSA: hda - Add/fix ALC269 FSC and Quanta models
  ALSA: hda - Add ALC670 codec support
  OMAP4: PMIC: Add support for twl6030 codec
  ALSA: hda - remove unnecessary msleep on power state transitions
  usb/gadget/{f_audio,gmidi}.c: follow recent changes in audio.h
  ASoC: fsi: Modify over/under run error settlement
  ASoC: OMAP4: Add McPDM platform driver
  ASoC: OMAP4: Add support for McPDM
  ASoC: OMAP: data_type and sync_mode configurable in audio dma
  ALSA: hda - Add missing description in HD-Audio-Models.txt
  ALSA: add support for Macbook Air 2,1 internal speaker
  ALSA: usbaudio: consolidate header files
  ALSA: usbmixer: bail out early when parsing audio class v2 descriptors
  ALSA: usbaudio: implement basic set of class v2.0 parser
  ALSA: usbaudio: introduce new types for audio class v2
  ALSA: usbaudio: parse USB descriptors with structs
  ALSA: hda - enable snoop for Intel Cougar Point
  ALSA: hda - Remove identical definitions for macmini3 model
  ...
2010-03-01 08:58:44 -08:00
Takashi Iwai 6679ee1870 Merge branch 'topic/asoc' into for-linus 2010-03-01 12:38:59 +01:00
Roel Kluin f1acb878b6 iop-adma: redundant/wrong tests in iop_*_count()?
When we reach the loop, len is at least 1, we only stay in the loop when
len is at least MAX_BYTE_COUNT + 1, MAX_BYTE_COUNT is subtracted in each
iteration. So when we leave the loop, or didn't take it, len is at least 1.
Testing whether len is non-zero appears redundant.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
2010-02-28 22:22:12 -07:00
Linus Torvalds 2b8c70b217 Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (362 commits)
  V4L-DVB: cx88-dvb: remove extra attribution for core
  V4L/DVB: v4l: soc_camera: fix bound checking of mbus_fmt[] index
  V4L/DVB: Add support for SMT7020 to cx88
  V4L/DVB: radio-si470x: Use UTF-8 encoding on a comment
  V4L/DVB: MAINTAINERS: Telegent tlg2300 section fix
  V4L/DVB: gspca_stv06xx: Add support for camera button
  V4L/DVB: gspca_ov519: add support for the button on ov511 based cams
  V4L/DVB: gspca_ov519: Add support for the button on ov518 based cams
  V4L/DVB: gspca_ov519: add support for the button on ov519 based cams
  V4L/DVB: gspca_main: Fix a compile error when CONFIG_INPUT is not set
  V4L/DVB: gspca_main: some input error handling fixes
  V4L/DVB: gspca_main: Allow use of input device creation code for non int. inputs
  V4L/DVB: gspca_pac7302: much improved exposure control
  V4L/DVB: gspca_sonixb: Make sonixb driver handle pas106 and pas202 cameras
  V4L/DVB: gspca_sonixb: pas106: fixup bright ctrl and add gain and exposure ctrls
  V4L/DVB: Documentation: gspca.txt: update known mr97310a cams
  V4L/DVB: gspca_mr97310a: add support for the Sakar 1638x CyberPix
  V4L/DVB: gscpa_sonixb: limit ov7630 max framerate at 640x480
  V4L/DVB: gspca_sonixb: pas202: fixup brightness ctrl and add gain and exposure ctrls
  V4L/DVB: gscpa_sonixb: Differentiate between sensors with a coarse and fine expo ctrl
  ...
2010-02-26 17:16:20 -08:00
Linus Torvalds f24407d2bd Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/xfs-vipt
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/xfs-vipt:
  xfs: fix xfs to work with Virtually Indexed architectures
  sh: add mm API for DMA to vmalloc/vmap areas
  arm: add mm API for DMA to vmalloc/vmap areas
  parisc: add mm API for DMA to vmalloc/vmap areas
  mm: add coherence API for DMA to vmalloc/vmap areas
2010-02-26 17:05:10 -08:00
Linus Torvalds 37d4008484 Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (31 commits)
  crypto: aes_generic - Fix checkpatch errors
  crypto: fcrypt - Fix checkpatch errors
  crypto: ecb - Fix checkpatch errors
  crypto: des_generic - Fix checkpatch errors
  crypto: deflate - Fix checkpatch errors
  crypto: crypto_null - Fix checkpatch errors
  crypto: cipher - Fix checkpatch errors
  crypto: crc32 - Fix checkpatch errors
  crypto: compress - Fix checkpatch errors
  crypto: cast6 - Fix checkpatch errors
  crypto: cast5 - Fix checkpatch errors
  crypto: camellia - Fix checkpatch errors
  crypto: authenc - Fix checkpatch errors
  crypto: api - Fix checkpatch errors
  crypto: anubis - Fix checkpatch errors
  crypto: algapi - Fix checkpatch errors
  crypto: blowfish - Fix checkpatch errors
  crypto: aead - Fix checkpatch errors
  crypto: ablkcipher - Fix checkpatch errors
  crypto: pcrypt - call the complete function on error
  ...
2010-02-26 16:50:02 -08:00
Tony Lindgren 9418c65f9b omap2: Initialize Menelaus and MMC for N8X0
Initialize MMC for N8X0

Based on an earlier patches from Nokia released kernel
sources at:

http://repository.maemo.org/pool/os2008/free/source/k/kernel-source-rx-34/

Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-26 15:31:12 -08:00
Murali Karicheri a30d6744cf V4L/DVB: DaVinci - Adding platform & board changes for vpfe capture on DM365
This patch adds following changes:-
	1) add sub device configuration data for TVP5146 used by vpfe capture
	2) registers platform devices for vpfe_capture, isif and vpss
	3) defines hardware resources for the devices listed under 2)
	4) defines clock aliase for isif driver
	5) adding setup_pinmux() for isif

Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Murali Karicheri <mkaricheri@gmail.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-02-26 15:11:06 -03:00
Antonio Ospite 6b727c68ea pxa_camera: remove init() callback
pxa_camera init() callback is sometimes abused to setup MFP for PXA CIF, or
even to request GPIOs to be used by the camera *sensor*. These initializations
can be performed statically in machine init functions.

The current semantics for this init() callback is ambiguous anyways, it is
invoked in pxa_camera_activate(), hence at device node open, but its users use
it like a generic initialization to be done at module init time (configure
MFP, request GPIOs for *sensor* control).

Signed-off-by: Antonio Ospite <ospite@studenti.unina.it>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-02-26 15:11:00 -03:00
Muralidharan Karicheri 77c8b5fb0e V4L/DVB: vpfe-capture: converting ccdc drivers to platform-drivers
This adds platform code for ccdc driver on DM355 and DM6446.

1) new ccdc platform devices added
2) added clock aliases master and slave for CCDC clocks
3) added dm355_ccdc_setup_pinmux() pin-mux setup hook in dm355 ccdc driver platform data

Reviewed-by: Vaibhav Hiremath <hvaibhav@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Muralidharan Karicheri <m-karicheri2@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-02-26 15:10:45 -03:00
Russell King 98e12b5a6e ARM: Fix decompressor's kernel size estimation for ROM=y
Commit 2552fc2 changed the way the decompressor decides if it is safe
to decompress the kernel directly to its final location.  Unfortunately,
it took the top of the compressed data as being the stack pointer,
which it is for ROM=n cases.  However, for ROM=y, the stack pointer
is not relevant, and results in the wrong answer.

Fix this by explicitly storing the end of the biggybacked data in the
decompressor, and use that to calculate the compressed image size.

CC: <stable@kernel.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-26 00:10:47 +00:00
Sriram 7b97f3edf3 AM3517 EVM: correct typo - tca6416 mispelt as tca6516
Correct instances where tca6416 is misspelt as tca6516 in
the board-am3517evm file.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-25 14:45:09 -08:00
Sriram 6d20ca78b6 AM3517 EVM: Enable I2C support
There are multiple devices connected to I2C bus on AM3517EVM
(for instance audio codec, IO expander etc). Enable I2C support
in the default kernel configuration for AM3517 EVM.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-25 14:45:09 -08:00
Ajay Kumar Gupta 13fc638289 AM35x: Enable OMAP_MUX in defconfig
Enabling OMAP_MUX in defconfig as it is required for EHCI to work.

Signed-off-by: Ajay Kumar Gupta <ajay.gupta@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-25 14:45:09 -08:00
Ajay Kumar Gupta fec3eebdce AM35x: Add missing GPIO mux config for EHCI port
Adding GPIO mux config used for PHY reset of EHCI port on base board.
We get below failure message without this patch,

"hub 1-0:1.0: unable to enumerate USB device on port 1"

Signed-off-by: Ajay Kumar Gupta <ajay.gupta@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-25 14:45:09 -08:00
manjugk manjugk 93bfc85b23 Zoom3: Defconfig update
Some of the features are not enabled by default in zoom3 defconfig.

This patch enables:
 - MMC Resume
 - TWL4030 RTC driver
 - Debug File system

Build and boot tested on Zoom3 board.

Signed-off-by: Manjunatha GK <manjugk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-25 14:45:08 -08:00
Jarkko Nikula 9833eff3d7 omap: i2c: Fix muxing for command line enabled bus
The commit b63128e812 broke the pin muxing
for I2C busses that are enabled from the kernel command line.

Fix this by defining the board registration function omap_register_i2c_bus
in common platform code as it was before but keep the muxing in architecture
dependent files.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-25 14:45:08 -08:00
Russell King 9f33be2c3a Merge branches 'clks' and 'pnx' into devel 2010-02-25 22:10:38 +00:00
Russell King 2741ecb4ce Merge branch 'misc2' into devel 2010-02-25 22:09:41 +00:00
Russell King bc85e585c6 Merge branch 'perf' into devel
Conflicts:
	arch/arm/Kconfig
2010-02-25 22:09:22 +00:00
Russell King 186f93ea1f Merge branch 'tmpreg' into devel
Conflicts:
	arch/arm/Kconfig
	arch/arm/mach-ux500/include/mach/debug-macro.S
2010-02-25 22:07:25 +00:00
Russell King 3560adf620 Merge branches 'at91', 'cache', 'cup', 'ep93xx', 'ixp4xx', 'nuc', 'pending-dma-streaming', 'u300' and 'umc' into devel 2010-02-25 22:06:43 +00:00
Russell King 2a2d10f386 Merge branch 'for-rmk' of git://git.marvell.com/orion into devel-stable 2010-02-25 20:41:34 +00:00
Russell King 5de813b6cd ARM: Eliminate decompressor -Dstatic= PIC hack
We used to build decompressors with -Dstatic= to avoid any local data
being generated.  The problem is that local data generates GOTOFF
relocations, which means we can't relocate the data relative to the
text segment.

Global data, on the other hand, goes through the GOT, and can be
relocated anywhere.

Unfortunately, with the new decompressors, this presents a problem
since they declare static data within functions, and this leads to
stack overflow.

Fix this by separating out the decompressor code into a separate file,
and removing 'static' from BSS data in misc.c.

Also, discard the .data section - this means that should we end up
with read/write initialized data, the decompressor will fail to link
and the problem will be obvious.

Acked-by: Nicolas Pitre <nico@fluxnic.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-25 19:34:31 +00:00
Tomi Valkeinen 53055aae20 OMAP: DSS2: DSI: add dsi_vc_dcs_read_2() helper
Add dsi_vc_dcs_read_2() helper function to read two bytes from the DSI
peripheral.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-25 18:28:41 +02:00
Uwe Kleine-König 9b1489e989 Merge branch 'mxc-master' of git://git.pengutronix.de/git/imx/linux-2.6 into imx/master
Removed selection of COMMON_CLKDEV by CONFIG_ARCH_MX5.  This is handled
in 03e09cd890.

arch/arm/plat-mxc/iomux-mx1-mx2.c was moved to
arch/arm/plat-mxc/iomux-v1.c in 5e2e95f520
and got bug fixed in 5c17ef878f.  The bug
in arch/arm/plat-mxc/iomux-v1.c isn't present any more since
bac3fcfad5, so
arch/arm/plat-mxc/iomux-mx1-mx2.c is simply deleted.

Conflicts:
	arch/arm/plat-mxc/Kconfig
	arch/arm/plat-mxc/Makefile
	arch/arm/plat-mxc/iomux-mx1-mx2.c

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-25 14:01:49 +01:00
Kuninori Morimoto 17ccb834d5 ARM: mach-shmobile: ap4evb: Add KEYSC support
Because AP4 board has capacitor for KEYSC,
we need much time for waiting.

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-25 16:58:34 +09:00
Tony Lindgren b610ec5023 Merge branch 'for_2.6.34_b' of git://git.pwsan.com/linux-2.6 into omap-for-linus 2010-02-24 20:53:03 -08:00
Santosh Shilimkar ad001f145d OMAP4: clock: Remove clock hacks from timer-gp.c
Now the omap4 clock framework is in mainline and clk_get_rate()
is functional. Hence reomve the hardcoded clock hacks.

This patch also fixes
Division by zero in kernel.
Backtrace:
[<c0025fb8>] (dump_backtrace+0x0/0x110) from [<c017febc>] (dump_stack+0x18/0x1c)
 r7:60000093 r6:c0641050 r5:c0223e78 r4:c02126b4
[<c017fea4>] (dump_stack+0x0/0x1c) from [<c00260fc>] (__div0+0x18/0x20)
[<c00260e4>] (__div0+0x0/0x20) from [<c01431fc>] (Ldiv0+0x8/0x10)
[<c00318d4>] (omap_dm_timer_stop+0x0/0xb0) from [<c002c148>] (omap2_gp_timer_set_mode+0x1c/0x68)
 r5:c0223e78 r4:00000000
[<c002c12c>] (omap2_gp_timer_set_mode+0x0/0x68) from [<c0063270>] (clockevents_set_mode+0x30/0x64)
 r5:c020cae0 r4:00000000
[<c0063240>] (clockevents_set_mode+0x0/0x64) from [<c00632fc>] (clockevents_exchange_device+0x30/0x9c)
 r5:c020cae0 r4:c02146e0
[<c00632cc>] (clockevents_exchange_device+0x0/0x9c) from [<c00636e0>] (tick_notify+0x17c/0x404)
 r7:00000000 r6:c0641050 r5:00000000 r4:c020cae0
[<c0063564>] (tick_notify+0x0/0x404) from [<c005d5fc>] (notifier_call_chain+0x34/0x78)
[<c005d5c8>] (notifier_call_chain+0x0/0x78) from [<c005d684>] (__raw_notifier_call_chain+0x1c/0x24)
[<c005d668>] (__raw_notifier_call_chain+0x0/0x24) from [<c005d6ac>] (raw_notifier_call_chain+0x20/0x28)
[<c005d68c>] (raw_notifier_call_chain+0x0/0x28) from [<c0062e78>] (clockevents_do_notify+0x1c/0x24)
[<c0062e5c>] (clockevents_do_notify+0x0/0x24) from [<c0062f18>] (clockevents_register_device+0x98/0xd0)
[<c0062e80>] (clockevents_register_device+0x0/0xd0) from [<c001a194>] (percpu_timer_setup+0x80/0x9c)
 r7:00000000 r6:00000002 r5:00000002 r4:00000003
[<c001a114>] (percpu_timer_setup+0x0/0x9c) from [<c000e9f0>] (smp_prepare_cpus+0xb0/0xe8)
[<c000e940>] (smp_prepare_cpus+0x0/0xe8) from [<c00084e8>] (kernel_init+0x5c/0x1fc)
 r7:00000000 r6:00000000 r5:00000000 r4:c001b8a4
[<c000848c>] (kernel_init+0x0/0x1fc) from [<c0046c50>] (do_exit+0x0/0x604)
 r7:00000000 r6:00000000 r5:00000000 r4:00000000

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 17:45:17 -07:00
Santosh Shilimkar 7c43d54728 OMAP4: clock: Add dummy clock nodes for interface clocks
On OMAP4 platform the iclk control is completly under hardware control
and no software control is available.

This difference w.r.t previous OMAP's needs all the common driver
accross OMAP's , cpu_is_xxxx() checks. To avoid poulluting the
drivers dummy clock nodes are created (The autogeneration
script has been updated accordingly).

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Benoit Cousson <b-cousson@ti.com>
[paul@pwsan.com: made OMAP1 dummy_ck common and edited patch to reuse that]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 17:45:17 -07:00
Rajendra Nayak 5477605026 OMAP4: clock: Rename leaf clock nodes to end with a _ick or _fck
All leaf clock nodes are renamed for OMAP4 to have a clk name which
end with a _ick or a _fck. This is done so that the naming convention
is same as that followed on older OMAPs.

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>
2010-02-24 17:45:16 -07:00
Paul Walmsley 30962d9d0c OMAP2+ clock: revise omap2_clk_{disable,enable}()
Simplify the code in the omap2_clk_disable() and omap2_clk_enable()
functions, reducing levels of indentation.  This makes the code easier
to read.  Add some additional debugging pr_debug()s here also to help
others understand what is going on.

Revise the omap2_clk_disable() logic so that it now attempts to
disable the clock's clockdomain before recursing up the clock tree.
Simultaneously, ensure that omap2_clk_enable() is called on parent
clocks first, before enabling the clockdomain.  This ensures that a
parent clock's clockdomain is enabled before the child clock's
clockdomain.  These sequences should be the inverse of each other.

Revise the omap2_clk_enable() logic so that it now cleans up after
itself upon encountering an error.  Previously, an error enabling a
parent clock could have resulted in inconsistent usecounts on the
enclosing clockdomain.

Remove the trivial _omap2_clk_disable() and _omap2_clk_enable() static
functions, and replace it with the clkops calls that they were
executing.

For all this to work, the clockdomain omap2_clkdm_clk_enable() and
omap2_clkdm_clk_disable() code must not return an error on clockdomains
without CLKSTCTRL registers; so modify those functions to simply return 0
in that case.

While here, add some basic kerneldoc documentation on both functions,
and get rid of some old non-CodingStyle-compliant comments that have
existed since the dawn of time (at least, the OMAP clock framework's
time).

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
2010-02-24 17:45:16 -07:00
Paul Walmsley 4d30e82c26 OMAP2/3 clock: combine OMAP2 & 3 boot-time MPU rate change code
The OMAP2 and OMAP3 boot-time MPU rate change code is almost
identical.  Merge them into mach-omap2/clock.c, and add kerneldoc
documentation.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 17:45:15 -07:00
Paul Walmsley ad9561609c OMAP clockdomain: if no autodeps exist, don't try to add or remove them
_clkdm_add_autodeps() and _clkdm_del_autodeps() will attempt to dereference
a NULL pointer if no autodeps were supplied to clkdm_init().

Based on a patch from Roel Kluin <roel.kluin@gmail.com> - thanks Roel.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Roel Kluin <roel.kluin@gmail.com>
2010-02-24 17:45:15 -07:00
Paul Walmsley 43b40992ce OMAP hwmod: add hwmod class support
Add support for categorizing and iterating over hardware IP blocks by
the "class" of the IP block.  The class is the type of the IP block:
e.g., "timer", "timer1ms", etc.  Move the OCP_SYSCONFIG/SYSSTATUS data
from the struct omap_hwmod into the struct omap_hwmod_class, since
it's expected to stay consistent for each class.  While here, fix some
comments.

The hwmod_class structures in this patch were designed and proposed by
Benoît Cousson <b-cousson@ti.com> and were refined in a discussion
between Thara Gopinath <thara@ti.com>, Kevin Hilman
<khilman@deeprootsystems.com>, and myself.

This patch uses WARN() lines that are longer than 80 characters, as
Kevin noted a broader lkml consensus to increase greppability by
keeping the messages all on one line.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Benoît Cousson <b-cousson@ti.com>
Cc: Thara Gopinath <thara@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-24 17:45:14 -07:00
Mark Brown d608c738bb ARM: S3C64XX: Add initial support for board specific IRQs
Follow the scheme used for IRQs. By default 16 GPIOs are allocated
for board use.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 23:54:43 +00:00
Kukjin Kim e6502522c2 ARM: S5PV210: Add S5PC110 configuration file
This patch adds S5PC110 default configuration file.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 22:47:24 +00:00
Kukjin Kim af60ca4f29 ARM: S5PV210: Add S5PV210 configuration file
This patch adds S5PV210 default configuration file.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 22:47:23 +00:00
Kukjin Kim d515ec339b ARM: S5PV210: Add SMDKC110 board support file
This patch adds SMDKC110 board support file.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 22:47:23 +00:00
Kukjin Kim 981744165e ARM: S5PV210: Add SMDKV210 board support file
This patch adds SMDKV210 board support file.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 22:47:23 +00:00
Kukjin Kim 170f4e4258 ARM: S5PV210: Update Kconfig and Makefiles
Updates arch/arm Kconfig and Makefile for building the S5PV210 support.
Also modifies the plat-s5p Kconfig file to include the support for plat-s5p
for S5PV210.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 22:47:23 +00:00
Kukjin Kim 2c798557b9 ARM: S5PV210: Add IRQ support
This patch adds IRQ support for S5PV210. This patch adds interrupt
register definitions, IRQ definitions for various interrupt sources
and new VIC base for VIC2 and VIC3 in plat-s5p common irq code.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 22:47:22 +00:00
Kukjin Kim 0c1945d336 ARM: S5PV210: Add clock support for S5PV210
This patch adds clock support for S5PV210. This patch adds the clock
register definitions and the various system clocks in S5PV210.
Clocks that are common to other S5P SoC'c are added in the common
S5P clock support.

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-02-24 22:47:22 +00:00
Kukjin Kim 939d28aae1 ARM: S5PV210: Add Samsung S5PV210 CPU support
This patch adds support for Samsung S5PV210 CPU. This patch also adds
an entry for S5PV210 cpu in plat-s5p cpu table.

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-02-24 22:47:21 +00:00
Linus Walleij cd71f8f48e ARM: 5958/1: ARM: U300: fix inverted clk round rate
The clk_round_rate() functions in the U300 clocking will always
select the lowest clocking frequency due to inverted rounding
comparisons. Fix this.

Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:10:17 +00:00
Roel Kluin fcfadcaa57 ARM: 5956/1: misplaced parentheses
The parentheses appear misplaced.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Acked-by: Linus Walleij <linus.walleij@stericsson.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:10:07 +00:00
Hartley Sweeten 1587a373f0 ARM: 5955/1: ep93xx: move timer defines into core.c and document
The timer defines are only used in core.c. Move them so
they will not be globaly exposed.

While here, add additional defines to document the magic
numbers used in the registers. Also, add some comments
for clarification.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Acked-by: Ryan Mallon <ryan@bluewatersys.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:08:36 +00:00
Hartley Sweeten d056ab7855 ARM: 5954/1: ep93xx: move gpio interrupt support to gpio.c
The GPIO support in core.c handles the interrupt support for GPIO
ports A, B, and F. The gpiolib implementation in gpio.c needs to
access the function ep93xx_gpio_int_mask when a gpio pin is made
an output and ep93xx_gpio_update_int_params in order to update
the registers.

Moving this support from core.c to gpio.c allows making the two
functions static. It also keeps all the GPIO handling together in one
file.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Acked-by: Ryan Mallon <ryan@bluewatersys.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:08:36 +00:00
Hartley Sweeten ba7c6a3bcc ARM: 5953/1: ep93xx: fix broken build of clock.c
Patch 5879/1: ep93xx: define magic numbers for pll1 and pll2 broke
the ep93xx build due to one missing rename of EP93XX_SYSCON_CLOCK_SET2.
The correct name should be EP93XX_SYSCON_CLKSET2.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Acked-by: Ryan Mallon <ryan@bluewatersys.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:08:35 +00:00
Kukjin Kim d6d502fa4b ARM: 5952/1: ARM: MM: Add ARM_L1_CACHE_SHIFT_6 for handle inside each ARCH Kconfig
Add ARM_L1_CACHE_SHIFT_6 to arch/arm/Kconfig to allow CPUs with
L1 cache lines which are 64bytes to indicate this without having to
alter the arch/arm/mm/Kconfig entry each time.

Update the mm Kconfig so that ARM_L1_CACHE_SHIFT default value
uses this and change OMAP3 and S5PC1XX to select ARM_L1_CACHE_SHIFT_6.

Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:07:22 +00:00
Paul Walmsley 7359154e94 OMAP hwmod: convert header files with static allocations into C files
Code should be able to #include any header file without the fear that
the header file will go allocating memory.  This is a coding style
issue, similar to commit 82e9bd5885.
Move the existing hwmod data from .h files to .c files.

While here, convert "omap34xx" to "omap3xxx" in the hwmod files, since
most of these structures should be reusable across all OMAP3 chips.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-24 12:29:45 -07:00
Paul Walmsley 50ebdac2ec OMAP hwmod: convert hwmod to use hardware clock names rather than clkdev dev+con
The OMAP hwmod core code is intended to use SoC IP block description
structures that are autogenerated from TI's OMAP hardware database.
Currently the hwmod code uses clkdev device + connection addressing to
identify clocks.  This causes problems in the hwmod autogeneration
process, since the TI hardware database doesn't use platform_device or
clkdev addressing; it uses a single clock signal name string, which
tends to bear some resemblance to what is used in the OMAP TRMs.  This
patch converts the hwmod code and existing data to use omap_clk_get_by_name(),
introduced in the previous patch.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-24 12:29:44 -07:00
Paul Walmsley 74be842743 OMAP clock: add omap_clk_get_by_name() for use by OMAP hwmod core code
The OMAP hwmod core code is intended to use SoC IP block description
structures that are autogenerated from TI's OMAP hardware database.
Currently the hwmod code uses clkdev device + connection addressing to
identify clocks.  This causes problems in the hwmod autogeneration
process, since the TI hardware database doesn't use platform_device or
clkdev addressing; it uses a single clock signal name string, which
tends to bear some resemblance to what is used in the OMAP TRMs.  This
patch adds a non-exported function to the OMAP clock code,
omap_clk_get_by_name().  A subsequent patch will convert the hwmod
code to use this function.

This function is for use only by core code, and practically, no other
code outside the hwmod code should need it.  Device driver code in the
kernel must not use this function, which is why it is not exported.
Drivers should use the appropriate clock alias provided by the clkdev
data structures, so driver code can be completely SoC-independent.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-24 12:29:43 -07:00
Vimarsh Zutshi e8d373779e OMAP3: clock: add capability to change rate of dpll4_m5_ck_3630
Add necessary clk_sel definitions to clock framework to allow changing
dpll4_m5_ck_3630 rate. This is used by the ISP driver.

Signed-off-by: Vimarsh Zutshi <vimarsh.zutshi@nokia.com>
[paul@pwsan.com: updated to apply]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:29:43 -07:00
Paul Walmsley 53c92d8f20 OMAP4 clock: drop the ALWAYS_ENABLED clock flag
Get rid of the ALWAYS_ENABLED clock flag - it doesn't actually do anything.
(The OMAP4 clock autogeneration scripts have been updated accordingly.)

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Benoît Cousson <b-cousson@ti.com>
2010-02-24 12:29:43 -07:00
Paul Walmsley 51c1954162 OMAP clock: drop RATE_FIXED clock flag
The RATE_FIXED clock flag is pointless.  In the OMAP1 clock code, it
simply causes the omap1_clk_round_rate() function to return the
current rate of the clock.  omap1_clk_round_rate(), however, should
never be called for a fixed-rate clock, since none of these clocks
have a .round_rate function pointer set in their struct clk records.
Similarly, in the OMAP2+ clock code, the RATE_FIXED flag just causes
the clock code to emit a warning if the OMAP clock maintainer was
foolish enough to add a .round_rate function pointer to a fixed-rate
clock.  "Doctor, it hurts when I pretend that a fixed-rate clock is
rate-changeable."  "Then don't pretend that a fixed-rate clock is
rate-changeable."  It has no functional value.  This patch drops the
RATE_FIXED clock flag, removing it from all clocks that are so marked.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:29:43 -07:00
Paul Walmsley 8c34974ab0 OMAP2 clock: drop DELAYED_APP clock flag
All of the clocks that are marked with DELAYED_APP are changed as part
of the virt_prcm_set OPP virtual clock.  On 24xx, these clocks all
need to be changed as part of a group to keep the clock tree
functional - hence the need for the VALID_CONFIG bit, which is not
present on later OMAPs.  These clocks should not be rate-changed
independently.  So prevent these clocks from being changed
independently by dropping their .round_rate and .set_rate function
pointers.  It then turns out that the DELAYED_APP clock flag is no
longer useful, so drop it and the associated code and renumber the
clock flags.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:29:42 -07:00
Paul Walmsley 5173804fbb OMAP2430 clock: make func_96m_ck parent-selectable
func_96m_ck was incorrectly marked as being rate-selectable, when in
fact it is only parent-selectable.  Remove the .set_rate and .round_rate
function pointers for this clk.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:29:42 -07:00
Paul Walmsley 81b34fbecb OMAP2 clock: split OMAP2420, OMAP2430 clock data into their own files
In preparation for multi-OMAP2 kernels, split
mach-omap2/clock2xxx_data.c into mach-omap2/clock2420_data.c and
mach-omap2/clock2430_data.c.  2430 uses a different device space
physical memory layout than past or future OMAPs, and we use a
different virtual memory layout as well, which causes trouble for
architecture-level code/data that tries to support both.  We tried
using offsets from the virtual base last year, but those patches never
made it upstream; so after some discussion with Tony about the best
all-around approach, we'll just grit our teeth and duplicate the
structures.  The maintenance advantages of a single kernel config that
can compile and boot on OMAP2, 3, and 4 platforms are simply too
compelling.

This approach does have some nice benefits beyond multi-OMAP 2 kernel
support.  The runtime size of OMAP2420-specific and OMAP2430-specific
kernels is smaller, since unused clocks for the other OMAP2 chip will
no longer be compiled in.  (At some point we will mark the clock data
__initdata and allocate it during registration, which will eliminate
the runtime memory advantage.)  It also makes the clock trees slightly
easier to read, since 2420-specific and 2430-specific clocks are no
longer mixed together.

This patch also splits 2430-specific clock code into its own file,
mach-omap2/clock2430.c, which is only compiled in for 2430 builds -
mostly for organizational clarity.

While here, fix a bug in the OMAP2430 clock tree: "emul_ck" was
incorrectly marked as being 2420-only, when actually it is present on
both OMAP2420 and OMAP2430.

Thanks to Tony for some good discussions about how to approach this
problem.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:29:42 -07:00
Paul Walmsley 657ebfadc1 OMAP3/4 clock: split into per-chip family files
clock34xx_data.c now contains data for the OMAP34xx family, the
OMAP36xx family, and the OMAP3517 family, so rename it to
clock3xxx_data.c.  Rename clock34xx.c to clock3xxx.c, and move the
chip family-specific clock functions to clock34xx.c, clock36xx.c, or
clock3517.c, as appropriate.  So now "clock3xxx.*" refers to the OMAP3
superset.

The main goal here is to prepare to compile chip family-specific clock
functions only for kernel builds that target that chip family.  To get to
that point, we also need to add CONFIG_SOC_* options for those other
chip families; that will be done in future patches, planned for 2.6.35.

OMAP4 is also affected by this.  It duplicated the OMAP3 non-CORE DPLL
clkops structure.  The OMAP4 variant of this clkops structure has been
removed, and since there was nothing else currently in clock44xx.c, it
too has been removed -- it can always be added back later when there
is some content for it.  (The OMAP4 clock autogeneration scripts have been
updated accordingly.)

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Ranjith Lohithakshan <ranjithl@ti.com>
Cc: Tony Lindgren <tony@atomide.com>
2010-02-24 12:16:15 -07:00
Paul Walmsley b92c170d01 OMAP clock: drop .id field; ensure each clock has a unique name
After the clkdev conversion, the struct clk.id field became
superfluous, so, drop it.  Bring the clock names closer to the TRMs
and ensure they are unique for debugfs.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:16:13 -07:00
Paul Walmsley f71eddb158 OMAP clock: compress clock flags down to a u8
There are now only eight OMAP clock flags, so renumber the flags to
fit in a u8 and shrink the size of struct clk.flags from a u32 to a
u8.  The intention is to save memory.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:06 -07:00
Paul Walmsley 1a3377176b OMAP2 clock: drop CONFIG_PARTICIPANT clock flag
It turns out that the only purpose of the CONFIG_PARTICIPANT clock
flag is to prevent omap2_clk_set_rate() and omap2_clk_set_parent()
from being executed on clocks with that flag set.  The rate-changing
component can be more directly accomplished by dropping the .set_rate
and .round_rate function pointers from those CONFIG_PARTICIPANT struct
clks.  As far as the parent-changing component is concerned, it turns
out that none of the CONFIG_PARTICIPANT clocks have multiple parent
choices, so all that is necessary is for omap2_clk_set_parent() to
bail out early if the new parent is equal to the old parent.
Implement this change and get rid of the flag, which has always had a
confusing name (it appears to be a Kconfig option, falsely).

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley 17d092733d OMAP2xxx clock: drop DELAYED_APP flag from non-clksel clocks
The DELAYED_APP flag is effective only with clksel clocks, so drop it from
clocks that are not rate-changeable or that use non-clksel rate changing code
(e.g., virt_prcm_set).

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley 94297784ee OMAP2xxx clock: GFX functional clock rates are not independently changeable
According to the OMAP242x TRM Rev X Figure 5-15 "Clock Output Control
- Functional Clocks 2", the GFX functional clocks should be marked
both DELAYED_APP and CONFIG_PARTICIPANT, meaning that their rates must
be reprogrammed as part of a larger OPP set change.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley c78a05e8e4 OMAP4 clock: drop the CLOCK_IN_OMAP4430 clock flag
The CLOCK_IN_OMAP4430 clock flag is not currently needed in the OMAP4
ES1 clock tree, and platform discrimination via clock flags is
deprecated in favor of the clkdev mechanism, so, drop it.  (The OMAP4
clock tree autogeneration script has been updated accordingly.)

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley 93340a2294 OMAP2/3/4 clock: fix DPLL multiplier value errors; also copyrights, includes, documentation
The maximum DPLL multiplier (M) values for OMAP2xxx and OMAP3xxx are
one increment higher than they should be.  See for example the
OMAP242x TRM Rev X Section 5.10.6 "Clock Generator Registers" and the
OMAP36xx TRM Rev C Table 3-202 "CM_CLKSEL1_PLL".  Programming a 0 into
the DPLL's M register bitfield is valid for OMAP2/3 and indicates that
the DPLL should enter MN-bypass mode.  Also, increase the minimum
multiplier (M) value for the DPLL rate rounding code from 1 to 2, to
ensure that it does not inadvertently put the DPLL into bypass.

Note that the register documentation in the OMAP2xxx and OMAP3xxx TRMs
does not make clear that the actual DPLL divider value (the "N") is
the content of the appropriate register bitfield for the N value,
_plus one_.  (In other words, an N register bitfield of 0 indicates a
DPLL divider value of 1.)  This is only clearly documented in the
OMAP4430 TRM, in, for example, OMAP4430 TRM Rev A Table 3-1167
"CM_CLKSEL_DPLL_USB".

While here, update copyrights, add kerneldoc for struct dpll_data,
drop the unused struct dpll_data.max_tolerance field, remove some
unnecessary #includes in DPLL-related code, and replace the #include
of <linux/module.h> with <linux/list.h>, which is what was really
needed.  The OMAP4 clock autogenerator script has been updated
accordingly.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
2010-02-24 12:15:03 -07:00
Vishwanath BS 7356f0b26b OMAP3 clock: add support for 192Mhz DPLL4M2 output
In 3630, DPLL4M2 output can be 96MHz or 192MHz (for SGX to run at
192). This patch has changes to support this feature. 96MHz clock is
generated by dividing 192Mhz clock by 2 using CM_CLKSEL_CORE register.
SGX can select Core Clock, 192MHz clock or CM_96M_FCLK as it's
functional clock. In summary changes done are:
1. Added a feature called omap3_has_192mhz_clk and enabled for 3630
2. Added a new clock node called omap_192m_alwon_ck
3. Made omap_96m_alwon_fck to derive its clock from omap_192m_alwon_ck

Signed-off-by: Vishwanath BS <Vishwanath.bs@ti.com>
[paul@pwsan.com: fixed whitespace]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:03 -07:00
Vishwanath BS 678bc9a2ea OMAP3 clock: Introduce 3630 DPLL4 HSDivider changes
Divider (M2, M3, M4, M5 and M6) field width has been increased by 1 bit
in 3630. This patch has changes to accommodate this in CM dynamically
based on chip version.
Basically new clock nodes have been added for 3630 DPLL4 M2,M3,M4,M5 and
M6 and value of these nodes are used if cpu type is 3630.

Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
[paul@pwsan.com: updated to apply on 2.6.34 queue; comments added]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:03 -07:00
Richard Woodruff 358965d7ba OMAP3 clock: introduce DPLL4 Jtype
DPLL4 for 3630 introduces a changed block called j type dpll, requiring
special divisor bits and additional reg fields. To allow for silicons to
use this, this is introduced as a flag and is enabled for 3630 silicon.
OMAP4 also has j type dpll for usb.

Tested with 3630 ZOOM3 and OMAP3430 ZOOM2

Signed-off-by: Richard Woodruff <r-woodruff2@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Vishwanath BS <Vishwanath.bs@ti.com>
[paul@pwsan.com: added some comments; updated copyrights and credits; fixed
 some style issues]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:02 -07:00
Abhijit Pagare 91808a81fe ARM: OMAP4 clock domain: Add check for avoiding dependency related update.
A check is added for avoiding the sleep/wakeup dependency updates
for OMAP4 as the structures for the dependencies are currently absent.

Signed-off-by: Abhijit Pagare <abhijitpagare@ti.com>
[paul@pwsan.com: added warnings, explanatory comment, copyright update]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:14:59 -07:00
Mike Turquette a7e069fc5a OMAP3630: Clock: Workaround for DPLL HS divider limitation
This patch implements a workaround for the DPLL HS divider limitation
in OMAP3630 as given by Errata ID: i556.

Errata:
When PWRDN bit is set, it resets the internal HSDIVIDER divide-by value (Mx).
The reset value gets loaded instead of the previous value.
The following HSDIVIDERs exhibit above behavior:
. DPLL4 : M6 / M5 / M4 / M3 / M2 (CM_CLKEN_PLL[31:26] register bits)
. DPLL3 : M3 (CM_CLKEN_PLL[12] register bit).

Work Around:
It is mandatory to apply the following sequence to ensure the write
value will
be loaded in DPLL HSDIVIDER FSM:
The global sequence when using PWRDN bit is the following:
. Disable Mx HSDIVIDER clock output related functional clock enable bits
        (in CM_FCLKEN_xxx / CM_ICLKEN_xxx)
. Enable PWRDN bit of HSDIVIDER
. Disable PWRDN bit of HSDIVIDER
. Read current HSDIVIDER register value
. Write different value in HSDIVIDER register
. Write expected value in HSDIVIDER register
. Enable Mx HSDIVIDER clock output related functional clocks
        (CM_FCLKEN_xxx / CM_ICLKEN_xxx)

Signed-off-by: Mike Turquette <mturquette@ti.com>
Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
Signed-off-by: Vijaykumar GN <vijaykumar.gn@ti.com>
[paul@pwsan.com: updated patch to apply; made workaround function static;
 marked as being 36xx-specific]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:06:00 -07:00
Thara Gopinath c23a97d377 OMAP: HWMOD: Add support for early device register into omap device layer
This patch adds support in omap device layer to register devices
as early platform devices. Certain devices needed during system boot up
like timers, gpio etc can be registered as early devices. This will
allow for them to be probed very early on during system boot up.
This patch adds a parameter is_early_device in omap_device_build.
Depending on this parameter a call to early_platform_add_devices
or platform_register_device is made.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:58 -07:00
Thara Gopinath 358f0e630d OMAP3: hwmod: support to specify the offset position of various SYSCONFIG register bits.
In OMAP3 Some modules like Smartreflex do not have the regular sysconfig
register.Instead clockactivity bits are part of another register at a
different bit position than the usual bit positions 8 and 9.

In OMAP4, a new scheme is available  due to the new protocol
between the PRCM and the IPs. Depending of the scheme, the SYSCONFIG
bitfields position will be different.
The IP_REVISION register should be at offset 0x00.
It should contain a SCHEME field. From this we can determine whether
the IP follows legacy scheme or the new scheme.

31:30 SCHEME  Used to distinguish between old scheme and current.
 Read 0x0:  Legacy protocol.
 Read 0x1:  New PRCM protocol defined for new OMAP4 IPs

For legacy IP
 13:12 MIDLEMODE
 11:8  CLOCKACTIVITY
 6     EMUSOFT
 5     EMUFREE
 4:3   SIDLEMODE
 2     ENAWAKEUP
 1     SOFTRESET
 0     AUTOIDLE

For new OMAP4 IP's, the bit position in SYSCONFIG is (for simple target):
 5:4   STANDBYMODE (Ex MIDLEMODE)
 3:2   IDLEMODE (Ex SIDLEMODE)
 1     FREEEMU (Ex EMUFREE)
 0     SOFTRESET

Unfortunately In OMAP4 also some IPs will not follow any of these
two schemes. This is the case at least for McASP, SmartReflex
and some security IPs.

This patch introduces a new field sysc_fields in omap_hwmod_sysconfig which
can be used by the hwmod structures to specify the offsets for the
sysconfig register of the IP.Also two static structures
omap_hwmod_sysc_type1 and omap_hwmod_sysc_type2 are defined
which can be used directly to populate the sysc_fields if the IP follows
legacy or new OMAP4 scheme. If the IP follows none of these two schemes
a new omap_hwmod_sysc_fields structure has to be defined and
passed as part of omap_hwmod_sysconfig.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:58 -07:00
Vishwanath BS 5eb75f5578 OMAP3 clock: Remove FreqSel for 3630
DPLL_FREQSEL field in CLKEN_PLL register is no longer valid for
OMAP3630. So remove references to that.

Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
Cc: Sergei Shtylyov <sshtylyov@mvista.com>
[paul@pwsan.com: added comment fix from Sergei Shtylyov]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:57 -07:00
Kevin Hilman 0cc9314eaf OMAP2/3: PRCM: fix misc. compiler warnings
- missing return in omap_prcm_get_reset_sources()
- potential use of uninitialized variable in omap_prcm_arch_reset()

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:56 -07:00
Sanjeev Premi a51ba28407 OMAP3 clock: Check return values for clk_get()
This patch checks if clk_get() returned success for
the clocks used in function omap2_clk_arch_init().

This version incorporates review comments from
Kevin Hilman and Paul Walmsley.

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:56 -07:00
Ranjith Lohithakshan 3cc4a2fc2e AM35xx: Add clock support for new modules on AM35xx
This patch adds clock support for the following AM35xx modules
	- Ethernet MAC
	- CAN Controller (HECC)
	- New MUSB OTG Controller with integrated Phy
	- Video Processing Front End (VPFE)
	- Additional UART (UART4)

Signed-off-by: Ranjith Lohithakshan <ranjithl@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:55 -07:00
Ranjith Lohithakshan 419cc97d36 OMAP2/3 clock: Extend find_idlest() to pass back idle state value
Current implementation defines clock idle state indicators based on the
cpu information (cpu_is_omap24xx() or cpu_is_omap34xx()) in a system wide
manner. This patch extends the find_idlest() function in clkops to pass
back the idle state indicator for that clock, thus allowing idle state
indicators to be defined on a per clock basis if required.

This is specifically needed on AM35xx devices as the new IPSS clocks
indicates the idle status (0 is idle, 1 is ready) in a way just
opposite to how its handled in OMAP3 (0 is ready, 1 is idle).

Signed-off-by: Ranjith Lohithakshan <ranjithl@ti.com>
[paul@pwsan.com: updated to apply after commit 98c45457 et seq.]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:54 -07:00
Thara Gopinath cde08f81b1 OMAP3 PM: Adding counters for power domain logic off and mem off during retention.
This patch adds counters to keep track of whether the powerdomain
logic or software controllable memory banks are turned off when
the power domain enters retention. During power domain retention
if logic gets turned off, the scenario is known as Open Switch Retention.
Also during retention s/w controllable memory banks of a power
domain can be chosen to be kept in retention or off.

This patch adds one counter per powerdomain to track the power domain
logic state during retention. Number of memory bank state counters
added depends on the number of software controllable memory banks
of the powerdomain. To view these counters do
	cat ../debug/pm_debug/count

Signed-off-by: Thara Gopinath <thara@ti.com>
[paul@pwsan.com: conditional expressions simplified; counter increment
 code moved to its own function]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:50 -07:00
Thara Gopinath 4133a44e28 OMAP3 PM: Defining .pwrsts_logic_ret field for core power domain structure
This patch adds the flag .pwrsts_logic_ret info for the core power domain
in the associated powerdomain structure. This flag specifies the states
core domain logic can hit in event of the domain entering retention.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:50 -07:00
Thara Gopinath 1e3d0d2ba9 OMAP2/3 PM: Adding powerdomain APIs for reading the next logic and mem state
This patch adds APIs pwrdm_read_logic_retst and
pwrdm_read_mem_retst for reading the next programmed
logic and memory state a powerdomain is to hit in event
of the next power domain state being retention.
These are needed for OSWR support.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:49 -07:00
Tero Kristo b024b542c3 OMAP3: Clock: Added IDLEST definitions for SGX
Added definitions for OMAP3430ES2_ST_SGX_SHIFT and OMAP3430ES2_ST_SGX_MASK
as these were missing.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:48 -07:00
Kevin Hilman dfa6d6f892 OMAP3: clock: use std _MASK suffix for CM_FCLKEN_IVA2 defines
Add _MASK suffix to CM_FCLKEN_IVA2 bitfieds to conform with the rest
of the usage in cm-regbits-34xx.h of using _SHIFT and _MASK suffixes.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:48 -07:00
Kevin Hilman 24d82e3421 OMAP: omap_device: when 'called from invalid state', print state
The omap_device_[enable|idle|shutdown] functions print a warning
when called from an invalid state.  Print the invalid state in
the warning messages.  This also uses __func__ to get the function
name.

Also, move the entire print string onto a single line to facilitate
grepping or error messages.  Recent discussions on LKML show
strong preference for grep-able code vs. strict 80 column limit.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:45 -07:00
Kevin Hilman 0007122ad8 OMAP: omap_device: add omap_device_is_valid()
The omap_device struct contains a 'struct platform_device'.  Normally,
converting a platform_device pointer to an omap_device pointer
consists of simply doing a container_of(), as is done currently by the
to_omap_device() macro.

However, if this is attempted when using platform_device that has not
been created as part of the omap_device creation, the container_of()
will point to a memory location before the platform_device pointer
which will contain random data.

Therefore, we need a way to detect valid omap_device pointers.  This
patch solves this by using the simple magic number approach.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:45 -07:00
Tomi Valkeinen 69b2048f44 OMAP: DSS2: move timing functions
Move check/set/get_timings() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 3651131268 OMAP: DSS2: move set/get_wss()
Move set/get_wss() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 37ac60e414 OMAP: DSS2: move enable/disable/suspend/resume
Move enable/disable/suspend/resume from omap_dss_device to
omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 18946f62c6 OMAP: DSS2: move update() and sync()
Move update() and sync() from omap_dss_device to omap_dss_driver.

Also, update was hardcoded to use virtual channel 0. This patch adds a
parameter that specifies the VC.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 446f7bff70 OMAP: DSS2: move set/get_update_mode()
Move set/get_update_mode() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 225b650d41 OMAP: DSS2: move enable/get_te()
Move enable/get_te() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen a269950405 OMAP: DSS2: move get_recommended_bpp()
Move get_recommended_bpp() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 96adceceed OMAP: DSS2: move get_resolution()
Move get_resolution() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen a2faee84f6 OMAP: DSS2: move enable/disable_channel to overlay manager
Move enable/disable_channel() from omap_dss_device to overlay manager.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 3f71cbe736 OMAP: DSS2: move wait_vsync()
Move wait_vsync() from omap_dss_device to overlay manager.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 87424e1bff OMAP: DSS2: move get/set_rotate()
Move get/set_rotate() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 8d8aa61dcf OMAP: DSS2: move set/get_mirror()
Move set/get_mirror() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00