mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mateusz Majewski <m.majewski2@samsung.com>
To: linux-pm@vger.kernel.org, linux-samsung-soc@vger.kernel.org,
	devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Cc: Mateusz Majewski <m.majewski2@samsung.com>,
	Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>,
	Krzysztof Kozlowski <krzk@kernel.org>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	Daniel Lezcano <daniel.lezcano@linaro.org>,
	Zhang Rui <rui.zhang@intel.com>,
	Lukasz Luba <lukasz.luba@arm.com>, Rob Herring <robh@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Alim Akhtar <alim.akhtar@samsung.com>,
	Sam Protsenko <semen.protsenko@linaro.org>,
	Anand Moon <linux.amoon@gmail.com>,
	Marek Szyprowski <m.szyprowski@samsung.com>
Subject: [PATCH v4 4/7] drivers/thermal/exynos: reuse data->temp_mask in exynos_tmu_update_temp
Date: Wed, 11 Sep 2024 14:11:27 +0200	[thread overview]
Message-ID: <20240911121136.1120026-5-m.majewski2@samsung.com> (raw)
In-Reply-To: <20240911121136.1120026-1-m.majewski2@samsung.com>

Both the intention and the actual logic is identical, little point in
duplicating it.

Signed-off-by: Mateusz Majewski <m.majewski2@samsung.com>
---
 drivers/thermal/samsung/exynos_tmu.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c
index 8b1014915c31..9bddf9fd5049 100644
--- a/drivers/thermal/samsung/exynos_tmu.c
+++ b/drivers/thermal/samsung/exynos_tmu.c
@@ -357,15 +357,10 @@ static void exynos_tmu_update_bit(struct exynos_tmu_data *data, int reg_off,
 static void exynos_tmu_update_temp(struct exynos_tmu_data *data, int reg_off,
 				   int bit_off, u8 temp)
 {
-	u16 tmu_temp_mask;
 	u32 th;
 
-	tmu_temp_mask =
-		(data->soc == SOC_ARCH_EXYNOS7) ? EXYNOS7_TMU_TEMP_MASK
-						: EXYNOS_TMU_TEMP_MASK;
-
 	th = readl(data->base + reg_off);
-	th &= ~(tmu_temp_mask << bit_off);
+	th &= ~(data->temp_mask << bit_off);
 	th |= temp_to_code(data, temp) << bit_off;
 	writel(th, data->base + reg_off);
 }
-- 
2.45.2


  parent reply	other threads:[~2024-09-11 12:11 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20240911121149eucas1p29b9ccf99a545cfaa924b122cd8dd3183@eucas1p2.samsung.com>
2024-09-11 12:11 ` [PATCH v4 0/7] Add initial Exynos850 support to the thermal driver Mateusz Majewski
     [not found]   ` <CGME20240911121152eucas1p113445ce1ce6b6bd9c8f96322604bf517@eucas1p1.samsung.com>
2024-09-11 12:11     ` [PATCH v4 1/7] drivers/thermal/exynos: use DEFINE_SIMPLE_DEV_PM_OPS Mateusz Majewski
     [not found]   ` <CGME20240911121153eucas1p20f864c51746e6a7de55ecd0e52efe5c4@eucas1p2.samsung.com>
2024-09-11 12:11     ` [PATCH v4 2/7] drivers/thermal/exynos: use pm_sleep_ptr instead of conditional compilation Mateusz Majewski
     [not found]   ` <CGME20240911121154eucas1p1a429a565c446cdd968f565df1ffae42c@eucas1p1.samsung.com>
2024-09-11 12:11     ` [PATCH v4 3/7] drivers/thermal/exynos: improve sanitize_temp_error Mateusz Majewski
     [not found]   ` <CGME20240911121155eucas1p160223d89bff83a89a03c5447252f44a9@eucas1p1.samsung.com>
2024-09-11 12:11     ` Mateusz Majewski [this message]
     [not found]   ` <CGME20240911121157eucas1p2a8ff398f0f30f141de974763680bb041@eucas1p2.samsung.com>
2024-09-11 12:11     ` [PATCH v4 5/7] dt-bindings: thermal: samsung,exynos: add exynos850-tmu string Mateusz Majewski
     [not found]   ` <CGME20240911121158eucas1p2ab3ec5b5b59351af22c5740e02236b16@eucas1p2.samsung.com>
2024-09-11 12:11     ` [PATCH v4 6/7] drivers/thermal/exynos: add initial Exynos850 support Mateusz Majewski
     [not found]   ` <CGME20240911121159eucas1p1ecfa41871f21953b49d90c287d121409@eucas1p1.samsung.com>
2024-09-11 12:11     ` [PATCH v4 7/7] dt-bindings: thermal: samsung,exynos: remove driver-specific information Mateusz Majewski
2026-02-18 18:29   ` [PATCH v4 0/7] Add initial Exynos850 support to the thermal driver Alexey Klimov
2026-03-03  9:02     ` Mateusz Majewski
2026-03-06 12:35       ` Mateusz Majewski
2026-03-10  2:56       ` Alexey Klimov
     [not found]         ` <CGME20260312160809eucas1p1fc79e4d333f3995a48b68ff07ec7726c@eucas1p1.samsung.com>
2026-03-12 16:07           ` Mateusz Majewski

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=20240911121136.1120026-5-m.majewski2@samsung.com \
    --to=m.majewski2@samsung.com \
    --cc=alim.akhtar@samsung.com \
    --cc=bzolnier@gmail.com \
    --cc=conor+dt@kernel.org \
    --cc=daniel.lezcano@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=linux.amoon@gmail.com \
    --cc=lukasz.luba@arm.com \
    --cc=m.szyprowski@samsung.com \
    --cc=rafael@kernel.org \
    --cc=robh@kernel.org \
    --cc=rui.zhang@intel.com \
    --cc=semen.protsenko@linaro.org \
    /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

all inboxes | Powered by JetHome®