Skip to content
  • Christoph Hellwig's avatar
    aio: simplify cancellation · 888933f8
    Christoph Hellwig authored
    
    
    With the current aio code there is no need for the magic KIOCB_CANCELLED
    value, as a cancelation just kicks the driver to queue the completion
    ASAP, with all actual completion handling done in another thread. Given
    that both the completion path and cancelation take the context lock there
    is no need for magic cmpxchg loops either.  If we remove iocbs from the
    active list after calling ->ki_cancel (but with ctx_lock still held), we
    can also rely on the invariant thay anything found on the list has a
    ->ki_cancel callback and can be cancelled, further simplifing the code.
    
    Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
    888933f8