summaryrefslogtreecommitdiffstats
path: root/drivers/phy/samsung
diff options
context:
space:
mode:
authorChanho Park <chanho61.park@samsung.com>2022-06-07 09:29:05 +0200
committerVinod Koul <vkoul@kernel.org>2022-06-08 18:21:32 +0200
commit521f88bf4daa04ca96968be1f49a49f5a4e31488 (patch)
treea55abef434515878b6f54726791bf7bd0c0f3a57 /drivers/phy/samsung
parentphy: samsung: ufs: rename cfg to cfgs for clarification (diff)
downloadlinux-521f88bf4daa04ca96968be1f49a49f5a4e31488.tar.xz
linux-521f88bf4daa04ca96968be1f49a49f5a4e31488.zip
phy: samsung: ufs: constify samsung_ufs_phy_cfg
Put const qualifier of samsung_ufs_phy_cfg pointer because they will not be changed from drvdata. Signed-off-by: Chanho Park <chanho61.park@samsung.com> Reviewed-by: Alim Akhtar <alim.akhtar@samsung.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20220607072907.127000-4-chanho61.park@samsung.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/phy/samsung')
-rw-r--r--drivers/phy/samsung/phy-samsung-ufs.c4
-rw-r--r--drivers/phy/samsung/phy-samsung-ufs.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/drivers/phy/samsung/phy-samsung-ufs.c b/drivers/phy/samsung/phy-samsung-ufs.c
index ed272631e8aa..cd1c02d2cdda 100644
--- a/drivers/phy/samsung/phy-samsung-ufs.c
+++ b/drivers/phy/samsung/phy-samsung-ufs.c
@@ -75,7 +75,7 @@ out:
static int samsung_ufs_phy_calibrate(struct phy *phy)
{
struct samsung_ufs_phy *ufs_phy = get_samsung_ufs_phy(phy);
- struct samsung_ufs_phy_cfg **cfgs = ufs_phy->cfgs;
+ const struct samsung_ufs_phy_cfg * const *cfgs = ufs_phy->cfgs;
const struct samsung_ufs_phy_cfg *cfg;
int err = 0;
int i;
@@ -327,7 +327,7 @@ static int samsung_ufs_phy_probe(struct platform_device *pdev)
drvdata = match->data;
phy->dev = dev;
phy->drvdata = drvdata;
- phy->cfgs = (struct samsung_ufs_phy_cfg **)drvdata->cfgs;
+ phy->cfgs = drvdata->cfgs;
phy->isol = &drvdata->isol;
phy->lane_cnt = PHY_DEF_LANE_CNT;
diff --git a/drivers/phy/samsung/phy-samsung-ufs.h b/drivers/phy/samsung/phy-samsung-ufs.h
index 1788b356cf56..5cd919539a3e 100644
--- a/drivers/phy/samsung/phy-samsung-ufs.h
+++ b/drivers/phy/samsung/phy-samsung-ufs.h
@@ -121,7 +121,7 @@ struct samsung_ufs_phy {
struct clk *rx0_symbol_clk;
struct clk *rx1_symbol_clk;
const struct samsung_ufs_phy_drvdata *drvdata;
- struct samsung_ufs_phy_cfg **cfgs;
+ const struct samsung_ufs_phy_cfg * const *cfgs;
const struct pmu_isol *isol;
u8 lane_cnt;
int ufs_phy_state;