[Skiboot] [PATCH v4] capi: Poll Err/Status register during CAPP recovery

Stewart Smith stewart at linux.vnet.ibm.com
Wed Apr 4 18:54:07 AEST 2018

Vaibhav Jain <vaibhav at linux.vnet.ibm.com> writes:
> This patch updates do_capp_recovery_scoms() to poll the CAPP
> Err/Status control register, check for CAPP-Recovery to complete/fail
> based on indications of BITS-1,5,9 and then proceed with the
> CAPP-Recovery scoms iif recovery completed successfully. This would
> prevent cases where we bring-up the PCIe link while recovery sequencer
> on CAPP is still busy with casting out cache lines.
> In case CAPP-Recovery didn't complete successfully an error is returned
> from do_capp_recovery_scoms() asking phb4_creset() to keep the phb4
> fenced and mark it as broken.
> The loop that implements polling of Err/Status register will also log
> an error on the PHB when it continues for more than 168ms which is the
> max time to failure for CAPP-Recovery.
> Signed-off-by: Vaibhav Jain <vaibhav at linux.vnet.ibm.com>
> ---
> Changelog:
> v4 -> Use OPAL_SUCCESS for return-code & error check  [Alastair]
> v3 -> Introduced a timeout for the Poll loop of 168ms [Christophe]
> v2 -> Added an extra check for Bit(0) in Err/Status reg at the
>       beginning to check if recovery mode was entered. [Christophe]
> ---
>  hw/phb4.c | 85 ++++++++++++++++++++++++++++++++++++++++++++++++++-------------
>  1 file changed, 68 insertions(+), 17 deletions(-)

Merged to master as of 09b853cae0aa0aeb7633112a5f7487f4591bc721
Stewart Smith
OPAL Architect, IBM.

More information about the Skiboot mailing list