diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-09-21 11:03:13 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-09-21 11:03:13 -0400 |
commit | 59b69e27ca9f6c6347b1ec07066a9250140cb9e8 (patch) | |
tree | d8ea8948c92bdfc7f3bdfc03a7b789243ffbaaa8 /arch/arm/mach-u300/include | |
parent | 9c5e8fecc4a86adbf363f5cf344c0ccccdbb8982 (diff) | |
parent | ee2b805c8eb6459cf541ef141ff70dae17af59ca (diff) |
Merge branch 'u300' into devel
Diffstat (limited to 'arch/arm/mach-u300/include')
-rw-r--r-- | arch/arm/mach-u300/include/mach/syscon.h | 120 |
1 files changed, 113 insertions, 7 deletions
diff --git a/arch/arm/mach-u300/include/mach/syscon.h b/arch/arm/mach-u300/include/mach/syscon.h index 1c90d1b1ccb6..7444f5c7da97 100644 --- a/arch/arm/mach-u300/include/mach/syscon.h +++ b/arch/arm/mach-u300/include/mach/syscon.h | |||
@@ -240,8 +240,13 @@ | |||
240 | #define U300_SYSCON_PMC1LR_CDI_MASK (0xC000) | 240 | #define U300_SYSCON_PMC1LR_CDI_MASK (0xC000) |
241 | #define U300_SYSCON_PMC1LR_CDI_CDI (0x0000) | 241 | #define U300_SYSCON_PMC1LR_CDI_CDI (0x0000) |
242 | #define U300_SYSCON_PMC1LR_CDI_EMIF (0x4000) | 242 | #define U300_SYSCON_PMC1LR_CDI_EMIF (0x4000) |
243 | #ifdef CONFIG_MACH_U300_BS335 | ||
244 | #define U300_SYSCON_PMC1LR_CDI_CDI2 (0x8000) | ||
245 | #define U300_SYSCON_PMC1LR_CDI_WCDMA_APP_GPIO (0xC000) | ||
246 | #elif CONFIG_MACH_U300_BS365 | ||
243 | #define U300_SYSCON_PMC1LR_CDI_GPIO (0x8000) | 247 | #define U300_SYSCON_PMC1LR_CDI_GPIO (0x8000) |
244 | #define U300_SYSCON_PMC1LR_CDI_WCDMA (0xC000) | 248 | #define U300_SYSCON_PMC1LR_CDI_WCDMA (0xC000) |
249 | #endif | ||
245 | #define U300_SYSCON_PMC1LR_PDI_MASK (0x3000) | 250 | #define U300_SYSCON_PMC1LR_PDI_MASK (0x3000) |
246 | #define U300_SYSCON_PMC1LR_PDI_PDI (0x0000) | 251 | #define U300_SYSCON_PMC1LR_PDI_PDI (0x0000) |
247 | #define U300_SYSCON_PMC1LR_PDI_EGG (0x1000) | 252 | #define U300_SYSCON_PMC1LR_PDI_EGG (0x1000) |
@@ -345,19 +350,69 @@ | |||
345 | #define U300_SYSCON_MMCR_MASK (0x0003) | 350 | #define U300_SYSCON_MMCR_MASK (0x0003) |
346 | #define U300_SYSCON_MMCR_MMC_FB_CLK_SEL_ENABLE (0x0002) | 351 | #define U300_SYSCON_MMCR_MMC_FB_CLK_SEL_ENABLE (0x0002) |
347 | #define U300_SYSCON_MMCR_MSPRO_FREQSEL_ENABLE (0x0001) | 352 | #define U300_SYSCON_MMCR_MSPRO_FREQSEL_ENABLE (0x0001) |
348 | 353 | /* Pull up/down control (R/W) */ | |
354 | #define U300_SYSCON_PUCR (0x104) | ||
355 | #define U300_SYSCON_PUCR_EMIF_1_WAIT_N_PU_ENABLE (0x0200) | ||
356 | #define U300_SYSCON_PUCR_EMIF_1_NFIF_READY_PU_ENABLE (0x0100) | ||
357 | #define U300_SYSCON_PUCR_EMIF_1_16BIT_PU_ENABLE (0x0080) | ||
358 | #define U300_SYSCON_PUCR_EMIF_1_8BIT_PU_ENABLE (0x0040) | ||
359 | #define U300_SYSCON_PUCR_KEY_IN_PU_EN_MASK (0x003F) | ||
360 | /* Padmux 2 control */ | ||
361 | #define U300_SYSCON_PMC2R (0x100) | ||
362 | #define U300_SYSCON_PMC2R_APP_MISC_0_MASK (0x00C0) | ||
363 | #define U300_SYSCON_PMC2R_APP_MISC_0_APP_GPIO (0x0000) | ||
364 | #define U300_SYSCON_PMC2R_APP_MISC_0_EMIF_SDRAM (0x0040) | ||
365 | #define U300_SYSCON_PMC2R_APP_MISC_0_MMC (0x0080) | ||
366 | #define U300_SYSCON_PMC2R_APP_MISC_0_CDI2 (0x00C0) | ||
367 | #define U300_SYSCON_PMC2R_APP_MISC_1_MASK (0x0300) | ||
368 | #define U300_SYSCON_PMC2R_APP_MISC_1_APP_GPIO (0x0000) | ||
369 | #define U300_SYSCON_PMC2R_APP_MISC_1_EMIF_SDRAM (0x0100) | ||
370 | #define U300_SYSCON_PMC2R_APP_MISC_1_MMC (0x0200) | ||
371 | #define U300_SYSCON_PMC2R_APP_MISC_1_CDI2 (0x0300) | ||
372 | #define U300_SYSCON_PMC2R_APP_MISC_2_MASK (0x0C00) | ||
373 | #define U300_SYSCON_PMC2R_APP_MISC_2_APP_GPIO (0x0000) | ||
374 | #define U300_SYSCON_PMC2R_APP_MISC_2_EMIF_SDRAM (0x0400) | ||
375 | #define U300_SYSCON_PMC2R_APP_MISC_2_MMC (0x0800) | ||
376 | #define U300_SYSCON_PMC2R_APP_MISC_2_CDI2 (0x0C00) | ||
377 | #define U300_SYSCON_PMC2R_APP_MISC_3_MASK (0x3000) | ||
378 | #define U300_SYSCON_PMC2R_APP_MISC_3_APP_GPIO (0x0000) | ||
379 | #define U300_SYSCON_PMC2R_APP_MISC_3_EMIF_SDRAM (0x1000) | ||
380 | #define U300_SYSCON_PMC2R_APP_MISC_3_MMC (0x2000) | ||
381 | #define U300_SYSCON_PMC2R_APP_MISC_3_CDI2 (0x3000) | ||
382 | #define U300_SYSCON_PMC2R_APP_MISC_4_MASK (0xC000) | ||
383 | #define U300_SYSCON_PMC2R_APP_MISC_4_APP_GPIO (0x0000) | ||
384 | #define U300_SYSCON_PMC2R_APP_MISC_4_EMIF_SDRAM (0x4000) | ||
385 | #define U300_SYSCON_PMC2R_APP_MISC_4_MMC (0x8000) | ||
386 | #define U300_SYSCON_PMC2R_APP_MISC_4_ACC_GPIO (0xC000) | ||
349 | /* TODO: More SYSCON registers missing */ | 387 | /* TODO: More SYSCON registers missing */ |
350 | #define U300_SYSCON_PMC3R (0x10c) | 388 | #define U300_SYSCON_PMC3R (0x10c) |
351 | #define U300_SYSCON_PMC3R_APP_MISC_11_MASK (0xc000) | 389 | #define U300_SYSCON_PMC3R_APP_MISC_11_MASK (0xc000) |
352 | #define U300_SYSCON_PMC3R_APP_MISC_11_SPI (0x4000) | 390 | #define U300_SYSCON_PMC3R_APP_MISC_11_SPI (0x4000) |
353 | #define U300_SYSCON_PMC3R_APP_MISC_10_MASK (0x3000) | 391 | #define U300_SYSCON_PMC3R_APP_MISC_10_MASK (0x3000) |
354 | #define U300_SYSCON_PMC3R_APP_MISC_10_SPI (0x1000) | 392 | #define U300_SYSCON_PMC3R_APP_MISC_10_SPI (0x1000) |
355 | /* TODO: Missing other configs, I just added the SPI stuff */ | 393 | /* TODO: Missing other configs */ |
356 | 394 | #define U300_SYSCON_PMC4R (0x168) | |
395 | #define U300_SYSCON_PMC4R_APP_MISC_12_MASK (0x0003) | ||
396 | #define U300_SYSCON_PMC4R_APP_MISC_12_APP_GPIO (0x0000) | ||
397 | #define U300_SYSCON_PMC4R_APP_MISC_13_MASK (0x000C) | ||
398 | #define U300_SYSCON_PMC4R_APP_MISC_13_CDI (0x0000) | ||
399 | #define U300_SYSCON_PMC4R_APP_MISC_13_SMIA (0x0004) | ||
400 | #define U300_SYSCON_PMC4R_APP_MISC_13_SMIA2 (0x0008) | ||
401 | #define U300_SYSCON_PMC4R_APP_MISC_13_APP_GPIO (0x000C) | ||
402 | #define U300_SYSCON_PMC4R_APP_MISC_14_MASK (0x0030) | ||
403 | #define U300_SYSCON_PMC4R_APP_MISC_14_CDI (0x0000) | ||
404 | #define U300_SYSCON_PMC4R_APP_MISC_14_SMIA (0x0010) | ||
405 | #define U300_SYSCON_PMC4R_APP_MISC_14_CDI2 (0x0020) | ||
406 | #define U300_SYSCON_PMC4R_APP_MISC_14_APP_GPIO (0x0030) | ||
407 | #define U300_SYSCON_PMC4R_APP_MISC_16_MASK (0x0300) | ||
408 | #define U300_SYSCON_PMC4R_APP_MISC_16_APP_GPIO_13 (0x0000) | ||
409 | #define U300_SYSCON_PMC4R_APP_MISC_16_APP_UART1_CTS (0x0100) | ||
410 | #define U300_SYSCON_PMC4R_APP_MISC_16_EMIF_1_STATIC_CS5_N (0x0200) | ||
357 | /* SYS_0_CLK_CONTROL first clock control 16bit (R/W) */ | 411 | /* SYS_0_CLK_CONTROL first clock control 16bit (R/W) */ |
358 | #define U300_SYSCON_S0CCR (0x120) | 412 | #define U300_SYSCON_S0CCR (0x120) |
359 | #define U300_SYSCON_S0CCR_FIELD_MASK (0x43FF) | 413 | #define U300_SYSCON_S0CCR_FIELD_MASK (0x43FF) |
360 | #define U300_SYSCON_S0CCR_CLOCK_REQ (0x4000) | 414 | #define U300_SYSCON_S0CCR_CLOCK_REQ (0x4000) |
415 | #define U300_SYSCON_S0CCR_CLOCK_REQ_MONITOR (0x2000) | ||
361 | #define U300_SYSCON_S0CCR_CLOCK_INV (0x0200) | 416 | #define U300_SYSCON_S0CCR_CLOCK_INV (0x0200) |
362 | #define U300_SYSCON_S0CCR_CLOCK_FREQ_MASK (0x01E0) | 417 | #define U300_SYSCON_S0CCR_CLOCK_FREQ_MASK (0x01E0) |
363 | #define U300_SYSCON_S0CCR_CLOCK_SELECT_MASK (0x001E) | 418 | #define U300_SYSCON_S0CCR_CLOCK_SELECT_MASK (0x001E) |
@@ -375,6 +430,7 @@ | |||
375 | #define U300_SYSCON_S1CCR (0x124) | 430 | #define U300_SYSCON_S1CCR (0x124) |
376 | #define U300_SYSCON_S1CCR_FIELD_MASK (0x43FF) | 431 | #define U300_SYSCON_S1CCR_FIELD_MASK (0x43FF) |
377 | #define U300_SYSCON_S1CCR_CLOCK_REQ (0x4000) | 432 | #define U300_SYSCON_S1CCR_CLOCK_REQ (0x4000) |
433 | #define U300_SYSCON_S1CCR_CLOCK_REQ_MONITOR (0x2000) | ||
378 | #define U300_SYSCON_S1CCR_CLOCK_INV (0x0200) | 434 | #define U300_SYSCON_S1CCR_CLOCK_INV (0x0200) |
379 | #define U300_SYSCON_S1CCR_CLOCK_FREQ_MASK (0x01E0) | 435 | #define U300_SYSCON_S1CCR_CLOCK_FREQ_MASK (0x01E0) |
380 | #define U300_SYSCON_S1CCR_CLOCK_SELECT_MASK (0x001E) | 436 | #define U300_SYSCON_S1CCR_CLOCK_SELECT_MASK (0x001E) |
@@ -393,6 +449,7 @@ | |||
393 | #define U300_SYSCON_S2CCR_FIELD_MASK (0xC3FF) | 449 | #define U300_SYSCON_S2CCR_FIELD_MASK (0xC3FF) |
394 | #define U300_SYSCON_S2CCR_CLK_STEAL (0x8000) | 450 | #define U300_SYSCON_S2CCR_CLK_STEAL (0x8000) |
395 | #define U300_SYSCON_S2CCR_CLOCK_REQ (0x4000) | 451 | #define U300_SYSCON_S2CCR_CLOCK_REQ (0x4000) |
452 | #define U300_SYSCON_S2CCR_CLOCK_REQ_MONITOR (0x2000) | ||
396 | #define U300_SYSCON_S2CCR_CLOCK_INV (0x0200) | 453 | #define U300_SYSCON_S2CCR_CLOCK_INV (0x0200) |
397 | #define U300_SYSCON_S2CCR_CLOCK_FREQ_MASK (0x01E0) | 454 | #define U300_SYSCON_S2CCR_CLOCK_FREQ_MASK (0x01E0) |
398 | #define U300_SYSCON_S2CCR_CLOCK_SELECT_MASK (0x001E) | 455 | #define U300_SYSCON_S2CCR_CLOCK_SELECT_MASK (0x001E) |
@@ -425,6 +482,44 @@ | |||
425 | #define U300_SYSCON_MCR_PMGEN_CR_0_EMIF_0_SDRAM (0x000C) | 482 | #define U300_SYSCON_MCR_PMGEN_CR_0_EMIF_0_SDRAM (0x000C) |
426 | #define U300_SYSCON_MCR_PM1G_MODE_ENABLE (0x0002) | 483 | #define U300_SYSCON_MCR_PM1G_MODE_ENABLE (0x0002) |
427 | #define U300_SYSCON_MCR_PMTG5_MODE_ENABLE (0x0001) | 484 | #define U300_SYSCON_MCR_PMTG5_MODE_ENABLE (0x0001) |
485 | /* SC_PLL_IRQ_CONTROL 16bit (R/W) */ | ||
486 | #define U300_SYSCON_PICR (0x0130) | ||
487 | #define U300_SYSCON_PICR_MASK (0x00FF) | ||
488 | #define U300_SYSCON_PICR_FORCE_PLL208_LOCK_LOW_ENABLE (0x0080) | ||
489 | #define U300_SYSCON_PICR_FORCE_PLL208_LOCK_HIGH_ENABLE (0x0040) | ||
490 | #define U300_SYSCON_PICR_FORCE_PLL13_LOCK_LOW_ENABLE (0x0020) | ||
491 | #define U300_SYSCON_PICR_FORCE_PLL13_LOCK_HIGH_ENABLE (0x0010) | ||
492 | #define U300_SYSCON_PICR_IRQMASK_PLL13_UNLOCK_ENABLE (0x0008) | ||
493 | #define U300_SYSCON_PICR_IRQMASK_PLL13_LOCK_ENABLE (0x0004) | ||
494 | #define U300_SYSCON_PICR_IRQMASK_PLL208_UNLOCK_ENABLE (0x0002) | ||
495 | #define U300_SYSCON_PICR_IRQMASK_PLL208_LOCK_ENABLE (0x0001) | ||
496 | /* SC_PLL_IRQ_STATUS 16 bit (R/-) */ | ||
497 | #define U300_SYSCON_PISR (0x0134) | ||
498 | #define U300_SYSCON_PISR_MASK (0x000F) | ||
499 | #define U300_SYSCON_PISR_PLL13_UNLOCK_IND (0x0008) | ||
500 | #define U300_SYSCON_PISR_PLL13_LOCK_IND (0x0004) | ||
501 | #define U300_SYSCON_PISR_PLL208_UNLOCK_IND (0x0002) | ||
502 | #define U300_SYSCON_PISR_PLL208_LOCK_IND (0x0001) | ||
503 | /* SC_PLL_IRQ_CLEAR 16 bit (-/W) */ | ||
504 | #define U300_SYSCON_PICLR (0x0138) | ||
505 | #define U300_SYSCON_PICLR_MASK (0x000F) | ||
506 | #define U300_SYSCON_PICLR_RWMASK (0x0000) | ||
507 | #define U300_SYSCON_PICLR_PLL13_UNLOCK_SC (0x0008) | ||
508 | #define U300_SYSCON_PICLR_PLL13_LOCK_SC (0x0004) | ||
509 | #define U300_SYSCON_PICLR_PLL208_UNLOCK_SC (0x0002) | ||
510 | #define U300_SYSCON_PICLR_PLL208_LOCK_SC (0x0001) | ||
511 | /* CAMIF_CONTROL 16 bit (-/W) */ | ||
512 | #define U300_SYSCON_CICR (0x013C) | ||
513 | #define U300_SYSCON_CICR_MASK (0x0FFF) | ||
514 | #define U300_SYSCON_CICR_APP_SUBLVDS_TESTMODE_MASK (0x0F00) | ||
515 | #define U300_SYSCON_CICR_APP_SUBLVDS_TESTMODE_PORT1 (0x0C00) | ||
516 | #define U300_SYSCON_CICR_APP_SUBLVDS_TESTMODE_PORT0 (0x0300) | ||
517 | #define U300_SYSCON_CICR_APP_SUBLVDS_RESCON_MASK (0x00F0) | ||
518 | #define U300_SYSCON_CICR_APP_SUBLVDS_RESCON_PORT1 (0x00C0) | ||
519 | #define U300_SYSCON_CICR_APP_SUBLVDS_RESCON_PORT0 (0x0030) | ||
520 | #define U300_SYSCON_CICR_APP_SUBLVDS_PWR_DWN_N_MASK (0x000F) | ||
521 | #define U300_SYSCON_CICR_APP_SUBLVDS_PWR_DWN_N_PORT1 (0x000C) | ||
522 | #define U300_SYSCON_CICR_APP_SUBLVDS_PWR_DWN_N_PORT0 (0x0003) | ||
428 | /* Clock activity observability register 0 */ | 523 | /* Clock activity observability register 0 */ |
429 | #define U300_SYSCON_C0OAR (0x140) | 524 | #define U300_SYSCON_C0OAR (0x140) |
430 | #define U300_SYSCON_C0OAR_MASK (0xFFFF) | 525 | #define U300_SYSCON_C0OAR_MASK (0xFFFF) |
@@ -513,7 +608,7 @@ | |||
513 | /** | 608 | /** |
514 | * CPU medium frequency in MHz | 609 | * CPU medium frequency in MHz |
515 | */ | 610 | */ |
516 | #define SYSCON_CPU_CLOCK_MEDIUM 104 | 611 | #define SYSCON_CPU_CLOCK_MEDIUM 52 |
517 | /** | 612 | /** |
518 | * CPU low frequency in MHz | 613 | * CPU low frequency in MHz |
519 | */ | 614 | */ |
@@ -527,7 +622,7 @@ | |||
527 | /** | 622 | /** |
528 | * EMIF medium frequency in MHz | 623 | * EMIF medium frequency in MHz |
529 | */ | 624 | */ |
530 | #define SYSCON_EMIF_CLOCK_MEDIUM 104 | 625 | #define SYSCON_EMIF_CLOCK_MEDIUM 52 |
531 | /** | 626 | /** |
532 | * EMIF low frequency in MHz | 627 | * EMIF low frequency in MHz |
533 | */ | 628 | */ |
@@ -541,7 +636,7 @@ | |||
541 | /** | 636 | /** |
542 | * AHB medium frequency in MHz | 637 | * AHB medium frequency in MHz |
543 | */ | 638 | */ |
544 | #define SYSCON_AHB_CLOCK_MEDIUM 52 | 639 | #define SYSCON_AHB_CLOCK_MEDIUM 26 |
545 | /** | 640 | /** |
546 | * AHB low frequency in MHz | 641 | * AHB low frequency in MHz |
547 | */ | 642 | */ |
@@ -553,6 +648,15 @@ enum syscon_busmaster { | |||
553 | SYSCON_BM_VIDEO_ENC | 648 | SYSCON_BM_VIDEO_ENC |
554 | }; | 649 | }; |
555 | 650 | ||
651 | /* Selectr a resistor or a set of resistors */ | ||
652 | enum syscon_pull_up_down { | ||
653 | SYSCON_PU_KEY_IN_EN, | ||
654 | SYSCON_PU_EMIF_1_8_BIT_EN, | ||
655 | SYSCON_PU_EMIF_1_16_BIT_EN, | ||
656 | SYSCON_PU_EMIF_1_NFIF_READY_EN, | ||
657 | SYSCON_PU_EMIF_1_NFIF_WAIT_N_EN, | ||
658 | }; | ||
659 | |||
556 | /* | 660 | /* |
557 | * Note that this array must match the order of the array "clk_reg" | 661 | * Note that this array must match the order of the array "clk_reg" |
558 | * in syscon.c | 662 | * in syscon.c |
@@ -575,6 +679,7 @@ enum syscon_clk { | |||
575 | SYSCON_CLKCONTROL_SPI, | 679 | SYSCON_CLKCONTROL_SPI, |
576 | SYSCON_CLKCONTROL_I2S0_CORE, | 680 | SYSCON_CLKCONTROL_I2S0_CORE, |
577 | SYSCON_CLKCONTROL_I2S1_CORE, | 681 | SYSCON_CLKCONTROL_I2S1_CORE, |
682 | SYSCON_CLKCONTROL_UART1, | ||
578 | SYSCON_CLKCONTROL_AAIF, | 683 | SYSCON_CLKCONTROL_AAIF, |
579 | SYSCON_CLKCONTROL_AHB, | 684 | SYSCON_CLKCONTROL_AHB, |
580 | SYSCON_CLKCONTROL_APEX, | 685 | SYSCON_CLKCONTROL_APEX, |
@@ -604,7 +709,8 @@ enum syscon_sysclk_mode { | |||
604 | 709 | ||
605 | enum syscon_sysclk_req { | 710 | enum syscon_sysclk_req { |
606 | SYSCON_SYSCLKREQ_DISABLED, | 711 | SYSCON_SYSCLKREQ_DISABLED, |
607 | SYSCON_SYSCLKREQ_ACTIVE_LOW | 712 | SYSCON_SYSCLKREQ_ACTIVE_LOW, |
713 | SYSCON_SYSCLKREQ_MONITOR | ||
608 | }; | 714 | }; |
609 | 715 | ||
610 | enum syscon_clk_mode { | 716 | enum syscon_clk_mode { |