Re: [RFC 6/9] clk: ti: add support for omap4 module clocks

2016-01-04 Thread Tero Kristo
On 01/04/2016 06:37 PM, Tony Lindgren wrote: * Russell King - ARM Linux [160104 06:43]: On Mon, Jan 04, 2016 at 03:27:57PM +0200, Tero Kristo wrote: On 01/04/2016 12:21 PM, Geert Uytterhoeven wrote: FWIW, there are small loops with just a cpu_relax() in various clock drivers under drivers

Re: [RFC 6/9] clk: ti: add support for omap4 module clocks

2016-01-04 Thread Tero Kristo
On 01/04/2016 12:21 PM, Geert Uytterhoeven wrote: Hi Tero, On Mon, Jan 4, 2016 at 8:36 AM, Tero Kristo wrote: On 01/01/2016 07:48 AM, Michael Turquette wrote: Quoting Tero Kristo (2015-12-18 05:58:58) +static int _omap4_hwmod_clk_enable(struct clk_hw *hw) +{ + struct clk_hw_omap *clk

Re: [RFC 6/9] clk: ti: add support for omap4 module clocks

2016-01-03 Thread Tero Kristo
On 01/01/2016 07:48 AM, Michael Turquette wrote: Hi Tero, Quoting Tero Kristo (2015-12-18 05:58:58) Previously, hwmod core has been used for controlling the hwmod level clocks. This has certain drawbacks, like being unable to share the clocks for multiple users, missing usecounting and

Re: [PATCH v4] clk: ti: Add support for dm814x ADPLL

2015-12-22 Thread Tero Kristo
"ARM: OMAP2+: Change core_initcall levels to postcore_initcall". Also note that this patch does not implement clk_set_rate for the PLL, that will be posted later on when available. Cc: Michael Turquette Cc: Stephen Boyd Cc: Tero Kristo Signed-off-by: Tony Lindgren --- If no mor

[RFC 3/9] clk: ti: remove un-used definitions from public clk_hw_omap struct

2015-12-18 Thread Tero Kristo
Clksel support has been deprecated a while back, so remove these from the struct also. Signed-off-by: Tero Kristo --- include/linux/clk/ti.h |4 1 file changed, 4 deletions(-) diff --git a/include/linux/clk/ti.h b/include/linux/clk/ti.h index 223be69..ec5613a 100644 --- a/include

[RFC 2/9] ARM: OMAP2+: hwmod: initialize main clocks directly from DT

2015-12-18 Thread Tero Kristo
This avoids the need to add clock aliases under drivers/clk/ti/clk-xyz.c files. Signed-off-by: Tero Kristo --- arch/arm/mach-omap2/omap_hwmod.c | 19 ++- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2

[RFC 0/9] ARM: OMAP4: hwmod clkctrl conversion to DT + clock driver

2015-12-18 Thread Tero Kristo
Hi, This series adds support for hwmod gate clock type, and changes OMAP4 as an example to use the new clock type, converting the existing hwmod_data clkctrl definitions to clock nodes under device tree. Some additional magic is required for handling timer clocks, as the clock driver assumes it ca

[RFC 8/9] ARM: OMAP4: hwmod_data: use module clocks from DT

2015-12-18 Thread Tero Kristo
Replace the usage of prcm->clkstctrl with main_clk:s provided via DT. This is done in preparation to get rid of hwmod data from kernel. Signed-off-by: Tero Kristo --- arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 339 1 file changed, 95 insertions(+), 244 deleti

[RFC 9/9] clk: ti: omap4: update clock aliases to reflect new module clocks

2015-12-18 Thread Tero Kristo
The clock data in DT has been updated, and the clock aliases must be updated to match. Signed-off-by: Tero Kristo --- drivers/clk/ti/clk-44xx.c | 22 +++--- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/drivers/clk/ti/clk-44xx.c b/drivers/clk/ti/clk-44xx.c

[RFC 4/9] clk: ti: mux: export mux clock APIs locally

2015-12-18 Thread Tero Kristo
get_parent and set_parent are going to be required by the support of module clocks, so export these locally. Signed-off-by: Tero Kristo --- drivers/clk/ti/clock.h |3 +++ drivers/clk/ti/mux.c |4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/clk/ti

[RFC 7/9] ARM: dts: omap4: add hwmod module clocks

2015-12-18 Thread Tero Kristo
Add clock nodes for the SoC hwmods. This is done in preparation to remove hwmod data from kernel, hwmod will use the clock nodes instead for module level enable / disable logic. Signed-off-by: Tero Kristo --- arch/arm/boot/dts/omap44xx-clocks.dtsi | 854 +--- 1 file

[RFC 6/9] clk: ti: add support for omap4 module clocks

2015-12-18 Thread Tero Kristo
clock driver, which will be used to convert all the existing hwmdo clocks to. This helps to get rid of the clock related hwmod data from kernel and instead parsing this from DT. Signed-off-by: Tero Kristo --- drivers/clk/ti/Makefile |3 +- drivers/clk/ti/clkt_mod.c | 351

[RFC 5/9] dt-bindings: clk: ti: Document module clock type

2015-12-18 Thread Tero Kristo
Document the new TI module clock type, which is intended to replace the internal clock control handling within omap_hwmod. Module clock is effectively a gate clock controlling both interface and functional clocks for a single hardware IP block. Signed-off-by: Tero Kristo --- .../devicetree

[RFC 1/9] ARM: OMAP2+: omap_device: create clock alias purely from DT data

2015-12-18 Thread Tero Kristo
This avoids the need to add most of the clock aliases under drivers/clk/ti/clk-xyz.c files. Signed-off-by: Tero Kristo --- arch/arm/mach-omap2/omap_device.c | 12 1 file changed, 12 insertions(+) diff --git a/arch/arm/mach-omap2/omap_device.c b/arch/arm/mach-omap2/omap_device.c

[PATCHv2] clk: ti: omap5+: dpll: implement errata i810

2015-12-16 Thread Tero Kristo
setting the DPLL AUTO_DPLL_MODE=0 or keeping a clock request active by setting a dependent clock domain in SW_WKUP. This errata is known to impact OMAP5 and DRA7 chips, but lets enable it unconditionally to avoid any potential problems with earlier generation SoCs also. Signed-off-by: Tero Kristo

Re: [PATCH] clk: ti: omap5+: dpll: implement errata i810

2015-12-11 Thread Tero Kristo
On 12/03/2015 06:48 PM, Tony Lindgren wrote: * Tero Kristo [151130 06:44]: + /* +* Errata i810 - DPLL controller can get stuck while transitioning +* to a power saving state. Software must ensure the DPLL can not +* transition to a low power state while changing M

Re: [PATCH v2] clk: ti: Add support for dm814x ADPLL

2015-12-10 Thread Tero Kristo
On 12/11/2015 04:26 AM, Tony Lindgren wrote: On dm814x we have 13 ADPLLs with 3 to 4 outputs on each. The ADPLLs have several dividers and muxes controlled by a shared control register for each PLL. Note that for the clocks to work as device drivers for booting on dm814x, this patch depends on "

[PATCH] clk: ti: omap5+: dpll: implement errata i810

2015-11-30 Thread Tero Kristo
setting the DPLL AUTO_DPLL_MODE=0 or keeping a clock request active by setting a dependent clock domain in SW_WKUP. This errata impacts OMAP5 and DRA7 chips, so enable the errata for these. Signed-off-by: Tero Kristo --- arch/arm/mach-omap2/clock.c |4 drivers/clk/ti/dpll3xxx.c | 25

Re: [PATCH] ti/clkt_dpll: fix wrong do_div() usage

2015-11-24 Thread Tero Kristo
On 11/04/2015 06:09 AM, Nicolas Pitre wrote: do_div() is meant to be used with an unsigned dividend. Signed-off-by: Nicolas Pitre Fixed Subject locally to format "clk: ti: %s". Queued for 4.4-rc fixes, thanks. -Tero diff --git a/drivers/clk/ti/clkt_dpll.c b/drivers/clk/ti/clkt_dpll.c ind

Re: [PATCH v2 2/4] clk: ti816x: Add missing dmtimer clkdev entries

2015-11-24 Thread Tero Kristo
On 11/13/2015 06:29 PM, Neil Armstrong wrote: Add missing clkdev dmtimer related entries for dm816x. 32Khz and ext sources were missing. Cc: Brian Hutchinson Acked-by: Tony Lindgren Signed-off-by: Neil Armstrong Your own sign-off should be at the top of the list, fixed this locally myself.

[GIT PULL] clk: ti: fixes for 4.4-rc

2015-11-24 Thread Tero Kristo
Hi Michael, Stephen, Here are some TI clock driver fixes for 4.4-rc. -Tero The following changes since commit 8005c49d9aea74d382f474ce11afbbc7d7130bec: Linux 4.4-rc1 (2015-11-15 17:00:27 -0800) are available in the git reposi

Re: [PATCH] clk: ti: drop locking code from mux/divider drivers

2015-11-24 Thread Tero Kristo
On 10/24/2015 12:10 AM, Grygorii Strashko wrote: On 10/01/2015 10:20 PM, Grygorii Strashko wrote: TI's mux and divider clock drivers do not require locking and they do not initialize internal spinlocks. This code was occasionally copy-posted from generic mux/divider drivers. So remove it. Cc: T

Re: [PATCH] ti/fapll: fix wrong do_div() usage

2015-11-24 Thread Tero Kristo
On 11/04/2015 06:17 AM, Nicolas Pitre wrote: do_div() is meant to be used with an unsigned dividend. Signed-off-by: Nicolas Pitre Fixed Subject locally to format "clk: ti: %s". Queued for 4.4-rc-fixes, thanks. -Tero diff --git a/drivers/clk/ti/fapll.c b/drivers/clk/ti/fapll.c index f4b2e

Re: [PATCH] clk: ti: fix dual-registration of uart4_ick

2015-10-05 Thread Tero Kristo
On 10/05/2015 01:17 PM, Tony Lindgren wrote: * Ben Dooks [150929 06:14]: On 25/09/15 06:42, Tero Kristo wrote: On 09/23/2015 08:30 PM, Tony Lindgren wrote: * Ben Dooks [150923 07:53]: On the OMAP AM3517 platform the uart4_ick gets registered twice, causing any power managment to /dev/ttyO3

[GIT PULL] clock: ti: fixes for 4.3-rc

2015-10-01 Thread Tero Kristo
Hi Stephen, Mike, A few TI clock driver fixes to pull against 4.3-rc. -Tero The following changes since commit 9ffecb10283508260936b96022d4ee43a7798b4c: Linux 4.3-rc3 (2015-09-27 07:50:08 -0400) are available in the git repository at: https://github.com/t-kristo/linux-p

Re: [PATCH] clk: ti: dflt: fix enable_reg validity check

2015-10-01 Thread Tero Kristo
On 09/30/2015 01:37 AM, Suman Anna wrote: The default clock enabling functions for TI clocks - omap2_dflt_clk_enable() and omap2_dflt_clk_disable() perform a NULL check for the enable_reg field of the clk_hw_omap structure. This enable_reg field however is merely a combination of the index of the

Re: [PATCH v2] clk: ti: fix dual-registration of uart4_ick

2015-10-01 Thread Tero Kristo
initial clock conversion commit as a fixes by for this: commit aafd900cab87d339dc3004c241eebc854005124b Author: Tero Kristo Date: Fri Aug 2 14:04:19 2013 +0300 CLK: TI: add omap3 clock init file I'll add a fixes tag to this and queue it for 4.3-rc-fixes. -Tero -- To unsubscribe from this

Re: [PATCH] clk: ti: clk-7xx: Remove hardwired ABE clock configuration

2015-09-25 Thread Tero Kristo
On 09/25/2015 09:59 AM, Peter Ujfalusi wrote: Tero, On 09/16/2015 09:42 AM, Tero Kristo wrote: On 09/14/2015 11:52 AM, Peter Ujfalusi wrote: Hi Tero, On 08/24/2015 10:35 AM, Peter Ujfalusi wrote: The ABE related clocks should be configured via DT and not have it wired inside of the kernel

Re: [PATCH] clk: ti: fix dual-registration of uart4_ick

2015-09-24 Thread Tero Kristo
On 09/23/2015 08:30 PM, Tony Lindgren wrote: * Ben Dooks [150923 07:53]: On the OMAP AM3517 platform the uart4_ick gets registered twice, causing any power managment to /dev/ttyO3 to fail when trying to wake the device up. This solves the following oops: [] Unhandled fault: external abort on

Re: [PATCH] clk: ti: clk-7xx: Remove hardwired ABE clock configuration

2015-09-15 Thread Tero Kristo
On 09/14/2015 11:52 AM, Peter Ujfalusi wrote: Hi Tero, On 08/24/2015 10:35 AM, Peter Ujfalusi wrote: The ABE related clocks should be configured via DT and not have it wired inside of the kernel. can you take a look at this patch? It will not cause any regression since we do not have audio su