[PATCH v8 00/20] OMAP2+: UART: Runtime adaptation + cleanup

2011-11-11 Thread Govindraj.R
Converting uart driver to adapt to pm runtime API's. Code re-org + cleanup. Moving some functionality from serial.c to omap-serial.c Changes involves: 1.) Cleaning up certain uart calls from sram_idle func. 2.) Removed all types of uart clock handling code from serial.c 3.) Using

[PATCH v8 05/20] OMAP2+: UART: Remove mapbase/membase fields from pdata.

2011-11-11 Thread Govindraj.R
The mapbase (start_address), membase(io_remap cookie) part of pdata struct omap_uart_port_info are removed as this should be derived within driver. Signed-off-by: Govindraj.R govindraj.r...@ti.com --- arch/arm/mach-omap2/serial.c |2 --

[PATCH v8 02/20] OMAP2+: UART: cleanup 8250 console driver support

2011-11-11 Thread Govindraj.R
We had been using traditional 8250 driver as uart console driver prior to omap-serial driver. Since we have omap-serial driver in mainline kernel for some time now it has been used as default uart console driver on omap2+ platforms. Remove 8250 support for omap-uarts. Serial_in and serial_out

[PATCH v8 08/20] OMAP2+: UART: Ensure all reg values configured are available from port structure

2011-11-11 Thread Govindraj.R
Add missing uart regs to uart_port structure which can be used in context restore. Store dll, dlh, mdr1, scr, efr, lcr, mcr reg values into uart_port structure while configuring individual port in termios function. Signed-off-by: Govindraj.R govindraj.r...@ti.com ---

[PATCH v8 03/20] OMAP2+: UART: Cleanup part of clock gating mechanism for uart

2011-11-11 Thread Govindraj.R
Currently we use a shared irq handler to identify uart activity and then trigger a timer. By default the timeout value is zero and can be set or modified from sysfs. If there was no uart activity for the period set through sysfs, the timer will expire and call timer handler this will set a flag

[PATCH v8 09/20] OMAP2+: UART: Remove uart reset function.

2011-11-11 Thread Govindraj.R
Remove the uart reset function which is configuring the TX empty irq which can now be handled within omap-serial driver. Signed-off-by: Govindraj.R govindraj.r...@ti.com --- arch/arm/mach-omap2/serial.c | 14 -- arch/arm/plat-omap/include/plat/omap-serial.h |2

[PATCH v8 07/20] OMAP2+: UART: Remove context_save and move context restore to driver

2011-11-11 Thread Govindraj.R
Remove context save function from serial.c and move context restore function to omap-serial. Remove all regs stored in omap_uart_state for contex_save/restore, reg read write funcs used in context_save/restore, io_addresses populated for read/write funcs. Clock gating mechanism was done in

[PATCH v8 04/20] OMAP2+: UART: Add default mux for all uarts.

2011-11-11 Thread Govindraj.R
Padconf wakeup is used to wakeup uart after uart fclks/iclks are gated. Rx-Pad wakeup was done by writing to rx-pad offset value populated in serial.c idle_init. Remove the direct reading and writing into rx pad. Remove the padconf field part of omap_uart_state struct and pad offsets populated.

[PATCH v8 06/20] OMAP2+: UART: Add runtime pm support for omap-serial driver

2011-11-11 Thread Govindraj.R
Adapts omap-serial driver to use pm_runtime API's. Use runtime runtime API's to handle uart clocks and obtain device_usage statics. Set runtime API's usage to irq_safe so that we can use get_sync from irq context. Auto-suspend for port specific activities and put for reg access. Moving

[PATCH v8 01/20] OMAP2+: UART: cleanup + remove uart pm specific API

2011-11-11 Thread Govindraj.R
In preparation to UART runtime conversion remove uart specific calls from pm24xx/34xx files and their definition from serial.c These func calls will no more be used with upcoming uart runtime design. 1.) omap_uart_prepare_suspend :- can be taken care with driver suspend hooks. 2.)

[PATCH v8 10/20] OMAP2+: UART: Get context loss count to context restore

2011-11-11 Thread Govindraj.R
Avoid unconditional context restore every time we gate uart clocks. Check whether context loss happened based on which we can context restore uart regs from uart_port structure. Signed-off-by: Govindraj.R govindraj.r...@ti.com --- arch/arm/mach-omap2/serial.c |2 ++

[PATCH v8 11/20] OMAP2+: UART: Move errata handling from serial.c to omap-serial

