diff mbox series

clk: sprd: don't gate uart console clock

Message ID 20200331104532.12698-1-chunyan.zhang@unisoc.com (mailing list archive)
State Changes Requested, archived
Headers show
Series clk: sprd: don't gate uart console clock | expand

Commit Message

Chunyan Zhang March 31, 2020, 10:45 a.m. UTC
Don't gate uart1_eb which provides console clock, gating that clock would
make serial stop working if serial driver didn't enable that explicitly.

Signed-off-by: Chunyan Zhang <chunyan.zhang@unisoc.com>
---
 drivers/clk/sprd/sc9863a-clk.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Chunyan Zhang April 3, 2020, 1:56 a.m. UTC | #1
Hi Stephen,

This is also a fix, could you please take it into clk-next as well?

Thanks,
Chunyan

On Tue, 31 Mar 2020 at 18:45, Chunyan Zhang <zhang.lyra@gmail.com> wrote:
>
> Don't gate uart1_eb which provides console clock, gating that clock would
> make serial stop working if serial driver didn't enable that explicitly.
>
> Signed-off-by: Chunyan Zhang <chunyan.zhang@unisoc.com>
> ---
>  drivers/clk/sprd/sc9863a-clk.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/clk/sprd/sc9863a-clk.c b/drivers/clk/sprd/sc9863a-clk.c
> index 24f064262814..6c6ac158ef61 100644
> --- a/drivers/clk/sprd/sc9863a-clk.c
> +++ b/drivers/clk/sprd/sc9863a-clk.c
> @@ -1671,8 +1671,9 @@ static SPRD_SC_GATE_CLK_FW_NAME(i2c4_eb,  "i2c4-eb",      "ext-26m", 0x0,
>                                 0x1000, BIT(12), 0, 0);
>  static SPRD_SC_GATE_CLK_FW_NAME(uart0_eb,      "uart0-eb",     "ext-26m", 0x0,
>                                 0x1000, BIT(13), 0, 0);
> +/* uart1_eb is for console, don't gate even if unused */
>  static SPRD_SC_GATE_CLK_FW_NAME(uart1_eb,      "uart1-eb",     "ext-26m", 0x0,
> -                               0x1000, BIT(14), 0, 0);
> +                               0x1000, BIT(14), CLK_IGNORE_UNUSED, 0);
>  static SPRD_SC_GATE_CLK_FW_NAME(uart2_eb,      "uart2-eb",     "ext-26m", 0x0,
>                                 0x1000, BIT(15), 0, 0);
>  static SPRD_SC_GATE_CLK_FW_NAME(uart3_eb,      "uart3-eb",     "ext-26m", 0x0,
> --
> 2.20.1
>
Stephen Boyd April 5, 2020, 3:08 a.m. UTC | #2
Quoting Chunyan Zhang (2020-03-31 03:45:32)
> Don't gate uart1_eb which provides console clock, gating that clock would
> make serial stop working if serial driver didn't enable that explicitly.
> 
> Signed-off-by: Chunyan Zhang <chunyan.zhang@unisoc.com>
> ---

Do you have a Fixes: tag?
Chunyan Zhang April 7, 2020, 2:02 a.m. UTC | #3
On Sun, 5 Apr 2020 at 11:08, Stephen Boyd <sboyd@kernel.org> wrote:
>
> Quoting Chunyan Zhang (2020-03-31 03:45:32)
> > Don't gate uart1_eb which provides console clock, gating that clock would
> > make serial stop working if serial driver didn't enable that explicitly.
> >
> > Signed-off-by: Chunyan Zhang <chunyan.zhang@unisoc.com>
> > ---
>
> Do you have a Fixes: tag?

I didn't leave a Fixed tag since that commit [1] will be merged into v5.7-rc1

[1] https://www.spinics.net/lists/linux-clk/msg46430.html
Stephen Boyd April 7, 2020, 8:34 p.m. UTC | #4
Quoting Chunyan Zhang (2020-04-06 19:02:38)
> On Sun, 5 Apr 2020 at 11:08, Stephen Boyd <sboyd@kernel.org> wrote:
> >
> > Quoting Chunyan Zhang (2020-03-31 03:45:32)
> > > Don't gate uart1_eb which provides console clock, gating that clock would
> > > make serial stop working if serial driver didn't enable that explicitly.
> > >
> > > Signed-off-by: Chunyan Zhang <chunyan.zhang@unisoc.com>
> > > ---
> >
> > Do you have a Fixes: tag?
> 
> I didn't leave a Fixed tag since that commit [1] will be merged into v5.7-rc1
> 
> [1] https://www.spinics.net/lists/linux-clk/msg46430.html

Please still provide a Fixes tag. It helps track what commit is fixed
regardless.
diff mbox series

Patch

diff --git a/drivers/clk/sprd/sc9863a-clk.c b/drivers/clk/sprd/sc9863a-clk.c
index 24f064262814..6c6ac158ef61 100644
--- a/drivers/clk/sprd/sc9863a-clk.c
+++ b/drivers/clk/sprd/sc9863a-clk.c
@@ -1671,8 +1671,9 @@  static SPRD_SC_GATE_CLK_FW_NAME(i2c4_eb,	"i2c4-eb",	"ext-26m", 0x0,
 				0x1000, BIT(12), 0, 0);
 static SPRD_SC_GATE_CLK_FW_NAME(uart0_eb,	"uart0-eb",	"ext-26m", 0x0,
 				0x1000, BIT(13), 0, 0);
+/* uart1_eb is for console, don't gate even if unused */
 static SPRD_SC_GATE_CLK_FW_NAME(uart1_eb,	"uart1-eb",	"ext-26m", 0x0,
-				0x1000, BIT(14), 0, 0);
+				0x1000, BIT(14), CLK_IGNORE_UNUSED, 0);
 static SPRD_SC_GATE_CLK_FW_NAME(uart2_eb,	"uart2-eb",	"ext-26m", 0x0,
 				0x1000, BIT(15), 0, 0);
 static SPRD_SC_GATE_CLK_FW_NAME(uart3_eb,	"uart3-eb",	"ext-26m", 0x0,