_IIO_EVENT_CODE(9)
π _IIO_EVENT_CODE(9) β like, the Kernel API Manual page, bestie
okay so. this is a page from the Kernel API Manual and it's about one (1) macro that literally just builds an event identifier for you. it's giving "small but mighty" energy and honestly? we're obsessed. π
β¨ NAME β¨
_IIO_EVENT_CODE β creates an event identifier. that's it. that's the whole job. β¨
πΈ SYNOPSIS πΈ
_IIO_EVENT_CODE (chan_type , diff , modifier , direction , type , chan ,
chan1 , chan2 );
look at all those args. a whole little buffet of parameters. no cap. π
π¦ ARGUMENTS π¦
every single one of these matters, so pay attention bestie:
chan_typeβ the type of the channel. it should be one ofenum iio_chan_type. like, please don't freestyle this one. πdiffβ tells you whether the event is for a differential channel or not. yes/no vibes.modifierβ the modifier for the channel. it should be one ofenum iio_modifier. pick from the list, king. πdirectionβ the direction of the event. one ofenum iio_event_direction.typeβ the type of the event. it should be one ofenum iio_event_type.chanβ the channel number for non-differential channels. (so, the regular-girl channels π )chan1β the first channel number for differential channels.chan2β the second channel number for differential channels. yes there are two of them, it's a whole duo, main character energy fr fr.
π DESCRIPTION π
so here's the tea: drivers should not be using this macro directly. like, at all. π«Ά
drivers should use the specialized macros below instead. this one is more of a backstage, behind-the-scenes situation β the specialized ones are the ones out here actually living their lives. iykyk.
π SEE ALSO π
- Kernel file
./include/linux/iio/events.h IIO_MOD_EVENT_CODE(9)IIO_UNMOD_EVENT_CODE(9)IIO_DIFF_EVENT_CODE(9)
go read those too, bestie, they're literally iconic. π₯
okay that's the whole page!! this gem lives over in ./include/linux/iio, dated October 2026, and it slayed every step of the way. mwah. πβ¨
π¦ 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