2011-11-11 Thread Govindraj.R
Move the errata handling mechanism from serial.c to omap-serial file and utilise the same func in driver file. Errata i202, i291 are moved to be handled with omap-serial Moving the errata macro from serial.c file to driver header file as from on errata will be handled in driver file itself.

[PATCH v8 12/20] OMAP2+: UART: Add wakeup mechanism for omap-uarts

2011-11-11 Thread Govindraj.R
From the runtime callbacks enable hwmod wakeups for uart which will internally enable io-pad wakeups for uarts if they have rx-pad pins set as wakeup capabale. Use the io-ring wakeup mechanism after uart clock gating and leave the PM_WKST set for uart to default reset values cleanup the code in

[PATCH v8 13/20] OMAP2+: UART: Remove old and unused clocks handling funcs

2011-11-11 Thread Govindraj.R
With runtime adaptation done remove clock_enable/disbale API's Signed-off-by: Govindraj.R govindraj.r...@ti.com --- arch/arm/mach-omap2/serial.c | 36 1 files changed, 0 insertions(+), 36 deletions(-) diff --git a/arch/arm/mach-omap2/serial.c

[PATCH v8 14/20] OMAP2+: UART: Allow UART parameters to be configured from board file.

2011-11-11 Thread Govindraj.R
From: Deepak K deepa...@ti.com The following UART parameters are defined within the UART driver: 1). Whether the UART uses DMA (dma_enabled), by default set to 0 2). The size of dma buffer (set to 4096 bytes) 3). The time after which the dma should stop if no more data is received. 4). The auto

[PATCH v8 16/20] OMAP2+: UART: remove temporary variable used to count uart instance

2011-11-11 Thread Govindraj.R
Reuse the num_uarts variable itself to count number of uarts. Signed-off-by: Govindraj.R govindraj.r...@ti.com --- arch/arm/mach-omap2/serial.c |7 ++- 1 files changed, 2 insertions(+), 5 deletions(-) diff --git a/arch/arm/mach-omap2/serial.c b/arch/arm/mach-omap2/serial.c index

[PATCH v8 17/20] OMAP2+: UART: Use custom activate func for console uart.

2011-11-11 Thread Govindraj.R
Omap-uart can be used as console uart to print early boot messages using earlyprintk so for console uart prevent hwmod reset or idling during bootup. Identify the console_uart set the id and use the custom pm_latency ops for console uart for the first time to idle console uart left enabled from

[PATCH v8 15/20] OMAP2+: UART: Make the RX_TIMEOUT for DMA configurable for each UART

2011-11-11 Thread Govindraj.R
From: Jon Hunter jon-hun...@ti.com When using DMA there are two timeouts defined. The first timeout, rx_timeout, is really a polling rate in which software polls the DMA status to see if the DMA has finished. This is necessary for the RX side because we do not know how much data we will receive.

[PATCH v8 19/20] OMAP2+: UART: Do not gate uart clocks if used for debug_prints

2011-11-11 Thread Govindraj.R
If OMAP UART is used as console uart and debug is enabled, avoid gating of uart clocks to print all debug prints. If uart clocks are gated then the debug prints from omap_device framework or hwmod framework can cause uart to enter recursive pm_runtime calls, which can cause a deadlock over power

[PATCH v8 18/20] OMAP2+: UART: Avoid uart idling on suspend for no_console_suspend usecase

2011-11-11 Thread Govindraj.R
If no_console_suspend is used we have prevent uart idling during suspend to provide debug prints. Power domain hooks can idle uarts if left enabled during system wide suspend so re-use the omap_device_disable_idle_on_suspend API's to ensure console_uart is not idled during suspend.

[PATCH v8 20/20] OMAP2+: UART: Remove omap_uart_can_sleep and add pm_qos

2011-11-11 Thread Govindraj.R
Omap_uart_can_sleep function blocks system wide low power state until uart is active remove this func and add qos requests to prevent MPU from transitioning. Keep qos request to default value which will allow MPU to transition and while uart baud rate is available calculate the latency value from

Re: [PATCH v7 11/21] OMAP2+: UART: Move errata handling from serial.c to omap-serial

2011-11-11 Thread Govindraj
Hi Jon, On Fri, Nov 11, 2011 at 5:14 AM, Jon Hunter jon-hun...@ti.com wrote: Hi Govindraj, On 10/18/2011 10:26, Govindraj.R wrote: Move the errata handling mechanism from serial.c to omap-serial file and utilise the same func in driver file. Errata i202, i291 are moved to be handled with

Re: [PATCH v7 17/21] OMAP2+: UART: Remove omap_uart_can_sleep and add pm_qos

2011-11-11 Thread Govindraj
On Fri, Nov 11, 2011 at 12:32 AM, Kevin Hilman khil...@ti.com wrote: Govindraj govindraj...@gmail.com writes: [..] I have fixed this and other uart_v7 comments and have re-based the patch series on top of 3.2-rc1 along with Tero's v9 irq chaining patches and tested the same. Available

RE: [PATCH] ARM: OMAP: PM: only register TWL with voltage layer when device is present

2011-11-11 Thread Premi, Sanjeev
-Original Message- From: Hilman, Kevin Sent: Friday, November 11, 2011 12:04 AM To: Premi, Sanjeev Cc: linux-omap@vger.kernel.org; linux-arm-ker...@lists.infradead.org; Koyamangalath, Abhilash Subject: Re: [PATCH] ARM: OMAP: PM: only register TWL with voltage layer when

Help with clk API

2011-11-11 Thread Felipe Balbi
Hi Paul, I have a doubt about using clk API to change CLKSEL_UTMI_P1 bit for a silicon errata (OMAP4460 i693) implementation. According to errata, I need to switch from external to internal clock during USB port suspend, wait 1ms and switch back from internal to external. How can I do that with

Re: [PATCH v5 4/7] arm: omap4: hwmod: introduce emu hwmod

2011-11-11 Thread Will Deacon
[Adding Benoit to CC]. On Thu, Nov 10, 2011 at 09:02:14AM +, Paul Walmsley wrote: On Wed, 9 Nov 2011, Ming Lei wrote: Also, current arm perf code don't handle three IRQs(one pl310 irq and two CTI irq) inside one device correctly. To fix this, that ARM perf code should either be using

Re: [PATCH v5 4/7] arm: omap4: hwmod: introduce emu hwmod

2011-11-11 Thread Jamie Iles
On Fri, Nov 11, 2011 at 11:41:47AM +, Will Deacon wrote: [Adding Benoit to CC]. On Thu, Nov 10, 2011 at 09:02:14AM +, Paul Walmsley wrote: On Wed, 9 Nov 2011, Ming Lei wrote: Also, current arm perf code don't handle three IRQs(one pl310 irq and two CTI irq) inside one device

Re: [PATCH v5 4/7] arm: omap4: hwmod: introduce emu hwmod

