Rename CLOCK_FREQ macro to CPU_FREQ: now clock frequency has to be set in the makefile.
[bertos.git] / bertos / cpu / arm / drv / kdebug_at91.c
index b6ec8b199ac457ba71ebcf04f28338ab90b0313d..5f1b6023f03aeb13ba3c9ca47dcb23b9bf7a4bbe 100644 (file)
@@ -37,7 +37,7 @@
  */
 
 #include "kdebug_at91.h"
-#include "hw/hw_cpu.h"     /* for CLOCK_FREQ */
+#include <hw/hw_cpufreq.h>     /* for CPU_FREQ */
 #include "hw/hw_ser.h"     /* Required for bus macros overrides */
 
 #include "cfg/cfg_debug.h"
@@ -72,7 +72,7 @@ INLINE void kdbg_hw_init(void)
                /* Reset DBGU */
                DBGU_CR =  BV(US_RSTRX) | BV(US_RSTTX) | BV(US_RXDIS) | BV(US_TXDIS);
                /* Set baudrate */
-               DBGU_BRGR = DIV_ROUND(CLOCK_FREQ, 16 * CONFIG_KDEBUG_BAUDRATE);
+               DBGU_BRGR = DIV_ROUND(CPU_FREQ, 16 * CONFIG_KDEBUG_BAUDRATE);
                /* Set DBGU mode to 8 data bits, no parity and 1 stop bit. */
                DBGU_MR =  US_CHMODE_NORMAL | US_CHRL_8 | US_PAR_NO | US_NBSTOP_1;
                /* Enable DBGU transmitter. */