drivers/greybus/bundle.c
Source file repositories/reference/linux-study-clean/drivers/greybus/bundle.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/greybus/bundle.c- Extension
.c- Size
- 5524 bytes
- Lines
- 253
- Domain
- Driver Families
- Bucket
- drivers/greybus
- 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.
- 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/greybus.hgreybus_trace.h
Detected Declarations
function bundle_class_showfunction bundle_id_showfunction state_showfunction state_storefunction list_for_each_entryfunction gb_bundle_releasefunction gb_bundle_disable_all_connectionsfunction gb_bundle_enable_all_connectionsfunction gb_bundle_suspendfunction gb_bundle_resumefunction gb_bundle_idlefunction gb_bundle_addfunction gb_bundle_destroy
Annotated Snippet
ret = device_add(&bundle->dev);
if (ret) {
dev_err(&bundle->dev, "failed to register bundle: %d\n", ret);
return ret;
}
trace_gb_bundle_add(bundle);
return 0;
}
/*
* Tear down a previously set up bundle.
*/
void gb_bundle_destroy(struct gb_bundle *bundle)
{
trace_gb_bundle_destroy(bundle);
if (device_is_registered(&bundle->dev))
device_del(&bundle->dev);
list_del(&bundle->links);
put_device(&bundle->dev);
}
Annotation
- Immediate include surface: `linux/greybus.h`, `greybus_trace.h`.
- Detected declarations: `function bundle_class_show`, `function bundle_id_show`, `function state_show`, `function state_store`, `function list_for_each_entry`, `function gb_bundle_release`, `function gb_bundle_disable_all_connections`, `function gb_bundle_enable_all_connections`, `function gb_bundle_suspend`, `function gb_bundle_resume`.
- Atlas domain: Driver Families / drivers/greybus.
- Implementation status: source implementation candidate.
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.