drivers/clk/rockchip/clk-rk3568.c
Source file repositories/reference/linux-study-clean/drivers/clk/rockchip/clk-rk3568.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/clk/rockchip/clk-rk3568.c- Extension
.c- Size
- 79307 bytes
- Lines
- 1750
- Domain
- Driver Families
- Bucket
- drivers/clk
- 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.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/clk-provider.hlinux/module.hlinux/of.hlinux/of_address.hlinux/platform_device.hlinux/syscore_ops.hdt-bindings/clock/rk3568-cru.hclk.h
Detected Declarations
struct clk_rk3568_initsenum rk3568_pmu_pllsenum rk3568_pllsfunction rk3568_pmu_clk_initfunction rk3568_clk_initfunction clk_rk3568_probe
Annotated Snippet
struct clk_rk3568_inits {
void (*inits)(struct device_node *np);
};
static const struct clk_rk3568_inits clk_rk3568_pmucru_init = {
.inits = rk3568_pmu_clk_init,
};
static const struct clk_rk3568_inits clk_3568_cru_init = {
.inits = rk3568_clk_init,
};
static const struct of_device_id clk_rk3568_match_table[] = {
{
.compatible = "rockchip,rk3568-cru",
.data = &clk_3568_cru_init,
}, {
.compatible = "rockchip,rk3568-pmucru",
.data = &clk_rk3568_pmucru_init,
},
{ }
};
static int __init clk_rk3568_probe(struct platform_device *pdev)
{
struct device_node *np = pdev->dev.of_node;
const struct clk_rk3568_inits *init_data;
init_data = (struct clk_rk3568_inits *)of_device_get_match_data(&pdev->dev);
if (!init_data)
return -EINVAL;
if (init_data->inits)
init_data->inits(np);
return 0;
}
static struct platform_driver clk_rk3568_driver = {
.driver = {
.name = "clk-rk3568",
.of_match_table = clk_rk3568_match_table,
.suppress_bind_attrs = true,
},
};
builtin_platform_driver_probe(clk_rk3568_driver, clk_rk3568_probe);
Annotation
- Immediate include surface: `linux/clk-provider.h`, `linux/module.h`, `linux/of.h`, `linux/of_address.h`, `linux/platform_device.h`, `linux/syscore_ops.h`, `dt-bindings/clock/rk3568-cru.h`, `clk.h`.
- Detected declarations: `struct clk_rk3568_inits`, `enum rk3568_pmu_plls`, `enum rk3568_plls`, `function rk3568_pmu_clk_init`, `function rk3568_clk_init`, `function clk_rk3568_probe`.
- Atlas domain: Driver Families / drivers/clk.
- 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.