clk: tegra: fix blink clock rate
Subsystems (3)
PATCH 1/5 clk: tegra: fix blink clock rate
From: Stephen Warren <[email protected]>
The blink clock rate needs to be configured, or it will run at ~1Hz rather than the desired 32KHz. If it runs at the wrong rate, e.g. the SDIO WiFi on Seaboard and Cardhu will fail to be detected.
---
This probably needs to be squashed into commit 32721a734a3d "clk: tegra:
move PMC, fixed clocks to common files".
--- drivers/clk/tegra/clk-tegra-pmc.c | 1 + 1 file changed, 1 insertion(+)
drivers/clk/tegra/clk-tegra-pmc.c +1 -0
@@ -114,6 +114,7 @@ void __init tegra_pmc_clk_init(void __iomem *pmc_base, }/* blink */ +writel_relaxed (0 , pmc_base +PMC_BLINK_TIMER ); clk =clk_register_gate (NULL ,"blink_override" ,"clk_32k" ,0 , pmc_base +PMC_DPD_PADS_ORIDE ,PMC_DPD_PADS_ORIDE_BLINK_ENB ,0 ,NULL );
Signature · 1 line
1.8.1.5
PATCH 2/5 clk: tegra: remove some redundant defines from Tegra114
From: Stephen Warren <[email protected]>
These #defines aren't used. Delete them.
---
This probably should be squashed into commit 32721a734a3d "clk: tegra:
move PMC, fixed clocks to common files".
--- drivers/clk/tegra/clk-tegra114.c | 7 ------- 1 file changed, 7 deletions(-)
drivers/clk/tegra/clk-tegra114.c +0 -7
@@ -107,13 +107,6 @@#define PLLC_OUT 0x84#define PLLM_OUT 0x94 -#define PMC_CLK_OUT_CNTRL 0x1a8 -#define PMC_DPD_PADS_ORIDE 0x1c -#define PMC_DPD_PADS_ORIDE_BLINK_ENB 20 -#define PMC_CTRL 0 -#define PMC_CTRL_BLINK_ENB 7 -#define PMC_BLINK_TIMER 0x40 -#define OSC_CTRL 0x50#define OSC_CTRL_OSC_FREQ_SHIFT 28#define OSC_CTRL_PLL_REF_DIV_SHIFT 26
Signature · 1 line
1.8.1.5
PATCH 3/5 clk: tegra: remove some redundant defines from Tegra30
In reply to Stephen WarrenFrom: Stephen Warren <[email protected]>
These #defines aren't used. Delete them.
---
This probably should be squashed into commit ba2e2e8f2c55 "clk: tegra:
move tegra30 to common infra".
--- drivers/clk/tegra/clk-tegra30.c | 7 ------- 1 file changed, 7 deletions(-)
drivers/clk/tegra/clk-tegra30.c +0 -7
@@ -118,13 +118,6 @@#define AUDIO_SYNC_DOUBLER 0x49c -#define PMC_CTRL 0 -#define PMC_CTRL_BLINK_ENB 7 - -#define PMC_DPD_PADS_ORIDE 0x1c -#define PMC_DPD_PADS_ORIDE_BLINK_ENB 20 -#define PMC_BLINK_TIMER 0x40 -#define UTMIP_PLL_CFG2 0x488#define UTMIP_PLL_CFG2_STABLE_COUNT (x) (((x) & 0xffff) << 6)#define UTMIP_PLL_CFG2_ACTIVE_DLY_COUNT (x) (((x) & 0x3f) << 18)
Signature · 1 line
1.8.1.5
PATCH 4/5 clk: tegra: remove some redunant defines from Tegra20
In reply to Stephen WarrenFrom: Stephen Warren <[email protected]>
These #defines aren't used. Delete them.
---
This probably should be squashed into commit 776b2c0ba0dd "clk: tegra:
move tegra20 to common infra".
--- drivers/clk/tegra/clk-tegra20.c | 6 ------ 1 file changed, 6 deletions(-)
drivers/clk/tegra/clk-tegra20.c +0 -6
@@ -118,12 +118,6 @@#define AUDIO_SYNC_CLK 0x38 -#define PMC_CTRL 0x0 -#define PMC_CTRL_BLINK_ENB 7 -#define PMC_DPD_PADS_ORIDE 0x1c -#define PMC_DPD_PADS_ORIDE_BLINK_ENB 20 -#define PMC_BLINK_TIMER 0x40 -/* Tegra CPU clock and reset control regs */ #define TEGRA_CLK_RST_CONTROLLER_CLK_CPU_CMPLX 0x4c#define TEGRA_CLK_RST_CONTROLLER_RST_CPU_CMPLX_SET 0x340
Signature · 1 line
1.8.1.5
PATCH 5/5 clk: tegra: remove some redundant defines from Tegra124
In reply to Stephen WarrenFrom: Stephen Warren <[email protected]>
These #defines aren't used. Delete them.
---
This probably should be squashed into commit 8a0fc8917eef "clk: tegra124:
Add support for Tegra124 clocks".
--- drivers/clk/tegra/clk-tegra124.c | 2 -- 1 file changed, 2 deletions(-)
drivers/clk/tegra/clk-tegra124.c +0 -2
@@ -84,8 +84,6 @@#define PLLXC_SW_MAX_P 6 -#define PMC_BLINK_TIMER 0x40 -#define PMC_PLLM_WB0_OVERRIDE 0x1dc#define PMC_PLLM_WB0_OVERRIDE_2 0x2b0
Signature · 1 line
1.8.1.5
PATCH 1/5 clk: tegra: fix blink clock rate
In reply to Stephen WarrenQuoted 11 lines · Stephen Warren
From: Stephen Warren <[email protected]>
The blink clock rate needs to be configured, or it will run at ~1Hz rather than the desired 32KHz. If it runs at the wrong rate, e.g. the SDIO WiFi on Seaboard and Cardhu will fail to be detected.
Signed-off-by Stephen Warren <[email protected]>---
This probably needs to be squashed into commit32721a734a3d"clk: tegra:
move PMC, fixed clocks to common files".
---
I will squash this into the mentioned commit.
Cheers,
Peter.
PATCH 1/5 clk: tegra: fix blink clock rate
In reply to Stephen WarrenQuoted 5 lines · Stephen Warren
From: Stephen Warren <[email protected]>
The blink clock rate needs to be configured, or it will run at ~1Hz rather than the desired 32KHz. If it runs at the wrong rate, e.g. the SDIO WiFi on Seaboard and Cardhu will fail to be detected.
How is this related to WiFi?
Quoted 14 lines
Signed-off-by Stephen Warren <[email protected]>---
This probably needs to be squashed into commit32721a734a3d"clk: tegra:
move PMC, fixed clocks to common files".--- drivers/clk/tegra/clk-tegra-pmc.c | 1 + 1 file changed, 1 insertion(+)drivers/clk/tegra/clk-tegra-pmc.c +0
-0
drivers/clk/tegra/clk-tegra-pmc.c void __init tegra_pmc_clk_init(void __iomem *pmc_base, · line 120
Quoted 7 lines
drivers/clk/tegra/clk-tegra-pmc.c +1
-0@@ -114,6 +114,7 @@ void __init tegra_pmc_clk_init(void __iomem *pmc_base, }/* blink */ +writel_relaxed (0 , pmc_base +PMC_BLINK_TIMER ); clk =clk_register_gate (NULL ,"blink_override" ,"clk_32k" ,0 , pmc_base +PMC_DPD_PADS_ORIDE ,PMC_DPD_PADS_ORIDE_BLINK_ENB ,0 ,NULL );
Perhaps a better location would be a few lines below, where the "blink" clock is registered, since this actually controls the "blink" clock rather than "blink_override". But either way:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20131129/98f2f3f7/attachment.sig>
PATCH 1/5 clk: tegra: fix blink clock rate
Quoted 25 lines · Thierry Reding
Quoted 5 lines · Stephen Warren
From: Stephen Warren <[email protected]>
The blink clock rate needs to be configured, or it will run at ~1Hz rather than the desired 32KHz. If it runs at the wrong rate, e.g. the SDIO WiFi on Seaboard and Cardhu will fail to be detected.
How is this related to WiFi?
Quoted 16 lines
Signed-off-by Stephen Warren <[email protected]>---
This probably needs to be squashed into commit32721a734a3d"clk: tegra:
move PMC, fixed clocks to common files".--- drivers/clk/tegra/clk-tegra-pmc.c | 1 + 1 file changed, 1 insertion(+)drivers/clk/tegra/clk-tegra-pmc.c +0
-0@@ -114,6 +114,7 @@ void __init tegra_pmc_clk_init(void __iomem *pmc_base, }
Quoted 9 lines
drivers/clk/tegra/clk-tegra-pmc.c void __init tegra_pmc_clk_init(void __iomem *pmc_base, · line 120
Quoted 5 lines
drivers/clk/tegra/clk-tegra-pmc.c +1
-0/* blink */ +writel_relaxed (0 , pmc_base +PMC_BLINK_TIMER ); clk =clk_register_gate (NULL ,"blink_override" ,"clk_32k" ,0 , pmc_base +PMC_DPD_PADS_ORIDE ,PMC_DPD_PADS_ORIDE_BLINK_ENB ,0 ,NULL );Perhaps a better location would be a few lines below, where the "blink" clock is registered, since this actually controls the "blink" clock rather than "
blink_override". But either way:
Just realized that Peter already squashed all of these into his -next branch, so nevermind.
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20131129/81f676eb/attachment.sig>
PATCH 1/5 clk: tegra: fix blink clock rate
In reply to Thierry RedingQuoted 9 lines · Thierry Reding
Quoted 6 lines · Stephen Warren
From: Stephen Warren <[email protected]>
The blink clock rate needs to be configured, or it will run at ~1Hz rather than the desired 32KHz. If it runs at the wrong rate, e.g. the SDIO WiFi on Seaboard and Cardhu will fail to be detected.
How is this related to WiFi?
The "blink" clock output from Tegra is connected to the WiFi module, which then uses it for something; it probably has a PLL connected to it that drives all the internal circuitry.
PATCH 1/5 clk: tegra: fix blink clock rate
Quoted 9 lines · Stephen Warren
Quoted 8 lines · Thierry Reding
Quoted 6 lines · Stephen Warren
From: Stephen Warren <[email protected]>
The blink clock rate needs to be configured, or it will run at ~1Hz rather than the desired 32KHz. If it runs at the wrong rate, e.g. the SDIO WiFi on Seaboard and Cardhu will fail to be detected.
Quoted 5 lines
Quoted 1 line
How is this related to WiFi?
The "blink" clock output from Tegra is connected to the WiFi module, which then uses it for something; it probably has a PLL connected to it that drives all the internal circuitry.
Okay, thanks for explaining.
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20131202/cfb91343/attachment.sig>