Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Fields
clk_ops Struct Reference

#include <clock.h>

Data Fields

int(* enable )(unsigned id)
 
void(* disable )(unsigned id)
 
void(* auto_off )(unsigned id)
 
int(* reset )(unsigned id, enum clk_reset_action action)
 
int(* set_rate )(unsigned id, unsigned rate)
 
int(* set_min_rate )(unsigned id, unsigned rate)
 
int(* set_max_rate )(unsigned id, unsigned rate)
 
int(* set_flags )(unsigned id, unsigned flags)
 
unsigned(* get_rate )(unsigned id)
 
unsigned(* is_enabled )(unsigned id)
 
long(* round_rate )(unsigned id, unsigned rate)
 
bool(* is_local )(unsigned id)
 
unsigned long(* get_rate )(struct clk *c)
 
unsigned long(* round_rate )(struct clk *c, unsigned long rate)
 
int(* set_parent )(struct clk *c, struct clk *parent)
 
long(* round )(struct clk *, unsigned long)
 
int(* set )(struct clk *, unsigned long)
 
void(* setvco )(struct clk *, struct icst_vco)
 
int(* disable )(struct clk *clk)
 
void(* init )(struct clk *clk)
 
void(* enable )(struct clk *clk)
 
void(* recalc )(struct clk *clk)
 
int(* is_enabled )(struct clk *clk)
 

Detailed Description

struct clk_ops - standard clock operations : set the clock rate, see clk_set_rate(). : get the clock rate, see clk_get_rate(). : round a given clock rate, see clk_round_rate(). : set the clock's parent, see clk_set_parent().

Group the common clock implementations together so that we don't have to keep setting the same fields again. We leave enable in struct clk.

Adding an extra layer of indirection into the process should not be a problem as it is unlikely these operations are going to need to be called quickly.

Definition at line 34 of file clock.h.

Field Documentation

void(* auto_off)(unsigned id)

Definition at line 37 of file clock.h.

int(* disable)(struct clk *clk)

Definition at line 36 of file clock.h.

int(* disable)(struct clk *clk)

Definition at line 58 of file clocks.h.

void(* enable)(struct clk *clk)

Definition at line 15 of file clock.h.

int(* enable)(struct clk *clk)

Definition at line 35 of file clock.h.

unsigned long(* get_rate)(struct clk *clk)

Definition at line 37 of file clock.h.

unsigned long(* get_rate)(struct clk *clk)

Definition at line 43 of file clock.h.

void(* init)(struct clk *clk)

Definition at line 14 of file clock.h.

int(* is_enabled)(struct clk *clk)

Definition at line 39 of file clock.h.

unsigned(* is_enabled)(unsigned id)

Definition at line 44 of file clock.h.

bool(* is_local)(unsigned id)

Definition at line 46 of file clock.h.

void(* recalc)(struct clk *clk)

Definition at line 17 of file clock.h.

int(* reset)(unsigned id, enum clk_reset_action action)

Definition at line 38 of file clock.h.

long(* round)(struct clk *, unsigned long)

Definition at line 7 of file clock.h.

unsigned long(* round_rate)(struct clk *clk, unsigned long rate)

Definition at line 38 of file clock.h.

unsigned long(* round_rate)(struct clk *clk, unsigned long rate)

Definition at line 45 of file clock.h.

int(* set)(struct clk *, unsigned long)

Definition at line 8 of file clock.h.

int(* set_flags)(unsigned id, unsigned flags)

Definition at line 42 of file clock.h.

int(* set_max_rate)(unsigned id, unsigned rate)

Definition at line 41 of file clock.h.

int(* set_min_rate)(unsigned id, unsigned rate)

Definition at line 40 of file clock.h.

int(* set_parent)(struct clk *clk, struct clk *parent)

Definition at line 39 of file clock.h.

int(* set_rate)(struct clk *clk, unsigned long rate)

Definition at line 39 of file clock.h.

void(* setvco)(struct clk *, struct icst_vco)

Definition at line 9 of file clock.h.


The documentation for this struct was generated from the following files: