Bootloader USB mode for PP502x. Enable only on GoGear SA9200 for the time being....
[kugel-rb.git] / firmware / target / arm / tms320dm320 / system-target.h
blob4e0a97f10ee0443ea5c777273307a4b1423ff144
1 /***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
10 * Copyright (C) 2007, 2009 by Karl Kurbjun
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
17 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
18 * KIND, either express or implied.
20 ****************************************************************************/
21 #ifndef SYSTEM_TARGET_H
22 #define SYSTEM_TARGET_H
24 #include "system-arm.h"
25 #include "mmu-arm.h"
27 #define CPUFREQ_SLEEP 32768
28 #define CPUFREQ_DEFAULT 87500000
29 #define CPUFREQ_NORMAL 87500000
30 #define CPUFREQ_MAX 175000000
32 void udelay(int usec);
34 void dm320_set_io (char pin_num, bool input, bool invert, bool irq, bool irqany,
35 bool chat, char func_num );
37 #if defined(CREATIVE_ZVx) && defined(BOOTLOADER)
38 #define SLEEP_KERNEL_HOOK(ticks) \
39 ({ \ /* hacky.. */
40 long _sleep_ticks = current_tick + ticks + 1; \
41 while (TIME_BEFORE(current_tick, _sleep_ticks)) \
42 switch_thread(); \
43 true; }) /* handled here */
44 #endif
46 #endif /* SYSTEM_TARGET_H */