include/xen/interface/io/sndif.h
Source file repositories/reference/linux-study-clean/include/xen/interface/io/sndif.h
File Facts
- System
- Linux kernel
- Corpus path
include/xen/interface/io/sndif.h- Extension
.h- Size
- 48415 bytes
- Lines
- 1065
- Domain
- Repository Root And Misc
- Bucket
- include
- Inferred role
- Repository Root And Misc: implementation source
- Status
- source implementation candidate
Why This File Exists
Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
ring.h../grant_table.h
Detected Declarations
struct xensnd_open_reqstruct xensnd_page_directorystruct xensnd_rw_reqstruct xensnd_trigger_reqstruct xensnd_query_hw_paramstruct xensnd_cur_pos_evtstruct xensnd_reqstruct xensnd_respstruct xensnd_evtstruct xensnd_event_page
Annotated Snippet
struct xensnd_open_req {
uint32_t pcm_rate;
uint8_t pcm_format;
uint8_t pcm_channels;
uint16_t reserved;
uint32_t buffer_sz;
grant_ref_t gref_directory;
uint32_t period_sz;
};
/*
* Shared page for XENSND_OP_OPEN buffer descriptor (gref_directory in the
* request) employs a list of pages, describing all pages of the shared data
* buffer:
* 0 1 2 3 octet
* +----------------+----------------+----------------+----------------+
* | gref_dir_next_page | 4
* +----------------+----------------+----------------+----------------+
* | gref[0] | 8
* +----------------+----------------+----------------+----------------+
* |/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/|
* +----------------+----------------+----------------+----------------+
* | gref[i] | i*4+8
* +----------------+----------------+----------------+----------------+
* |/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/|
* +----------------+----------------+----------------+----------------+
* | gref[N - 1] | N*4+8
* +----------------+----------------+----------------+----------------+
*
* gref_dir_next_page - grant_ref_t, reference to the next page describing
* page directory. Must be 0 if there are no more pages in the list.
* gref[i] - grant_ref_t, reference to a shared page of the buffer
* allocated at XENSND_OP_OPEN
*
* Number of grant_ref_t entries in the whole page directory is not
* passed, but instead can be calculated as:
* num_grefs_total = (XENSND_OP_OPEN.buffer_sz + XEN_PAGE_SIZE - 1) /
* XEN_PAGE_SIZE
*/
struct xensnd_page_directory {
grant_ref_t gref_dir_next_page;
grant_ref_t gref[];
};
/*
* Request close - close an opened pcm stream:
* 0 1 2 3 octet
* +----------------+----------------+----------------+----------------+
* | id | XENSND_OP_CLOSE| reserved | 4
* +----------------+----------------+----------------+----------------+
* | reserved | 8
* +----------------+----------------+----------------+----------------+
* |/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/|
* +----------------+----------------+----------------+----------------+
* | reserved | 64
* +----------------+----------------+----------------+----------------+
*
* Request read/write - used for read (for capture) or write (for playback):
* 0 1 2 3 octet
* +----------------+----------------+----------------+----------------+
* | id | operation | reserved | 4
* +----------------+----------------+----------------+----------------+
* | reserved | 8
* +----------------+----------------+----------------+----------------+
* | offset | 12
* +----------------+----------------+----------------+----------------+
* | length | 16
* +----------------+----------------+----------------+----------------+
* | reserved | 20
* +----------------+----------------+----------------+----------------+
* |/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/|
* +----------------+----------------+----------------+----------------+
* | reserved | 64
* +----------------+----------------+----------------+----------------+
*
* operation - XENSND_OP_READ for read or XENSND_OP_WRITE for write
*/
struct xensnd_rw_req {
uint32_t offset;
uint32_t length;
};
/*
* Request set/get volume - set/get channels' volume of the stream given:
* 0 1 2 3 octet
* +----------------+----------------+----------------+----------------+
* | id | operation | reserved | 4
* +----------------+----------------+----------------+----------------+
Annotation
- Immediate include surface: `ring.h`, `../grant_table.h`.
- Detected declarations: `struct xensnd_open_req`, `struct xensnd_page_directory`, `struct xensnd_rw_req`, `struct xensnd_trigger_req`, `struct xensnd_query_hw_param`, `struct xensnd_cur_pos_evt`, `struct xensnd_req`, `struct xensnd_resp`, `struct xensnd_evt`, `struct xensnd_event_page`.
- Atlas domain: Repository Root And Misc / include.
- 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.