drivers/tty/serial/msm_serial.c
Source file repositories/reference/linux-study-clean/drivers/tty/serial/msm_serial.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/tty/serial/msm_serial.c- Extension
.c- Size
- 47995 bytes
- Lines
- 1941
- Domain
- Driver Families
- Bucket
- drivers/tty
- Inferred role
- Driver Families: exported/initcall integration point
- Status
- integration 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.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- 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/kernel.hlinux/atomic.hlinux/dma/qcom_adm.hlinux/dma-mapping.hlinux/dmaengine.hlinux/module.hlinux/io.hlinux/ioport.hlinux/interrupt.hlinux/init.hlinux/console.hlinux/tty.hlinux/tty_flip.hlinux/serial_core.hlinux/slab.hlinux/clk.hlinux/platform_device.hlinux/pm_opp.hlinux/delay.hlinux/of.hlinux/of_device.hlinux/wait.h
Detected Declarations
struct msm_dmastruct msm_portstruct msm_baud_mapfunction msm_writefunction msm_readfunction msm_serial_set_mnd_regs_tcxofunction msm_serial_set_mnd_regs_tcxoby4function msm_serial_set_mnd_regsfunction msm_stop_dmafunction msm_release_dmafunction msm_request_tx_dmafunction msm_request_rx_dmafunction msm_wait_for_xmitrfunction msm_stop_txfunction msm_start_txfunction msm_reset_dm_countfunction msm_complete_tx_dmafunction msm_handle_tx_dmafunction msm_complete_rx_dmafunction msm_start_rx_dmafunction msm_stop_rxfunction msm_enable_msfunction msm_handle_rx_dmfunction msm_handle_rxfunction msm_handle_tx_piofunction msm_handle_txfunction msm_handle_delta_ctsfunction msm_uart_irqfunction msm_tx_emptyfunction msm_get_mctrlfunction msm_resetfunction msm_set_mctrlfunction msm_break_ctlfunction msm_find_best_baudfunction msm_set_baud_ratefunction msm_init_clockfunction msm_startupfunction msm_shutdownfunction msm_set_termiosfunction msm_release_portfunction msm_request_portfunction msm_config_portfunction msm_verify_portfunction msm_powerfunction msm_poll_get_char_singlefunction msm_poll_get_char_dmfunction msm_poll_get_charfunction msm_poll_put_char
Annotated Snippet
module_init(msm_serial_init);
module_exit(msm_serial_exit);
MODULE_AUTHOR("Robert Love <rlove@google.com>");
MODULE_DESCRIPTION("Driver for msm7x serial device");
MODULE_LICENSE("GPL");
Annotation
- Immediate include surface: `linux/kernel.h`, `linux/atomic.h`, `linux/dma/qcom_adm.h`, `linux/dma-mapping.h`, `linux/dmaengine.h`, `linux/module.h`, `linux/io.h`, `linux/ioport.h`.
- Detected declarations: `struct msm_dma`, `struct msm_port`, `struct msm_baud_map`, `function msm_write`, `function msm_read`, `function msm_serial_set_mnd_regs_tcxo`, `function msm_serial_set_mnd_regs_tcxoby4`, `function msm_serial_set_mnd_regs`, `function msm_stop_dma`, `function msm_release_dma`.
- Atlas domain: Driver Families / drivers/tty.
- Implementation status: integration 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.