2011-11-11 Thread Will Deacon
On Fri, Nov 11, 2011 at 11:47:35AM +, Jamie Iles wrote: On Fri, Nov 11, 2011 at 11:41:47AM +, Will Deacon wrote: The issue stems from the fact that we have to route the PMU interrupts to the correct CPU manually (I think only MSM routes them as PPIs, which is clearly the correct

Re: [PATCH v4 2/7] iommu/core: split mapping to page sizes as supported by the hardware

2011-11-11 Thread Joerg Roedel
On Thu, Nov 10, 2011 at 07:28:39PM +, David Woodhouse wrote: ... which implies that a mapping, once made, might *never* actually get torn down until we loop and start reusing address space? That has interesting security implications. Yes, it is a trade-off between security and

[PATCH v2 1/2] OMAPDSS: HDMI: Move duplicate code from boardfile to

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com Move duplicate HDMI mux_init code from omap4 and panda board file to display file. Signed-off-by: Mythri P K mythr...@ti.com --- arch/arm/mach-omap2/board-4430sdp.c| 16 +--- arch/arm/mach-omap2/board-omap4panda.c | 17 +

[PATCH v2 1/2] OMAPDSS: HDMI: Move duplicate code from boardfile to

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com Move duplicate HDMI mux_init code from omap4 and panda board file to display file. Signed-off-by: Mythri P K mythr...@ti.com --- arch/arm/mach-omap2/board-4430sdp.c| 16 +--- arch/arm/mach-omap2/board-omap4panda.c | 17 +

[PATCH v2 2/2] OMAPDSS: HDMI: Disable HDMI DDC internal pull up

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com Disables the internal pull resistor for SDA and SCL enabled by default as there are expernal pull up's in 4460 and 4430 ES2.3, It is done to avoid the EDID read failure. Signed-off-by: Ricardo Salveti de Araujo ricardo.salv...@linaro.org Signed-off-by: Mythri P K

[PATCH v2 2/2] OMAPDSS: HDMI: Disable HDMI DDC internal pull up

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com Disables the internal pull resistor for SDA and SCL enabled by default as there are expernal pull up's in 4460 and 4430 ES2.3, It is done to avoid the EDID read failure. Signed-off-by: Ricardo Salveti de Araujo ricardo.salv...@linaro.org Signed-off-by: Mythri P K

[PATCH 1/4] OMAPDSS: HDMI: remove duplicate video interface code

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com video interface structure is a duplicate structure with parameters which are already present in ip_data config structure, Thus removing the structure and modifying corresponding code. Signed-off-by: Mythri P K mythr...@ti.com ---

[PATCH 3/4] OMAPDSS: HDMI: change the timing match logic

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com Change the timing match logic, Instead of the statically mapped method to get the corresponding timings for a given code and mode, move to a simpler array indexed method. It will help to scale up to add more timings when needed. Signed-off-by: Mythri P K

[PATCH 0/4] OMAPDSS: HDMI: Improve the timings logic in HDMI

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com There are some duplicate timing structure which are not needed thus removing them to clean the code. Also the static mapped timing structure is quite complicated to add new timings, so simplify it by using array indexed method. Mythri P K (4): OMAPDSS: HDMI:

[PATCH 4/4] OMAPDSS: HDMI: remove duplicate code and mode parameter

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com code and mode parameters are already a part of the ip_data structure so no need to keep the same parameters again in hdmi global structure. Signed-off-by: Mythri P K mythr...@ti.com --- drivers/video/omap2/dss/hdmi.c | 18 +++--- 1 files changed, 7

[PATCH 2/4] OMAPDSS: HDMI: update static timing table

2011-11-11 Thread mythripk
From: Mythri P K mythr...@ti.com Add the vsync polarity, hsync polarity, interlace to hdmi_video_timings. Remove the now duplicate structure hdmi_timings. update the static table structure in HDMI with CEA/VESA code and mode. Signed-off-by: Mythri P K mythr...@ti.com ---

Changing IOMMU-API for generic DMA-mapping supported by the hardware

2011-11-11 Thread Joerg Roedel
Okay, seperate thread for this one. On Thu, Nov 10, 2011 at 07:28:39PM +, David Woodhouse wrote: The plan is to have a single DMA-API implementation for all IOMMU drivers (X86 and ARM) which just uses the IOMMU-API. But to make this performing reasonalbly well a few changes to the

Re: [PATCH v4 2/7] iommu/core: split mapping to page sizes as supported by the hardware

2011-11-11 Thread Joerg Roedel
On Thu, Nov 10, 2011 at 01:12:00PM -0800, Stepan Moskovchenko wrote: I have been experimenting with an iommu_map_range call, which maps a given scatterlist of discontiguous physical pages into a contiguous virtual region at a given IOVA. This has some performance advantages over just calling

Re: [PATCH v4 2/7] iommu/core: split mapping to page sizes as supported by the hardware

2011-11-11 Thread David Woodhouse
On Fri, 2011-11-11 at 13:58 +0100, Joerg Roedel wrote: For AMD IOMMU there is a feature called not-present cache. It says that the IOMMU caches non-present entries as well and needs an IOTLB flush when something is mapped (meant for software implementations of the IOMMU). So it can't be

Re: [PATCH v4 2/7] iommu/core: split mapping to page sizes as supported by the hardware

2011-11-11 Thread Joerg Roedel
On Fri, Nov 11, 2011 at 01:27:28PM +, David Woodhouse wrote: On Fri, 2011-11-11 at 13:58 +0100, Joerg Roedel wrote: For AMD IOMMU there is a feature called not-present cache. It says that the IOMMU caches non-present entries as well and needs an IOTLB flush when something is mapped

Re: [PATCH v5 4/7] arm: omap4: hwmod: introduce emu hwmod

2011-11-11 Thread Cousson, Benoit
On 11/11/2011 12:47 PM, Jamie Iles wrote: On Fri, Nov 11, 2011 at 11:41:47AM +, Will Deacon wrote: [Adding Benoit to CC]. On Thu, Nov 10, 2011 at 09:02:14AM +, Paul Walmsley wrote: On Wed, 9 Nov 2011, Ming Lei wrote: Also, current arm perf code don't handle three IRQs(one pl310 irq

Re: [PATCH v5 4/7] arm: omap4: hwmod: introduce emu hwmod

2011-11-11 Thread Will Deacon
Hi Benoit, On Fri, Nov 11, 2011 at 02:56:05PM +, Cousson, Benoit wrote: It will come soon... along with the updated patch for reg-names support. Actually, I was hoping you could help Ming Lei with the hwmod stuff :) Will -- To unsubscribe from this list: send the line unsubscribe

