STRUCT CMB_OPERATIONS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

struct cmb_operations(9) πŸ’–

okay bestie, welcome to the Kernel API Manual β€” this is the page for struct cmb_operations, aka the little crew of functions you use depending on cmb_format. slay ✨


🌸 NAME 🌸

struct cmb_operations β€” functions to use depending on cmb_format


✨ SYNOPSIS ✨

struct cmb_operations {
    int (*alloc)  (struct ccw_device *);
    void (*free)   (struct ccw_device *);
    int (*set)    (struct ccw_device *, u32);
    u64 (*read)   (struct ccw_device *, int);
    int (*readall)(struct ccw_device *, struct cmbdata *);
    void (*reset)  (struct ccw_device *);
 };

πŸ’… Members πŸ’…

  • alloc β€” signature: int (*alloc) (struct ccw_device *); β€” allocate memory for a channel measurement block, either with the help of a special pool or with kmalloc. memory-getting moment ✨
  • free β€” signature: void (*free) (struct ccw_device *); β€” free memory allocated with alloc. no leaks, bestie 🫢
  • set β€” signature: int (*set) (struct ccw_device *, u32); β€” enable or disable measurement. on/off era πŸ”₯
  • read β€” signature: u64 (*read) (struct ccw_device *, int); β€” read a measurement entry at an index.
  • readall β€” signature: int (*readall)(struct ccw_device *, struct cmbdata *); β€” read a measurement block in a common format. the whole block, not just a lil peek πŸ‘€
  • reset β€” signature: void (*reset) (struct ccw_device *); β€” clear the data in the associated measurement block and reset its time stamp.

πŸ¦‹ Description πŸ¦‹

Most of these functions operate on a struct ccw_device. There is only one instance of struct cmb_operations because the format of the measurement data is guaranteed to be the same for every ccw_device. iconic consistency behavior, honestly πŸ’…βœ¨


🌟 SEE ALSO 🌟

Kernel file ./drivers/s390/cio/cmf.c; enum cmb_format(9), struct cmb_area(9), struct cmb(9), struct cmbe(9), enable_cmf(9), __disable_cmf(9), disable_cmf(9), cmf_read(9), cmf_readall(9), cmf_reactivate(9).


mwah πŸ’‹ this cutie is sourced from ./drivers/s390/cio, dated October 2026, and it’s serving struct cmb_operations(9) realness β€” periodt πŸŒˆπŸ‘‘

πŸ“¦ where this page comes from