STRUCT RPROC_OPS(9)

๐Ÿ“ฆ version 7.3.1, in nixpkgs unstable

๐ŸŒธ NAME ๐ŸŒธ

okay bestie, welcome to struct rproc_ops(9) from the Kernel API Manual โ€” this is the struct that holds platform-specific device handlers ๐Ÿ’…


โœจ SYNOPSIS โœจ

here's the struct in all its exact glory, line breaks and all. copy it exactly, no editing the drip:

       struct rproc_ops {
           int (*prepare)(struct rproc *rproc);
           int (*unprepare)(struct rproc *rproc);
           int (*start)(struct rproc *rproc);
           int (*stop)(struct rproc *rproc);
           int (*attach)(struct rproc *rproc);
           int (*detach)(struct rproc *rproc);
           void (*kick)(struct rproc *rproc, int vqid);
           void * (*da_to_va)(struct rproc *rproc, u64 da, size_t len, bool
       *is_iomem);
           int (*parse_fw)(struct rproc *rproc, const struct firmware *fw);
           int (*handle_rsc)(struct rproc *rproc, u32 rsc_type, void *rsc, int
       offset, int avail);
           struct resource_table *(*find_loaded_rsc_table)(struct rproc *rproc,
       const struct firmware *fw);
           struct resource_table *(*get_loaded_rsc_table)(struct rproc *rproc,
       size_t *size);
           int (*load)(struct rproc *rproc, const struct firmware *fw);
           int (*sanity_check)(struct rproc *rproc, const struct firmware *fw);
           u64 (*get_boot_addr)(struct rproc *rproc, const struct firmware
       *fw);
           unsigned long (*panic)(struct rproc *rproc);
           void (*coredump)(struct rproc *rproc);
        };

๐Ÿ’– Members ๐Ÿ’–

okay so these are the members, aka the function-pointer besties inside the struct. every single one has a job and we're gonna hype them all:

  • prepare โ€” prepare the device for code loading ๐Ÿ’ซ
  • unprepare โ€” unprepare the device after stop
  • start โ€” power on the device and boot it ๐Ÿ”ฅ
  • stop โ€” power off the device
  • attach โ€” attach to a device that his already powered up (the manpage said what it said, bestie ๐Ÿซถ)
  • detach โ€” detach from a device, leaving it powered up
  • kick โ€” kick a virtqueue (virtqueue id given as a parameter)
  • da_to_va โ€” optional platform hook to perform address translations
  • parse_fw โ€” parse firmware to extract information (e.g. resource table)
  • handle_rsc โ€” optional platform hook to handle vendor resources. Should return RSC_HANDLED if the resource was handled, RSC_IGNORED if not handled, and a negative value on error โš ๏ธ
  • find_loaded_rsc_table โ€” find the loaded resource table from firmware image
  • get_loaded_rsc_table โ€” get resource table installed in memory by external entity
  • load โ€” load firmware to memory, where the remote processor expects to find it
  • sanity_check โ€” sanity check the fw image
  • get_boot_addr โ€” get boot address to entry point specified in firmware
  • panic โ€” optional callback to react to system panic; the core will delay panic at least the returned number of milliseconds ๐Ÿ˜ญ
  • coredump โ€” collect firmware dump after the subsystem is shutdown

๐Ÿ”ฎ SEE ALSO ๐Ÿ”ฎ

Kernel file ./include/linux/remoteproc.h โ€” and the whole friend group:

  • struct rproc_mem_entry(9)
  • enum rsc_handling_status(9)
  • enum rproc_state(9)
  • enum rproc_crash_type(9)
  • enum rproc_dump_mechanism(9)
  • struct rproc_dump_segment(9)
  • enum rproc_features(9)
  • struct rproc(9)
  • struct rproc_subdev(9)
  • struct rproc_vring(9)
  • struct rproc_vdev(9)

xoxo, your kernel group-chat admin ๐Ÿ’– โ€” source/version: ./include/linux ยท date: October 2026 ยท page: struct rproc_ops(9) โœจ

๐Ÿ“ฆ where this page comes from