• Viresh Kumar's avatar
    dmaengine/dw_dmac: Reconfigure interrupt and chan_cfg register on resume · 61e183f8
    Viresh Kumar authored
    In S2R all DMA registers are reset by hardware and thus they are required to be
    reprogrammed. The channels which aren't reprogrammed are channel configuration
    and interrupt enable registers, which are currently programmed at chan_alloc
    time.
    
    This patch creates another routine to initialize a channel. It will try to
    initialize channel on every dwc_dostart() call. If channel is already
    initialised then it simply returns, otherwise it configures registers.
    
    This routine will also initialize registers on wakeup from S2R, as we mark
    channels as uninitialized on suspend.
    Signed-off-by: default avatarViresh Kumar <viresh.kumar@st.com>
    Signed-off-by: default avatarVinod Koul <vinod.koul@linux.intel.com>
    61e183f8
dw_dmac.c 40.9 KB