linux-renesas-soc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register
@ 2019-03-27  9:03 Nguyen An Hoan
  2019-03-27  9:31 ` Niklas Söderlund
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Nguyen An Hoan @ 2019-03-27  9:03 UTC (permalink / raw)
  To: linux-renesas-soc, geert+renesas
  Cc: rui.zhang, jslaby, wsa+renesas, edubezval, linux-pm,
	linux-kernel, kuninori.morimoto.gx, yoshihiro.shimoda.uh,
	h-inayoshi, nv-dung, na-hoan, cv-dong

From: Hoan Nguyen An <na-hoan@jinso.co.jp>

Fix setting value for IRQCTL register. We are setting the last 6 bits
of (IRQCTL) to be 1 (0x3f), this is only suitable for H3ES1.*, according
to Hardware manual values 1 are "setting prohibited" for Gen3.

Signed-off-by: Hoan Nguyen An <na-hoan@jinso.co.jp>
---
 drivers/thermal/rcar_gen3_thermal.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/thermal/rcar_gen3_thermal.c b/drivers/thermal/rcar_gen3_thermal.c
index 88fa41c..2482795 100644
--- a/drivers/thermal/rcar_gen3_thermal.c
+++ b/drivers/thermal/rcar_gen3_thermal.c
@@ -307,7 +307,7 @@ static void rcar_gen3_thermal_init(struct rcar_gen3_thermal_tsc *tsc)
 
 	usleep_range(1000, 2000);
 
-	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQCTL, 0x3F);
+	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQCTL, 0);
 	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQMSK, 0);
 	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQEN, IRQ_TEMPD1 | IRQ_TEMP2);
 
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register
  2019-03-27  9:03 [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register Nguyen An Hoan
@ 2019-03-27  9:31 ` Niklas Söderlund
  2019-03-27  9:34 ` Yoshihiro Shimoda
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Niklas Söderlund @ 2019-03-27  9:31 UTC (permalink / raw)
  To: Nguyen An Hoan
  Cc: linux-renesas-soc, geert+renesas, rui.zhang, jslaby, wsa+renesas,
	edubezval, linux-pm, linux-kernel, kuninori.morimoto.gx,
	yoshihiro.shimoda.uh, h-inayoshi, nv-dung, cv-dong

Hi Hoan,

Thanks for your work, and sorry for dropping the ball on this in v2.

On 2019-03-27 18:03:18 +0900, Nguyen An Hoan wrote:
> From: Hoan Nguyen An <na-hoan@jinso.co.jp>
> 
> Fix setting value for IRQCTL register. We are setting the last 6 bits
> of (IRQCTL) to be 1 (0x3f), this is only suitable for H3ES1.*, according
> to Hardware manual values 1 are "setting prohibited" for Gen3.
> 
> Signed-off-by: Hoan Nguyen An <na-hoan@jinso.co.jp>

Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>

> ---
>  drivers/thermal/rcar_gen3_thermal.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/thermal/rcar_gen3_thermal.c b/drivers/thermal/rcar_gen3_thermal.c
> index 88fa41c..2482795 100644
> --- a/drivers/thermal/rcar_gen3_thermal.c
> +++ b/drivers/thermal/rcar_gen3_thermal.c
> @@ -307,7 +307,7 @@ static void rcar_gen3_thermal_init(struct rcar_gen3_thermal_tsc *tsc)
>  
>  	usleep_range(1000, 2000);
>  
> -	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQCTL, 0x3F);
> +	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQCTL, 0);
>  	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQMSK, 0);
>  	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQEN, IRQ_TEMPD1 | IRQ_TEMP2);
>  
> -- 
> 2.7.4
> 

-- 
Regards,
Niklas Söderlund

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register
  2019-03-27  9:03 [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register Nguyen An Hoan
  2019-03-27  9:31 ` Niklas Söderlund
