Re: [PATCH 03/10] ufs: host: Add common Hibern8 TX FSM polling helper

Larisa Ileana Grigore <[email protected]>
Newsgroups org.kernel.vger.linux-scsi,dev.linux.lists.imx,org.infradead.lists.linux-arm-kernel,org.kernel.vger.linux-arm-msm,org.kernel.vger.linux-devicetree,org.kernel.vger.linux-kernel
Message-ID <[email protected]>
On 8/26/2026 6:33 PM, Bart Van Assche wrote:
> On 8/26/26 6:40 AM, Larisa Grigore wrote:
>> +    for (i = 0; i < num_lanes; i++) {
>> +        err = ufshcd_dme_get(hba,
>> +                UIC_ARG_MIB_SEL(TX_FSM_STATE,
>> +                    UIC_ARG_MPHY_TX_GEN_SEL_INDEX(i)),
>> +                &tx_fsm_val);
>> +        if (err) {
>> +            dev_err(hba->dev,
>> +                    "%s: unable to get TX_FSM_STATE for lane %u, err 
>> %d\n",
>> +                    __func__, i, err);
>> +            return err;
>> +        }
>> +
>> +        if (tx_fsm_val != TX_STATE_HIBERN8) {
>> +            dev_err(hba->dev,
>> +                    "%s: timeout waiting for lane %u to enter 
>> HIBERN8, TX_FSM_STATE=%u\n",
>> +                    __func__, i, tx_fsm_val);
>> +            return -ETIMEDOUT;
>> +        }
>> +    }
> Instead of duplicating this code block, please move it into a new
> function.
> 
> Thanks,
> 
> Bart.

Thanks for taking the time to review this patch series! Will do it.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.