/*1* Clock management for AT32AP CPUs2*3* Copyright (C) 2006 Atmel Corporation4*5* Based on arch/arm/mach-at91/clock.c6* Copyright (C) 2005 David Brownell7* Copyright (C) 2005 Ivan Kokshaysky8*9* This program is free software; you can redistribute it and/or modify10* it under the terms of the GNU General Public License version 2 as11* published by the Free Software Foundation.12*/13#include <linux/clk.h>14#include <linux/list.h>151617void at32_clk_register(struct clk *clk);1819struct clk {20struct list_head list; /* linking element */21const char *name; /* Clock name/function */22struct device *dev; /* Device the clock is used by */23struct clk *parent; /* Parent clock, if any */24void (*mode)(struct clk *clk, int enabled);25unsigned long (*get_rate)(struct clk *clk);26long (*set_rate)(struct clk *clk, unsigned long rate,27int apply);28int (*set_parent)(struct clk *clk, struct clk *parent);29u16 users; /* Enabled if non-zero */30u16 index; /* Sibling index */31};3233unsigned long pba_clk_get_rate(struct clk *clk);34void pba_clk_mode(struct clk *clk, int enabled);353637