Re: [PATCH v5 4/7] arm: omap4: hwmod: introduce emu hwmod

2011-11-11 Thread Cousson, Benoit
Hi Will, On 11/11/2011 3:58 PM, Will Deacon wrote: Hi Benoit, On Fri, Nov 11, 2011 at 02:56:05PM +, Cousson, Benoit wrote: It will come soon... along with the updated patch for reg-names support. Actually, I was hoping you could help Ming Lei with the hwmod stuff :) And I'll do :-)

Re: [PATCH v5 4/7] arm: omap4: hwmod: introduce emu hwmod

2011-11-11 Thread Will Deacon
On Fri, Nov 11, 2011 at 03:12:49PM +, Cousson, Benoit wrote: Hi Will, Hello, On 11/11/2011 3:58 PM, Will Deacon wrote: Actually, I was hoping you could help Ming Lei with the hwmod stuff :) And I'll do :-) Cheers! We already started looking at that with Paul a couple of days ago,

Re: [PATCH] ARM: OMAP: Introduce local common.h files

2011-11-11 Thread Russell King - ARM Linux
On Thu, Nov 10, 2011 at 03:33:47PM -0800, Tony Lindgren wrote: * Russell King - ARM Linux li...@arm.linux.org.uk [10 13:54]: Thanks, merged that into the series. The updated OMAP patch updated is below, which has been moved to part 2. Lastly, the final patch of part 2 has been updated

Re: [PATCH] ARM: OMAP: Introduce local common.h files

2011-11-11 Thread Tony Lindgren
* Russell King - ARM Linux li...@arm.linux.org.uk [11 07:42]: On Thu, Nov 10, 2011 at 03:33:47PM -0800, Tony Lindgren wrote: * Russell King - ARM Linux li...@arm.linux.org.uk [10 13:54]: Thanks, merged that into the series. The updated OMAP patch updated is below, which has been

Re: [PATCH v2 1/2] OMAPDSS: HDMI: Move duplicate code from boardfile to

2011-11-11 Thread Tony Lindgren
* mythr...@ti.com mythr...@ti.com [11 04:41]: From: Mythri P K mythr...@ti.com Move duplicate HDMI mux_init code from omap4 and panda board file to display file. Signed-off-by: Mythri P K mythr...@ti.com --- arch/arm/mach-omap2/board-4430sdp.c| 16 +---

Re: [PATCH v2 2/2] OMAPDSS: HDMI: Disable HDMI DDC internal pull up

2011-11-11 Thread Tony Lindgren
* mythr...@ti.com mythr...@ti.com [11 04:41]: From: Mythri P K mythr...@ti.com Disables the internal pull resistor for SDA and SCL enabled by default as there are expernal pull up's in 4460 and 4430 ES2.3, It is done to avoid the EDID read failure. Signed-off-by: Ricardo Salveti de

[PATCH] ARM: OMAP: Fix reprogramming of dpll1 rate

2011-11-11 Thread Tony Lindgren
Commit a66cb3454f220f49f900646ebdc76cb943319eb7 (ARM: OMAP: Map SRAM later on with ioremap_exec()) moved the SRAM init to happen later to remove a dependency to early SoC detection for map_io. This broke booting on some boards not using Kconfig option for OMAP_CLOCKS_SET_BY_BOOTLOADER as the

Re: [PATCH] ARM: OMAP: Fix reprogramming of dpll1 rate

2011-11-11 Thread Aaro Koskinen
Hi, On 11.11.2011, at 21.16, Tony Lindgren wrote: Commit a66cb3454f220f49f900646ebdc76cb943319eb7 (ARM: OMAP: Map SRAM later on with ioremap_exec()) moved the SRAM init to happen later to remove a dependency to early SoC detection for map_io. This broke booting on some boards not using Kconfig

Re: [PATCH v4 2/7] iommu/core: split mapping to page sizes as supported by the hardware

2011-11-11 Thread Stepan Moskovchenko
On 11/11/2011 5:24 AM, Joerg Roedel wrote: On Thu, Nov 10, 2011 at 01:12:00PM -0800, Stepan Moskovchenko wrote: I have been experimenting with an iommu_map_range call, which maps a given scatterlist of discontiguous physical pages into a contiguous virtual region at a given IOVA. This has some