summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/netronome/nfp/ccm_mbox.c
Commit message (Collapse)AuthorAgeFilesLines
* nfp: ccm: increase message limitsDirk van der Merwe2019-07-091-3/+3
| | | | | | | | | | | | | | | Increase the batch limit to consume small message bursts more effectively. Practically, the effect on the 'add' messages is not significant since the mailbox is sized such that the 'add' messages are still limited to the same order of magnitude that it was originally set for. Furthermore, increase the queue size limit to 1024 entries. This further improves the handling of bursts of small control messages. Signed-off-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com> Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* nfp: tls: ignore queue limits for delete commandsJakub Kicinski2019-07-091-8/+17
| | | | | | | | | | We need to do our best not to drop delete commands, otherwise we will have stale entries in the connection table. Ignore the control message queue limits for delete commands. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* nfp: add async version of mailbox communicationJakub Kicinski2019-06-111-16/+159
| | | | | | | | | | | | | | | | | | | | Some control messages must be sent from atomic context. The mailbox takes sleeping locks and uses a waitqueue so add a "posted" version of communication. Trylock the semaphore and if that's successful kick of the device communication. The device communication will be completed from a workqueue, which will also release the semaphore. If locks are taken queue the message and return. Schedule a different workqueue to take the semaphore and run the communication. Note that the there are currently no atomic users which would actually need the return value, so all replies to posted messages are just freed. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* nfp: rename nfp_ccm_mbox_alloc()Jakub Kicinski2019-06-111-2/+2
| | | | | | | | | We need the name nfp_ccm_mbox_alloc() for allocating the mailbox communication channel itself. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* nfp: add support for sending control messages via mailboxJakub Kicinski2019-06-061-0/+591
FW may prefer to handle some communication via a mailbox or the vNIC may simply not have a control queue (VFs). Add a way of exchanging ccm-compatible messages via a mailbox. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>