Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
awilliam
GitHub Repository: awilliam/linux-vfio
Path: blob/master/arch/arm/mach-lpc32xx/clock.h
10817 views
1
/*
2
* arch/arm/mach-lpc32xx/clock.h
3
*
4
* Author: Kevin Wells <[email protected]>
5
*
6
* Copyright (C) 2010 NXP Semiconductors
7
*
8
* This program is free software; you can redistribute it and/or modify
9
* it under the terms of the GNU General Public License as published by
10
* the Free Software Foundation; either version 2 of the License, or
11
* (at your option) any later version.
12
*
13
* This program is distributed in the hope that it will be useful,
14
* but WITHOUT ANY WARRANTY; without even the implied warranty of
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
* GNU General Public License for more details.
17
*/
18
19
#ifndef __LPC32XX_CLOCK_H
20
#define __LPC32XX_CLOCK_H
21
22
struct clk {
23
struct list_head node;
24
struct clk *parent;
25
u32 rate;
26
u32 usecount;
27
28
int (*set_rate) (struct clk *, unsigned long);
29
unsigned long (*round_rate) (struct clk *, unsigned long);
30
unsigned long (*get_rate) (struct clk *clk);
31
int (*enable) (struct clk *, int);
32
33
/* Register address and bit mask for simple clocks */
34
void __iomem *enable_reg;
35
u32 enable_mask;
36
};
37
38
#endif
39
40