Commit graph

109 commits

Author SHA1 Message Date
Stepan Moskovchenko c4bd2eebee msm: iomap: Addresses and IRQs for 2nd GFX core IOMMU
Add register addresses and IRQ numbers for the IOMMU used
for the second 2D graphics core.

Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-11-30 13:53:45 -08:00
Stepan Moskovchenko 23513c3b39 msm: iommu: Increase maximum MID size to 5 bits
On msm8x60, the MID field on the AXI connection to the
IOMMU can be up to five bits wide. Thus, allow the IOMMU
context platform data to map up to 32 MIDs.

Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-11-30 13:53:08 -08:00
Anand Gadiyar 963fec4e0f ARM: 6484/1: fix compile warning in mm/init.c
Commit 7c63984b86 (ARM: do not define VMALLOC_END relative to PAGE_OFFSET)
changed VMALLOC_END to be an explicit value. Before this, it was
relative to PAGE_OFFSET and therefore converted to unsigned long
as PAGE_OFFSET is an unsigned long. This introduced the following
build warning. Fix this by changing the explicit defines of
VMALLOC_END to be unsigned long.

  CC      arch/arm/mm/init.o
arch/arm/mm/init.c: In function 'mem_init':
arch/arm/mm/init.c:606: warning: format '%08lx' expects type 'long unsigned int', but argument 12 has type 'unsigned int'

Signed-off-by: Anand Gadiyar <gadiyar@ti.com>
Acked-by: Uwe Kleine-K <u.kleine-koenig@pengutronix.dee>
Acked-by: Nicolas Pitre <nicolas.pitre@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-11-21 22:05:56 +00:00
David Brown 44d4a4f784 msm: make constant unsigned long to correct format warning
Define VMALLOC_END as an unsigned long to match expected type.
Eliminates a warning:

arch/arm/mm/init.c: In function 'mem_init':
arch/arm/mm/init.c:606: warning: format '%08lx' expects type
   'long unsigned int', but argument 12 has type 'unsigned int'

Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-11-16 12:28:05 -08:00
Daniel Walker 06125ff051 msm: fix compile failure when no debug uart is selected
If the board has a debug uart the user is given a choice of which
uart to use. The user can also select NONE, which means not to use one.
In most of our header files when NONE is selected nothing is defined
for MSM_DEBUG_UART_PHYS or MSM_DEBUG_UART_BASE. This causes a compile
failure in debug-macro.S which expect something to be defined there.

Example of the failure,

arch/arm/kernel/built-in.o: In function `hexbuf':
linux-2.6/arch/arm/kernel/debug.S:186: undefined reference to `MSM_DEBUG_UART_PHYS'
linux-2.6/arch/arm/kernel/debug.S:186: undefined reference to `MSM_DEBUG_UART_BASE'

This fixes the compile failure by adding an ifdef to debug-macro.S
that removes all the debug uart code in the case of NONE.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-29 15:56:16 -07:00
Daniel Walker bcd72c3e0a msm: fix debug-macro.S build failure
Originally there was an ifdef case to handle when no debug uart
was selected. In commit 0ea1293009
that case was removed which causes the following build failure,

linux-2.6/arch/arm/kernel/debug.S: Assembler messages:
linux-2.6/arch/arm/kernel/debug.S:174: Error: bad instruction `addruart r1,r2'
linux-2.6/arch/arm/kernel/debug.S:176: Error: bad instruction `waituart r2,r3'
linux-2.6/arch/arm/kernel/debug.S:177: Error: bad instruction `senduart r1,r3'
linux-2.6/arch/arm/kernel/debug.S:178: Error: bad instruction `busyuart r2,r3'
linux-2.6/arch/arm/kernel/debug.S:190: Error: bad instruction `addruart r1,r2'

This is a partial revert to add back the case which was removed with
two caveats. First the API for the addruart macro was updated, and
the new addruart case now return 0xfff00000 so that a know IO mapping
is created instead of a random one.

Cc: Jeremy Kerr <jeremy.kerr@canonical.com>
Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Cc: Jason Wang <jason77.wang@gmail.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Nicolas Pitre <nico@fluxnic.net>
Cc: Russell King - ARM Linux <linux@arm.linux.org.uk>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-29 15:56:04 -07:00
Jeremy Kerr 0ea1293009 arm: return both physical and virtual addresses from addruart
Rather than checking the MMU status in every instance of addruart, do it
once in kernel/debug.S, and change the existing addruart macros to
return both physical and virtual addresses. The main debug code can then
select the appropriate address to use.

This will also allow us to retreive the address of a uart for the MMU
state that we're not current in.

Updated with fixes for OMAP from Jason Wang <jason77.wang@gmail.com>
and Tony Lindgren <tony@atomide.com>, and fix for versatile express from
Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>.

Signed-off-by: Jeremy Kerr <jeremy.kerr@canonical.com>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Signed-off-by: Jason Wang <jason77.wang@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Tested-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-10-20 00:27:33 -04:00
Russell King 3c00079b31 Merge branch 'msm-core' of git://codeaurora.org/quic/kernel/dwalker/linux-msm into devel-stable 2010-10-19 19:55:59 +01:00
Stepan Moskovchenko d9c8279b32 msm: Platform data for msm8x60 IOMMUs
Add the platform data for the IOMMUs found on the Qualcomm
msm8x60 SoC.

Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:52 -07:00
Stepan Moskovchenko 0720d1f052 msm: Add MSM IOMMU support
Add support for the IOMMUs found on the upcoming Qualcomm
MSM8x60 chips. These IOMMUs allow virtualization of the
address space used by most of the multimedia cores on these
chips.

Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:50 -07:00
Jeff Ohlstein 998ba079fe msm: physical offset for MSM8X60
The MSM8x60 has a different physical memory offset than other targets.

Signed-off-by: Jeff Ohlstein <johlstei@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:46 -07:00
Daniel Walker 46fe5f29e3 msm: allow uart to be conditionally disabled
Some MSM targets don't select the debug UART in this way. For those we
need to disable this selection mechanism.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: Jeff Ohlstein <johlstei@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:43 -07:00
Daniel Walker 4ca06de368 msm: dma: add stub functions for dma features not yet present on 8x60
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: Jeff Ohlstein <johlstei@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:42 -07:00
Steve Muckle f880c5649e msm: irq: rename existing entry-macro to entry-macro-vic
The existing MSM irq entry macro is specific to a VIC
implementation. Renaming this makes room for irq support based on
other interrupt controllers.

Signed-off-by: Steve Muckle <smuckle@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:38 -07:00
Steve Muckle a55df6edcf msm: MSM8X60 RUMI3 board support
Board configuration for MSM8X60 emulation on RUMI3.

Signed-off-by: Steve Muckle <smuckle@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:37 -07:00
Jeff Ohlstein 672039f035 msm: timer: support 8x60 timers
Signed-off-by: Jeff Ohlstein <johlstei@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:36 -07:00
Abhijeet Dharmapurikar 01eb4f5c77 msm: irqs-8x60: interrupt map
Define the interrupt map in irq-8x60.h

Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:35 -07:00
Steve Muckle ed1f31b4b7 msm: initial irq definitions for MSM8X60
IRQ assignments are different for MSM8X60 than other existing MSMs.

Signed-off-by: Steve Muckle <smuckle@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:34 -07:00
Steve Muckle 6cf6dfefe1 msm: io: MSM8X60 io support
MSM8X60 has different IO mappings than previous MSMs.

Signed-off-by: Steve Muckle <smuckle@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-08 15:12:33 -07:00
Gregory Bean 10c4580e79 msm: gpio: Remove tlmm routines obsoleted by gpiomux.
Now that all supported gpio_tlmm_config-using boards
are using gpiomux, remove the deprecated code.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-06 09:01:17 -07:00
Gregory Bean 1963a2afc8 msm: add gpiomux api for gpio multiplex & configuration.
Add the 'gpiomux' api, which addresses the following shortcomings
of existing tlmm api:

- gpio power-collapse, which is managed by a peripheral processor on
  other targets, must be managed by the application processor on the 8x60.
- The enable/disable flag of the legacy gpio_tlmm_config api
  is not applicable on the 8x60, and causes confusion.
- The gpio 'direction' bits are meaningless for all func_sel
  configurations except for generic-gpio mode (func_sel 0), in which
  case the gpio_direction_* functions should be used.  Having these
  bits in the tlmm api leads to confusion and misuse of the gpiolib
  api, and they have been removed in gpiomux.
- The functional api of the legacy system ran contrary to the typical
  use-case, which is a single massive configuration at boot.  Rather
  than forcing hundreds of 'config' function calls, the new api
  allows data to be configured with a single table.

gpiomux_get and gpiomux_put are meant to be called automatically
when gpio_request and gpio_free are called, giving automatic
gpiomux/tlmm control to those drivers/lines with simple
power profiles - in the simplest cases, an entry in the gpiomux table
and the correct usage of gpiolib is all that is required to get proper
gpio power control.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-10-06 09:01:15 -07:00
Nicolas Pitre 7c63984b86 ARM: do not define VMALLOC_END relative to PAGE_OFFSET
VMALLOC_END is supposed to be an absolute value, while PAGE_OFFSET may
vary depending on the selected user:kernel memory split mode through
CONFIG_VMSPLIT_*.  In fact, the goal of moving PAGE_OFFSET down is to
accommodate more directly addressed RAM by the kernel below the vmalloc
area, and having VMALLOC_END move along PAGE_OFFSET is rather against
the very reason why PAGE_OFFSET can be moved in the first place.

Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
2010-10-01 22:28:19 -04:00
Sahitya Tummala b5d643de3e msm: mmc: Add msm prefix to platform data structure
Rename mmc_platform_data to msm_mmc_platform_data as it is used
only by MSM platform.

Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-08-09 15:48:23 -07:00
Sahitya Tummala 28d6c3db67 msm: trout: Remove extern declaration from source file
Add msm_add_sdcc() prototype to mach/board.h to fix the
checkpatch warning.

Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-08-09 15:46:31 -07:00
Pavel Machek 923a081c72 Add GPIO support for HTC Dream.
Signed-off-by: Pavel Machek <pavel@ucw.cz>
[dwalker@codeaurora.org: renamed to trout, checkpatch cleanup]
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-06-15 13:19:43 -07:00
Linus Torvalds da7806f9b0 Merge branch 'msm-mmc_sdcc' of git://codeaurora.org/quic/kernel/dwalker/linux-msm
* 'msm-mmc_sdcc' of git://codeaurora.org/quic/kernel/dwalker/linux-msm:
  drivers: mmc: msm_sdcc: Add EMBEDDED_SDIO support
  mmc: msm_sdcc: Fix issue where clocks could be disabled mid transaction
  mmc: msm_sdcc: Fix the dma exec function to use the proper delays
  mmc: msm_sdcc: Don't set host->curr.mrq until after we're sure the busclk timer won't fire
  mmc: msm_sdcc: Enable busclk idle timer for power savings
  mmc: msm_sdcc: Don't disable interrupts while suspending
  mmc: msm_sdcc: Fix issue where we might not end a sucessfull request
  mmc: msm_sdcc: Featurize busclock power save and disable it by default
  mmc: msm_sdcc: Fix bug where busclk expiry timer was not properly disabled
  mmc: msm_sdcc: Reduce command timeouts and improve reliability.
  mmc: msm_sdcc: Schedule clock disable after probe
  mmc: msm_sdcc: Wrap readl/writel calls with appropriate clk delays
  mmc: msm_sdcc: Driver clocking/irq improvements
  msm: Add 'execute' datamover callback
  mmc: msm_sdcc: Snoop SDIO_CCCR_ABORT register
  mmc: msm_sdcc: Clean up clock management and add a 10us delay after enabling clocks
