[Skiboot] [RFC 06/12] npu2-opencapi: Simplify freset states

Frederic Barrat fbarrat at linux.ibm.com
Fri Jun 21 19:15:27 AEST 2019



Le 21/06/2019 à 02:27, Andrew Donnellan a écrit :
> On 19/6/19 10:45 pm, Frederic Barrat wrote:
>> Let's get rid of one transitional state, since there's no need to
>> pause in between releasing the reset signals of the ODL and the
>> adapter.
>>
>> Signed-off-by: Frederic Barrat <fbarrat at linux.ibm.com>
>> -        /*
>> -         * Minimal delay before taking adapter out of
>> -         * reset. Could be useless, but doesn't hurt
>> -         */
>> -        return pci_slot_set_sm_timeout(slot, msecs_to_tb(1));
>> -
> 
> So it turns out this is indeed useless?

Yes. The DLx designer had always stated so. I added the delay as a 
conservative measure a while back, as it took some time for the link 
retrain to become stable (needed a patch in the DLx/TLx + the new PHY 
settings + me understanding what was going on). But I've removed it in 
my setup for quite a while now, and my boot loop and reset loops have 
been working well, so I'm confident to remove it.

   Fred

> Reviewed-by: Andrew Donnellan <ajd at linux.ibm.com>
> 
>> -    case OCAPI_SLOT_FRESET_DEASSERT_DELAY:
>>           deassert_adapter_reset(dev);
>>           pci_slot_set_state(slot,
>> -                OCAPI_SLOT_FRESET_DEASSERT_DELAY2);
>> +                OCAPI_SLOT_FRESET_DEASSERT_DELAY);
>>           /* give 250ms to device to be ready */
>>           return pci_slot_set_sm_timeout(slot, msecs_to_tb(250));
>> -    case OCAPI_SLOT_FRESET_DEASSERT_DELAY2:
>> +    case OCAPI_SLOT_FRESET_DEASSERT_DELAY:
>>           unfence_brick(dev);
>>           set_init_pattern(chip_id, dev);
>>           pci_slot_set_state(slot,
>>
> 



More information about the Skiboot mailing list