epf_ntb_peer_spad_bar_clear(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… epf_ntb_peer_spad_bar_clear β€” a Kernel API Manual moment

okay so bestie, welcome to the Kernel API Manual entry for epf_ntb_peer_spad_bar_clear(9) β€” yes the whole thing is named after the function, iconic, we love a self-titled era ✨


🌸 NAME 🌸

epf_ntb_peer_spad_bar_clear β€” literally just Clear Peer Scratchpad BAR πŸ§ΉπŸŽ€


⭐ SYNOPSIS ⭐

void epf_ntb_peer_spad_bar_clear (struct epf_ntb_epc *ntb_epc );

that's it. that's the whole vibe check. no return value, it's giving void and unbothered πŸ’œ


πŸ¦‹ ARGUMENTS πŸ¦‹

  • ntb_epc β€” the EPC that's associated with one of the HOSTs, the one holding peer's outbound address 🫢

✨ DESCRIPTION ✨

okay so picture this, here's the layout, and yes i'm keeping it exactly as-is because it ate:

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ BAR0                  CONFIG REGION                       BAR0 β”‚
β”‚ BAR1                                  SCRATCHPAD REGION        β”‚
β”‚ BAR2   Local Memory   BAR2                                     β”‚
β”‚ BAR3                  BAR3                                     β”‚
β”‚ BAR4                  BAR4                                     β”‚
β”‚ BAR5                  BAR5                                     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
EP CONTROLLER 1                                        EP CONTROLLER 2

so what this function does is it clears BAR1 of EP CONTROLLER 2, which is the BAR holding HOST2's peer scratchpad region πŸ”₯

now, quick lore drop: BAR1 is the default peer scratchpad BAR, but an NTB could absolutely have other BARs for peer scratchpad β€” like, because of 64-bit BARs or reserved BARs, no cap. so this function can get the exact BAR that's actually being used for peer scratchpad from epf_ntb_bar[BAR_PEER_SPAD] πŸ‘‘

and here's the cute lil twist: since HOST2's peer scratchpad is also HOST1's self scratchpad, this function gets the address of peer scratchpad from peer_ntb_epc->epf_ntb_bar[BAR_CONFIG] πŸŽ€

ngl the two-controllers-one-scratchpad situation is very "we share a singular brain cell" energy and i respect it πŸ’€

🌈 SEE ALSO 🌈

the kernel file, living its best life at ./drivers/pci/endpoint/functions/pci-epf-ntb.c πŸ“

and the whole friend group, fr fr:


anyway that's the page!! this lil number lives in ./drivers/pci/endpoint/functions, dated October 2026, and it's filed under epf_ntb_peer_spad_bar_clear(9) πŸ¦‹βœ¨ go clear that BAR bestie, you're gonna slay πŸ’…πŸ‘‘

πŸ“¦ where this page comes from