drivers/clk/versatile/clk-versatile.c

Source file repositories/reference/linux-study-clean/drivers/clk/versatile/clk-versatile.c

File Facts

System
Linux kernel
Corpus path
drivers/clk/versatile/clk-versatile.c
Extension
.c
Size
2522 bytes
Lines
99
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.

Dependency Surface

Detected Declarations

Annotated Snippet

if (!parent) {
			pr_err("no parent on core module clock\n");
			return;
		}
		cm_base = of_iomap(parent, 0);
		of_node_put(parent);
		if (!cm_base) {
			pr_err("could not remap core module base\n");
			return;
		}
	}

	parent_name = of_clk_get_parent_name(np, 0);
	clk = icst_clk_register(NULL, desc, clk_name, parent_name, cm_base);
	if (!IS_ERR(clk))
		of_clk_add_provider(np, of_clk_src_simple_get, clk);
}

static void __init of_integrator_cm_osc_setup(struct device_node *np)
{
	cm_osc_setup(np, &cm_auxosc_desc);
}
CLK_OF_DECLARE(integrator_cm_auxosc_clk,
	"arm,integrator-cm-auxosc", of_integrator_cm_osc_setup);

static void __init of_versatile_cm_osc_setup(struct device_node *np)
{
	cm_osc_setup(np, &versatile_auxosc_desc);
}
CLK_OF_DECLARE(versatile_cm_auxosc_clk,
	       "arm,versatile-cm-auxosc", of_versatile_cm_osc_setup);

Annotation

Implementation Notes