drivers/ata/ata_piix.c
Source file repositories/reference/linux-study-clean/drivers/ata/ata_piix.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/ata/ata_piix.c- Extension
.c- Size
- 51545 bytes
- Lines
- 1970
- Domain
- Driver Families
- Bucket
- drivers/ata
- Inferred role
- Driver Families: operation-table or driver-model contract
- Status
- pattern 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 an operation table; this is where Linux turns generic core objects into subsystem-specific behavior.
- 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/module.hlinux/pci.hlinux/init.hlinux/blkdev.hlinux/delay.hlinux/device.hlinux/gfp.hscsi/scsi_host.hlinux/libata.hlinux/dmi.htrace/events/libata.h
Detected Declarations
struct piix_map_dbstruct piix_host_privstruct ich_laptopenum piix_controller_idsfunction piix_port_startfunction Nonefunction Nonefunction piix_set_timingsfunction Nonefunction Nonefunction Nonefunction Nonefunction piix_sidpr_selfunction piix_sidpr_scr_readfunction piix_sidpr_scr_writefunction piix_sidpr_set_lpmfunction piix_irq_checkfunction piix_broken_suspendfunction piix_pci_device_suspendfunction piix_pci_device_resumefunction piix_vmw_bmdma_statusfunction piix_disable_ahcifunction piix_check_450nx_erratafunction piix_init_pcsfunction piix_no_sidprfunction piix_init_sidprfunction piix_iocfg_bit18_quirkfunction piix_broken_system_powerofffunction piix_ignore_devices_quirkfunction layerfunction piix_remove_onefunction piix_initfunction piix_exitmodule init piix_init
Annotated Snippet
static struct pci_driver piix_pci_driver = {
.name = DRV_NAME,
.id_table = piix_pci_tbl,
.probe = piix_init_one,
.remove = piix_remove_one,
#ifdef CONFIG_PM_SLEEP
.suspend = piix_pci_device_suspend,
.resume = piix_pci_device_resume,
#endif
};
static int __init piix_init(void)
{
int rc;
rc = pci_register_driver(&piix_pci_driver);
if (rc)
return rc;
in_module_init = 0;
return 0;
}
static void __exit piix_exit(void)
{
pci_unregister_driver(&piix_pci_driver);
}
module_init(piix_init);
module_exit(piix_exit);
Annotation
- Immediate include surface: `linux/kernel.h`, `linux/module.h`, `linux/pci.h`, `linux/init.h`, `linux/blkdev.h`, `linux/delay.h`, `linux/device.h`, `linux/gfp.h`.
- Detected declarations: `struct piix_map_db`, `struct piix_host_priv`, `struct ich_laptop`, `enum piix_controller_ids`, `function piix_port_start`, `function None`, `function None`, `function piix_set_timings`, `function None`, `function None`.
- Atlas domain: Driver Families / drivers/ata.
- Implementation status: pattern 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.