2010-05-21 14:38:35 -07:00
Daniel Walker 41f04b17b6 msm: physical offset for MSM7X30
The MSM7x30 does not have a separate bank of memory for shared
memory communication with the radio CPU.  Set the kernel base
address 2MB in, to use this first 2MB for this purpose.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:51 -07:00
Daniel Walker c83b2bf66a msm: io: add io support for 7x30
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:49 -07:00
Daniel Walker 2f2a74e637 msm: dma: add 7x30 security domain abstraction
The MSM SOC's DMA controller contains several security domains.
On the MSM7x00, only security domain 3 is accessible to our CPU.
The 7x30, however, uses security domain 2.  Fix up the register
definition macros to select this appropriately, based on
configured target.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:46 -07:00
Daniel Walker 184d252acd msm: add msm_iomap-7x30.h for MSM7x30 support
Add a header describing the io regions for MSM7x30.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:41 -07:00
Daniel Walker 1b54b39eaf msm: irqs: add irqs-7x30.h for MSM7x30 support
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:40 -07:00
Daniel Walker 81d658ac64 msm: physical offset for QSD8x50
Support different RAM base addresses used by Qualcomm SOCs, with
QSD8x50 as the first addtional one.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:37 -07:00
Daniel Walker cf62ffae25 msm: io: add io support for 8x50
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:35 -07:00
Daniel Walker eb61bf8559 msm: add msm_iomap-8x50.h for QSD8x50 support
Add a header describing the io regions for QSD8x50.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:29 -07:00
Daniel Walker e502c3777f msm: irqs: add irqs-8x50.h for QSD8x50 support
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:27 -07:00
Gregory Bean 1de238e0eb msm: add tlmm support for gpio.
GPIO support for Qualcomm SOCs requires interaction with the
radio (baseband processor). This API allows the different boards
to enable GPIO through the radio processor in a generic way.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:22 -07:00
Daniel Walker 5e96da5d50 msm: generalize clock support.
The 'PCOM' method of clock control (commands issued to the radio
CPU) is shared across several (but not all) Qualcomm SOCs.
Generalize this clock mechanism so these other SOCs can be added.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:08:20 -07:00
Gregory Bean ec4d79255c msm: add sirc interrupt controller driver.
Scorpion-based SOCs from Qualcomm use a different interrupt
controller 'sirc'.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:07:56 -07:00
Gregory Bean d2e753bf93 msm: generialize iomap to support multiple SOCs.
msm_iomap.h is specific to the MSM7x00 series devices.  Generalize
this in preparation to support more devices.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:07:54 -07:00
Gregory Bean 8f90c7b60d msm: generialize IRQ to support multiple SOCs.
irqs.h is specific to the MSM7x00 series devices.  Generalize
this in preparation to support more devices.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
2010-05-13 16:07:53 -07:00
Daniel Walker 29d3dedf22 arm: msm: video: add msm_fb.h
Also drops the old mddi structure, which conflicts with the new
file.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-05-12 09:19:41 -07:00
Daniel Walker 79848a2a73 arm: msm: smd: checkpatch clean up of smd/proc_comm
This cleans up coding style. There are no run time changes.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-05-12 09:15:39 -07:00
Dima Zavin b42dc44afc arm: msm: correctly signal the apps-to-modem irq in smd/proc_comm
Signed-off-by: Dima Zavin <dima@android.com>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-05-12 09:15:35 -07:00
Brian Swetland 636eb9cbae msm: smd: provide atomic channel writes
Some smd clients may write from multiple threads, in which case it's
not safe to call smd_write without holding a lock.  smd_write_atomic()
provides the same functionality as smd_write() but obtains the smd
lock first.

Signed-off-by: Brian Swetland <swetland@google.com>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-05-12 09:15:31 -07:00
Brian Swetland 2eb44eb9c8 [ARM] msm: shared memory interface for baseband processor ipc
This code provides the low level interface to the "shared memory
state machine" (smsm), and the virtual serial channels (smd), used
to communicate with the baseband processor.  Higher level transports
(rpc, ethernet, AT command channel, etc) ride on top of this.

Signed-off-by: Brian Swetland <swetland@google.com>
2010-05-12 09:14:52 -07:00
Steve Muckle 4783de9bba arm: msm: status for vreg
Keep track of the success/failure of the last vreg proc comm
command, and return that on debugfs reads.

Signed-off-by: Steve Muckle <smuckle@quicinc.com>
2010-05-12 09:14:36 -07:00
Daniel Walker 43b39f9f04 arm: msm: add cpu frequency controls
This adds acpuclock-arm11.c from Google. This provides control
over the cpu frequency for arm11 cpu's.

This has shared authorship between Google, and Qualcomm. Most
of it was written by Mike Chan at Google.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-05-12 09:14:20 -07:00
San Mehat 5b00f40f90 msm: Add 'execute' datamover callback
Based on a patch from Brent DeGraaf:

"The datamover supports channels which can be shared amongst devices.
As a result, the actual data transfer may occur some time after the
request is queued up. Some devices such as mmc host controllers
will timeout if a command is issued too far in advance of the actual
transfer, so if dma to other devices on the same channel is already
in progress or queued up, the added delay can cause pending transfers
to fail before they start. This change extends the api to allow a
user callback to be invoked just before the actual transfer takes
place, thus allowing actions directly associated with the dma
transfer, such as device commands, to be invoked with precise timing.
Without this mechanism, there is no way for a driver to realize
this timing. Also adds a user pointer to the command structure for use
by the caller to reference information that may be needed by the
callback routine for proper identification and processing associated
with that specific request. This change is necessary to fix problems
associated with excessive command timeouts and race conditions in the
mmc driver."

This patch also fixes all the callers of msm_dmov_enqueue_cmd() to
ensure their callback function is NULL.

Signed-off-by: San Mehat <san@google.com>
Cc: Brent DeGraaf <bdegraaf@quicinc.com>
Cc: Brian Swetland <swetland@google.com>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2010-03-18 12:58:05 -07:00
Tony Lindgren 4e6d488af3 ARM: 5910/1: ARM: Add tmp register for addruart and loadsp
Otherwise more complicated uart configuration won't be possible.
We can use r1 for tmp register for both head.S and debug.S.

