aboutsummaryrefslogtreecommitdiff
path: root/arch/arm/include/asm/hardware/icst307.h
diff options
context:
space:
mode:
authorJames Morris <jmorris@namei.org>2008-08-28 10:47:34 +1000
committerJames Morris <jmorris@namei.org>2008-08-28 10:47:34 +1000
commit86d688984deefa3ae5a802880c11f2b408b5d6cf (patch)
tree7ea5e8189b0a774626d3ed7c3c87df2495a4c4a0 /arch/arm/include/asm/hardware/icst307.h
parent93c06cbbf9fea5d5be1778febb7fa9ab1a74e5f5 (diff)
parent4c246edd2550304df5b766cc841584b2bb058843 (diff)
Merge branch 'master' into next
Diffstat (limited to 'arch/arm/include/asm/hardware/icst307.h')
-rw-r--r--arch/arm/include/asm/hardware/icst307.h38
1 files changed, 38 insertions, 0 deletions
diff --git a/arch/arm/include/asm/hardware/icst307.h b/arch/arm/include/asm/hardware/icst307.h
new file mode 100644
index 00000000000..554f128a104
--- /dev/null
+++ b/arch/arm/include/asm/hardware/icst307.h
@@ -0,0 +1,38 @@
+/*
+ * arch/arm/include/asm/hardware/icst307.h
+ *
+ * Copyright (C) 2003 Deep Blue Solutions, Ltd, All Rights Reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * Support functions for calculating clocks/divisors for the ICS307
+ * clock generators. See http://www.icst.com/ for more information
+ * on these devices.
+ *
+ * This file is similar to the icst525.h file
+ */
+#ifndef ASMARM_HARDWARE_ICST307_H
+#define ASMARM_HARDWARE_ICST307_H
+
+struct icst307_params {
+ unsigned long ref;
+ unsigned long vco_max; /* inclusive */
+ unsigned short vd_min; /* inclusive */
+ unsigned short vd_max; /* inclusive */
+ unsigned char rd_min; /* inclusive */
+ unsigned char rd_max; /* inclusive */
+};
+
+struct icst307_vco {
+ unsigned short v;
+ unsigned char r;
+ unsigned char s;
+};
+
+unsigned long icst307_khz(const struct icst307_params *p, struct icst307_vco vco);
+struct icst307_vco icst307_khz_to_vco(const struct icst307_params *p, unsigned long freq);
+struct icst307_vco icst307_ps_to_vco(const struct icst307_params *p, unsigned long period);
+
+#endif