drivers/i2c/busses/i2c-sh_mobile.c
Source file repositories/reference/linux-study-clean/drivers/i2c/busses/i2c-sh_mobile.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/i2c/busses/i2c-sh_mobile.c- Extension
.c- Size
- 28959 bytes
- Lines
- 1007
- Domain
- Driver Families
- Bucket
- drivers/i2c
- 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/clk.hlinux/delay.hlinux/dmaengine.hlinux/dma-mapping.hlinux/err.hlinux/i2c.hlinux/init.hlinux/interrupt.hlinux/io.hlinux/kernel.hlinux/module.hlinux/of.hlinux/platform_device.hlinux/pm_runtime.hlinux/slab.hlinux/string_choices.h
Detected Declarations
struct sh_mobile_i2c_datastruct sh_mobile_dt_configenum sh_mobile_i2c_opfunction iic_wrfunction iic_rdfunction iic_set_clrfunction sh_mobile_i2c_icclfunction sh_mobile_i2c_icchfunction sh_mobile_i2c_check_timingfunction sh_mobile_i2c_initfunction sh_mobile_i2c_v2_initfunction i2c_opfunction sh_mobile_i2c_isr_txfunction sh_mobile_i2c_isr_rxfunction sh_mobile_i2c_isrfunction sh_mobile_i2c_cleanup_dmafunction sh_mobile_i2c_dma_callbackfunction sh_mobile_i2c_xfer_dmafunction start_chfunction poll_dtefunction poll_busyfunction sh_mobile_xferfunction sh_mobile_i2c_xferfunction sh_mobile_i2c_xfer_atomicfunction sh_mobile_i2c_funcfunction sh_mobile_i2c_r8a7740_workaroundfunction sh_mobile_i2c_release_dmafunction sh_mobile_i2c_hook_irqsfunction sh_mobile_i2c_probefunction sh_mobile_i2c_removefunction sh_mobile_i2c_suspendfunction sh_mobile_i2c_resumefunction sh_mobile_i2c_adap_initfunction sh_mobile_i2c_adap_exitmodule init sh_mobile_i2c_adap_init
Annotated Snippet
subsys_initcall(sh_mobile_i2c_adap_init);
static void __exit sh_mobile_i2c_adap_exit(void)
{
platform_driver_unregister(&sh_mobile_i2c_driver);
}
module_exit(sh_mobile_i2c_adap_exit);
MODULE_DESCRIPTION("SuperH Mobile I2C Bus Controller driver");
MODULE_AUTHOR("Magnus Damm");
MODULE_AUTHOR("Wolfram Sang");
MODULE_LICENSE("GPL v2");
MODULE_ALIAS("platform:i2c-sh_mobile");
Annotation
- Immediate include surface: `linux/clk.h`, `linux/delay.h`, `linux/dmaengine.h`, `linux/dma-mapping.h`, `linux/err.h`, `linux/i2c.h`, `linux/init.h`, `linux/interrupt.h`.
- Detected declarations: `struct sh_mobile_i2c_data`, `struct sh_mobile_dt_config`, `enum sh_mobile_i2c_op`, `function iic_wr`, `function iic_rd`, `function iic_set_clr`, `function sh_mobile_i2c_iccl`, `function sh_mobile_i2c_icch`, `function sh_mobile_i2c_check_timing`, `function sh_mobile_i2c_init`.
- Atlas domain: Driver Families / drivers/i2c.
- 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.