lpfc_check_pci_resettable(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ lpfc_check_pci_resettable ✨

okay so this is a page straight out of the Kernel API Manual (that's the manual name btw, in case you were wondering πŸ’…) and it's all about one lil function called lpfc_check_pci_resettable. buckle up bestie, it's a vibe check for your PCI bus πŸ¦‹


πŸŽ€ NAME πŸŽ€

lpfc_check_pci_resettable β€” walks the list of devices on the pci_dev's bus to check if issuing a pci_bus_reset is possibly unsafe

like, it's literally going door to door on the bus asking "hey are you gonna be chill if we reset" 😭


🌸 SYNOPSIS 🌸

int lpfc_check_pci_resettable (struct lpfc_hba *phba );

one function, one argument, no cap πŸ”₯


πŸ’– ARGUMENTS πŸ’–

  • phba β€” an lpfc_hba pointer. that's it. that's the whole argument. she's low maintenance ✨

🫢 DESCRIPTION 🫢

so what does it actually do? it walks the bus_list to make sure of three things, and honestly the way it's so picky is iconic πŸ‘‘

  • only PCI devices with Emulex vendor id are allowed on the bus, no randos πŸ™ˆ
  • the device ids have to be ones that support hot reset
  • and there can be only one occurrence of function 0 β€” one, singular, don't test her πŸ’…

if all of that checks out, then a pci_bus_reset is possibly not unsafe. "possibly" is doing a lot of work in that sentence ngl, but that's what the page says so that's what we're saying 🧚


⭐ RETURN ⭐

  • -EBADSLT β€” detected invalid device 0
  • successful

so like, you either get the success vibe or you get -EBADSLT because device 0 was out of pocket πŸ’€


πŸ¦‹ SEE ALSO πŸ¦‹

first up, the kernel file this lives near:

  • ./drivers/scsi/lpfc/lpfc_scsi.c

and now the entire friend group β€” literally everyone in lpfc_scsi, no one got left out 🫢

fr fr go read those if you want the full lore, this one function is just the entry point to a whole saga πŸ“š

πŸ’œ the sign-off πŸ’œ

this page lives in ./drivers/scsi/lpfc, and the version stamp on it is October 2026 β€” so like, mark your calendar bestie πŸ—“οΈβœ¨

anyway that's the whole page, lpfc_check_pci_resettable(9) explained, no details harmed in the making of this rewrite. slay, go reset some buses (responsibly) πŸ’…πŸŒˆ

πŸ“¦ where this page comes from