NOTE: This patch depends on another patch to add the the tmp register
into all debug-macro.S files. That can be done with:

$ sed -i -e "s/addruart,rx|addruart, rx/addruart, rx, tmp/"
	arch/arm/*/include/*/debug-macro.S

Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-12 17:27:52 +00:00
Pavel Machek 3989d17847 HTC Dream: mmc compilation fixes
Add missing include for msm_sdcc compilation, and remove pwrsink
support that is not mainline, yet.

Signed-off-by: Pavel Machek <pavel@ucw.cz>
[dwalker@codeaurora.org : fixed indent in mmc.h]
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2009-12-10 10:14:34 -08:00
Pavel Machek 6339f6695f msm: make debugging UART (for DEBUG_LL) configurable
Provides options to select one of the three "lowspeed" UARTs
on MSM7k SoCs for DEBUG_LL output from the zImage decompressor
and kernel.

Signed-off-by: Brian Swetland <swetland@google.com>
Signed-off-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
2009-11-20 06:40:05 -08:00
Russell King be093beb60 [ARM] pass reboot command line to arch_reset()
OMAP wishes to pass state to the boot loader upon reboot in order to
instruct it whether to wait for USB-based reflashing or not.  There is
already a facility to do this via the reboot() syscall, except we ignore
the string passed to machine_restart().

This patch fixes things to pass this string to arch_reset().  This means
that we keep the reboot mode limited to telling the kernel _how_ to
perform the reboot which should be independent of what we request the
boot loader to do.

Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-03-19 16:20:24 +00:00
Russell King 0560cf5aa5 [ARM] Add a common typesafe __io implementation
As Al did for Versatile in 2ad4f86b60,
add a typesafe __io implementation for platforms to use.  Convert
platforms to use this new simple typesafe implementation.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-11-30 11:45:54 +00:00
Nicolas Pitre b5ee900258 [ARM] remove a common set of __virt_to_bus definitions
Let's provide an overridable default instead of having every machine
class define __virt_to_bus and __bus_to_virt to the same thing.  What
most platforms are using is bus_addr == phys_addr so such is the default.

One exception is ebsa110 which has no DMA what so ever, so the actual
definition is not important except only for proper compilation.  Also
added a comment about the special footbridge bus translation.

Let's also remove comments alluding to set_dma_addr which is not
(and should not) be commonly used.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-11-28 15:36:49 +00:00
Brian Swetland f030d7b65e [ARM] msm: vreg interface to msm7k pmic
The baseband cpu owns the pmic, so voltage regulator control is only
available via a relatively limited interface through the proc_comm
transport.

Signed-off-by: Brian Swetland <swetland@google.com>
2008-10-22 02:41:00 -07:00
Brian Swetland 8a0f6f17c4 [ARM] msm: dma: various basic dma improvements and bugfixes
San:
- Propagate DM errors to the originator of the request.
- Implement msm_dmov_stop_cmd()
- Add return value to init code
- Modify msm_dmov_stop_cmd() to support ungraceful flushing

Arve:
- Disable datamover interrupt when not in use.
  We turn off the interrrupt to allow power collapse from idle.

Signed-off-by: San Mehat <san@android.com>
Signed-off-by: Arve Hjønnevåg <arve@android.com>
Signed-off-by: Brian Swetland <swetland@google.com>
2008-10-22 02:41:00 -07:00
Brian Swetland 600f7cfebe [ARM] msm: clock: provide clk_*() api support for
Makes use of the proc_comm interface to provide clock control on
MSM7X01A family SoCs.

Signed-off-by: Brian Swetland <swetland@google.com>
2008-10-22 02:41:00 -07:00
Brian Swetland bcc0f6af07 [ARM] msm: clean up iomap and devices
- Add some more peripherals (sdcc, etc) to the iomap.
- Remove virtual base addresses for devices that we should be passing
  physical addresses to drivers via resources and ioremap()ing.
- don't try to use uarts for ll debug once the mmu is enabled due to
  problems with the peripheral window
- make base addresses void __iomem * and fixup irq.c and timer.c
- Remove common.c and bring in devices.c/devices.h similar to
  the PXA architecture.

Signed-off-by: Brian Swetland <swetland@google.com>
2008-10-22 02:40:59 -07:00
Russell King a09e64fbc0 [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach
This just leaves include/asm-arm/plat-* to deal with.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 09:55:48 +01:00