ibv_query_port_speed(3)

πŸ“¦
version 65.0 Β· 4 versions
, in arch rolling

✨ ibv_query_port_speed(3) ✨

okay so this is from the Libibverbs Programmer's Manual and honestly? it's giving "tiny function, big plot" πŸ’…


🌸 NAME 🌸

ibv_query_port_speed β€” bestie, this one queries an RDMA port's effective bandwidth in 100Mb/s granularity. yes, that's the whole job. queen of knowing exactly what she's about πŸ‘‘


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <infiniband/verbs.h>

int ibv_query_port_speed(struct ibv_context *context, uint32_t port_num, uint64_t *port_speed);

πŸ’– DESCRIPTION πŸ’–

ibv_query_port_speed() β€” so what it does, right? It queries the device of the context at whatever port number you hand it, and it comes back with the effective bandwidth of that port in 100Mb/s granularity. That's it. That's the whole vibe check. no cap, it's that simple 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • context β€” the device context, literally the main character here. everything happens through her ✨
  • port_num β€” the device port number that needs to be queried. like, which port are we asking about, bestie? πŸ‘€
  • port_speed β€” the effective bandwidth of the port for the device context, in a granularity of 100 Mb/s. this is where the answer lands πŸ’Œ

πŸ”₯ RETURN VALUE πŸ”₯

ibv_query_port_speed() returns 0 on success, or the value of errno on failure β€” and that errno value tells you the failure reason. so if it's not 0, something went sideways and the number is literally the receipts πŸ’€


🧚 NOTES 🧚

ok so important caveat, do not skip this one:

the port_speed pointer value is valid only when the function returns 0. read it again. only then. fr fr πŸ™ˆ

πŸ‘‘ SEE ALSO πŸ‘‘


πŸ’œ AUTHOR πŸ’œ

  • Patrisious Haddad phaddad@nvidia.com
  • Or Har-Toov ohartoov@nvidia.com

that's the whole page, and it ate, no crumbs left πŸ“ so this lil icon came to you from libibverbs, dated 2025-10-19, and it's the ibv_query_port_speed(3) page. go forth and query responsibly, bestie πŸ’…πŸŒˆ

πŸ“¦ where this page comes from
  • arch rolling: rdma-core 65.0-1 Β· GPL-2.0-or-later OR LicenseRef-OpenIB.org-BSD-MIT AND GPL-2.0-or-later OR LicenseRef-OpenIB.org-BSD-FreeBSD AND GPL-2.0-or-later OR LicenseRef-Intel-BSD-3-Clause AND GPL-2.0-or-later OR LicenseRef-PathScale-BSD-Patent-License AND CC0-1.0 AND MIT AND BSD-2-Clause AND CPL-1.0 OR BSD-2-Clause OR GPL-2.0-or-later
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms