TARGET_TREE is not needed anymore
[maemo-rb.git] / firmware / export / config.h
blob9af8b1f70d019eec42752a74cd7e5cd1dcb1ed72
1 /***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
10 * Copyright (C) 2002 by Daniel Stenberg
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 ****************************************************************************/
22 #ifndef __CONFIG_H__
23 #define __CONFIG_H__
25 #include "autoconf.h"
27 /* symbolic names for multiple choice configurations: */
29 /* CONFIG_STORAGE (note these are combineable bit-flags) */
30 #define STORAGE_ATA 0x01
31 #define STORAGE_MMC 0x02
32 #define STORAGE_SD 0x04
33 #define STORAGE_NAND 0x08
34 #define STORAGE_RAMDISK 0x10
36 /* CONFIG_TUNER (note these are combineable bit-flags) */
37 #define S1A0903X01 0x01 /* Samsung */
38 #define TEA5767 0x02 /* Philips */
39 #define LV24020LP 0x04 /* Sanyo */
40 #define SI4700 0x08 /* Silicon Labs */
41 #define TEA5760 0x10 /* Philips */
42 #define LV240000 0x20 /* Sanyo */
43 #define IPOD_REMOTE_TUNER 0x40 /* Apple */
44 #define RDA5802 0x80 /* RDA Microelectronics */
46 /* CONFIG_CODEC */
47 #define MAS3587F 3587
48 #define MAS3507D 3507
49 #define MAS3539F 3539
50 #define SWCODEC 1 /* if codec is done by SW */
52 /* CONFIG_CPU */
53 #define SH7034 7034
54 #define MCF5249 5249
55 #define MCF5250 5250
56 #define PP5002 5002
57 #define PP5020 5020
58 #define PP5022 5022
59 #define PP5024 5024
60 #define PP6100 6100
61 #define PNX0101 101
62 #define S3C2440 2440
63 #define DSC25 25
64 #define DM320 320
65 #define IMX31L 31
66 #define TCC770 770
67 #define TCC771L 771
68 #define TCC773L 773
69 #define TCC7801 7801
70 #define S5L8700 8700
71 #define S5L8701 8701
72 #define S5L8702 8702
73 #define JZ4732 4732
74 #define AS3525 3525
75 #define AT91SAM9260 9260
76 #define AS3525v2 35252
77 #define IMX233 233
78 #define RK27XX 2700
80 /* platforms
81 * bit fields to allow PLATFORM_HOSTED to be OR'ed e.g. with a
82 * possible future PLATFORM_ANDROID (some OSes might need totally different
83 * handling to run on them than a stand-alone application) */
84 #define PLATFORM_NATIVE (1<<0)
85 #define PLATFORM_HOSTED (1<<1)
86 #define PLATFORM_ANDROID (1<<2)
87 #define PLATFORM_SDL (1<<3)
88 #define PLATFORM_MAEMO4 (1<<4)
89 #define PLATFORM_MAEMO5 (1<<5)
90 #define PLATFORM_MAEMO (PLATFORM_MAEMO4|PLATFORM_MAEMO5)
91 #define PLATFORM_PANDORA (1<<6)
93 /* CONFIG_KEYPAD */
94 #define PLAYER_PAD 1
95 #define RECORDER_PAD 2
96 #define ONDIO_PAD 3
97 #define IRIVER_H100_PAD 4
98 #define IRIVER_H300_PAD 5
99 #define IAUDIO_X5M5_PAD 6
100 #define IPOD_4G_PAD 7
101 #define IPOD_3G_PAD 8
102 #define IPOD_1G2G_PAD 9
103 #define IRIVER_IFP7XX_PAD 10
104 #define GIGABEAT_PAD 11
105 #define IRIVER_H10_PAD 12
106 #define SANSA_E200_PAD 13
107 #define SANSA_C200_PAD 14
108 #define TATUNG_TPJ1022_PAD 15
109 #define ARCHOS_AV300_PAD 16
110 #define MROBE100_PAD 17
111 #define MROBE500_PAD 18
112 #define GIGABEAT_S_PAD 19
113 #define LOGIK_DAX_PAD 20
114 #define IAUDIO67_PAD 21
115 #define COWON_D2_PAD 22
116 #define IAUDIO_M3_PAD 23
117 #define CREATIVEZVM_PAD 24
118 #define SANSA_M200_PAD 25
119 #define CREATIVEZV_PAD 26
120 #define PHILIPS_SA9200_PAD 27
121 #define SANSA_C100_PAD 28
122 #define PHILIPS_HDD1630_PAD 29
123 #define MEIZU_M6SL_PAD 30
124 #define ONDAVX747_PAD 31
125 #define ONDAVX767_PAD 32
126 #define MEIZU_M6SP_PAD 33
127 #define MEIZU_M3_PAD 34
128 #define SANSA_CLIP_PAD 35
129 #define SANSA_FUZE_PAD 36
130 #define LYRE_PROTO1_PAD 37
131 #define SAMSUNG_YH_PAD 38
132 #define ONDAVX777_PAD 39
133 #define SAMSUNG_YPS3_PAD 40
134 #define MINI2440_PAD 41
135 #define PHILIPS_HDD6330_PAD 42
136 #define PBELL_VIBE500_PAD 43
137 #define MPIO_HD200_PAD 44
138 #define ANDROID_PAD 45
139 #define SDL_PAD 46
140 #define MPIO_HD300_PAD 47
141 #define SANSA_FUZEPLUS_PAD 48
142 #define RK27XX_GENERIC_PAD 49
143 #define HM60X_PAD 50
144 #define HM801_PAD 51
145 #define SANSA_CONNECT_PAD 52
146 #define SAMSUNG_YPR0_PAD 53
148 /* CONFIG_REMOTE_KEYPAD */
149 #define H100_REMOTE 1
150 #define H300_REMOTE 2
151 #define IAUDIO_REMOTE 3
152 #define MROBE_REMOTE 4
154 /* CONFIG_BACKLIGHT_FADING */
155 /* No fading capabilities at all (yet) */
156 #define BACKLIGHT_NO_FADING 0x0
157 /* Backlight fading is controlled using a hardware PWM mechanism */
158 #define BACKLIGHT_FADING_PWM 0x1
159 /* Backlight is controlled using a software implementation
160 * BACKLIGHT_FADING_SW_SETTING means that backlight is turned on by only setting
161 * the brightness (i.e. no real difference between backlight_on and
162 * backlight_set_brightness)
163 * BACKLIGHT_FADING_SW_HW_REG means that backlight brightness is restored
164 * "in hardware", from a hardware register upon backlight_on
165 * Both types need to have minor adjustments in the software fading code */
166 #define BACKLIGHT_FADING_SW_SETTING 0x2
167 #define BACKLIGHT_FADING_SW_HW_REG 0x4
168 /* Backlight fading is done in a target specific way
169 * for example in hardware, but not controllable*/
170 #define BACKLIGHT_FADING_TARGET 0x8
172 /* CONFIG_CHARGING */
174 /* Generic types */
175 #define CHARGING_SIMPLE 1 /* Simple, hardware controlled charging
176 * (CPU cannot read charger state but may read
177 * when power is plugged-in). */
178 #define CHARGING_MONITOR 2 /* Hardware controlled charging with monitoring
179 * (CPU is able to read HW charging state and
180 * when power is plugged-in). */
182 /* Mostly target-specific code in the /target tree */
183 #define CHARGING_TARGET 3 /* Any algorithm - usually software controlled
184 * charging or specific programming is required to
185 * use the charging hardware. */
187 /* CONFIG_BATTERY_MEASURE bits */
188 #define VOLTAGE_MEASURE 1 /* Target can report battery voltage
189 * Usually native ports */
190 #define PERCENTAGE_MEASURE 2 /* Target can report remaining capacity in %
191 * Usually application/hosted ports */
192 #define TIME_MEASURE 4 /* Target can report remaining time estimation
193 Usually application ports, and only
194 if the estimation is better that ours
195 (which it probably is) */
196 /* CONFIG_LCD */
197 #define LCD_SSD1815 1 /* as used by Archos Recorders and Ondios */
198 #define LCD_SSD1801 2 /* as used by Archos Player/Studio */
199 #define LCD_S1D15E06 3 /* as used by iRiver H100 series */
200 #define LCD_H300 4 /* as used by iRiver H300 series, exact model name is
201 unknown at the time of this writing */
202 #define LCD_X5 5 /* as used by iAudio X5 series, exact model name is
203 unknown at the time of this writing */
204 #define LCD_IPODCOLOR 6 /* as used by iPod Color/Photo */
205 #define LCD_IPODNANO 7 /* as used by iPod Nano */
206 #define LCD_IPODVIDEO 8 /* as used by iPod Video */
207 #define LCD_IPOD2BPP 9 /* as used by all fullsize greyscale iPods */
208 #define LCD_IPODMINI 10 /* as used by iPod Mini g1/g2 */
209 #define LCD_IFP7XX 11 /* as used by iRiver iFP 7xx/8xx */
210 #define LCD_GIGABEAT 12
211 #define LCD_H10_20GB 13 /* as used by iriver H10 20Gb */
212 #define LCD_H10_5GB 14 /* as used by iriver H10 5Gb */
213 #define LCD_TPJ1022 15 /* as used by Tatung Elio TPJ-1022 */
214 #define LCD_DSC25 16 /* as used by Archos AV300 */
215 #define LCD_C200 17 /* as used by Sandisk Sansa c200 */
216 #define LCD_MROBE500 18 /* as used by Olympus M:Robe 500i */
217 #define LCD_MROBE100 19 /* as used by Olympus M:Robe 100 */
218 #define LCD_LOGIKDAX 20 /* as used by Logik DAX - SSD1815 */
219 #define LCD_IAUDIO67 21 /* as used by iAudio 6/7 - unknown */
220 #define LCD_CREATIVEZVM 22 /* as used by Creative Zen Vision:M */
221 #define LCD_TL0350A 23 /* as used by the iAudio M3 remote, treated as main LCD */
222 #define LCD_COWOND2 24 /* as used by Cowon D2 - LTV250QV, TCC7801 driver */
223 #define LCD_SA9200 25 /* as used by the Philips SA9200 */
224 #define LCD_S6B33B2 26 /* as used by the Sansa c100 */
225 #define LCD_HDD1630 27 /* as used by the Philips HDD1630 */
226 #define LCD_MEIZUM6 28 /* as used by the Meizu M6SP and M6SL (various models) */
227 #define LCD_ONDAVX747 29 /* as used by the Onda VX747 */
228 #define LCD_ONDAVX767 30 /* as used by the Onda VX767 */
229 #define LCD_SSD1303 31 /* as used by the Sansa Clip */
230 #define LCD_FUZE 32 /* as used by the Sansa Fuze */
231 #define LCD_LYRE_PROTO1 33 /* as used by the Lyre prototype 1 */
232 #define LCD_YH925 34 /* as used by Samsung YH-925 (similar to the H10 20GB) */
233 #define LCD_VIEW 35 /* as used by the Sansa View */
234 #define LCD_NANO2G 36 /* as used by the iPod Nano 2nd Generation */
235 #define LCD_MINI2440 37 /* as used by the Mini2440 */
236 #define LCD_HDD6330 38 /* as used by the Philips HDD6330 */
237 #define LCD_VIBE500 39 /* as used by the Packard Bell Vibe 500 */
238 #define LCD_IPOD6G 40 /* as used by the iPod Nano 2nd Generation */
239 #define LCD_FUZEPLUS 41
240 #define LCD_SPFD5420A 42 /* rk27xx */
241 #define LCD_CLIPZIP 43 /* as used by the Sandisk Sansa Clip Zip */
242 #define LCD_HX8340B 44 /* as used by the HiFiMAN HM-601/HM-602/HM-801 */
243 #define LCD_CONNECT 45 /* as used by the Sandisk Sansa Connect */
244 #define LCD_GIGABEATS 46
245 #define LCD_YPR0 47
247 /* LCD_PIXELFORMAT */
248 #define HORIZONTAL_PACKING 1
249 #define VERTICAL_PACKING 2
250 #define HORIZONTAL_INTERLEAVED 3
251 #define VERTICAL_INTERLEAVED 4
252 #define RGB565 565
253 #define RGB565SWAPPED 3553
255 /* LCD_STRIDEFORMAT */
256 #define VERTICAL_STRIDE 1
257 #define HORIZONTAL_STRIDE 2
259 /* CONFIG_ORIENTATION */
260 #define SCREEN_PORTRAIT 0
261 #define SCREEN_LANDSCAPE 1
262 #define SCREEN_SQUARE 2
264 /* CONFIG_I2C */
265 #define I2C_NONE 0 /* For targets that do not use I2C - as the
266 Lyre prototype 1 */
267 #define I2C_PLAYREC 1 /* Archos Player/Recorder style */
268 #define I2C_ONDIO 2 /* Ondio style */
269 #define I2C_COLDFIRE 3 /* Coldfire style */
270 #define I2C_PP5002 4 /* PP5002 style */
271 #define I2C_PP5020 5 /* PP5020 style */
272 #define I2C_PNX0101 6 /* PNX0101 style */
273 #define I2C_S3C2440 7
274 #define I2C_PP5024 8 /* PP5024 style */
275 #define I2C_IMX31L 9
276 #define I2C_TCC77X 10
277 #define I2C_TCC780X 11
278 #define I2C_DM320 12 /* DM320 style */
279 #define I2C_S5L8700 13
280 #define I2C_JZ47XX 14 /* Ingenic Jz47XX style */
281 #define I2C_AS3525 15
282 #define I2C_S5L8702 16 /* Same as S5L8700, but with two channels */
283 #define I2C_IMX233 17
284 #define I2C_RK27XX 18
286 /* CONFIG_LED */
287 #define LED_REAL 1 /* SW controlled LED (Archos recorders, player) */
288 #define LED_VIRTUAL 2 /* Virtual LED (icon) (Archos Ondio) */
289 /* else HW controlled LED (iRiver H1x0) */
291 /* CONFIG_NAND */
292 #define NAND_IFP7XX 1
293 #define NAND_TCC 2
294 #define NAND_SAMSUNG 3
295 #define NAND_CC 4 /* ChinaChip */
296 #define NAND_RK27XX 5
298 /* CONFIG_RTC */
299 #define RTC_M41ST84W 1 /* Archos Recorder */
300 #define RTC_PCF50605 2 /* iPod 3G, 4G & Mini */
301 #define RTC_PCF50606 3 /* iriver H300 */
302 #define RTC_S3C2440 4
303 #define RTC_E8564 5 /* iriver H10 */
304 #define RTC_AS3514 6 /* Sandisk Sansa series */
305 #define RTC_DS1339_DS3231 7 /* h1x0 RTC mod */
306 #define RTC_IMX31L 8
307 #define RTC_RX5X348AB 9
308 #define RTC_TCC77X 10
309 #define RTC_TCC780X 11
310 #define RTC_MR100 12
311 #define RTC_MC13783 13 /* Freescale MC13783 PMIC */
312 #define RTC_S5L8700 14
313 #define RTC_S35390A 15
314 #define RTC_JZ47XX 16 /* Ingenic Jz47XX */
315 #define RTC_NANO2G 17 /* This seems to be a PCF5063x */
316 #define RTC_D2 18 /* Either PCF50606 or PCF50635 */
317 #define RTC_S35380A 19
318 #define RTC_IMX233 20
319 #define RTC_STM41T62 21 /* ST M41T62 */
321 /* USB On-the-go */
322 #define USBOTG_M66591 6591 /* M:Robe 500 */
323 #define USBOTG_ISP1362 1362 /* iriver H300 */
324 #define USBOTG_ISP1583 1583 /* Creative Zen Vision:M */
325 #define USBOTG_M5636 5636 /* iAudio X5 */
326 #define USBOTG_ARC 5020 /* PortalPlayer 502x and IMX233 */
327 #define USBOTG_JZ4740 4740 /* Ingenic Jz4740/Jz4732 */
328 #define USBOTG_AS3525 3525 /* AMS AS3525 */
329 #define USBOTG_S3C6400X 6400 /* Samsung S3C6400X, also used in the S5L8701/S5L8702/S5L8720 */
330 #define USBOTG_RK27XX 2700 /* Rockchip rk27xx */
331 #define USBOTG_TNETV105 105 /* TI TNETV105 */
333 /* Multiple cores */
334 #define CPU 0
335 #define COP 1
337 /* now go and pick yours */
338 #if defined(ARCHOS_PLAYER)
339 #include "config/archosplayer.h"
340 #elif defined(ARCHOS_RECORDER)
341 #include "config/archosrecorder.h"
342 #elif defined(ARCHOS_FMRECORDER)
343 #include "config/archosfmrecorder.h"
344 #elif defined(ARCHOS_RECORDERV2)
345 #include "config/archosrecorderv2.h"
346 #elif defined(ARCHOS_ONDIOSP)
347 #include "config/archosondiosp.h"
348 #elif defined(ARCHOS_ONDIOFM)
349 #include "config/archosondiofm.h"
350 #elif defined(ARCHOS_AV300)
351 #include "config/archosav300.h"
352 #elif defined(IRIVER_H100)
353 #include "config/iriverh100.h"
354 #elif defined(IRIVER_H120)
355 #include "config/iriverh120.h"
356 #elif defined(IRIVER_H300)
357 #include "config/iriverh300.h"
358 #elif defined(IAUDIO_X5)
359 #include "config/iaudiox5.h"
360 #elif defined(IAUDIO_M5)
361 #include "config/iaudiom5.h"
362 #elif defined(IAUDIO_M3)
363 #include "config/iaudiom3.h"
364 #elif defined(IPOD_COLOR)
365 #include "config/ipodcolor.h"
366 #elif defined(IPOD_NANO)
367 #include "config/ipodnano1g.h"
368 #elif defined(IPOD_VIDEO)
369 #include "config/ipodvideo.h"
370 #elif defined(IPOD_1G2G)
371 #include "config/ipod1g2g.h"
372 #elif defined(IPOD_3G)
373 #include "config/ipod3g.h"
374 #elif defined(IPOD_4G)
375 #include "config/ipod4g.h"
376 #elif defined(IPOD_NANO2G)
377 #include "config/ipodnano2g.h"
378 #elif defined(IPOD_6G)
379 #include "config/ipod6g.h"
380 #elif defined(IRIVER_IFP7XX)
381 #include "config/iriverifp7xx.h"
382 #elif defined(GIGABEAT_F)
383 #include "config/gigabeatfx.h"
384 #elif defined(GIGABEAT_S)
385 #include "config/gigabeats.h"
386 #elif defined(IPOD_MINI)
387 #include "config/ipodmini1g.h"
388 #elif defined(IPOD_MINI2G)
389 #include "config/ipodmini2g.h"
390 #elif defined(IRIVER_H10)
391 #include "config/iriverh10.h"
392 #elif defined(IRIVER_H10_5GB)
393 #include "config/iriverh10_5gb.h"
394 #elif defined(SANSA_E200)
395 #include "config/sansae200.h"
396 #elif defined(SANSA_C200)
397 #include "config/sansac200.h"
398 #elif defined(SANSA_M200)
399 #include "config/sansam200.h"
400 #elif defined(TATUNG_TPJ1022)
401 #include "config/tatungtpj1022.h"
402 #elif defined(MROBE_100)
403 #include "config/mrobe100.h"
404 #elif defined(MROBE_500)
405 #include "config/mrobe500.h"
406 #elif defined(LOGIK_DAX)
407 #include "config/logikdax.h"
408 #elif defined(IAUDIO_7)
409 #include "config/iaudio7.h"
410 #elif defined(COWON_D2)
411 #include "config/cowond2.h"
412 #elif defined(CREATIVE_ZVM)
413 #include "config/zenvisionm30gb.h"
414 #elif defined(CREATIVE_ZVM60GB)
415 #include "config/zenvisionm60gb.h"
416 #elif defined(CREATIVE_ZV)
417 #include "config/zenvision.h"
418 #elif defined(PHILIPS_SA9200)
419 #include "config/gogearsa9200.h"
420 #elif defined(PHILIPS_HDD1630)
421 #include "config/gogearhdd1630.h"
422 #elif defined(PHILIPS_HDD6330)
423 #include "config/gogearhdd6330.h"
424 #elif defined(SANSA_C100)
425 #include "config/sansac100.h"
426 #elif defined(MEIZU_M6SL)
427 #include "config/meizum6sl.h"
428 #elif defined(MEIZU_M6SP)
429 #include "config/meizum6sp.h"
430 #elif defined(MEIZU_M3)
431 #include "config/meizum3.h"
432 #elif defined(ONDA_VX747) || defined(ONDA_VX747P)
433 #include "config/ondavx747.h"
434 #elif defined(ONDA_VX777)
435 #include "config/ondavx777.h"
436 #elif defined(ONDA_VX767)
437 #include "config/ondavx767.h"
438 #elif defined(SANSA_CLIP)
439 #include "config/sansaclip.h"
440 #elif defined(SANSA_CLIPV2)
441 #include "config/sansaclipv2.h"
442 #elif defined(SANSA_CLIPPLUS)
443 #include "config/sansaclipplus.h"
444 #elif defined(SANSA_E200V2)
445 #include "config/sansae200v2.h"
446 #elif defined(SANSA_M200V4)
447 #include "config/sansam200v4.h"
448 #elif defined(SANSA_FUZE)
449 #include "config/sansafuze.h"
450 #elif defined(SANSA_FUZEV2)
451 #include "config/sansafuzev2.h"
452 #elif defined(SANSA_FUZEPLUS)
453 #include "config/sansafuzeplus.h"
454 #elif defined(SANSA_CLIPZIP)
455 #include "config/sansaclipzip.h"
456 #elif defined(SANSA_C200V2)
457 #include "config/sansac200v2.h"
458 #elif defined(SANSA_VIEW)
459 #include "config/sansaview.h"
460 #elif defined(LYRE_PROTO1)
461 #include "config/lyreproto1.h"
462 #elif defined(MINI2440)
463 #include "config/mini2440.h"
464 #elif defined(SAMSUNG_YH820)
465 #include "config/samsungyh820.h"
466 #elif defined(SAMSUNG_YH920)
467 #include "config/samsungyh920.h"
468 #elif defined(SAMSUNG_YH925)
469 #include "config/samsungyh925.h"
470 #elif defined(SAMSUNG_YPS3)
471 #include "config/samsungyps3.h"
472 #elif defined(PBELL_VIBE500)
473 #include "config/vibe500.h"
474 #elif defined(MPIO_HD200)
475 #include "config/mpiohd200.h"
476 #elif defined(MPIO_HD300)
477 #include "config/mpiohd300.h"
478 #elif defined(RK27_GENERIC)
479 #include "config/rk27generic.h"
480 #elif defined(HM60X)
481 #include "config/hifimanhm60x.h"
482 #elif defined(HM801)
483 #include "config/hifimanhm801.h"
484 #elif defined(SANSA_CONNECT)
485 #include "config/sansaconnect.h"
486 #elif defined(SDLAPP)
487 #include "config/sdlapp.h"
488 #elif defined(ANDROID)
489 #include "config/android.h"
490 #elif defined(NOKIAN8XX)
491 #include "config/nokian8xx.h"
492 #elif defined(NOKIAN900)
493 #include "config/nokian900.h"
494 #elif defined(PANDORA)
495 #include "config/pandora.h"
496 #elif defined(SAMSUNG_YPR0)
497 #include "config/samsungypr0.h"
498 #else
499 /* no known platform */
500 #endif
502 #ifdef APPLICATION
503 #define CONFIG_CPU 0
504 #define CONFIG_STORAGE 0
505 #endif
507 /* keep this include after the target configs */
508 #ifdef SIMULATOR
509 #include "config/sim.h"
510 #endif
512 #ifndef CONFIG_PLATFORM
513 #define CONFIG_PLATFORM PLATFORM_NATIVE
514 #endif
516 /* setup basic macros from capability masks */
517 #include "config_caps.h"
519 /* setup CPU-specific defines */
521 /* define for all cpus from SH family */
522 #if (CONFIG_CPU == SH7034)
523 #define CPU_SH
524 #endif
526 /* define for all cpus from coldfire family */
527 #if (CONFIG_CPU == MCF5249) || (CONFIG_CPU == MCF5250)
528 #define CPU_COLDFIRE
529 #endif
531 /* define for all cpus from PP family */
532 #if (CONFIG_CPU == PP5002)
533 #define CPU_PP
534 #elif (CONFIG_CPU == PP5020) || (CONFIG_CPU == PP5022) \
535 || (CONFIG_CPU == PP5024) || (CONFIG_CPU == PP6100)
536 #define CPU_PP
537 #define CPU_PP502x
538 #endif
540 /* define for all cpus from S5L870X family */
541 #if (CONFIG_CPU == S5L8700) || (CONFIG_CPU == S5L8701) || (CONFIG_CPU == S5L8702)
542 #define CPU_S5L870X
543 #endif
545 /* define for all cpus from TCC77X family */
546 #if (CONFIG_CPU == TCC771L) || (CONFIG_CPU == TCC773L) || (CONFIG_CPU == TCC770)
547 #define CPU_TCC77X
548 #endif
550 /* define for all cpus from TCC780 family */
551 #if (CONFIG_CPU == TCC7801)
552 #define CPU_TCC780X
553 #endif
555 /* define for all cpus from ARM7TDMI family (for specific optimisations) */
556 #if defined(CPU_PP) || (CONFIG_CPU == PNX0101) || (CONFIG_CPU == DSC25)
557 #define CPU_ARM7TDMI
558 #endif
560 /* define for all cpus from ARM family */
561 #if ((CONFIG_PLATFORM & PLATFORM_MAEMO5) && defined(MAEMO_ARM_BUILD)) \
562 || (CONFIG_PLATFORM & PLATFORM_PANDORA)
563 #define CPU_ARM
564 #define ARM_ARCH 7 /* ARMv7 */
566 #elif (CONFIG_CPU == IMX31L) \
567 || ((CONFIG_PLATFORM & PLATFORM_MAEMO4) && defined(MAEMO_ARM_BUILD))
568 #define CPU_ARM
569 #define ARM_ARCH 6 /* ARMv6 */
571 #elif defined(CPU_TCC77X) || defined(CPU_TCC780X) || (CONFIG_CPU == DM320) \
572 || (CONFIG_CPU == AT91SAM9260) || (CONFIG_CPU == AS3525v2) \
573 || (CONFIG_CPU == S5L8702) || (CONFIG_CPU == IMX233) \
574 || (CONFIG_CPU == RK27XX) ||(CONFIG_PLATFORM & PLATFORM_ANDROID)
575 #define CPU_ARM
576 #define ARM_ARCH 5 /* ARMv5 */
578 #elif defined(CPU_PP) || (CONFIG_CPU == PNX0101) || (CONFIG_CPU == S3C2440) \
579 || (CONFIG_CPU == DSC25) || defined(CPU_S5L870X) || (CONFIG_CPU == AS3525)
580 #define CPU_ARM
581 #define ARM_ARCH 4 /* ARMv4 */
582 #endif
584 #if (CONFIG_CPU == JZ4732)
585 #define CPU_MIPS 32
586 #endif
588 /* now set any CONFIG_ defines correctly if they are not used,
589 No need to do this on CONFIG_'s which are compulsory (e.g CONFIG_CODEC ) */
591 #if !defined(CONFIG_BACKLIGHT_FADING)
592 #define CONFIG_BACKLIGHT_FADING BACKLIGHT_NO_FADING
593 #endif
595 #ifndef CONFIG_I2C
596 #define CONFIG_I2C I2C_NONE
597 #endif
599 #ifndef CONFIG_TUNER
600 #define CONFIG_TUNER 0
601 #endif
603 #ifndef CONFIG_USBOTG
604 #define CONFIG_USBOTG 0
605 #endif
607 #ifndef CONFIG_LED
608 #define CONFIG_LED LED_VIRTUAL
609 #endif
611 #ifndef CONFIG_CHARGING
612 #define CONFIG_CHARGING 0
613 #endif
615 #ifndef CONFIG_BATTERY_MEASURE
616 #define CONFIG_BATTERY_MEASURE 0
617 #define NO_LOW_BATTERY_SHUTDOWN
618 #endif
620 #ifndef CONFIG_RTC
621 #define CONFIG_RTC 0
622 #endif
624 #ifndef BATTERY_TYPES_COUNT
625 #define BATTERY_TYPES_COUNT 0
626 #endif
628 #ifndef BATTERY_CAPACITY_DEFAULT
629 #define BATTERY_CAPACITY_DEFAULT 0
630 #endif
632 #ifndef BATTERY_CAPACITY_INC
633 #define BATTERY_CAPACITY_INC 0
634 #endif
636 #ifndef CONFIG_ORIENTATION
637 #if LCD_HEIGHT > LCD_WIDTH
638 #define CONFIG_ORIENTATION SCREEN_PORTRAIT
639 #elif LCD_HEIGHT < LCD_WIDTH
640 #define CONFIG_ORIENTATION SCREEN_LANDSCAPE
641 #else
642 #define CONFIG_ORIENTATION SCREEN_SQUARE
643 #endif
644 #endif
646 /* Pixel aspect ratio is defined in terms of a multiplier for pixel width and
647 * height, and is set to 1:1 if the target does not set a value
649 #ifndef LCD_PIXEL_ASPECT_HEIGHT
650 #define LCD_PIXEL_ASPECT_HEIGHT 1
651 #endif
652 #ifndef LCD_PIXEL_ASPECT_WIDTH
653 #define LCD_PIXEL_ASPECT_WIDTH 1
654 #endif
656 /* Used for split displays (Sansa Clip). Set to 0 otherwise */
657 #ifndef LCD_SPLIT_LINES
658 #define LCD_SPLIT_LINES 0
659 #endif
661 /* Simulator LCD dimensions. Set to standard dimensions if undefined */
662 #ifndef SIM_LCD_WIDTH
663 #define SIM_LCD_WIDTH LCD_WIDTH
664 #endif
665 #ifndef SIM_LCD_HEIGHT
666 #define SIM_LCD_HEIGHT (LCD_HEIGHT + LCD_SPLIT_LINES)
667 #endif
669 #ifdef HAVE_REMOTE_LCD
670 #ifndef SIM_REMOTE_WIDTH
671 #define SIM_REMOTE_WIDTH LCD_REMOTE_WIDTH
672 #endif
673 #ifndef SIM_REMOTE_HEIGHT
674 #define SIM_REMOTE_HEIGHT LCD_REMOTE_HEIGHT
675 #endif
676 #endif /* HAVE_REMOTE_LCD */
678 /* define this in the target config.h to use a different size */
679 #ifndef CONFIG_DEFAULT_ICON_HEIGHT
680 #define CONFIG_DEFAULT_ICON_HEIGHT 8
681 #endif
682 #ifndef CONFIG_DEFAULT_ICON_WIDTH
683 #define CONFIG_DEFAULT_ICON_WIDTH 6
684 #endif
685 #ifndef CONFIG_REMOTE_DEFAULT_ICON_HEIGHT
686 #define CONFIG_REMOTE_DEFAULT_ICON_HEIGHT 8
687 #endif
688 #ifndef CONFIG_REMOTE_DEFAULT_ICON_WIDTH
689 #define CONFIG_REMOTE_DEFAULT_ICON_WIDTH 6
690 #endif
692 #if LCD_DEPTH > 1 || defined(HAVE_REMOTE_LCD) && LCD_REMOTE_DEPTH > 1
693 #define HAVE_BACKDROP_IMAGE
694 #endif
696 #if (CONFIG_TUNER & (CONFIG_TUNER - 1)) != 0
697 /* Multiple possible tuners */
698 #define CONFIG_TUNER_MULTI
699 #endif
701 /* deactivate fading in bootloader */
702 #if defined(BOOTLOADER)
703 #undef CONFIG_BACKLIGHT_FADING
704 #define CONFIG_BACKLIGHT_FADING BACKLIGHT_NO_FADING
705 #endif
707 /* determine which setting/manual text to use */
708 #if (CONFIG_BACKLIGHT_FADING == BACKLIGHT_FADING_PWM)
710 /* possibly overridden in target config */
711 #if !defined(HAVE_BACKLIGHT_FADING_BOOL_SETTING) \
712 && !defined(HAVE_BACKLIGHT_FADING_INT_SETTING)
713 #define HAVE_BACKLIGHT_FADING_INT_SETTING
714 #endif
716 #elif (CONFIG_BACKLIGHT_FADING == BACKLIGHT_FADING_SW_SETTING) \
717 || (CONFIG_BACKLIGHT_FADING == BACKLIGHT_FADING_SW_HW_REG) \
718 || (CONFIG_BACKLIGHT_FADING == BACKLIGHT_FADING_TARGET)
720 /* possibly overridden in target config */
721 #if !defined(HAVE_BACKLIGHT_FADING_BOOL_SETTING) \
722 && !defined(HAVE_BACKLIGHT_FADING_INT_SETTING)
723 #define HAVE_BACKLIGHT_FADING_BOOL_SETTING
724 #endif
726 #endif /* CONFIG_BACKLIGHT_FADING */
728 /* Storage related config handling */
730 #if (CONFIG_STORAGE & (CONFIG_STORAGE - 1)) != 0
731 /* Multiple storage drivers */
732 #define CONFIG_STORAGE_MULTI
733 #endif
735 /* Explicit HAVE_MULTIVOLUME in the config file. Allow the maximum number */
736 #ifdef HAVE_MULTIVOLUME
737 #define NUM_VOLUMES_PER_DRIVE 4
738 #else
739 #define NUM_VOLUMES_PER_DRIVE 1
740 #endif
741 #if defined(CONFIG_STORAGE_MULTI) && !defined(HAVE_MULTIDRIVE)
742 #define HAVE_MULTIDRIVE
743 #endif
745 #if defined(HAVE_MULTIDRIVE) && !defined(HAVE_MULTIVOLUME)
746 #define HAVE_MULTIVOLUME
747 #endif
749 #if defined(HAVE_MULTIDRIVE) && !defined(NUM_DRIVES)
750 #error HAVE_MULTIDRIVE needs to have an explicit NUM_DRIVES
751 #endif
753 #ifndef NUM_DRIVES
754 #define NUM_DRIVES 1
755 #endif
757 #define NUM_VOLUMES (NUM_DRIVES * NUM_VOLUMES_PER_DRIVE)
759 #if defined(BOOTLOADER) && defined(HAVE_ADJUSTABLE_CPU_FREQ)
760 /* Bootloaders don't use CPU frequency adjustment */
761 #undef HAVE_ADJUSTABLE_CPU_FREQ
762 #endif
764 /* Enable the directory cache and tagcache in RAM if we have
765 * plenty of RAM. Both features can be enabled independently. */
766 #if (MEMORYSIZE >= 8) && !defined(BOOTLOADER) && !defined(__PCTOOL__) \
767 && !defined(APPLICATION)
768 #define HAVE_DIRCACHE
769 #ifdef HAVE_TAGCACHE
770 #define HAVE_TC_RAMCACHE
771 #endif
772 #endif
774 #if defined(HAVE_TAGCACHE) && defined(HAVE_LCD_BITMAP)
775 #define HAVE_PICTUREFLOW_INTEGRATION
776 #endif
778 /* Add one HAVE_ define for all mas35xx targets */
779 #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3507D) || (CONFIG_CODEC == MAS3539F)
780 #define HAVE_MAS35XX
781 #endif
783 #if (CONFIG_CODEC == SWCODEC)
784 #ifdef BOOTLOADER
786 #ifdef HAVE_BOOTLOADER_USB_MODE
787 /* Priority in bootloader is wanted */
788 #define HAVE_PRIORITY_SCHEDULING
789 #define USB_STATUS_BY_EVENT
790 #define USB_DETECT_BY_REQUEST
791 #if defined(HAVE_USBSTACK) && CONFIG_USBOTG == USBOTG_ARC
792 #define INCLUDE_TIMEOUT_API
793 #define USB_DRIVER_CLOSE
794 #endif
795 #endif
797 #else /* !BOOTLOADER */
799 #define HAVE_EXTENDED_MESSAGING_AND_NAME
800 #define HAVE_WAKEUP_EXT_CB
803 #if defined(ASSEMBLER_THREADS) \
804 || defined(HAVE_WIN32_FIBER_THREADS) \
805 || defined(HAVE_SIGALTSTACK_THREADS)
806 #define HAVE_PRIORITY_SCHEDULING
807 #endif
809 #if (CONFIG_PLATFORM & PLATFORM_NATIVE)
810 #define HAVE_PRIORITY_SCHEDULING
811 #define HAVE_SCHEDULER_BOOSTCTRL
812 #endif /* PLATFORM_NATIVE */
815 #ifdef HAVE_USBSTACK
816 #if CONFIG_USBOTG == USBOTG_ARC
817 #define USB_STATUS_BY_EVENT
818 #define USB_DETECT_BY_REQUEST
819 #define INCLUDE_TIMEOUT_API
820 #elif CONFIG_USBOTG == USBOTG_AS3525
821 #define USB_STATUS_BY_EVENT
822 #define USB_DETECT_BY_REQUEST
823 #elif CONFIG_USBOTG == USBOTG_S3C6400X /* FIXME */ && CONFIG_CPU == AS3525v2
824 #define USB_STATUS_BY_EVENT
825 #define USB_DETECT_BY_REQUEST
826 #elif CONFIG_USBOTG == USBOTG_RK27XX
827 #define USB_STATUS_BY_EVENT
828 #define USB_DETECT_BY_REQUEST
829 #endif /* CONFIG_USB == */
830 #endif /* HAVE_USBSTACK */
832 #endif /* BOOTLOADER */
834 #if defined(HAVE_USBSTACK) || (CONFIG_CPU == JZ4732) \
835 || (CONFIG_CPU == AS3525) || (CONFIG_CPU == AS3525v2) \
836 || defined(CPU_S5L870X) || (CONFIG_CPU == S3C2440) \
837 || defined(APPLICATION) || (CONFIG_CPU == PP5002) \
838 || (CONFIG_CPU == RK27XX) || (CONFIG_CPU == IMX233)
839 #define HAVE_SEMAPHORE_OBJECTS
840 #endif
842 /*include support for crossfading - requires significant PCM buffer space*/
843 #if MEMORYSIZE > 2
844 #define HAVE_CROSSFADE
845 #endif
847 #endif /* (CONFIG_CODEC == SWCODEC) */
849 /* Determine if accesses should be strictly long aligned. */
850 #if (CONFIG_CPU == SH7034) || defined(CPU_ARM) || defined(CPU_MIPS)
851 #define ROCKBOX_STRICT_ALIGN 1
852 #endif
854 #if defined(CPU_ARM) && defined(__ASSEMBLER__)
855 /* ARMv4T doesn't switch the T bit when popping pc directly, we must use BX */
856 .macro ldmpc cond="", order="ia", regs
857 #if ARM_ARCH == 4 && defined(USE_THUMB)
858 ldm\cond\order sp!, { \regs, lr }
859 bx\cond lr
860 #else
861 ldm\cond\order sp!, { \regs, pc }
862 #endif
863 .endm
864 .macro ldrpc cond=""
865 #if ARM_ARCH == 4 && defined(USE_THUMB)
866 ldr\cond lr, [sp], #4
867 bx\cond lr
868 #else
869 ldr\cond pc, [sp], #4
870 #endif
871 .endm
872 #endif
874 #ifndef CODEC_SIZE
875 #define CODEC_SIZE 0
876 #endif
878 /* This attribute can be used to ensure that certain symbols are never profiled
879 * which can be important as profiling a function de-inlines it */
880 #ifdef RB_PROFILE
881 #define NO_PROF_ATTR __attribute__ ((no_instrument_function))
882 #else
883 #define NO_PROF_ATTR
884 #endif
886 /* IRAM usage */
887 #if (CONFIG_PLATFORM & PLATFORM_NATIVE) && /* Not for hosted environments */ \
888 (((CONFIG_CPU == SH7034) && !defined(PLUGIN)) || /* SH1 archos: core only */ \
889 defined(CPU_COLDFIRE) || /* Coldfire: core, plugins, codecs */ \
890 defined(CPU_PP) || /* PortalPlayer: core, plugins, codecs */ \
891 (CONFIG_CPU == AS3525 && MEMORYSIZE > 2 && !defined(BOOTLOADER)) || /* AS3525 +2MB: core, plugins, codecs */ \
892 (CONFIG_CPU == AS3525 && MEMORYSIZE <= 2 && !defined(PLUGIN) && !defined(CODEC) && !defined(BOOTLOADER)) || /* AS3525 2MB: core only */ \
893 (CONFIG_CPU == AS3525v2 && !defined(PLUGIN) && !defined(CODEC) && !defined(BOOTLOADER)) || /* AS3525v2: core only */ \
894 (CONFIG_CPU == PNX0101) || \
895 (CONFIG_CPU == TCC7801) || \
896 (CONFIG_CPU == IMX233 && !defined(PLUGIN) && !defined(CODEC)) || /* IMX233: core only */ \
897 defined(CPU_S5L870X)) || /* Samsung S5L8700: core, plugins, codecs */ \
898 (CONFIG_CPU == JZ4732 && !defined(PLUGIN) && !defined(CODEC)) /* Jz4740: core only */
899 #define ICODE_ATTR __attribute__ ((section(".icode")))
900 #define ICONST_ATTR __attribute__ ((section(".irodata")))
901 #define IDATA_ATTR __attribute__ ((section(".idata")))
902 #define IBSS_ATTR __attribute__ ((section(".ibss")))
903 #define USE_IRAM
904 #if CONFIG_CPU != SH7034 && (CONFIG_CPU != AS3525 || MEMORYSIZE > 2) \
905 && CONFIG_CPU != JZ4732 && CONFIG_CPU != AS3525v2 && CONFIG_CPU != IMX233
906 #define PLUGIN_USE_IRAM
907 #endif
908 #if defined(CPU_ARM) && !defined(__ARM_EABI__)
909 /* GCC quirk workaround: arm-elf-gcc treats static functions as short_call
910 * when not compiling with -ffunction-sections, even when the function has
911 * a section attribute.
912 * This is fixed with eabi since all calls are short ones by default */
913 #define STATICIRAM
914 #else
915 #define STATICIRAM static
916 #endif
917 #else
918 #define ICODE_ATTR
919 #define ICONST_ATTR
920 #define IDATA_ATTR
921 #define IBSS_ATTR
922 #define STATICIRAM static
923 #endif
925 #if (defined(CPU_PP) || (CONFIG_CPU == AS3525) || (CONFIG_CPU == AS3525v2) || \
926 (CONFIG_CPU == IMX31L) || (CONFIG_CPU == IMX233)) \
927 && (CONFIG_PLATFORM & PLATFORM_NATIVE) && !defined(BOOTLOADER)
928 /* Functions that have INIT_ATTR attached are NOT guaranteed to survive after
929 * root_menu() has been called. Their code may be overwritten by other data or
930 * code in order to save RAM, and references to them might point into
931 * zombie area.
933 * It is critical that you make sure these functions are only called before
934 * the final call to root_menu() (see apps/main.c) is called (i.e. basically
935 * only while main() runs), otherwise things may go wild,
936 * from crashes to freezes to exploding daps.
938 #define INIT_ATTR __attribute__ ((section(".init")))
939 #define INITDATA_ATTR __attribute__ ((section(".initdata")))
940 #define HAVE_INIT_ATTR
941 #else
942 #define INIT_ATTR
943 #define INITDATA_ATTR
944 #endif
946 /* We need to call storage_init more than once only if USB storage mode is
947 * handled in hardware:
948 * Deinit storage -> let hardware handle USB mode -> storage_init() again
950 #if defined(HAVE_USBSTACK) || defined(USB_NONE)
951 #define STORAGE_INIT_ATTR INIT_ATTR
952 #else
953 #define STORAGE_INIT_ATTR
954 #endif
956 #if (CONFIG_PLATFORM & PLATFORM_HOSTED) && defined(__APPLE__)
957 #define DATA_ATTR __attribute__ ((section("__DATA, .data")))
958 #else
959 #define DATA_ATTR __attribute__ ((section(".data")))
960 #endif
962 #ifndef IRAM_LCDFRAMEBUFFER
963 /* if the LCD framebuffer has not been moved to IRAM, define it empty here */
964 #define IRAM_LCDFRAMEBUFFER
965 #endif
967 /* Change this if you want to build a single-core firmware for a multicore
968 * target for debugging */
969 #if defined(BOOTLOADER) || (CONFIG_CPU == PP6100)
970 #define FORCE_SINGLE_CORE
971 #endif
973 #if defined(CPU_PP)
974 #define IDLE_STACK_SIZE 0x80
975 #define IDLE_STACK_WORDS 0x20
977 /* Attributes to place data in uncached DRAM */
978 /* These are useful beyond dual-core and ultimately beyond PP since they may
979 * be used for DMA buffers and such without cache maintenence calls. */
980 #define NOCACHEBSS_ATTR __attribute__((section(".ncbss"),nocommon))
981 #define NOCACHEDATA_ATTR __attribute__((section(".ncdata"),nocommon))
983 #if !defined(FORCE_SINGLE_CORE)
985 #define NUM_CORES 2
986 #define HAVE_CORELOCK_OBJECT
987 #define CURRENT_CORE current_core()
988 /* Attributes for core-shared data in DRAM where IRAM is better used for other
989 * purposes. */
990 #define SHAREDBSS_ATTR NOCACHEBSS_ATTR
991 #define SHAREDDATA_ATTR NOCACHEDATA_ATTR
993 #define IF_COP(...) __VA_ARGS__
994 #define IF_COP_VOID(...) __VA_ARGS__
995 #define IF_COP_CORE(core) core
997 #endif /* !defined(FORCE_SINGLE_CORE) */
999 #endif /* CPU_PP */
1001 #if CONFIG_CPU == IMX31L || CONFIG_CPU == IMX233
1002 #define NOCACHEBSS_ATTR __attribute__((section(".ncbss"),nocommon))
1003 #define NOCACHEDATA_ATTR __attribute__((section(".ncdata"),nocommon))
1004 #endif
1006 #ifndef NUM_CORES
1007 /* Default to single core */
1008 #define NUM_CORES 1
1009 #define CURRENT_CORE CPU
1010 /* Attributes for core-shared data in DRAM - no caching considerations */
1011 #define SHAREDBSS_ATTR
1012 #define SHAREDDATA_ATTR
1013 #ifndef NOCACHEBSS_ATTR
1014 #define NOCACHEBSS_ATTR
1015 #define NOCACHEDATA_ATTR
1016 #endif
1018 #define IF_COP(...)
1019 #define IF_COP_VOID(...) void
1020 #define IF_COP_CORE(core) CURRENT_CORE
1022 #endif /* NUM_CORES */
1024 #ifdef HAVE_HEADPHONE_DETECTION
1025 /* Timeout objects required if headphone detection is enabled */
1026 #define INCLUDE_TIMEOUT_API
1027 #endif /* HAVE_HEADPHONE_DETECTION */
1029 #ifdef HAVE_TOUCHSCREEN
1030 /* Timeout objects required for kinetic list scrolling */
1031 #define INCLUDE_TIMEOUT_API
1032 /* Enable skin variable system, may not be the best place for this #define. */
1033 #define HAVE_SKIN_VARIABLES
1034 #endif /* HAVE_TOUCHSCREEN */
1036 #if defined(HAVE_USB_CHARGING_ENABLE) && defined(HAVE_USBSTACK)
1037 /* USB charging support in the USB stack requires timeout objects */
1038 #define INCLUDE_TIMEOUT_API
1039 #endif /* HAVE_USB_CHARGING_ENABLE && HAVE_USBSTACK */
1041 #if defined(HAVE_GUI_BOOST) && defined(HAVE_ADJUSTABLE_CPU_FREQ)
1042 /* Timeout objects required if GUI boost is enabled */
1043 #define INCLUDE_TIMEOUT_API
1044 #endif /* HAVE_GUI_BOOST && HAVE_ADJUSTABLE_CPU_FREQ */
1046 #if defined(HAVE_USBSTACK) || (CONFIG_STORAGE & STORAGE_NAND)
1047 #define STORAGE_GET_INFO
1048 #endif
1050 #ifdef CPU_MIPS
1051 #include <stdbool.h> /* MIPS GCC fix? */
1052 #endif
1054 #if defined(HAVE_USBSTACK)
1055 /* Define the implemented USB transport classes */
1056 #if CONFIG_USBOTG == USBOTG_ISP1583
1057 #define USB_HAS_BULK
1058 #elif (CONFIG_USBOTG == USBOTG_ARC) || \
1059 (CONFIG_USBOTG == USBOTG_JZ4740) || \
1060 (CONFIG_USBOTG == USBOTG_M66591) || \
1061 (CONFIG_USBOTG == USBOTG_AS3525)
1062 #define USB_HAS_BULK
1063 #define USB_HAS_INTERRUPT
1064 #elif defined(CPU_TCC780X) || defined(CPU_TCC77X)
1065 #define USB_HAS_BULK
1066 #elif CONFIG_USBOTG == USBOTG_S3C6400X
1067 #define USB_HAS_BULK
1068 //#define USB_HAS_INTERRUPT -- seems to be broken
1069 #endif /* CONFIG_USBOTG */
1071 #if (CONFIG_USBOTG == USBOTG_ARC) || \
1072 (CONFIG_USBOTG == USBOTG_AS3525)
1073 #define USB_HAS_ISOCHRONOUS
1074 #endif
1076 /* define the class drivers to enable */
1077 #ifdef BOOTLOADER
1079 /* enable usb storage for targets that do bootloader usb */
1080 #if defined(HAVE_BOOTLOADER_USB_MODE) || \
1081 defined(CREATIVE_ZVx) || defined(CPU_TCC77X) || defined(CPU_TCC780X) || \
1082 CONFIG_USBOTG == USBOTG_JZ4740 || CONFIG_USBOTG == USBOTG_AS3525 || \
1083 CONFIG_USBOTG == USBOTG_S3C6400X
1084 #define USB_ENABLE_STORAGE
1085 #endif
1087 #else /* BOOTLOADER */
1089 #if (CONFIG_PLATFORM & PLATFORM_NATIVE)
1090 #ifdef USB_HAS_BULK
1091 //#define USB_ENABLE_SERIAL
1092 #ifdef USE_ROCKBOX_USB
1093 #define USB_ENABLE_STORAGE
1094 #endif /* USE_ROCKBOX_USB */
1095 #endif /* USB_HAS_BULK */
1097 #ifdef USB_HAS_INTERRUPT
1098 #define USB_ENABLE_HID
1099 #else
1100 #define USB_ENABLE_CHARGING_ONLY
1101 #endif
1102 #endif
1104 #endif /* BOOTLOADER */
1106 #endif /* HAVE_USBSTACK */
1108 /* This attribute can be used to enable to detection of plugin file handles leaks.
1109 * When enabled, the plugin core will monitor open/close/creat and when the plugin exits
1110 * will display an error message if the plugin leaked some file handles */
1111 #if (CONFIG_PLATFORM & PLATFORM_NATIVE)
1112 #define HAVE_PLUGIN_CHECK_OPEN_CLOSE
1113 #endif
1115 #if defined(HAVE_DIRCACHE) && (CONFIG_PLATFORM & PLATFORM_NATIVE)
1116 #define HAVE_IO_PRIORITY
1117 #endif
1119 #if defined(CPU_COLDIRE) || CONFIG_CPU == IMX31L
1120 /* Can record and play simultaneously */
1121 #define HAVE_PCM_FULL_DUPLEX
1122 #endif
1124 #endif /* __CONFIG_H__ */