drivers/firmware/arm_ffa/driver.c
Source file repositories/reference/linux-study-clean/drivers/firmware/arm_ffa/driver.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/firmware/arm_ffa/driver.c- Extension
.c- Size
- 57234 bytes
- Lines
- 2240
- Domain
- Driver Families
- Bucket
- drivers/firmware
- 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/acpi.hlinux/arm_ffa.hlinux/bitfield.hlinux/cpuhotplug.hlinux/delay.hlinux/device.hlinux/hashtable.hlinux/interrupt.hlinux/io.hlinux/kernel.hlinux/module.hlinux/mm.hlinux/mutex.hlinux/of_irq.hlinux/platform_device.hlinux/scatterlist.hlinux/slab.hlinux/smp.hlinux/uuid.hlinux/xarray.hasm/virt.hcommon.h
Detected Declarations
struct ffa_pcpu_irqstruct ffa_drv_infostruct ffa_partition_info_lestruct ffa_notify_bitmapsstruct ffa_dev_part_infostruct notifier_cb_infoenum notify_typefunction ffa_to_linux_errnofunction callerfunction ffa_version_checkfunction invoke_ffa_fnfunction ffa_rx_releasefunction invoke_ffa_fnfunction ffa_rxtx_mapfunction invoke_ffa_fnfunction ffa_rxtx_unmapfunction invoke_ffa_fnfunction ffa_featuresfunction invoke_ffa_fnfunction __ffa_partition_info_getfunction __ffa_partition_info_get_regsfunction invoke_ffa_fnfunction ffa_partition_probefunction ffa_id_getfunction invoke_ffa_fnfunction ffa_msg_send_wait_for_completionfunction invoke_ffa_fnfunction ffa_msg_send_direct_reqfunction invoke_ffa_fnfunction ffa_msg_send2function ffa_msg_send_direct_req2function ffa_mem_first_fragfunction invoke_ffa_fnfunction ffa_mem_next_fragfunction invoke_ffa_fnfunction ffa_transmit_fragmentfunction ffa_get_num_pages_sgfunction ffa_memory_attributes_getfunction ffa_emad_impdef_value_initfunction ffa_mem_region_additional_setupfunction ffa_setup_and_transmitfunction ffa_memory_opsfunction ffa_memory_reclaimfunction invoke_ffa_fnfunction ffa_notification_bitmap_createfunction invoke_ffa_fnfunction ffa_notification_bitmap_destroyfunction invoke_ffa_fn
Annotated Snippet
module_init(ffa_init);
static void __exit ffa_exit(void)
{
platform_device_unregister(ffa_pdev);
platform_driver_unregister(&ffa_driver);
}
module_exit(ffa_exit);
MODULE_ALIAS("arm-ffa");
MODULE_AUTHOR("Sudeep Holla <sudeep.holla@arm.com>");
MODULE_DESCRIPTION("Arm FF-A interface driver");
MODULE_LICENSE("GPL v2");
Annotation
- Immediate include surface: `linux/acpi.h`, `linux/arm_ffa.h`, `linux/bitfield.h`, `linux/cpuhotplug.h`, `linux/delay.h`, `linux/device.h`, `linux/hashtable.h`, `linux/interrupt.h`.
- Detected declarations: `struct ffa_pcpu_irq`, `struct ffa_drv_info`, `struct ffa_partition_info_le`, `struct ffa_notify_bitmaps`, `struct ffa_dev_part_info`, `struct notifier_cb_info`, `enum notify_type`, `function ffa_to_linux_errno`, `function caller`, `function ffa_version_check`.
- Atlas domain: Driver Families / drivers/firmware.
- 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.