Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Nícolas F. R. A. Prado" <nfraprado@collabora.com>
To: bchihi@baylibre.com
Cc: daniel.lezcano@linaro.org,
	angelogioacchino.delregno@collabora.com, rafael@kernel.org,
	amitk@kernel.org, rui.zhang@intel.com, matthias.bgg@gmail.com,
	robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org,
	rdunlap@infradead.org, ye.xingchen@zte.com.cn,
	p.zabel@pengutronix.de, linux-pm@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org,
	wenst@chromium.org, james.lo@mediatek.com,
	rex-bc.chen@mediatek.com, abailon@baylibre.com,
	amergnat@baylibre.com, khilman@baylibre.com
Subject: Re: [PATCH v2 5/5] thermal/drivers/mediatek/lvts_thermal: Update calibration data documentation
Date: Wed, 3 May 2023 21:01:51 -0400	[thread overview]
Message-ID: <b120f52a-38c4-4f06-86d5-503a67bb1dab@notapiano> (raw)
In-Reply-To: <20230425133052.199767-6-bchihi@baylibre.com>

On Tue, Apr 25, 2023 at 03:30:52PM +0200, bchihi@baylibre.com wrote:
> From: Balsam CHIHI <bchihi@baylibre.com>
> 
> Update LVTS calibration data documentation for mt8192 and mt8195.
> 
> Signed-off-by: Balsam CHIHI <bchihi@baylibre.com>
> ---
>  drivers/thermal/mediatek/lvts_thermal.c | 59 ++++++++++++++++++-------
>  1 file changed, 43 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/thermal/mediatek/lvts_thermal.c b/drivers/thermal/mediatek/lvts_thermal.c
> index 8df7b4c72a658..3df4989f9902b 100644
> --- a/drivers/thermal/mediatek/lvts_thermal.c
> +++ b/drivers/thermal/mediatek/lvts_thermal.c
> @@ -531,30 +531,57 @@ static int lvts_sensor_init(struct device *dev, struct lvts_ctrl *lvts_ctrl,
>   * The efuse blob values follows the sensor enumeration per thermal
>   * controller. The decoding of the stream is as follow:
>   *
> - * stream index map for MCU Domain :
> + * MT8195 :
> + * Stream index map for MCU Domain mt8195 :
>   *
> - * <-----mcu-tc#0-----> <-----sensor#0-----> <-----sensor#1----->
> - *  0x01 | 0x02 | 0x03 | 0x04 | 0x05 | 0x06 | 0x07 | 0x08 | 0x09
> + * <-----sensor#0-----> <-----sensor#1----->
> + *  0x04 | 0x05 | 0x06 | 0x07 | 0x08 | 0x09

I don't think you need to remove the controller calibration data from this
comment, even though you don't use it in the code. Could come in handy in the
future.

>   *
[..]
> + * MT8192 :
> + * Stream index map for MCU Domain mt8192 :
> + *
> + * <--------sensor#0---------> <--------sensor#1--------->
> + *  0x04 | 0x05 | 0x06 | 0x07 | 0x08 | 0x09 | 0x0A | 0x0B

Each sensor data is 3 bytes long, just like for MT8195. The fourth byte contains
the controller calibration data, but it is spread across these fourth bytes. I'd
just leave these bytes undocumented for now since they're not currently used.

So,

  + * <-----sensor#0----->        <-----sensor#1----->       
  + *  0x04 | 0x05 | 0x06 | 0x07 | 0x08 | 0x09 | 0x0A | 0x0B

etc.

With that fixed,

Reviewed-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>

Thanks,
Nícolas

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2023-05-04  1:02 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-25 13:30 [PATCH v2 0/5] Add LVTS support for mt8192 bchihi
2023-04-25 13:30 ` [PATCH v2 1/5] thermal/drivers/mediatek/lvts_thermal: Add suspend and resume bchihi
2023-04-25 13:30 ` [PATCH v2 2/5] dt-bindings: thermal: mediatek: Add LVTS thermal controller definition for mt8192 bchihi
2023-05-04  0:49   ` Nícolas F. R. A. Prado
2023-04-25 13:30 ` [PATCH v2 3/5] thermal/drivers/mediatek/lvts_thermal: Add mt8192 support bchihi
2023-04-28 20:10   ` Nícolas F. R. A. Prado
2023-05-04  0:51   ` Nícolas F. R. A. Prado
2023-04-25 13:30 ` [PATCH v2 4/5] arm64: dts: mediatek: mt8192: Add thermal nodes and thermal zones bchihi
2023-05-04  0:53   ` Nícolas F. R. A. Prado
2023-04-25 13:30 ` [PATCH v2 5/5] thermal/drivers/mediatek/lvts_thermal: Update calibration data documentation bchihi
2023-05-04  1:01   ` Nícolas F. R. A. Prado [this message]
2023-05-02 10:35 ` [PATCH v2 0/5] Add LVTS support for mt8192 Chen-Yu Tsai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b120f52a-38c4-4f06-86d5-503a67bb1dab@notapiano \
    --to=nfraprado@collabora.com \
    --cc=abailon@baylibre.com \
    --cc=amergnat@baylibre.com \
    --cc=amitk@kernel.org \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=bchihi@baylibre.com \
    --cc=daniel.lezcano@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=james.lo@mediatek.com \
    --cc=khilman@baylibre.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=matthias.bgg@gmail.com \
    --cc=p.zabel@pengutronix.de \
    --cc=rafael@kernel.org \
    --cc=rdunlap@infradead.org \
    --cc=rex-bc.chen@mediatek.com \
    --cc=robh+dt@kernel.org \
    --cc=rui.zhang@intel.com \
    --cc=wenst@chromium.org \
    --cc=ye.xingchen@zte.com.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox