Skip to content
Commit e4b8dce1 authored by Patryk Duda's avatar Patryk Duda Committed by Carles Cufí
Browse files

drivers: dma: Simplify stm32_dma_check_fifo_mburst() function



This function is responsible for checking if combination of msize,
mburst and FIFO level is allowed. Possible combinations can be found in
ST documentation, eg. Table 36. FIFO threshold configurations, RM0402
9.3.13 FIFO chapter.

Previously there was no 'break' or '__fallthrough' in msize switch which
caused compilation errors. Since we are confirming that combination is
correct, 'break' statements should be used.

Besides of introducing missing 'break' statements, this patch moves
'return false' from switch to the end of the function. This makes code
shorter and easier to understand, because we have only correct
combinations.

Signed-off-by: default avatarPatryk Duda <pdk@semihalf.com>
parent 997f5edf
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment