lkml.org 
[lkml]   [2013]   [Jul]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH v2 4/6] usb: phy: msm: Remove unnecessarily check for valid regulators.
    Date
    From: "Ivan T. Ivanov" <iivanov@mm-sol.com>

    Whether regulators are available or not is checked at driver
    probe. If they are not available driver will refuse to load,
    so no need to check them again.

    Signed-off-by: Ivan T. Ivanov <iivanov@mm-sol.com>
    ---
    drivers/usb/phy/phy-msm-usb.c | 10 ----------
    1 file changed, 10 deletions(-)

    diff --git a/drivers/usb/phy/phy-msm-usb.c b/drivers/usb/phy/phy-msm-usb.c
    index c72f7c1..0e93dbc 100644
    --- a/drivers/usb/phy/phy-msm-usb.c
    +++ b/drivers/usb/phy/phy-msm-usb.c
    @@ -159,16 +159,6 @@ static int msm_hsusb_ldo_set_mode(struct msm_otg *motg, int on)
    {
    int ret = 0;

    - if (!motg->v1p8 || IS_ERR(motg->v1p8)) {
    - pr_err("%s: HSUSB_1p8 is not initialized\n", __func__);
    - return -ENODEV;
    - }
    -
    - if (!motg->v3p3 || IS_ERR(motg->v3p3)) {
    - pr_err("%s: HSUSB_3p3 is not initialized\n", __func__);
    - return -ENODEV;
    - }
    -
    if (on) {
    ret = regulator_set_optimum_mode(motg->v1p8,
    USB_PHY_1P8_HPM_LOAD);
    --
    1.7.9.5


    \
     
     \ /
      Last update: 2013-07-29 09:41    [W:2.729 / U:0.024 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site