STRUCT HIDI2C_DEV_DESCRIPTOR(9)
πΈ NAME πΈ
okay so bestie, this is struct hidi2c_dev_descriptor β the HIDI2C device descriptor definition. that's it, that's the whole vibe check. it's from the Kernel API Manual and it's literally the blueprint for how a HID-over-I2C device introduces itself. π
β¨ SYNOPSIS β¨
struct hidi2c_dev_descriptor {
__le16 dev_desc_len;
__le16 bcd_ver;
__le16 report_desc_len;
__le16 report_desc_reg;
__le16 input_reg;
__le16 max_input_len;
__le16 output_reg;
__le16 max_output_len;
__le16 cmd_reg;
__le16 data_reg;
__le16 vendor_id;
__le16 product_id;
__le16 version_id;
__le16 reserved0;
__le16 reserved1;
};
like, that's the whole struct, no notes. it ate. π«Ά
π Members π
okay so every single field, in order, no skipping β this is the main character energy right here:
dev_desc_lenβ the length of the complete device descriptor, and it's fixed to0x1E(30). no cap, it's always 30. πbcd_verβ the version number of the HIDI2C protocol it supports, in binary coded decimal (BCD) format.report_desc_lenβ the length of the report descriptor.report_desc_regβ the register address where you go to retrieve the report descriptor.input_regβ the register address where you go to retrieve the input report.max_input_lenβ the length of the largest possible HID input (or feature) report.output_regβ the register address you use to send the output report.max_output_lenβ the length of the largest output (or feature) report.cmd_regβ the register address to send a command. π¦data_regβ the register address to send command data.vendor_idβ the Device manufacturers vendor ID.product_idβ the Device unique model/product ID. iykyk. πversion_idβ the Device's unique version.reserved0β Reserved and should be0.reserved1β Reserved and should be0.
bestie, lowkey mind thereservedfields β they're reserved and should be0, so fr fr keep them at0. π
π SEE ALSO π
- Kernel file
./include/linux/hid-over-i2c.hstruct hidi2c_report_packet(9)
go read those if you want the full lore, they're iconic. β
and that's the page, bestie!! π this came from ./include/linux, dated October 2026, and yes the footer still calls it struct hidi2...v_descriptor(9) because it's long and we respect the abbreviation era. slay. π₯
π¦ 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