• Damien.Horsley's avatar
    dmaengine: mdc: Correct terminate_all handling · 0c328de7
    Damien.Horsley authored
    Use of the CANCEL bit in mdc_terminate_all creates an
    additional 'command done' to appear in the registers (in
    addition to an interrupt).
    
    In addition, there is a potential race between
    mdc_terminate_all and the irq handler if a transfer
    completes at the same time as the terminate all (presently
    this results in an inappropriate warning).
    
    To handle these issues, any outstanding 'command done'
    events are cleared during mdc_terminate_all and the irq
    handler takes no action when there are no new 'command done'
    events.
    Signed-off-by: default avatarDamien.Horsley <Damien.Horsley@imgtec.com>
    Signed-off-by: default avatarVinod Koul <vinod.koul@intel.com>
    0c328de7
img-mdc-dma.c 26.5 KB