2
0

132-dmaengine-at_xdmac-adapt-perid-for-mem2mem-operation.patch 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. From 1dccaa4c1e99cd8bd27684a2c87ec806d426c088 Mon Sep 17 00:00:00 2001
  2. From: Eugen Hristev <[email protected]>
  3. Date: Fri, 16 Oct 2020 12:37:25 +0300
  4. Subject: [PATCH 132/247] dmaengine: at_xdmac: adapt perid for mem2mem
  5. operations
  6. The PERID in the CC register for mem2mem operations must match an unused
  7. PERID.
  8. The PERID field is 7 bits, but the selected value is 0x3f.
  9. On later products we can have more reserved PERIDs for actual peripherals,
  10. thus this needs to be increased to maximum size.
  11. Changing the value to 0x7f, which is the maximum for 7 bits field.
  12. Signed-off-by: Eugen Hristev <[email protected]>
  13. Reviewed-by: Tudor Ambarus <[email protected]>
  14. Link: https://lore.kernel.org/r/[email protected]
  15. Signed-off-by: Vinod Koul <[email protected]>
  16. ---
  17. drivers/dma/at_xdmac.c | 6 +++---
  18. 1 file changed, 3 insertions(+), 3 deletions(-)
  19. --- a/drivers/dma/at_xdmac.c
  20. +++ b/drivers/dma/at_xdmac.c
  21. @@ -865,7 +865,7 @@ at_xdmac_interleaved_queue_desc(struct d
  22. * match the one of another channel. If not, it could lead to spurious
  23. * flag status.
  24. */
  25. - u32 chan_cc = AT_XDMAC_CC_PERID(0x3f)
  26. + u32 chan_cc = AT_XDMAC_CC_PERID(0x7f)
  27. | AT_XDMAC_CC_DIF(0)
  28. | AT_XDMAC_CC_SIF(0)
  29. | AT_XDMAC_CC_MBSIZE_SIXTEEN
  30. @@ -1047,7 +1047,7 @@ at_xdmac_prep_dma_memcpy(struct dma_chan
  31. * match the one of another channel. If not, it could lead to spurious
  32. * flag status.
  33. */
  34. - u32 chan_cc = AT_XDMAC_CC_PERID(0x3f)
  35. + u32 chan_cc = AT_XDMAC_CC_PERID(0x7f)
  36. | AT_XDMAC_CC_DAM_INCREMENTED_AM
  37. | AT_XDMAC_CC_SAM_INCREMENTED_AM
  38. | AT_XDMAC_CC_DIF(0)
  39. @@ -1153,7 +1153,7 @@ static struct at_xdmac_desc *at_xdmac_me
  40. * match the one of another channel. If not, it could lead to spurious
  41. * flag status.
  42. */
  43. - u32 chan_cc = AT_XDMAC_CC_PERID(0x3f)
  44. + u32 chan_cc = AT_XDMAC_CC_PERID(0x7f)
  45. | AT_XDMAC_CC_DAM_UBS_AM
  46. | AT_XDMAC_CC_SAM_INCREMENTED_AM
  47. | AT_XDMAC_CC_DIF(0)