Home | History | Annotate | Download | only in asm
      1 /****************************************************************************
      2  ****************************************************************************
      3  ***
      4  ***   This header was automatically generated from a Linux kernel header
      5  ***   of the same name, to make information necessary for userspace to
      6  ***   call into the kernel available to libc.  It contains only constants,
      7  ***   structures, and macros generated from the original header, and thus,
      8  ***   contains no copyrightable information.
      9  ***
     10  ****************************************************************************
     11  ****************************************************************************/
     12 #ifndef __ASM_SH_CLOCK_H
     13 #define __ASM_SH_CLOCK_H
     14 
     15 #include <linux/kref.h>
     16 #include <linux/list.h>
     17 #include <linux/seq_file.h>
     18 #include <linux/clk.h>
     19 #include <linux/err.h>
     20 
     21 struct clk;
     22 
     23 struct clk_ops {
     24  void (*init)(struct clk *clk);
     25  void (*enable)(struct clk *clk);
     26  void (*disable)(struct clk *clk);
     27  void (*recalc)(struct clk *clk);
     28  int (*set_rate)(struct clk *clk, unsigned long rate, int algo_id);
     29  long (*round_rate)(struct clk *clk, unsigned long rate);
     30 };
     31 
     32 struct clk {
     33  struct list_head node;
     34  const char *name;
     35  int id;
     36  struct module *owner;
     37 
     38  struct clk *parent;
     39  struct clk_ops *ops;
     40 
     41  struct kref kref;
     42 
     43  unsigned long rate;
     44  unsigned long flags;
     45  unsigned long arch_flags;
     46 };
     47 
     48 #define CLK_ALWAYS_ENABLED (1 << 0)
     49 #define CLK_RATE_PROPAGATES (1 << 1)
     50 
     51 enum clk_sh_algo_id {
     52  NO_CHANGE = 0,
     53 
     54  IUS_N1_N1,
     55  IUS_322,
     56  IUS_522,
     57  IUS_N11,
     58 
     59  SB_N1,
     60 
     61  SB3_N1,
     62  SB3_32,
     63  SB3_43,
     64  SB3_54,
     65 
     66  BP_N1,
     67 
     68  IP_N1,
     69 };
     70 #endif
     71