Browse Source

[ARM] 5052/1: export clock functions for the at91x40

Export the AT91 clock functions for the AT91X40. Some external code common
to all AT91 family parts relys on this, like the gpio and serial support.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Greg Ungerer 17 years ago
parent
commit
66aaeff1c2
1 changed files with 17 additions and 1 deletions
  1. 17 1
      arch/arm/mach-at91/at91x40.c

+ 17 - 1
arch/arm/mach-at91/at91x40.c

@@ -16,16 +16,32 @@
 #include <asm/mach/arch.h>
 #include <asm/mach/arch.h>
 #include <asm/arch/at91x40.h>
 #include <asm/arch/at91x40.h>
 #include <asm/arch/at91_st.h>
 #include <asm/arch/at91_st.h>
+#include <asm/arch/timex.h>
 #include "generic.h"
 #include "generic.h"
 
 
 /*
 /*
- * This is used in the gpio code, stub locally.
+ * Export the clock functions for the AT91X40. Some external code common
+ * to all AT91 family parts relys on this, like the gpio and serial support.
  */
  */
 int clk_enable(struct clk *clk)
 int clk_enable(struct clk *clk)
 {
 {
 	return 0;
 	return 0;
 }
 }
 
 
+void clk_disable(struct clk *clk)
+{
+}
+
+unsigned long clk_get_rate(struct clk *clk)
+{
+	return AT91X40_MASTER_CLOCK;
+}
+
+struct clk *clk_get(struct device *dev, const char *id)
+{
+	return NULL;
+}
+
 void __init at91x40_initialize(unsigned long main_clock)
 void __init at91x40_initialize(unsigned long main_clock)
 {
 {
 	at91_extern_irq = (1 << AT91X40_ID_IRQ0) | (1 << AT91X40_ID_IRQ1)
 	at91_extern_irq = (1 << AT91X40_ID_IRQ0) | (1 << AT91X40_ID_IRQ1)