• Tejun Heo's avatar
    libata-pmp-prep: implement qc_defer helpers · da917d69
    Tejun Heo authored
    Implement ap->nr_active_links (the number of links with active qcs),
    ap->excl_link (pointer to link which can be used by ->qc_defer and is
    cleared when a qc with ATA_QCFLAG_CLEAR_EXCL completes), and
    ata_link_active().
    
    These can be used by ->qc_defer() to implement proper command
    exclusion.  This set of helpers seem enough for both sil24 (ATAPI
    exclusion needed) and cmd-switching PMP.
    Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
    Signed-off-by: default avatarJeff Garzik <jeff@garzik.org>
    da917d69
libata-eh.c 63.3 KB