clkdev.h 475 字节
Newer Older
1 2 3 4
#ifndef __ASM_MACH_CLKDEV_H
#define __ASM_MACH_CLKDEV_H

#include <linux/module.h>
5
#include <asm/hardware/icst.h>
6 7 8 9

struct clk {
	unsigned long		rate;
	struct module		*owner;
10
	const struct icst_params *params;
11
	void __iomem		*vcoreg;
12
	void			(*setvco)(struct clk *, struct icst_vco vco);
13
	void			*data;
14 15 16 17 18 19 20 21 22 23 24 25 26
};

static inline int __clk_get(struct clk *clk)
{
	return try_module_get(clk->owner);
}

static inline void __clk_put(struct clk *clk)
{
	module_put(clk->owner);
}

#endif