drivers/misc/mei/mei_dev.h
Source file repositories/reference/linux-study-clean/drivers/misc/mei/mei_dev.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/misc/mei/mei_dev.h- Extension
.h- Size
- 25094 bytes
- Lines
- 931
- Domain
- Driver Families
- Bucket
- drivers/misc
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/types.hlinux/cdev.hlinux/poll.hlinux/mei.hlinux/mei_cl_bus.hhw.hhbm.h
Detected Declarations
struct mei_msg_datastruct mei_dma_datastruct mei_dma_dscrstruct mei_fw_statusstruct mei_me_clientstruct mei_clstruct mei_cl_cbstruct mei_cl_vtagstruct mei_clstruct mei_hw_opsstruct mei_fw_versionstruct mei_dev_timeoutsstruct mei_deviceenum file_stateenum mei_dev_stateenum mei_dev_pxp_modeenum mei_dev_reset_to_pxpenum mei_file_transaction_statesenum mei_cb_file_opsenum mei_cl_io_modeenum mei_pg_eventenum mei_pg_statefunction Copyrightfunction mei_secs_to_jiffiesfunction mei_data2slotsfunction mei_hbm2slotsfunction mei_slots2datafunction mei_hw_configfunction mei_pg_statefunction mei_pg_in_transitionfunction mei_pg_is_enabledfunction mei_hw_resetfunction mei_hw_startfunction mei_clear_interruptsfunction mei_enable_interruptsfunction mei_disable_interruptsfunction mei_synchronize_irqfunction mei_host_is_readyfunction mei_hw_is_readyfunction mei_hbuf_is_readyfunction mei_hbuf_empty_slotsfunction mei_hbuf_depthfunction mei_write_messagefunction mei_read_hdrfunction mei_read_slotsfunction mei_count_full_read_slotsfunction mei_trc_statusfunction mei_fw_status
Annotated Snippet
struct mei_msg_data {
size_t size;
unsigned char *data;
};
struct mei_dma_data {
u8 buffer_id;
void *vaddr;
dma_addr_t daddr;
size_t size;
};
/**
* struct mei_dma_dscr - dma address descriptor
*
* @vaddr: dma buffer virtual address
* @daddr: dma buffer physical address
* @size : dma buffer size
*/
struct mei_dma_dscr {
void *vaddr;
dma_addr_t daddr;
size_t size;
};
/* Maximum number of processed FW status registers */
#define MEI_FW_STATUS_MAX 6
/* Minimal buffer for FW status string (8 bytes in dw + space or '\0') */
#define MEI_FW_STATUS_STR_SZ (MEI_FW_STATUS_MAX * (8 + 1))
/*
* struct mei_fw_status - storage of FW status data
*
* @count: number of actually available elements in array
* @status: FW status registers
*/
struct mei_fw_status {
int count;
u32 status[MEI_FW_STATUS_MAX];
};
/**
* struct mei_me_client - representation of me (fw) client
*
* @list: link in me client list
* @refcnt: struct reference count
* @props: client properties
* @client_id: me client id
* @tx_flow_ctrl_creds: flow control credits
* @connect_count: number connections to this client
* @bus_added: added to bus
*/
struct mei_me_client {
struct list_head list;
struct kref refcnt;
struct mei_client_properties props;
u8 client_id;
u8 tx_flow_ctrl_creds;
u8 connect_count;
u8 bus_added;
};
struct mei_cl;
/**
* struct mei_cl_cb - file operation callback structure
*
* @list: link in callback queue
* @cl: file client who is running this operation
* @fop_type: file operation type
* @buf: buffer for data associated with the callback
* @buf_idx: last read index
* @vtag: virtual tag
* @fp: pointer to file structure
* @status: io status of the cb
* @internal: communication between driver and FW flag
* @blocking: transmission blocking mode
* @ext_hdr: extended header
*/
struct mei_cl_cb {
struct list_head list;
struct mei_cl *cl;
enum mei_cb_file_ops fop_type;
struct mei_msg_data buf;
size_t buf_idx;
u8 vtag;
const struct file *fp;
int status;
Annotation
- Immediate include surface: `linux/types.h`, `linux/cdev.h`, `linux/poll.h`, `linux/mei.h`, `linux/mei_cl_bus.h`, `hw.h`, `hbm.h`.
- Detected declarations: `struct mei_msg_data`, `struct mei_dma_data`, `struct mei_dma_dscr`, `struct mei_fw_status`, `struct mei_me_client`, `struct mei_cl`, `struct mei_cl_cb`, `struct mei_cl_vtag`, `struct mei_cl`, `struct mei_hw_ops`.
- Atlas domain: Driver Families / drivers/misc.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.