Skip to contentSkip to conversation

linux-next: build failure after merge of the regulator tree

PATCH Applied Stephen Rothwell 2 participants 2 messages Mar 10, 2015

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

Hi all,

After merging the regulator tree, today's linux-next build (arm multi_v7_defconfig) failed like this:

drivers/gpu/drm/msm/edp/edp_ctrl.c: In function 'edp_regulator_enable':
drivers/gpu/drm/msm/edp/edp_ctrl.c:335:2: error: implicit declaration of function 'regulator_set_optimum_mode' [-Werror=implicit-function-declaration]
ret = regulator_set_optimum_mode(ctrl->vdda_vreg, VDDA_UA_ON_LOAD);
^

Caused by commits e39ce48f5362 ("regulator: Rename regulator_set_optimum_mode") and ae6e808f1574 ("regulator: Drop temporary regulator_set_optimum_mode wrapper") interacting with commit ab5b0107ccf3 ("drm/msm: Initial add eDP support in msm drm driver (v5)") from Linus' tree (in v4.0-rc1) tree.

There was another use of regulator_set_optimum_mode() in drivers/phy/phy-qcom-ufs.c (introduced by commit adaafaa393ef ("phy:
qcom-ufs: add support for QUALCOMM Technologies UFS PHY drivers") also from v4.0-rc1) which I also fixed in the patch below.

grep is your friend ...

This patch should be applied to your tree as it is based off v4.0-rc1 already.

From: Stephen Rothwell <[email protected]>
Date: Tue, 10 Mar 2015 13:35:59 +1100
Subject: [PATCH] fixes for regulator_set_optimum_mode name change

---
 drivers/gpu/drm/msm/edp/edp_ctrl.c | 6 +++---
 drivers/phy/phy-qcom-ufs.c         | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)
drivers/gpu/drm/msm/edp/edp_ctrl.c +3 -3
index 3e246210c46f..0ec5abdba5c4 100644
@@ -332,7 +332,7 @@ static int edp_regulator_enable(struct edp_ctrl *ctrl)
 		goto vdda_set_fail;
 	}
 
-	ret = regulator_set_optimum_mode(ctrl->vdda_vreg, VDDA_UA_ON_LOAD);
+	ret = regulator_set_load(ctrl->vdda_vreg, VDDA_UA_ON_LOAD);
 	if (ret < 0) {
 		pr_err("%s: vdda_vreg set regulator mode failed.\n", __func__);
 		goto vdda_set_fail;
@@ -356,7 +356,7 @@ static int edp_regulator_enable(struct edp_ctrl *ctrl)
 lvl_enable_fail:
 	regulator_disable(ctrl->vdda_vreg);
 vdda_enable_fail:
-	regulator_set_optimum_mode(ctrl->vdda_vreg, VDDA_UA_OFF_LOAD);
+	regulator_set_load(ctrl->vdda_vreg, VDDA_UA_OFF_LOAD);
 vdda_set_fail:
 	return ret;
 }
@@ -365,7 +365,7 @@ static void edp_regulator_disable(struct edp_ctrl *ctrl)
 {
 	regulator_disable(ctrl->lvl_vreg);
 	regulator_disable(ctrl->vdda_vreg);
-	regulator_set_optimum_mode(ctrl->vdda_vreg, VDDA_UA_OFF_LOAD);
+	regulator_set_load(ctrl->vdda_vreg, VDDA_UA_OFF_LOAD);
 }
 
 static int edp_gpio_config(struct edp_ctrl *ctrl)
drivers/phy/phy-qcom-ufs.c +2 -2
index 44ee983d57fe..86665e9dc399 100644
@@ -346,10 +346,10 @@ int ufs_qcom_phy_cfg_vreg(struct phy *phy,
 			goto out;
 		}
 		uA_load = on ? vreg->max_uA : 0;
-		ret = regulator_set_optimum_mode(reg, uA_load);
+		ret = regulator_set_load(reg, uA_load);
 		if (ret >= 0) {
 			/*
-			 * regulator_set_optimum_mode() returns new regulator
+			 * regulator_set_load() returns new regulator
 			 * mode upon success.
 			 */
 			ret = 0;
Signature · 4 lines
2.1.4
-- 
Cheers,
Stephen Rothwell                    [email protected]
maintainer Applied
#1 lore raw
Quoted 1 line · Stephen Rothwell

grep is your friend ...

Indeed :(

Quoted 2 lines

This patch should be applied to your tree as it is based off v4.0-rc1 already.

Applied, thanks.