STRUCT MHI_RESULT(9)
π struct mhi_result(9) β Completed buffer information
okay so bestie, this is a page out of the Kernel API Manual (yes, that one), and it's literally just one little struct that tells you what happened to a buffer after it finished doing its thing. She's short, she's iconic, she's giving "receipts after the transaction." Let's get into it π«Ά
β¨ NAME β¨
struct mhi_result β completed buffer information π¦
Like, the whole personality is: "here's what the buffer looked like when it was done." No cap.
πΈ SYNOPSIS πΈ
struct mhi_result {
void *buf_addr;
size_t bytes_xferd;
enum dma_data_direction dir;
int transaction_status;
};
Look at her. Four fields. Immaculate. π
π Members π
buf_addrβ the address of the data buffer. literally where the data lives, bestie πbytes_xferdβ the # of bytes transferred. yeah it's spelled like that, don't come for her πdirβ the channel direction. which way the vibe is flowing π¦transaction_statusβ the status of the last transaction. did it slay or did it flop, this field knows π₯
π SEE ALSO π
So there's a whole friend group, and honestly? The group chat is popping off. Start with the kernel file ./include/linux/mhi.h, then meet the rest of the squad:
enum mhi_callback(9)enum mhi_flags(9)enum mhi_device_type(9)enum mhi_ch_type(9)struct mhi_buf(9)struct image_info(9)struct mhi_link_info(9)enum mhi_ee_type(9)enum mhi_state(9)enum mhi_ch_ee_mask(9)enum mhi_er_data_type(9)enum mhi_db_brst_mode(9)struct mhi_channel_config(9)struct mhi_event_config(9)struct mhi_controller_config(9)struct mhi_controller(9)struct mhi_device(9)struct mhi_driver(9)mhi_alloc_controller(9)mhi_free_controller(9)mhi_register_controller(9)mhi_unregister_controller(9)__mhi_driver_register(9)mhi_driver_unregister(9)mhi_set_mhi_state(9)mhi_notify(9)mhi_get_free_desc_count(9)mhi_prepare_for_power_up(9)mhi_async_power_up(9)mhi_sync_power_up(9)mhi_power_down(9)mhi_power_down_keep_dev(9)mhi_unprepare_after_power_down(9)mhi_pm_suspend(9)mhi_pm_resume(9)mhi_pm_resume_force(9)mhi_download_rddm_image(9)mhi_force_rddm_mode(9)mhi_get_exec_env(9)mhi_get_mhi_state(9)mhi_soc_reset(9)mhi_device_get_sync(9)mhi_device_put(9)mhi_prepare_for_transfer(9)mhi_unprepare_from_transfer(9)mhi_queue_buf(9)mhi_queue_skb(9)mhi_queue_is_full(9)mhi_get_channel_doorbell_offset(9)
Forty-nine whole entries and not a single one skipped, because we do NOT leave members of the squad out of the tag π
ngl if you're reading this at 3am trying to debug a transfer, hydrate, blink, and go read ./include/linux/mhi.h. the source is right there and it's free π
β¨ that's the whole page, bestie β short, sweet, and fully documented β¨
Cute little sign-off: this page lives out of ./include/linux and it's dated October 2026 (time-traveling kernel docs, we love to see it π§), filed under struct mhi_result(9). byeeee πππ¦
π¦ 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