• T
    [PATCH] libata-eh: implement ata_eh_info and ata_eh_context · f3e81b19
    Tejun Heo 提交于
    struct ata_eh_info serves as the communication channel between
    execution path and EH.  Execution path describes detected error
    condition in ap->eh_info and EH recovers the port using it.  To avoid
    missing error conditions detected during EH, EH makes its own copy of
    eh_info and clears it on entry allowing error info to accumulate
    during EH.
    
    Most EH states including EH's copy of eh_info are stored in
    ap->eh_context (struct ata_eh_context) which is owned by EH and thus
    doesn't require any synchronization to access and alter.  This
    standardized context makes it easy to integrate various parts of EH
    and extend EH to handle multiple links (for PM).
    Signed-off-by: NTejun Heo <htejun@gmail.com>
    f3e81b19
libata.h 31.0 KB