hisi_qm_sriov_enable(9)
π hisi_qm_sriov_enable π
okay so bestie, welcome to the Kernel API Manual β yes, that's the actual manual name, we're being official today π β and this one little page is all about one function that does Exactly One Thing.
β¨ NAME β¨
hisi_qm_sriov_enable β enable virtual functions π¦
β¨ SYNOPSIS β¨
int hisi_qm_sriov_enable (struct pci_dev *pdev , int max_vfs );
look at her. two arguments, one int coming back at you. she's simple, she's focused, she's the moment. π
β¨ ARGUMENTS β¨
pdevβ the PCIe device π like, the actual hardware bestie we're doing the thing to.max_vfsβ the number of virtual functions to enable π’ that's how many VFs you're asking for, bestie, so choose wisely.
β¨ DESCRIPTION β¨
okay so the tea β β this function returns the number of enabled VFs. that's the whole win. that's the slay.
but listen, there are two situations where it does NOT do that and instead returns failure π:
- if there are VFs enabled already (like, girl, they're already on, we can't re-enable what's enabled π), or
- if
max_vfsis more than the total number of VFs the device can enable (you're asking for more than the device can give, and no amount of manifesting is fixing that π).
lowkey important: those are the only two failure conditions on the page, so don't go inventing more, iykyk.
β¨ SEE ALSO β¨
okay this list is giving group chat with 38 members π₯ β every single one of these is invited:
Kernel file ./drivers/crypto/hisilicon/qm.cβ literally the file, go read it πstruct qm_hw_err(9)hisi_qm_get_hw_info(9)hisi_qm_create_qp(9)hisi_qm_release_qp(9)hisi_qm_start_qp(9)qp_stop_fail_cb(9)qm_drain_qp(9)hisi_qm_stop_qp(9)hisi_qp_send(9)qm_hw_err_isolate(9)qm_frozen(9)hisi_qm_wait_task_finish(9)hisi_qm_uninit(9)hisi_qm_get_vft(9)hisi_qm_set_vft(9)hisi_qm_start(9)qm_invalid_queues(9)hisi_qm_stop(9)hisi_qm_dev_err_init(9)hisi_qm_dev_err_uninit(9)hisi_qm_free_qps(9)hisi_qm_alloc_qps_node(9)hisi_qm_set_algqos_init(9)hisi_qm_sriov_disable(9)hisi_qm_sriov_configure(9)hisi_qm_dev_err_detected(9)hisi_qm_dev_slot_reset(9)hisi_qm_dev_shutdown(9)hisi_qm_alg_register(9)hisi_qm_alg_unregister(9)hisi_qm_init(9)hisi_qm_get_dfx_access(9)hisi_qm_put_dfx_access(9)hisi_qm_pm_init(9)hisi_qm_pm_uninit(9)hisi_qm_suspend(9)hisi_qm_resume(9)
bestie if you read all of these you will be so powerful. no cap. π
and that's the page!! π«Ά this little angel lives over in ./drivers/crypto/hisilicon, and this particular glow-up is dated October 2026. mwah, go enable some virtual functions responsibly π β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms