[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250910-memory-tegra-cleanup-v1-1-023c33a2d997@linaro.org>
Date: Wed, 10 Sep 2025 12:43:57 +0200
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Krzysztof Kozlowski <krzk@...nel.org>,
Thierry Reding <thierry.reding@...il.com>,
Jonathan Hunter <jonathanh@...dia.com>
Cc: linux-kernel@...r.kernel.org, linux-tegra@...r.kernel.org,
Aaron Kling <webgeek1234@...il.com>,
Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Subject: [PATCH 01/13] memory: tegra124-emc: Simplify return of emc_init()
emc_init() returns always success, so just drop return valye to simplify
it.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
---
drivers/memory/tegra/tegra124-emc.c | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/drivers/memory/tegra/tegra124-emc.c b/drivers/memory/tegra/tegra124-emc.c
index 03f1daa2d132a81d28705ec7c62d640d7d25a894..9aad02901613f1b2ed855c11bcd76fef153034af 100644
--- a/drivers/memory/tegra/tegra124-emc.c
+++ b/drivers/memory/tegra/tegra124-emc.c
@@ -896,7 +896,7 @@ static void emc_read_current_timing(struct tegra_emc *emc,
timing->emc_mode_reset = 0;
}
-static int emc_init(struct tegra_emc *emc)
+static void emc_init(struct tegra_emc *emc)
{
emc->dram_type = readl(emc->regs + EMC_FBIO_CFG5);
@@ -913,8 +913,6 @@ static int emc_init(struct tegra_emc *emc)
emc->dram_num = tegra_mc_get_emem_device_count(emc->mc);
emc_read_current_timing(emc, &emc->last_timing);
-
- return 0;
}
static int load_one_timing_from_dt(struct tegra_emc *emc,
@@ -1472,11 +1470,7 @@ static int tegra_emc_probe(struct platform_device *pdev)
ram_code);
}
- err = emc_init(emc);
- if (err) {
- dev_err(&pdev->dev, "EMC initialization failed: %d\n", err);
- return err;
- }
+ emc_init(emc);
platform_set_drvdata(pdev, emc);
--
2.48.1
Powered by blists - more mailing lists