STRUCT FW_RSC_VDEV(9)
π struct fw_rsc_vdev(9) β the virtio device header, bestie π
okay so this is straight out of the Kernel API Manual, bestie β we're talking struct fw_rsc_vdev(9), and it is literally the main character of remoteproc/virtio land. let's get into it π
β¨ NAME β¨
struct fw_rsc_vdev β the virtio device header π¦
β¨ SYNOPSIS β¨
struct fw_rsc_vdev {
u32 id;
u32 notifyid;
u32 dfeatures;
u32 gfeatures;
u32 config_len;
u8 status;
u8 num_of_vrings;
u8 reserved[2];
struct fw_rsc_vdev_vring vring[];
};
like, that's the whole glow-up right there π
β¨ Members β¨
idβ the virtio device id (as invirtio_ids.h). that's its whole identity, iykyk πΈnotifyidβ a unique rproc-wide notify index for this vdev. this notify index is used when kicking a remote processor, to let it know that the status/features of this vdev have changes. yes, "have changes" β iconic grammar, we keep it π«Άdfeaturesβ specifies the virtio device features supported by the firmware β¨gfeaturesβ a place holder used by the host to write back the negotiated features that are supported by both sides. teamwork, slay π€config_lenβ the size of the virtio config space of this vdev. and the config space lies in the resource table immediate after this vdev header β so it's right there, no cap πstatusβ a place holder where the host will indicate its virtio progress. we're rooting for you, status πnum_of_vringsβ indicates how many vrings are described in this vdev header π₯reservedβ reserved (must be zero). must be zero, bestie, do not test me πvringβ an array ofnum_of_vringsentries ofstruct fw_rsc_vdev_vringπ
β¨ Description β¨
so this resource is a virtio device header: it provides information about the vdev, and is then used by the host and its peer remote processors to negotiate and share certain virtio properties. it's giving matchmaker but for processors π
and by providing this resource entry, the firmware essentially asks remoteproc to statically allocate a vdev upon registration of the rproc. and note that dynamic vdev allocation is not yet supported β not yet, ok, we're manifesting it π―οΈβ¨
β¨ Note β¨
- unlike virtualization systems, the term 'host' here means the Linux side which is running remoteproc to control the remote processors. we use the name
gfeaturesto comply with virtio's terms, though there isn't really any virtualized guest OS here: it's the host which is responsible for negotiating the final features. yeah, it's a bit confusing π we said it first, ok. - immediately following this structure is the virtio config space for this vdev (which is specific to the vdev; for more info, read the virtio spec). the size of the config space is specified by
config_len. go read the virtio spec, bestie, it ate ππ₯
β¨ SEE ALSO β¨
./include/linux/rsc_table.hstruct resource_table(9)struct fw_rsc_hdr(9)enum fw_resource_type(9)struct fw_rsc_carveout(9)struct fw_rsc_devmem(9)struct fw_rsc_trace(9)struct fw_rsc_vdev_vring(9)rsc_table_for_each_entry(9)
like a whole friend group fr fr π«Άπ¦
π and that's the tea! this one lives in./include/linux, dated October 2026, and it's officially pagestruct fw_rsc_vdev(9). mwah, go forth and negotiate those features, queen πβ¨π
π¦ 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