lkml.org 
[lkml]   [2020]   [Aug]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[BUG] crypto: hisilicon: accessing the data mapped to streaming DMA
Date
In qm_qp_ctx_cfg(), "sqc" and "aeqc" are mapped to streaming DMA:
  eqc_dma = dma_map_single(..., eqc, ...);
  ......
  aeqc_dma = dma_map_single(..., aeqc, ...);

Then "sqc" and "aeqc" are accessed at many places, such as:
  eqc->base_l = cpu_to_le32(lower_32_bits(qm->eqe_dma));
  eqc->base_h = cpu_to_le32(upper_32_bits(qm->eqe_dma));
  ......
  aeqc->base_l = cpu_to_le32(lower_32_bits(qm->aeqe_dma));
  aeqc->base_h = cpu_to_le32(upper_32_bits(qm->aeqe_dma));

These accesses may cause data inconsistency between CPU cache and hardware.

I am not sure how to properly fix this problem, and thus I only report it.


Best wishes,
Jia-Ju Bai

\
 
 \ /
  Last update: 2020-08-02 16:53    [W:0.070 / U:0.264 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site