Re: [PATCH 4/8 v4] thermal: rcar: retern error rcar_thermal_get_temp() if no ctemp update

2015-12-14 Thread Kuninori Morimoto
Hi Eduardo, again > I believe the problem here is actually the lack of error > handling/propagation. Are you sure you want to write to parameter > in the fail path ? > > rcar_thermal_update_temp already returns error code when it fails > to read temperature. Don't you think it would make more se

Re: [PATCH 4/8 v4] thermal: rcar: retern error rcar_thermal_get_temp() if no ctemp update

2015-12-14 Thread Kuninori Morimoto
Hi Eduardo > > --- a/drivers/thermal/rcar_thermal.c > > +++ b/drivers/thermal/rcar_thermal.c > > @@ -199,9 +199,9 @@ static int rcar_thermal_update_temp(struct > > rcar_thermal_priv *priv) > > > > dev_dbg(dev, "thermal%d %d -> %d\n", priv->id, priv->ctemp, ctemp); > > > > - priv->ctem

Re: [PATCH 4/8 v4] thermal: rcar: retern error rcar_thermal_get_temp() if no ctemp update

2015-12-14 Thread Eduardo Valentin
On Tue, Dec 08, 2015 at 05:28:13AM +, Kuninori Morimoto wrote: > From: Kuninori Morimoto > > Current rcar_thermal_get_temp() returns latest temperature, but it might > not be updated if some HW issue happened. This means user might get > wrong temperature. This patch solved this issue. > > S

[PATCH 4/8 v4] thermal: rcar: retern error rcar_thermal_get_temp() if no ctemp update

2015-12-07 Thread Kuninori Morimoto
From: Kuninori Morimoto Current rcar_thermal_get_temp() returns latest temperature, but it might not be updated if some HW issue happened. This means user might get wrong temperature. This patch solved this issue. Signed-off-by: Kuninori Morimoto --- v3 -> v4 - "happend" -> "happened" drive