net: mvpp2: add PPv23 RX FIFO flow control
authorStefan Chulski <stefanc@marvell.com>
Thu, 11 Feb 2021 10:49:00 +0000 (12:49 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 11 Feb 2021 22:50:24 +0000 (14:50 -0800)
commitaca0e23584c90fb3b3aee3e413fd872dee1d55fb
treec35613d887487a37614c53ab7fefdde9eb3c656b
parenteb30b269549a0cd27c3b9a67676f6a39c77fcfa0
net: mvpp2: add PPv23 RX FIFO flow control

New FIFO flow control feature was added in PPv23.
PPv2 FIFO polled by HW and trigger pause frame if FIFO
fill level is below threshold.
FIFO HW flow control enabled with CM3 RXQ&BM flow
control with ethtool.
Current  FIFO thresholds is:
9KB for port with maximum speed 10Gb/s port
4KB for port with maximum speed 5Gb/s port
2KB for port with maximum speed 1Gb/s port

Signed-off-by: Stefan Chulski <stefanc@marvell.com>
Acked-by: Marcin Wojtas <mw@semihalf.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvpp2/mvpp2.h
drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c