提交 fd91ddad 编写于 作者: V Vivek Gautam 提交者: Martin K. Petersen

phy: qcom-ufs: Remove unnecessary BUG_ON

BUG_ON() are not preferred in the driver, plus the variable
on which BUG_ON is asserted is already checked in the code
before passing.
Signed-off-by: NVivek Gautam <vivek.gautam@codeaurora.org>
Reviewed-by: NSubhash Jadavani <subhashj@codeaurora.org>
Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
上级 fd3e165a
...@@ -322,8 +322,6 @@ int ufs_qcom_phy_cfg_vreg(struct phy *phy, ...@@ -322,8 +322,6 @@ int ufs_qcom_phy_cfg_vreg(struct phy *phy,
struct ufs_qcom_phy *ufs_qcom_phy = get_ufs_qcom_phy(phy); struct ufs_qcom_phy *ufs_qcom_phy = get_ufs_qcom_phy(phy);
struct device *dev = ufs_qcom_phy->dev; struct device *dev = ufs_qcom_phy->dev;
BUG_ON(!vreg);
if (regulator_count_voltages(reg) > 0) { if (regulator_count_voltages(reg) > 0) {
min_uV = on ? vreg->min_uV : 0; min_uV = on ? vreg->min_uV : 0;
ret = regulator_set_voltage(reg, min_uV, vreg->max_uV); ret = regulator_set_voltage(reg, min_uV, vreg->max_uV);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册