STRUCT CCW_DEVICE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 STRUCT CCW_DEVICE 🌸

ok so bestie, this is the manual page for struct ccw_device β€” it lives in the Kernel API Manual, and it's literally the whole vibe for a channel attached device. channel attached device. that's the NAME section, periodt. πŸ’…


✨ SYNOPSIS ✨

bestie. look at this struct. it's giving main character energy, no cap:

struct ccw_device {
    spinlock_t *ccwlock;
    struct ccw_device_id id;
    struct ccw_driver *drv;
    struct device dev;
    int online;
    void (*handler) (struct ccw_device *, unsigned long, struct irb *);
 };

πŸŽ€ MEMBERS πŸŽ€

okay so let's meet the cast, one by one 🫢

  • ccwlock β€” pointer to device lock. it's the lock. for the device. that's it, that's the whole job πŸ’–
  • id β€” id of this device. yes, that's literally what it is ✨
  • drv β€” ccw driver for this device. the driver that drives it πŸš—πŸ’¨
  • dev β€” embedded device structure. it's a struct inside a struct, we love a nested moment πŸ’…
  • online β€” online status of device. is the device online? check here, bestie πŸ”₯
  • handler β€” interrupt handler. iconic. see below for the ✨lore✨ 🌈

πŸ’œ DESCRIPTION πŸ’œ

okay so here's the tea β˜• and it's actually kind of important:

handler is a member of the device rather than the driver since a driver can have different interrupt handlers for different ccw devices (multi-subchannel drivers).

like, let that sink in. multi-subchannel drivers are out here needing different interrupt handlers for different devices, so the handler lives on the device itself, not the driver. the way that makes sense immediately when you hear it. ate. πŸ‘‘


🌟 SEE ALSO 🌟

go look at these, bestie, i'm obsessed πŸ¦‹

  • Kernel file ./arch/s390/include/asm/ccwdev.h
  • struct ccw_driver(9)

ngl bestie, if you're writing a ccw driver, the handler-on-the-device thing is the detail you'd lowkey miss. so glad you read to the end πŸ’€πŸ’–

that's the whole page, and fr fr thank you for reading this far, you're the bestie πŸ’œ this one's from ./arch/s390/include/asm, dated October 2026 β€” so go off, you're officially a ccw_device girlie now πŸŽ€βœ¨πŸ«ΆπŸŒˆβ­

πŸ“¦ where this page comes from