forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
octeontx2-pf: Mailbox communication with AF
In the resource virtualization unit (RVU) each of the PF and AF (admin function) share a 64KB of reserved memory region for communication. This patch initializes PF <=> AF mailbox IRQs, registers handlers for processing these communication messages. Also adds support to process these messages in both directions ie responses to PF initiated DOWN (PF => AF) messages and AF initiated UP messages (AF => PF). Mbox communication APIs and message formats are defined in AF driver (drivers/net/ethernet/marvell/octeontx2/af), mbox.h from AF driver is included here to avoid duplication. Signed-off-by: Geetha sowjanya <[email protected]> Signed-off-by: Christina Jacob <[email protected]> Signed-off-by: Subbaraya Sundeep <[email protected]> Signed-off-by: Aleksey Makarov <[email protected]> Signed-off-by: Sunil Goutham <[email protected]> Signed-off-by: David S. Miller <[email protected]>
- Loading branch information
Showing
4 changed files
with
552 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// SPDX-License-Identifier: GPL-2.0 | ||
/* Marvell OcteonTx2 RVU Ethernet driver | ||
* | ||
* Copyright (C) 2020 Marvell International Ltd. | ||
* | ||
* This program is free software; you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License version 2 as | ||
* published by the Free Software Foundation. | ||
*/ | ||
|
||
#include <linux/interrupt.h> | ||
#include <linux/pci.h> | ||
|
||
#include "otx2_reg.h" | ||
#include "otx2_common.h" | ||
|
||
#define M(_name, _id, _fn_name, _req_type, _rsp_type) \ | ||
int __weak \ | ||
otx2_mbox_up_handler_ ## _fn_name(struct otx2_nic *pfvf, \ | ||
struct _req_type *req, \ | ||
struct _rsp_type *rsp) \ | ||
{ \ | ||
/* Nothing to do here */ \ | ||
return 0; \ | ||
} \ | ||
EXPORT_SYMBOL(otx2_mbox_up_handler_ ## _fn_name); | ||
MBOX_UP_CGX_MESSAGES | ||
#undef M |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.