[PATCH v6 0/4] pci: endpoint: vntb: add MSI doorbell support

Frank Li posted 4 patches 2 months ago
drivers/pci/endpoint/functions/pci-epf-vntb.c | 152 +++++++++++++++++++++---
drivers/pci/endpoint/pci-epf-core.c           | 163 +++++++++++++++++++++-----
include/linux/pci-epf.h                       |  12 +-
3 files changed, 275 insertions(+), 52 deletions(-)
[PATCH v6 0/4] pci: endpoint: vntb: add MSI doorbell support
Posted by Frank Li 2 months ago
Since commit 1c3b002c6bf68 PCI: endpoint: Add RC-to-EP doorbell support
using platform MSI controller, PCI EP can get notification from Host.

VNTB use this feature to reduce ping latency.

The first patch impove epf core API to allow set any MMIO address to specfic
bar.

The second patch add MSI doorbell support.

Signed-off-by: Frank Li <Frank.Li@nxp.com>
---
Changes in v6:
- update commit message by bar_size
- collect Niklas Cassel's review by tags
- rebased to v6.18-rc1
- Link to v5: https://lore.kernel.org/r/20251009-vntb_msi_doorbell-v5-0-4cfb7b6c4be1@nxp.com

Changes in v5:
- update atu field aligned_size to mem_size.
- Link to v4: https://lore.kernel.org/r/20250930-vntb_msi_doorbell-v4-0-ea2c94c6ff2e@nxp.com

Changes in v4:
- use 'bar_size' instead of aligned_bar_size
- Link to v3: https://lore.kernel.org/r/20250925-vntb_msi_doorbell-v3-0-ae0b0c93caae@nxp.com

Changes in v3:
- update function name to pci_epf_assign_bar_space()
- detail check each patch's change log
- Link to v2: https://lore.kernel.org/r/20250915-vntb_msi_doorbell-v2-0-ca71605e3444@nxp.com

Changes in v2:
- add help funciton to get bar's inbounce size
- fix miss x8 when caculate bits
- Link to v1: https://lore.kernel.org/r/20250815-vntb_msi_doorbell-v1-0-32df6c4bf96c@nxp.com

---
Frank Li (4):
      PCI: endpoint: Rename aligned_size to mem_size
      PCI: endpoint: Add helper function pci_epf_get_bar_required_size()
      PCI: endpoint: Add API pci_epf_assign_bar_space()
      PCI: endpoint: pci-epf-vntb: Add MSI doorbell support

 drivers/pci/endpoint/functions/pci-epf-vntb.c | 152 +++++++++++++++++++++---
 drivers/pci/endpoint/pci-epf-core.c           | 163 +++++++++++++++++++++-----
 include/linux/pci-epf.h                       |  12 +-
 3 files changed, 275 insertions(+), 52 deletions(-)
---
base-commit: 48a881fd8adc6ef7d29b4cf2395b04cdc271e636
change-id: 20250812-vntb_msi_doorbell-bf0fbac6d6d7

Best regards,
--
Frank Li <Frank.Li@nxp.com>
Re: [PATCH v6 0/4] pci: endpoint: vntb: add MSI doorbell support
Posted by Manivannan Sadhasivam 1 month, 2 weeks ago
On Wed, 15 Oct 2025 11:27:27 -0400, Frank Li wrote:
> Since commit 1c3b002c6bf68 PCI: endpoint: Add RC-to-EP doorbell support
> using platform MSI controller, PCI EP can get notification from Host.
> 
> VNTB use this feature to reduce ping latency.
> 
> The first patch impove epf core API to allow set any MMIO address to specfic
> bar.
> 
> [...]

I've done some minor code cleanups and applied the series to pci/endpoint.
Please check the commits to make sure I didn't mess up like last time. Thanks!

[1/4] PCI: endpoint: Rename aligned_size to mem_size
      commit: 483768846d66c04354898f00bcdaad58a3763be2
[2/4] PCI: endpoint: Add helper function pci_epf_get_bar_required_size()
      commit: f71e2b67b51dcb2fd8c6d566230f17a735770bee
[3/4] PCI: endpoint: Add API pci_epf_assign_bar_space()
      commit: 0bfc6758f213a701bd662982de86f0032b51f18c
[4/4] PCI: endpoint: pci-epf-vntb: Add MSI doorbell support
      commit: dc693d60664470ec47188c328055d80e8ce7ea44

Best regards,
-- 
Manivannan Sadhasivam <mani@kernel.org>