• Erwan Le Ray's avatar
    serial: stm32: add support of RX FIFO threshold · d0a6a7bc
    Erwan Le Ray authored
    Adds the support of RX FIFO threshold in order to improve the RX FIFO
    management.
    This is done by enabling fifo threshold interrupt, instead of relying
    on rx empty/fifo not full irq. That basically generates one irq/char
    currently. With this patch:
    - RXCFG is set to half fifo size (e.g. 16/2 = 8 data for a 16 data depth
      FIFO)
    - irq rate may be reduced by up to 1/RXCFG,  e.g. 1 over 8 with current
      RXCFG setting.
    - Receiver timeout is used to gather chars when FIFO threshold isn't
      reached.
    Signed-off-by: default avatarErwan Le Ray <erwan.leray@st.com>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    d0a6a7bc
stm32-usart.h 7.54 KB