RE: [PATCH][RESEND] scsi: ufs-mediatek: Correct operator & -> &&

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> From: dongjian <dongjian@xxxxxxxxxx>
> 
> The "lpm" and "->enabled" are all bool type, it should be using
> operator && rather than bit operator.
> 
> Fixes: 488edafb1120 (scsi: ufs-mediatek: Introduce low-power mode for device
> power supply)
> 
> Signed-off-by: dongjian <dongjian@xxxxxxxxxx>
> Signed-off-by: Yue Hu <huyue2@xxxxxxxxxx>
Reviewed-by: Avri Altman <avri.altman@xxxxxxx>


> ---
>  drivers/scsi/ufs/ufs-mediatek.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/scsi/ufs/ufs-mediatek.c b/drivers/scsi/ufs/ufs-mediatek.c
> index c55202b..a981f26 100644
> --- a/drivers/scsi/ufs/ufs-mediatek.c
> +++ b/drivers/scsi/ufs/ufs-mediatek.c
> @@ -911,7 +911,7 @@ static void ufs_mtk_vreg_set_lpm(struct ufs_hba
> *hba, bool lpm)
>         if (!hba->vreg_info.vccq2 || !hba->vreg_info.vcc)
>                 return;
> 
> -       if (lpm & !hba->vreg_info.vcc->enabled)
> +       if (lpm && !hba->vreg_info.vcc->enabled)
>                 regulator_set_mode(hba->vreg_info.vccq2->reg,
>                                    REGULATOR_MODE_IDLE);
>         else if (!lpm)
> --
> 1.9.1
> 





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux