RDMA_POST_WRITEV(3)
π RDMA_POST_WRITEV(3) π
okay bestie, pull up a chair, because we're about to talk about rdma_post_writev β yes it's from the Librdmacm Programmer's Manual, yes it's giving serious low-level energy, and yes you're gonna slay it. this page is literally just "post an RDMA write work request." that's it. that's the whole vibe. but let's get into it because the details matter, periodt. π¦
β¨ NAME β¨
rdma_post_writev β post an RDMA write work request.
πΈ SYNOPSIS πΈ
#include <rdma/rdma_verbs.h>
int rdma_post_writev (struct rdma_cm_id *id, void *context, struct
ibv_sge *sgl, int nsge, int flags, uint64_t remote_addr, uint32_t rkey);
π ARGUMENTS π
idβ a reference to a communication identifier where the request will be posted. it's the main character, obviously. πcontextβ user-defined context associated with the request. your lil personal sticker on the request, iykyk.sglβ a scatter-gather list of the source buffers of the write. the stuff you're sending out into the world. πnsgeβ the number of scatter-gather array entries. count 'em, bestie.flagsβ optional flags used to control the write operation. the seasoning. β¨remote_addrβ the address of the remote registered memory to write into. that's where the data is going.rkeyβ the registered memory key associated with the remote address. the little keycard that lets you in. π
π DESCRIPTION π
so here's the tea: this function posts a work request to the send queue of the queue pair associated with the rdma_cm_id. and then β and this is the cute part β the contents of the local data buffers get written into the remote memory region. like you're sliding a note under someone's door but the door is a remote memory region and the note is your scatter-gather list. π«Ά
β RETURN VALUE β
returns 0 on success, or -1 on error. and if an error happens? errno will be set to indicate the failure reason. so like, if it goes wrong, it tells you why. we love communication in this house. π
π§ NOTES π§
for a list of supported flags, see ibv_post_send. don't just make them up, bestie, go look. π
unless inline data is specified, the local data buffers must have been registered before the write is issued, and the buffers must remain registered until the write completes. the remote buffers must always be registered. no registration, no write. that's the rule. that's not a suggestion. π
write operations may not be posted to an rdma_cm_id or the corresponding queue pair until it has been connected. connect first. then post. in that order. do not skip steps. π₯
the user-defined context associated with the write request will be returned to you through the work completion wr_id field β that's the work request identifier, in case you were wondering what wr_id stands for. so whatever you put in the context, you get it back later. it's giving boomerang. π
π SEE ALSO π
rdma_cm(7), rdma_connect(3), rdma_accept(3), ibv_post_send(3), rdma_post_write(3), rdma_reg_write(3), rdma_reg_msgs(3)
and that's the whole page, bestie. this one's from librdmacm, dated 2010-07-19 β vintage, iconic, still serving. go register your buffers and stay hydrated. mwah. π πβ¨
π¦ where this page comes from
- alpine 3.24: rdma-core-doc 61.0-r0 Β· GPL-2.0-only OR BSD-2-Clause
- 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
- centos-stream 10: rdma-core-devel 62.0-3.el10 Β· GPLv2 or BSD
- centos-stream 9: rdma-core-devel 61.0-3.el9 Β· GPLv2 or BSD
- centos-stream 9: rdma-core-devel 61.0-3.el9 Β· GPLv2 or BSD
- debian bookworm: librdmacm-dev 44.0-2 Β· BSD-MIT OR GPL-2.0-only
- debian trixie: librdmacm-dev 56.1-1 Β· BSD-MIT OR GPL-2.0-only
- fedora 43: rdma-core-devel 58.0-4.fc43 Β· GPL-2.0-only OR BSD-2-Clause AND BSD-3-Clause
- fedora 43: rdma-core-devel 58.0-4.fc43 Β· GPL-2.0-only OR BSD-2-Clause AND BSD-3-Clause
- fedora 44: rdma-core-devel 61.0-2.fc44 Β· GPL-2.0-only OR BSD-2-Clause AND BSD-3-Clause
- fedora 44: rdma-core-devel 61.0-2.fc44 Β· GPL-2.0-only OR BSD-2-Clause AND BSD-3-Clause
- fedora 44: rdma-core-devel 61.1^20260812git975bdaf-1.fc44 Β· GPL-2.0-only OR BSD-2-Clause AND BSD-3-Clause
- fedora 44: rdma-core-devel 61.1^20260812git975bdaf-1.fc44 Β· GPL-2.0-only OR BSD-2-Clause AND BSD-3-Clause
- freebsd 14.5: base 14.5
- freebsd 15.1: base 15.1
- nixos 26.05: rdma-core 62.0
- nixpkgs unstable: rdma-core 65.0
- opensuse-leap 16.0: rdma-core-devel 56.1-160000.2.2 Β· BSD-2-Clause OR GPL-2.0-only
- opensuse-leap 16.0: rdma-core-devel 56.1-160000.2.2 Β· BSD-2-Clause OR GPL-2.0-only
- opensuse-leap 16.0: rdma-core-devel 56.1-160000.2.2 Β· BSD-2-Clause OR GPL-2.0-only
- opensuse-leap 16.0: rdma-core-devel 56.1-160000.2.2 Β· BSD-2-Clause OR GPL-2.0-only
- ubuntu jammy: librdmacm-dev 39.0-1 Β· BSD-MIT OR GPL-2.0-only
- ubuntu noble: librdmacm-dev 50.0-2build2 Β· BSD-MIT OR GPL-2.0-only
- ubuntu noble: librdmacm-dev 50.0-2ubuntu0.2 Β· BSD-MIT OR GPL-2.0-only
- ubuntu questing: librdmacm-dev 56.1-1ubuntu1
- ubuntu resolute: librdmacm-dev 61.0-2ubuntu3 Β· BSD-MIT OR GPL-2.0-only
- ubuntu stonking: librdmacm-dev 64.0-1ubuntu1 Β· BSD-MIT OR GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms