drivers/net/ethernet/huawei/hinic3/hinic3_mgmt.h
Source file repositories/reference/linux-study-clean/drivers/net/ethernet/huawei/hinic3/hinic3_mgmt.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/net/ethernet/huawei/hinic3/hinic3_mgmt.h- Extension
.h- Size
- 2145 bytes
- Lines
- 69
- Domain
- Driver Families
- Bucket
- drivers/net
- 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.hhinic3_mbox.hhinic3_hw_intf.h
Detected Declarations
struct hinic3_hwdevstruct hinic3_recv_msgstruct hinic3_msg_pf_to_mgmtstruct mgmt_msg_handle_workenum comm_pf_to_mgmt_event_state
Annotated Snippet
struct hinic3_recv_msg {
/* Preallocated buffer of size MAX_PF_MGMT_BUF_SIZE that accumulates
* receive message, segment-by-segment.
*/
void *msg;
/* Message id for which segments are accumulated. */
u8 msg_id;
/* Sequence id of last received segment of current message. */
u8 seq_id;
u16 msg_len;
int async_mgmt_to_pf;
enum mgmt_mod_type mod;
u16 cmd;
struct completion recv_done;
};
enum comm_pf_to_mgmt_event_state {
COMM_SEND_EVENT_UNINIT,
COMM_SEND_EVENT_START,
COMM_SEND_EVENT_SUCCESS,
COMM_SEND_EVENT_TIMEOUT,
};
struct hinic3_msg_pf_to_mgmt {
struct hinic3_hwdev *hwdev;
struct workqueue_struct *workq;
void *mgmt_ack_buf;
struct hinic3_recv_msg recv_msg_from_mgmt;
struct hinic3_recv_msg recv_resp_msg_from_mgmt;
u16 async_msg_id;
u16 sync_msg_id;
void *async_msg_cb_data[MGMT_MOD_HW_MAX];
/* synchronizes message send with message receives via event queue */
spinlock_t sync_event_lock;
enum comm_pf_to_mgmt_event_state event_flag;
};
struct mgmt_msg_handle_work {
struct work_struct work;
struct hinic3_msg_pf_to_mgmt *pf_to_mgmt;
void *msg;
u16 msg_len;
enum mgmt_mod_type mod;
u16 cmd;
u16 msg_id;
int async_mgmt_to_pf;
};
int hinic3_pf_to_mgmt_init(struct hinic3_hwdev *hwdev);
void hinic3_pf_to_mgmt_free(struct hinic3_hwdev *hwdev);
void hinic3_flush_mgmt_workq(struct hinic3_hwdev *hwdev);
void hinic3_mgmt_msg_aeqe_handler(struct hinic3_hwdev *hwdev,
u8 *header, u8 size);
#endif
Annotation
- Immediate include surface: `linux/types.h`, `hinic3_mbox.h`, `hinic3_hw_intf.h`.
- Detected declarations: `struct hinic3_hwdev`, `struct hinic3_recv_msg`, `struct hinic3_msg_pf_to_mgmt`, `struct mgmt_msg_handle_work`, `enum comm_pf_to_mgmt_event_state`.
- Atlas domain: Driver Families / drivers/net.
- 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.