aboutsummaryrefslogtreecommitdiff
path: root/lib/test_dynamic_debug.c
diff options
context:
space:
mode:
authorSerge Semin <fancer.lancer@gmail.com>2024-08-02 10:50:50 +0300
committerVinod Koul <vkoul@kernel.org>2024-08-05 22:07:47 +0530
commitd8fa0802f63502c0409d02c6b701d51841a6f1bd (patch)
tree3756cf68fc493effdd218ccccdb45e3e197eb846 /lib/test_dynamic_debug.c
parent3acb301d33749a8974e61ecda16a5f5441fc9628 (diff)
dmaengine: dw: Simplify max-burst calculation procedure
In order to have a more coherent DW AHB DMA slave configuration method - dwc_config() - let's simplify the source and destination channel max-burst calculation procedure: 1. Create the max-burst verification method as it has been just done for the memory and peripheral address widths. Thus the dwc_config() method will turn to a set of the verification methods execution. 2. Since both the generic DW AHB DMA and Intel iDMA 32-bit engines support the power-of-2 bursts only, then the specified by the client driver max-burst values can be converted to being power-of-2 right in the max-burst verification method. 3. Since max-burst encoded value is required on the CTL_LO fields calculation stage, the encode_maxburst() callback can be easily dropped from the dw_dma structure meanwhile the encoding procedure will be executed right in the CTL_LO register value calculation. Thus the update will provide the next positive effects: the internal DMA-slave config structure will contain only the real DMA-transfer config values, which will be encoded to the DMA-controller register fields only when it's required on the buffer mapping; the redundant encode_maxburst() callback will be dropped simplifying the internal HW-abstraction API; dwc_config() will look more readable executing the verification functions one-by-one. Signed-off-by: Serge Semin <fancer.lancer@gmail.com> Acked-by: Andy Shevchenko <andy@kernel.org> Link: https://lore.kernel.org/r/20240802075100.6475-6-fancer.lancer@gmail.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'lib/test_dynamic_debug.c')
0 files changed, 0 insertions, 0 deletions