Linux ARM-MSM sub-architecture
 help / color / mirror / Atom feed
From: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
To: Manikanta Mylavarapu <quic_mmanikan@quicinc.com>,
	srinivas.kandagatla@linaro.org, robh@kernel.org,
	krzk+dt@kernel.org, conor+dt@kernel.org, amitk@kernel.org,
	thara.gopinath@gmail.com, rafael@kernel.org,
	daniel.lezcano@linaro.org, rui.zhang@intel.com,
	lukasz.luba@arm.com, andersson@kernel.org,
	konradybcio@kernel.org, linux-arm-msm@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-pm@vger.kernel.org
Cc: quic_srichara@quicinc.com, quic_varada@quicinc.com
Subject: Re: [PATCH v8 3/7] thermal/drivers/tsens: Add TSENS enable and calibration support for V2
Date: Fri, 22 Nov 2024 13:35:17 +0100	[thread overview]
Message-ID: <bf27f92a-5fc6-4b09-8653-4ac3ef438d4f@oss.qualcomm.com> (raw)
In-Reply-To: <20241115103957.1157495-4-quic_mmanikan@quicinc.com>

On 15.11.2024 11:39 AM, Manikanta Mylavarapu wrote:
> From: Praveenkumar I <quic_ipkumar@quicinc.com>
> 
> SoCs without RPM need to enable sensors and calibrate them from the kernel.
> The IPQ5332 and IPQ5424 use the tsens v2.3.3 IP and do not have RPM.
> Therefore, add a new calibration function for V2, as the tsens.c calib
> function only supports V1. Also add new feature_config, ops and data for
> IPQ5332, IPQ5424.
> 
> Although the TSENS IP supports 16 sensors, not all are used. The hw_id
> is used to enable the relevant sensors.
> 
> Signed-off-by: Praveenkumar I <quic_ipkumar@quicinc.com>
> Signed-off-by: Manikanta Mylavarapu <quic_mmanikan@quicinc.com>
> ---

[...]

> +{
> +	u32 shift = V2_SHIFT_DEFAULT;
> +	u32 slope = V2_SLOPE_DEFAULT, czero = V2_CZERO_DEFAULT, val;

Please don't mix initialized and uninitialized variables in the same line,
I think it would be the cleanest if you initialized the ones you want on
separate lines and then declared val separately as well (and preferably
in reverse-Christmas-tree order)

[...]

> +	}
> +
> +	val =	FIELD_PREP(CONVERSION_SHIFT_MASK, shift) |

tab->space after '='

[...]

> +	/* Select temperature format, unit is deci-Celsius */
> +	regmap_field_write(priv->rf[CODE_OR_TEMP], RSEULT_FORMAT_TEMP);

"result"?

Konrad

  reply	other threads:[~2024-11-22 12:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-15 10:39 [PATCH v8 0/7] Add TSENS support for IPQ5332, IPQ5424 Manikanta Mylavarapu
2024-11-15 10:39 ` [PATCH v8 1/7] dt-bindings: thermal: tsens: Add ipq5332, ipq5424 compatible Manikanta Mylavarapu
2024-11-15 10:39 ` [PATCH v8 2/7] dt-bindings: nvmem: Add compatible for IPQ5424 Manikanta Mylavarapu
2024-11-15 10:39 ` [PATCH v8 3/7] thermal/drivers/tsens: Add TSENS enable and calibration support for V2 Manikanta Mylavarapu
2024-11-22 12:35   ` Konrad Dybcio [this message]
2024-11-22 12:56     ` Manikanta Mylavarapu
2024-11-15 10:39 ` [PATCH v8 4/7] arm64: dts: qcom: ipq5332: Add tsens node Manikanta Mylavarapu
2024-11-15 10:39 ` [PATCH v8 5/7] arm64: dts: qcom: ipq5332: Add thermal zone nodes Manikanta Mylavarapu
2024-11-15 10:39 ` [PATCH v8 6/7] arm64: dts: qcom: ipq5424: Add tsens node Manikanta Mylavarapu
2024-11-15 10:39 ` [PATCH v8 7/7] arm64: dts: qcom: ipq5424: Add thermal zone nodes Manikanta Mylavarapu

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=bf27f92a-5fc6-4b09-8653-4ac3ef438d4f@oss.qualcomm.com \
    --to=konrad.dybcio@oss.qualcomm.com \
    --cc=amitk@kernel.org \
    --cc=andersson@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=daniel.lezcano@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=konradybcio@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=lukasz.luba@arm.com \
    --cc=quic_mmanikan@quicinc.com \
    --cc=quic_srichara@quicinc.com \
    --cc=quic_varada@quicinc.com \
    --cc=rafael@kernel.org \
    --cc=robh@kernel.org \
    --cc=rui.zhang@intel.com \
    --cc=srinivas.kandagatla@linaro.org \
    --cc=thara.gopinath@gmail.com \
    /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