3939 */
4040
4141#define ATC_DEFAULT_CFG (ATC_FIFOCFG_HALFFIFO)
42- #define ATC_DEFAULT_CTRLA (0)
4342#define ATC_DEFAULT_CTRLB (ATC_SIF(AT_DMA_MEM_IF) \
4443 |ATC_DIF(AT_DMA_MEM_IF))
4544
@@ -574,7 +573,6 @@ atc_prep_dma_memcpy(struct dma_chan *chan, dma_addr_t dest, dma_addr_t src,
574573 return NULL ;
575574 }
576575
577- ctrla = ATC_DEFAULT_CTRLA ;
578576 ctrlb = ATC_DEFAULT_CTRLB | ATC_IEN
579577 | ATC_SRC_ADDR_MODE_INCR
580578 | ATC_DST_ADDR_MODE_INCR
@@ -585,13 +583,13 @@ atc_prep_dma_memcpy(struct dma_chan *chan, dma_addr_t dest, dma_addr_t src,
585583 * of the most common optimization.
586584 */
587585 if (!((src | dest | len ) & 3 )) {
588- ctrla | = ATC_SRC_WIDTH_WORD | ATC_DST_WIDTH_WORD ;
586+ ctrla = ATC_SRC_WIDTH_WORD | ATC_DST_WIDTH_WORD ;
589587 src_width = dst_width = 2 ;
590588 } else if (!((src | dest | len ) & 1 )) {
591- ctrla | = ATC_SRC_WIDTH_HALFWORD | ATC_DST_WIDTH_HALFWORD ;
589+ ctrla = ATC_SRC_WIDTH_HALFWORD | ATC_DST_WIDTH_HALFWORD ;
592590 src_width = dst_width = 1 ;
593591 } else {
594- ctrla | = ATC_SRC_WIDTH_BYTE | ATC_DST_WIDTH_BYTE ;
592+ ctrla = ATC_SRC_WIDTH_BYTE | ATC_DST_WIDTH_BYTE ;
595593 src_width = dst_width = 0 ;
596594 }
597595
@@ -668,7 +666,7 @@ atc_prep_slave_sg(struct dma_chan *chan, struct scatterlist *sgl,
668666 return NULL ;
669667 }
670668
671- ctrla = ATC_DEFAULT_CTRLA | atslave -> ctrla ;
669+ ctrla = atslave -> ctrla ;
672670 ctrlb = ATC_IEN ;
673671
674672 switch (direction ) {
@@ -801,7 +799,7 @@ atc_dma_cyclic_fill_desc(struct dma_chan *chan, struct at_desc *desc,
801799 u32 ctrla ;
802800
803801 /* prepare common CRTLA value */
804- ctrla = ATC_DEFAULT_CTRLA | atslave -> ctrla
802+ ctrla = atslave -> ctrla
805803 | ATC_DST_WIDTH (reg_width )
806804 | ATC_SRC_WIDTH (reg_width )
807805 | period_len >> reg_width ;
0 commit comments