drivers/comedi/drivers/das1800.c
Source file repositories/reference/linux-study-clean/drivers/comedi/drivers/das1800.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/comedi/drivers/das1800.c- Extension
.c- Size
- 37654 bytes
- Lines
- 1364
- Domain
- Driver Families
- Bucket
- drivers/comedi
- 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.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/module.hlinux/interrupt.hlinux/slab.hlinux/io.hlinux/comedi/comedidev.hlinux/comedi/comedi_8254.hlinux/comedi/comedi_isadma.h
Detected Declarations
struct das1800_boardstruct das1800_privateenum das1800_boardidfunction das1800_ai_mungefunction das1800_handle_fifo_half_fullfunction das1800_handle_fifo_not_emptyfunction das1800_flush_dma_channelfunction das1800_flush_dmafunction das1800_handle_dmafunction das1800_ai_cancelfunction das1800_ai_handlerfunction das1800_ai_pollfunction das1800_interruptfunction das1800_ai_fixup_paced_timingfunction das1800_ai_fixup_burst_timingfunction das1800_ai_check_chanlistfunction das1800_ai_cmdtestfunction das1800_ai_chanspec_bitsfunction das1800_ai_transfer_sizefunction das1800_ai_setup_dmafunction das1800_ai_set_chanlistfunction das1800_ai_cmdfunction das1800_ai_eocfunction das1800_ai_insn_readfunction das1800_ao_insn_writefunction das1800_di_insn_bitsfunction das1800_do_insn_bitsfunction das1800_init_dmafunction das1800_free_dmafunction das1800_probefunction das1800_attachfunction das1800_detach
Annotated Snippet
struct das1800_board {
const char *name;
unsigned char id;
unsigned int ai_speed;
unsigned int is_01_series:1;
};
static const struct das1800_board das1800_boards[] = {
[BOARD_DAS1701ST] = {
.name = "das-1701st",
.id = DAS1800_ID_ST,
.ai_speed = 6250,
.is_01_series = 1,
},
[BOARD_DAS1701ST_DA] = {
.name = "das-1701st-da",
.id = DAS1800_ID_ST_DA,
.ai_speed = 6250,
.is_01_series = 1,
},
[BOARD_DAS1702ST] = {
.name = "das-1702st",
.id = DAS1800_ID_ST,
.ai_speed = 6250,
},
[BOARD_DAS1702ST_DA] = {
.name = "das-1702st-da",
.id = DAS1800_ID_ST_DA,
.ai_speed = 6250,
},
[BOARD_DAS1702HR] = {
.name = "das-1702hr",
.id = DAS1800_ID_HR,
.ai_speed = 20000,
},
[BOARD_DAS1702HR_DA] = {
.name = "das-1702hr-da",
.id = DAS1800_ID_HR_DA,
.ai_speed = 20000,
},
[BOARD_DAS1701AO] = {
.name = "das-1701ao",
.id = DAS1800_ID_AO,
.ai_speed = 6250,
.is_01_series = 1,
},
[BOARD_DAS1702AO] = {
.name = "das-1702ao",
.id = DAS1800_ID_AO,
.ai_speed = 6250,
},
[BOARD_DAS1801ST] = {
.name = "das-1801st",
.id = DAS1800_ID_ST,
.ai_speed = 3000,
.is_01_series = 1,
},
[BOARD_DAS1801ST_DA] = {
.name = "das-1801st-da",
.id = DAS1800_ID_ST_DA,
.ai_speed = 3000,
.is_01_series = 1,
},
[BOARD_DAS1802ST] = {
.name = "das-1802st",
.id = DAS1800_ID_ST,
.ai_speed = 3000,
},
[BOARD_DAS1802ST_DA] = {
.name = "das-1802st-da",
.id = DAS1800_ID_ST_DA,
.ai_speed = 3000,
},
[BOARD_DAS1802HR] = {
.name = "das-1802hr",
.id = DAS1800_ID_HR,
.ai_speed = 10000,
},
[BOARD_DAS1802HR_DA] = {
.name = "das-1802hr-da",
.id = DAS1800_ID_HR_DA,
.ai_speed = 10000,
},
[BOARD_DAS1801HC] = {
.name = "das-1801hc",
.id = DAS1800_ID_HC,
.ai_speed = 3000,
.is_01_series = 1,
},
[BOARD_DAS1802HC] = {
Annotation
- Immediate include surface: `linux/module.h`, `linux/interrupt.h`, `linux/slab.h`, `linux/io.h`, `linux/comedi/comedidev.h`, `linux/comedi/comedi_8254.h`, `linux/comedi/comedi_isadma.h`.
- Detected declarations: `struct das1800_board`, `struct das1800_private`, `enum das1800_boardid`, `function das1800_ai_munge`, `function das1800_handle_fifo_half_full`, `function das1800_handle_fifo_not_empty`, `function das1800_flush_dma_channel`, `function das1800_flush_dma`, `function das1800_handle_dma`, `function das1800_ai_cancel`.
- Atlas domain: Driver Families / drivers/comedi.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
- IRQ or DMA behavior appears here, which is relevant to the selected PCIe/NVMe device path.
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.