@ 2019-03-27  9:34 ` Yoshihiro Shimoda
  2019-03-28  7:06 ` Wolfram Sang
  2019-03-28  8:05 ` Geert Uytterhoeven
  3 siblings, 0 replies; 5+ messages in thread
From: Yoshihiro Shimoda @ 2019-03-27  9:34 UTC (permalink / raw)
  To: Nguyen An Hoan
  Cc: rui.zhang, jslaby, wsa+renesas, edubezval, linux-pm,
	linux-kernel, Kuninori Morimoto, hideo inayoshi, nv-dung,
	cv-dong, linux-renesas-soc, geert+renesas

Hi Hoan-san,

> From: Nguyen An Hoan, Sent: Wednesday, March 27, 2019 6:03 PM
> 
> Fix setting value for IRQCTL register. We are setting the last 6 bits
> of (IRQCTL) to be 1 (0x3f), this is only suitable for H3ES1.*, according
> to Hardware manual values 1 are "setting prohibited" for Gen3.
> 
> Signed-off-by: Hoan Nguyen An <na-hoan@jinso.co.jp>

Thank you for the patch!

Reviewed-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>

Best regards,
Yoshihiro Shimoda


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register
  2019-03-27  9:03 [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register Nguyen An Hoan
  2019-03-27  9:31 ` Niklas Söderlund
  2019-03-27  9:34 ` Yoshihiro Shimoda
@ 2019-03-28  7:06 ` Wolfram Sang
  2019-03-28  8:05 ` Geert Uytterhoeven
  3 siblings, 0 replies; 5+ messages in thread
From: Wolfram Sang @ 2019-03-28  7:06 UTC (permalink / raw)
  To: Nguyen An Hoan
  Cc: linux-renesas-soc, geert+renesas, rui.zhang, jslaby, wsa+renesas,
	edubezval, linux-pm, linux-kernel, kuninori.morimoto.gx,
	yoshihiro.shimoda.uh, h-inayoshi, nv-dung, cv-dong

[-- Attachment #1: Type: text/plain, Size: 566 bytes --]

On Wed, Mar 27, 2019 at 06:03:18PM +0900, Nguyen An Hoan wrote:
> From: Hoan Nguyen An <na-hoan@jinso.co.jp>
> 
> Fix setting value for IRQCTL register. We are setting the last 6 bits
> of (IRQCTL) to be 1 (0x3f), this is only suitable for H3ES1.*, according
> to Hardware manual values 1 are "setting prohibited" for Gen3.
> 
> Signed-off-by: Hoan Nguyen An <na-hoan@jinso.co.jp>

Yes, this is what we discussed for "[v2 PATCH] thermal:
rcar_gen3_thermal: Fix init value of IRQCTL register"

Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register
  2019-03-27  9:03 [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register Nguyen An Hoan
                   ` (2 preceding siblings ...)
  2019-03-28  7:06 ` Wolfram Sang
@ 2019-03-28  8:05 ` Geert Uytterhoeven
  3 siblings, 0 replies; 5+ messages in thread
From: Geert Uytterhoeven @ 2019-03-28  8:05 UTC (permalink / raw)
  To: Nguyen An Hoan
  Cc: Linux-Renesas, Geert Uytterhoeven, Zhang Rui, Jiri Slaby,
	Wolfram Sang, Eduardo Valentin, Linux PM list,
	Linux Kernel Mailing List, Kuninori Morimoto, Yoshihiro Shimoda,
	稲吉, Dung:人ソ,
	カオ・ヴァン・ドン

On Wed, Mar 27, 2019 at 10:04 AM Nguyen An Hoan <na-hoan@jinso.co.jp> wrote:
> From: Hoan Nguyen An <na-hoan@jinso.co.jp>
>
> Fix setting value for IRQCTL register. We are setting the last 6 bits
> of (IRQCTL) to be 1 (0x3f), this is only suitable for H3ES1.*, according
> to Hardware manual values 1 are "setting prohibited" for Gen3.
>
> Signed-off-by: Hoan Nguyen An <na-hoan@jinso.co.jp>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-03-28  8:05 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-27  9:03 [RESEND PATCH] thermal: rcar_gen3_thermal: Fix init value of IRQCTL register Nguyen An Hoan
2019-03-27  9:31 ` Niklas Söderlund
2019-03-27  9:34 ` Yoshihiro Shimoda
2019-03-28  7:06 ` Wolfram Sang
2019-03-28  8:05 ` Geert Uytterhoeven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).