Merge branch 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm

* 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm: (44 commits)
[ARM] 3541/2: workaround for PXA27x erratum E7
[ARM] nommu: provide a way for correct control register value selection
[ARM] 3705/1: add supersection support to ioremap()
[ARM] 3707/1: iwmmxt: use the generic thread notifier infrastructure
[ARM] 3706/2: ep93xx: add cirrus logic edb9315a support
[ARM] 3704/1: format IOP Kconfig with tabs, create more consistency
[ARM] 3703/1: Add help description for ARCH_EP80219
[ARM] 3678/1: MMC: Make OMAP MMC work
[ARM] 3677/1: OMAP: Update H2 defconfig
[ARM] 3676/1: ARM: OMAP: Fix dmtimers and timer32k to compile on OMAP1
[ARM] Add section support to ioremap
[ARM] Fix sa11x0 SDRAM selection
[ARM] Set bit 4 on section mappings correctly depending on CPU
[ARM] 3666/1: TRIZEPS4 [1/5] core
ARM: OMAP: Multiplexing for 24xx GPMC wait pin monitoring
ARM: OMAP: Fix SRAM to use MT_MEMORY instead of MT_DEVICE
ARM: OMAP: Update dmtimers
ARM: OMAP: Make clock variables static
ARM: OMAP: Fix GPMC compilation when DEBUG is defined
ARM: OMAP: Mux updates for external DMA and GPIO
...

+5705 -951
+6 -6
arch/arm/Kconfig
··· 121 121 help 122 122 This enables support for ARM Ltd Versatile board. 123 123 124 - config ARCH_AT91RM9200 125 - bool "Atmel AT91RM9200" 124 + config ARCH_AT91 125 + bool "Atmel AT91" 126 126 help 127 - Say Y here if you intend to run this kernel on an Atmel 128 - AT91RM9200-based board. 127 + This enables support for systems based on the Atmel AT91RM9200 128 + and AT91SAM9xxx processors. 129 129 130 130 config ARCH_CLPS7500 131 131 bool "Cirrus CL-PS7500FE" ··· 547 547 ARCH_LUBBOCK || MACH_MAINSTONE || ARCH_NETWINDER || \ 548 548 ARCH_OMAP || ARCH_P720T || ARCH_PXA_IDP || \ 549 549 ARCH_SA1100 || ARCH_SHARK || ARCH_VERSATILE || \ 550 - ARCH_AT91RM9200 550 + ARCH_AT91RM9200 || MACH_TRIZEPS4 551 551 help 552 552 If you say Y here, the LEDs on your machine will be used 553 553 to provide useful information about your current system status. ··· 678 678 679 679 endmenu 680 680 681 - if (ARCH_SA1100 || ARCH_INTEGRATOR || ARCH_OMAP1) 681 + if (ARCH_SA1100 || ARCH_INTEGRATOR || ARCH_OMAP) 682 682 683 683 menu "CPU Frequency scaling" 684 684
+1 -1
arch/arm/Makefile
··· 114 114 machine-$(CONFIG_ARCH_H720X) := h720x 115 115 machine-$(CONFIG_ARCH_AAEC2000) := aaec2000 116 116 machine-$(CONFIG_ARCH_REALVIEW) := realview 117 - machine-$(CONFIG_ARCH_AT91RM9200) := at91rm9200 117 + machine-$(CONFIG_ARCH_AT91) := at91rm9200 118 118 machine-$(CONFIG_ARCH_EP93XX) := ep93xx 119 119 machine-$(CONFIG_ARCH_PNX4008) := pnx4008 120 120 machine-$(CONFIG_ARCH_NETX) := netx
+5 -2
arch/arm/boot/compressed/head.S
··· 447 447 mov r1, #-1 448 448 mcr p15, 0, r3, c2, c0, 0 @ load page table pointer 449 449 mcr p15, 0, r1, c3, c0, 0 @ load domain access control 450 - mcr p15, 0, r0, c1, c0, 0 @ load control register 451 - mov pc, lr 450 + b 1f 451 + .align 5 @ cache line aligned 452 + 1: mcr p15, 0, r0, c1, c0, 0 @ load control register 453 + mrc p15, 0, r0, c1, c0, 0 @ and read it back to 454 + sub pc, lr, r0, lsr #32 @ properly flush pipeline 452 455 453 456 /* 454 457 * All code following this line is relocatable. It is relocated by
+1
arch/arm/configs/at91rm9200dk_defconfig
··· 103 103 # CONFIG_ARCH_IMX is not set 104 104 # CONFIG_ARCH_H720X is not set 105 105 # CONFIG_ARCH_AAEC2000 is not set 106 + CONFIG_ARCH_AT91=y 106 107 CONFIG_ARCH_AT91RM9200=y 107 108 108 109 #
+1
arch/arm/configs/at91rm9200ek_defconfig
··· 103 103 # CONFIG_ARCH_IMX is not set 104 104 # CONFIG_ARCH_H720X is not set 105 105 # CONFIG_ARCH_AAEC2000 is not set 106 + CONFIG_ARCH_AT91=y 106 107 CONFIG_ARCH_AT91RM9200=y 107 108 108 109 #
+1
arch/arm/configs/ateb9200_defconfig
··· 105 105 # CONFIG_ARCH_IMX is not set 106 106 # CONFIG_ARCH_H720X is not set 107 107 # CONFIG_ARCH_AAEC2000 is not set 108 + CONFIG_ARCH_AT91=y 108 109 CONFIG_ARCH_AT91RM9200=y 109 110 110 111 #
+1
arch/arm/configs/carmeva_defconfig
··· 82 82 # CONFIG_ARCH_VERSATILE is not set 83 83 # CONFIG_ARCH_IMX is not set 84 84 # CONFIG_ARCH_H720X is not set 85 + CONFIG_ARCH_AT91=y 85 86 CONFIG_ARCH_AT91RM9200=y 86 87 87 88 #
+1
arch/arm/configs/csb337_defconfig
··· 103 103 # CONFIG_ARCH_IMX is not set 104 104 # CONFIG_ARCH_H720X is not set 105 105 # CONFIG_ARCH_AAEC2000 is not set 106 + CONFIG_ARCH_AT91=y 106 107 CONFIG_ARCH_AT91RM9200=y 107 108 108 109 #
+1
arch/arm/configs/csb637_defconfig
··· 103 103 # CONFIG_ARCH_IMX is not set 104 104 # CONFIG_ARCH_H720X is not set 105 105 # CONFIG_ARCH_AAEC2000 is not set 106 + CONFIG_ARCH_AT91=y 106 107 CONFIG_ARCH_AT91RM9200=y 107 108 108 109 #
+1
arch/arm/configs/kafa_defconfig
··· 105 105 # CONFIG_ARCH_IMX is not set 106 106 # CONFIG_ARCH_H720X is not set 107 107 # CONFIG_ARCH_AAEC2000 is not set 108 + CONFIG_ARCH_AT91=y 108 109 CONFIG_ARCH_AT91RM9200=y 109 110 110 111 #
+1
arch/arm/configs/kb9202_defconfig
··· 80 80 # CONFIG_ARCH_IMX is not set 81 81 # CONFIG_ARCH_H720X is not set 82 82 # CONFIG_ARCH_AAEC2000 is not set 83 + CONFIG_ARCH_AT91=y 83 84 CONFIG_ARCH_AT91RM9200=y 84 85 85 86 #
+91 -38
arch/arm/configs/omap_h2_1610_defconfig
··· 1 1 # 2 2 # Automatically generated make config: don't edit 3 - # Linux kernel version: 2.6.14 4 - # Wed Nov 9 18:53:40 2005 3 + # Linux kernel version: 2.6.17 4 + # Thu Jun 29 15:25:18 2006 5 5 # 6 6 CONFIG_ARM=y 7 7 CONFIG_MMU=y 8 - CONFIG_UID16=y 9 8 CONFIG_RWSEM_GENERIC_SPINLOCK=y 9 + CONFIG_GENERIC_HWEIGHT=y 10 10 CONFIG_GENERIC_CALIBRATE_DELAY=y 11 + CONFIG_VECTORS_BASE=0xffff0000 12 + CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" 11 13 12 14 # 13 15 # Code maturity level options 14 16 # 15 17 CONFIG_EXPERIMENTAL=y 16 - CONFIG_CLEAN_COMPILE=y 17 18 CONFIG_BROKEN_ON_SMP=y 18 19 CONFIG_LOCK_KERNEL=y 19 20 CONFIG_INIT_ENV_ARG_LIMIT=32 ··· 30 29 # CONFIG_BSD_PROCESS_ACCT is not set 31 30 CONFIG_SYSCTL=y 32 31 # CONFIG_AUDIT is not set 33 - # CONFIG_HOTPLUG is not set 34 - CONFIG_KOBJECT_UEVENT=y 35 32 # CONFIG_IKCONFIG is not set 33 + # CONFIG_RELAY is not set 36 34 CONFIG_INITRAMFS_SOURCE="" 35 + CONFIG_UID16=y 36 + CONFIG_CC_OPTIMIZE_FOR_SIZE=y 37 37 # CONFIG_EMBEDDED is not set 38 38 CONFIG_KALLSYMS=y 39 39 # CONFIG_KALLSYMS_EXTRA_PASS is not set 40 + CONFIG_HOTPLUG=y 40 41 CONFIG_PRINTK=y 41 42 CONFIG_BUG=y 43 + CONFIG_ELF_CORE=y 42 44 CONFIG_BASE_FULL=y 43 45 CONFIG_FUTEX=y 44 46 CONFIG_EPOLL=y 45 - CONFIG_CC_OPTIMIZE_FOR_SIZE=y 46 47 CONFIG_SHMEM=y 47 - CONFIG_CC_ALIGN_FUNCTIONS=0 48 - CONFIG_CC_ALIGN_LABELS=0 49 - CONFIG_CC_ALIGN_LOOPS=0 50 - CONFIG_CC_ALIGN_JUMPS=0 48 + CONFIG_SLAB=y 51 49 # CONFIG_TINY_SHMEM is not set 52 50 CONFIG_BASE_SMALL=0 51 + # CONFIG_SLOB is not set 53 52 54 53 # 55 54 # Loadable module support ··· 57 56 CONFIG_MODULES=y 58 57 CONFIG_MODULE_UNLOAD=y 59 58 # CONFIG_MODULE_FORCE_UNLOAD is not set 60 - CONFIG_OBSOLETE_MODPARM=y 61 59 # CONFIG_MODVERSIONS is not set 62 60 # CONFIG_MODULE_SRCVERSION_ALL is not set 63 61 # CONFIG_KMOD is not set ··· 64 64 # 65 65 # Block layer 66 66 # 67 + # CONFIG_BLK_DEV_IO_TRACE is not set 67 68 68 69 # 69 70 # IO Schedulers ··· 82 81 # 83 82 # System Type 84 83 # 84 + # CONFIG_ARCH_AAEC2000 is not set 85 + # CONFIG_ARCH_INTEGRATOR is not set 86 + # CONFIG_ARCH_REALVIEW is not set 87 + # CONFIG_ARCH_VERSATILE is not set 88 + # CONFIG_ARCH_AT91RM9200 is not set 85 89 # CONFIG_ARCH_CLPS7500 is not set 86 90 # CONFIG_ARCH_CLPS711X is not set 87 91 # CONFIG_ARCH_CO285 is not set 88 92 # CONFIG_ARCH_EBSA110 is not set 93 + # CONFIG_ARCH_EP93XX is not set 89 94 # CONFIG_ARCH_FOOTBRIDGE is not set 90 - # CONFIG_ARCH_INTEGRATOR is not set 95 + # CONFIG_ARCH_NETX is not set 96 + # CONFIG_ARCH_H720X is not set 97 + # CONFIG_ARCH_IMX is not set 91 98 # CONFIG_ARCH_IOP3XX is not set 92 99 # CONFIG_ARCH_IXP4XX is not set 93 100 # CONFIG_ARCH_IXP2000 is not set 101 + # CONFIG_ARCH_IXP23XX is not set 94 102 # CONFIG_ARCH_L7200 is not set 103 + # CONFIG_ARCH_PNX4008 is not set 95 104 # CONFIG_ARCH_PXA is not set 96 105 # CONFIG_ARCH_RPC is not set 97 106 # CONFIG_ARCH_SA1100 is not set ··· 109 98 # CONFIG_ARCH_SHARK is not set 110 99 # CONFIG_ARCH_LH7A40X is not set 111 100 CONFIG_ARCH_OMAP=y 112 - # CONFIG_ARCH_VERSATILE is not set 113 - # CONFIG_ARCH_REALVIEW is not set 114 - # CONFIG_ARCH_IMX is not set 115 - # CONFIG_ARCH_H720X is not set 116 - # CONFIG_ARCH_AAEC2000 is not set 117 101 118 102 # 119 103 # TI OMAP Implementations ··· 147 141 CONFIG_MACH_OMAP_H2=y 148 142 # CONFIG_MACH_OMAP_H3 is not set 149 143 # CONFIG_MACH_OMAP_OSK is not set 144 + # CONFIG_MACH_NOKIA770 is not set 150 145 # CONFIG_MACH_OMAP_GENERIC is not set 151 146 152 147 # ··· 184 177 # 185 178 # Bus support 186 179 # 187 - CONFIG_ISA_DMA_API=y 188 180 189 181 # 190 182 # PCCARD (PCMCIA/CardBus) support ··· 195 189 # 196 190 CONFIG_PREEMPT=y 197 191 CONFIG_NO_IDLE_HZ=y 192 + CONFIG_HZ=128 193 + # CONFIG_AEABI is not set 198 194 # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set 199 195 CONFIG_SELECT_MEMORY_MODEL=y 200 196 CONFIG_FLATMEM_MANUAL=y ··· 257 249 # Power management options 258 250 # 259 251 CONFIG_PM=y 252 + CONFIG_PM_LEGACY=y 253 + # CONFIG_PM_DEBUG is not set 260 254 # CONFIG_APM is not set 261 255 262 256 # ··· 269 259 # 270 260 # Networking options 271 261 # 262 + # CONFIG_NETDEBUG is not set 272 263 CONFIG_PACKET=y 273 264 # CONFIG_PACKET_MMAP is not set 274 265 CONFIG_UNIX=y 266 + CONFIG_XFRM=y 267 + # CONFIG_XFRM_USER is not set 275 268 # CONFIG_NET_KEY is not set 276 269 CONFIG_INET=y 277 270 # CONFIG_IP_MULTICAST is not set ··· 291 278 # CONFIG_INET_AH is not set 292 279 # CONFIG_INET_ESP is not set 293 280 # CONFIG_INET_IPCOMP is not set 281 + # CONFIG_INET_XFRM_TUNNEL is not set 294 282 # CONFIG_INET_TUNNEL is not set 283 + CONFIG_INET_XFRM_MODE_TRANSPORT=y 284 + CONFIG_INET_XFRM_MODE_TUNNEL=y 295 285 CONFIG_INET_DIAG=y 296 286 CONFIG_INET_TCP_DIAG=y 297 287 # CONFIG_TCP_CONG_ADVANCED is not set 298 288 CONFIG_TCP_CONG_BIC=y 299 289 # CONFIG_IPV6 is not set 290 + # CONFIG_INET6_XFRM_TUNNEL is not set 291 + # CONFIG_INET6_TUNNEL is not set 292 + # CONFIG_NETWORK_SECMARK is not set 300 293 # CONFIG_NETFILTER is not set 301 294 302 295 # ··· 314 295 # SCTP Configuration (EXPERIMENTAL) 315 296 # 316 297 # CONFIG_IP_SCTP is not set 298 + 299 + # 300 + # TIPC Configuration (EXPERIMENTAL) 301 + # 302 + # CONFIG_TIPC is not set 317 303 # CONFIG_ATM is not set 318 304 # CONFIG_BRIDGE is not set 319 305 # CONFIG_VLAN_8021Q is not set ··· 336 312 # QoS and/or fair queueing 337 313 # 338 314 # CONFIG_NET_SCHED is not set 339 - # CONFIG_NET_CLS_ROUTE is not set 340 315 341 316 # 342 317 # Network testing ··· 356 333 CONFIG_STANDALONE=y 357 334 CONFIG_PREVENT_FIRMWARE_BUILD=y 358 335 # CONFIG_FW_LOADER is not set 336 + # CONFIG_SYS_HYPERVISOR is not set 337 + 338 + # 339 + # Connector - unified userspace <-> kernelspace linker 340 + # 341 + # CONFIG_CONNECTOR is not set 359 342 360 343 # 361 344 # Memory Technology Devices (MTD) ··· 555 526 CONFIG_VT=y 556 527 CONFIG_VT_CONSOLE=y 557 528 CONFIG_HW_CONSOLE=y 529 + # CONFIG_VT_HW_CONSOLE_BINDING is not set 558 530 # CONFIG_SERIAL_NONSTANDARD is not set 559 531 560 532 # ··· 564 534 CONFIG_SERIAL_8250=y 565 535 CONFIG_SERIAL_8250_CONSOLE=y 566 536 CONFIG_SERIAL_8250_NR_UARTS=4 537 + CONFIG_SERIAL_8250_RUNTIME_UARTS=4 567 538 # CONFIG_SERIAL_8250_EXTENDED is not set 568 539 569 540 # ··· 590 559 # Watchdog Device Drivers 591 560 # 592 561 # CONFIG_SOFT_WATCHDOG is not set 562 + # CONFIG_HW_RANDOM is not set 593 563 # CONFIG_NVRAM is not set 594 - # CONFIG_RTC is not set 595 564 # CONFIG_DTLK is not set 596 565 # CONFIG_R3964 is not set 597 566 ··· 603 572 # 604 573 # TPM devices 605 574 # 575 + # CONFIG_TCG_TPM is not set 606 576 # CONFIG_TELCLOCK is not set 607 577 608 578 # ··· 612 580 # CONFIG_I2C is not set 613 581 614 582 # 583 + # SPI support 584 + # 585 + # CONFIG_SPI is not set 586 + # CONFIG_SPI_MASTER is not set 587 + 588 + # 589 + # Dallas's 1-wire bus 590 + # 591 + 592 + # 615 593 # Hardware Monitoring support 616 594 # 617 595 CONFIG_HWMON=y 618 596 # CONFIG_HWMON_VID is not set 597 + # CONFIG_SENSORS_ABITUGURU is not set 598 + # CONFIG_SENSORS_F71805F is not set 619 599 # CONFIG_HWMON_DEBUG_CHIP is not set 620 600 621 601 # ··· 635 591 # 636 592 637 593 # 638 - # Multimedia Capabilities Port drivers 594 + # LED devices 595 + # 596 + # CONFIG_NEW_LEDS is not set 597 + 598 + # 599 + # LED drivers 600 + # 601 + 602 + # 603 + # LED Triggers 639 604 # 640 605 641 606 # 642 607 # Multimedia devices 643 608 # 644 609 # CONFIG_VIDEO_DEV is not set 610 + CONFIG_VIDEO_V4L2=y 645 611 646 612 # 647 613 # Digital Video Broadcasting Devices ··· 661 607 # 662 608 # Graphics support 663 609 # 610 + CONFIG_FIRMWARE_EDID=y 664 611 CONFIG_FB=y 665 612 # CONFIG_FB_CFB_FILLRECT is not set 666 613 # CONFIG_FB_CFB_COPYAREA is not set 667 614 # CONFIG_FB_CFB_IMAGEBLIT is not set 668 615 # CONFIG_FB_MACMODES is not set 616 + # CONFIG_FB_BACKLIGHT is not set 669 617 CONFIG_FB_MODE_HELPERS=y 670 618 # CONFIG_FB_TILEBLITTING is not set 671 619 # CONFIG_FB_S1D13XXX is not set ··· 691 635 # CONFIG_FONT_SUN8x16 is not set 692 636 # CONFIG_FONT_SUN12x22 is not set 693 637 # CONFIG_FONT_10x18 is not set 694 - # CONFIG_FONT_RL is not set 695 638 696 639 # 697 640 # Logo configuration ··· 715 660 # Open Sound System 716 661 # 717 662 CONFIG_SOUND_PRIME=y 718 - # CONFIG_OBSOLETE_OSS_DRIVER is not set 719 663 # CONFIG_SOUND_MSNDCLAS is not set 720 664 # CONFIG_SOUND_MSNDPIN is not set 721 - # CONFIG_SOUND_OSS is not set 722 665 723 666 # 724 667 # USB support 725 668 # 726 669 CONFIG_USB_ARCH_HAS_HCD=y 727 670 CONFIG_USB_ARCH_HAS_OHCI=y 671 + # CONFIG_USB_ARCH_HAS_EHCI is not set 728 672 # CONFIG_USB is not set 729 673 730 674 # ··· 734 680 # USB Gadget Support 735 681 # 736 682 # CONFIG_USB_GADGET is not set 737 - # CONFIG_USB_GADGET_NET2280 is not set 738 - # CONFIG_USB_GADGET_PXA2XX is not set 739 - # CONFIG_USB_GADGET_GOKU is not set 740 - # CONFIG_USB_GADGET_LH7A40X is not set 741 - # CONFIG_USB_GADGET_OMAP is not set 742 - # CONFIG_USB_GADGET_DUMMY_HCD is not set 743 - # CONFIG_USB_ZERO is not set 744 - # CONFIG_USB_ETH is not set 745 - # CONFIG_USB_GADGETFS is not set 746 - # CONFIG_USB_FILE_STORAGE is not set 747 - # CONFIG_USB_G_SERIAL is not set 748 683 749 684 # 750 685 # MMC/SD Card support 751 686 # 752 687 # CONFIG_MMC is not set 688 + 689 + # 690 + # Real Time Clock 691 + # 692 + CONFIG_RTC_LIB=y 693 + # CONFIG_RTC_CLASS is not set 753 694 754 695 # 755 696 # File systems ··· 753 704 # CONFIG_EXT2_FS_XATTR is not set 754 705 # CONFIG_EXT2_FS_XIP is not set 755 706 # CONFIG_EXT3_FS is not set 756 - # CONFIG_JBD is not set 757 707 # CONFIG_REISERFS_FS is not set 758 708 # CONFIG_JFS_FS is not set 759 709 # CONFIG_FS_POSIX_ACL is not set 760 710 # CONFIG_XFS_FS is not set 711 + # CONFIG_OCFS2_FS is not set 761 712 # CONFIG_MINIX_FS is not set 762 713 CONFIG_ROMFS_FS=y 763 714 CONFIG_INOTIFY=y 715 + CONFIG_INOTIFY_USER=y 764 716 # CONFIG_QUOTA is not set 765 717 CONFIG_DNOTIFY=y 766 718 # CONFIG_AUTOFS_FS is not set ··· 791 741 # CONFIG_TMPFS is not set 792 742 # CONFIG_HUGETLB_PAGE is not set 793 743 CONFIG_RAMFS=y 794 - # CONFIG_RELAYFS_FS is not set 744 + # CONFIG_CONFIGFS_FS is not set 795 745 796 746 # 797 747 # Miscellaneous filesystems ··· 893 843 # Kernel hacking 894 844 # 895 845 # CONFIG_PRINTK_TIME is not set 846 + # CONFIG_MAGIC_SYSRQ is not set 896 847 # CONFIG_DEBUG_KERNEL is not set 897 848 CONFIG_LOG_BUF_SHIFT=14 898 849 CONFIG_DEBUG_BUGVERBOSE=y 850 + # CONFIG_DEBUG_FS is not set 899 851 CONFIG_FRAME_POINTER=y 852 + # CONFIG_UNWIND_INFO is not set 900 853 # CONFIG_DEBUG_USER is not set 901 854 902 855 #
+1
arch/arm/configs/onearm_defconfig
··· 85 85 # CONFIG_ARCH_INTEGRATOR is not set 86 86 # CONFIG_ARCH_REALVIEW is not set 87 87 # CONFIG_ARCH_VERSATILE is not set 88 + CONFIG_ARCH_AT91=y 88 89 CONFIG_ARCH_AT91RM9200=y 89 90 # CONFIG_ARCH_CLPS7500 is not set 90 91 # CONFIG_ARCH_CLPS711X is not set
+1579
arch/arm/configs/trizeps4_defconfig
··· 1 + # 2 + # Automatically generated make config: don't edit 3 + # Linux kernel version: 2.6.17 4 + # Sat Jun 24 22:45:14 2006 5 + # 6 + CONFIG_ARM=y 7 + CONFIG_MMU=y 8 + CONFIG_RWSEM_GENERIC_SPINLOCK=y 9 + CONFIG_GENERIC_HWEIGHT=y 10 + CONFIG_GENERIC_CALIBRATE_DELAY=y 11 + CONFIG_ARCH_MTD_XIP=y 12 + CONFIG_VECTORS_BASE=0xffff0000 13 + 14 + # 15 + # Code maturity level options 16 + # 17 + CONFIG_EXPERIMENTAL=y 18 + CONFIG_BROKEN_ON_SMP=y 19 + CONFIG_LOCK_KERNEL=y 20 + CONFIG_INIT_ENV_ARG_LIMIT=32 21 + 22 + # 23 + # General setup 24 + # 25 + CONFIG_LOCALVERSION="" 26 + CONFIG_LOCALVERSION_AUTO=y 27 + CONFIG_SWAP=y 28 + CONFIG_SYSVIPC=y 29 + CONFIG_POSIX_MQUEUE=y 30 + CONFIG_BSD_PROCESS_ACCT=y 31 + CONFIG_BSD_PROCESS_ACCT_V3=y 32 + CONFIG_SYSCTL=y 33 + CONFIG_AUDIT=y 34 + CONFIG_IKCONFIG=y 35 + CONFIG_IKCONFIG_PROC=y 36 + # CONFIG_RELAY is not set 37 + CONFIG_INITRAMFS_SOURCE="" 38 + CONFIG_UID16=y 39 + CONFIG_CC_OPTIMIZE_FOR_SIZE=y 40 + CONFIG_EMBEDDED=y 41 + CONFIG_KALLSYMS=y 42 + CONFIG_KALLSYMS_EXTRA_PASS=y 43 + CONFIG_HOTPLUG=y 44 + CONFIG_PRINTK=y 45 + CONFIG_BUG=y 46 + CONFIG_ELF_CORE=y 47 + CONFIG_BASE_FULL=y 48 + CONFIG_FUTEX=y 49 + CONFIG_EPOLL=y 50 + CONFIG_SHMEM=y 51 + CONFIG_SLAB=y 52 + # CONFIG_TINY_SHMEM is not set 53 + CONFIG_BASE_SMALL=0 54 + # CONFIG_SLOB is not set 55 + CONFIG_OBSOLETE_INTERMODULE=y 56 + 57 + # 58 + # Loadable module support 59 + # 60 + CONFIG_MODULES=y 61 + CONFIG_MODULE_UNLOAD=y 62 + CONFIG_MODULE_FORCE_UNLOAD=y 63 + # CONFIG_MODVERSIONS is not set 64 + CONFIG_MODULE_SRCVERSION_ALL=y 65 + CONFIG_KMOD=y 66 + 67 + # 68 + # Block layer 69 + # 70 + # CONFIG_BLK_DEV_IO_TRACE is not set 71 + 72 + # 73 + # IO Schedulers 74 + # 75 + CONFIG_IOSCHED_NOOP=y 76 + CONFIG_IOSCHED_AS=y 77 + CONFIG_IOSCHED_DEADLINE=y 78 + CONFIG_IOSCHED_CFQ=y 79 + CONFIG_DEFAULT_AS=y 80 + # CONFIG_DEFAULT_DEADLINE is not set 81 + # CONFIG_DEFAULT_CFQ is not set 82 + # CONFIG_DEFAULT_NOOP is not set 83 + CONFIG_DEFAULT_IOSCHED="anticipatory" 84 + 85 + # 86 + # System Type 87 + # 88 + # CONFIG_ARCH_CLPS7500 is not set 89 + # CONFIG_ARCH_CLPS711X is not set 90 + # CONFIG_ARCH_CO285 is not set 91 + # CONFIG_ARCH_EBSA110 is not set 92 + # CONFIG_ARCH_EP93XX is not set 93 + # CONFIG_ARCH_FOOTBRIDGE is not set 94 + # CONFIG_ARCH_INTEGRATOR is not set 95 + # CONFIG_ARCH_IOP3XX is not set 96 + # CONFIG_ARCH_IXP4XX is not set 97 + # CONFIG_ARCH_IXP2000 is not set 98 + # CONFIG_ARCH_IXP23XX is not set 99 + # CONFIG_ARCH_L7200 is not set 100 + CONFIG_ARCH_PXA=y 101 + # CONFIG_ARCH_RPC is not set 102 + # CONFIG_ARCH_SA1100 is not set 103 + # CONFIG_ARCH_S3C2410 is not set 104 + # CONFIG_ARCH_SHARK is not set 105 + # CONFIG_ARCH_LH7A40X is not set 106 + # CONFIG_ARCH_OMAP is not set 107 + # CONFIG_ARCH_VERSATILE is not set 108 + # CONFIG_ARCH_REALVIEW is not set 109 + # CONFIG_ARCH_IMX is not set 110 + # CONFIG_ARCH_H720X is not set 111 + # CONFIG_ARCH_AAEC2000 is not set 112 + # CONFIG_ARCH_AT91RM9200 is not set 113 + 114 + # 115 + # Intel PXA2xx Implementations 116 + # 117 + # CONFIG_ARCH_LUBBOCK is not set 118 + # CONFIG_MACH_LOGICPD_PXA270 is not set 119 + # CONFIG_MACH_MAINSTONE is not set 120 + # CONFIG_ARCH_PXA_IDP is not set 121 + # CONFIG_PXA_SHARPSL is not set 122 + CONFIG_MACH_TRIZEPS4=y 123 + CONFIG_MACH_TRIZEPS4_CONXS=y 124 + # CONFIG_MACH_TRIZEPS4_ANY is not set 125 + CONFIG_PXA27x=y 126 + 127 + # 128 + # Processor Type 129 + # 130 + CONFIG_CPU_32=y 131 + CONFIG_CPU_XSCALE=y 132 + CONFIG_CPU_32v5=y 133 + CONFIG_CPU_ABRT_EV5T=y 134 + CONFIG_CPU_CACHE_VIVT=y 135 + CONFIG_CPU_TLB_V4WBI=y 136 + 137 + # 138 + # Processor Features 139 + # 140 + CONFIG_ARM_THUMB=y 141 + CONFIG_XSCALE_PMU=y 142 + 143 + # 144 + # Bus support 145 + # 146 + 147 + # 148 + # PCCARD (PCMCIA/CardBus) support 149 + # 150 + CONFIG_PCCARD=m 151 + # CONFIG_PCMCIA_DEBUG is not set 152 + CONFIG_PCMCIA=m 153 + CONFIG_PCMCIA_LOAD_CIS=y 154 + CONFIG_PCMCIA_IOCTL=y 155 + 156 + # 157 + # PC-card bridges 158 + # 159 + CONFIG_PCMCIA_PXA2XX=m 160 + 161 + # 162 + # Kernel Features 163 + # 164 + CONFIG_PREEMPT=y 165 + # CONFIG_NO_IDLE_HZ is not set 166 + CONFIG_HZ=100 167 + # CONFIG_AEABI is not set 168 + # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set 169 + CONFIG_SELECT_MEMORY_MODEL=y 170 + CONFIG_FLATMEM_MANUAL=y 171 + # CONFIG_DISCONTIGMEM_MANUAL is not set 172 + # CONFIG_SPARSEMEM_MANUAL is not set 173 + CONFIG_FLATMEM=y 174 + CONFIG_FLAT_NODE_MEM_MAP=y 175 + # CONFIG_SPARSEMEM_STATIC is not set 176 + CONFIG_SPLIT_PTLOCK_CPUS=4096 177 + CONFIG_LEDS=y 178 + CONFIG_LEDS_TIMER=y 179 + CONFIG_LEDS_CPU=y 180 + CONFIG_ALIGNMENT_TRAP=y 181 + 182 + # 183 + # Boot options 184 + # 185 + CONFIG_ZBOOT_ROM_TEXT=0 186 + CONFIG_ZBOOT_ROM_BSS=0 187 + CONFIG_CMDLINE="root=/dev/nfs ip=bootp console=ttyS0,115200n8" 188 + # CONFIG_XIP_KERNEL is not set 189 + 190 + # 191 + # Floating point emulation 192 + # 193 + 194 + # 195 + # At least one emulation must be selected 196 + # 197 + CONFIG_FPE_NWFPE=y 198 + CONFIG_FPE_NWFPE_XP=y 199 + # CONFIG_FPE_FASTFPE is not set 200 + 201 + # 202 + # Userspace binary formats 203 + # 204 + CONFIG_BINFMT_ELF=y 205 + # CONFIG_BINFMT_AOUT is not set 206 + CONFIG_BINFMT_MISC=m 207 + # CONFIG_ARTHUR is not set 208 + 209 + # 210 + # Power management options 211 + # 212 + CONFIG_PM=y 213 + CONFIG_PM_LEGACY=y 214 + # CONFIG_PM_DEBUG is not set 215 + CONFIG_APM=y 216 + 217 + # 218 + # Networking 219 + # 220 + CONFIG_NET=y 221 + 222 + # 223 + # Networking options 224 + # 225 + # CONFIG_NETDEBUG is not set 226 + CONFIG_PACKET=y 227 + CONFIG_PACKET_MMAP=y 228 + CONFIG_UNIX=y 229 + CONFIG_XFRM=y 230 + CONFIG_XFRM_USER=m 231 + CONFIG_NET_KEY=y 232 + CONFIG_INET=y 233 + # CONFIG_IP_MULTICAST is not set 234 + # CONFIG_IP_ADVANCED_ROUTER is not set 235 + CONFIG_IP_FIB_HASH=y 236 + CONFIG_IP_PNP=y 237 + CONFIG_IP_PNP_DHCP=y 238 + CONFIG_IP_PNP_BOOTP=y 239 + # CONFIG_IP_PNP_RARP is not set 240 + # CONFIG_NET_IPIP is not set 241 + # CONFIG_NET_IPGRE is not set 242 + # CONFIG_ARPD is not set 243 + # CONFIG_SYN_COOKIES is not set 244 + # CONFIG_INET_AH is not set 245 + # CONFIG_INET_ESP is not set 246 + # CONFIG_INET_IPCOMP is not set 247 + # CONFIG_INET_XFRM_TUNNEL is not set 248 + # CONFIG_INET_TUNNEL is not set 249 + CONFIG_INET_DIAG=y 250 + CONFIG_INET_TCP_DIAG=y 251 + # CONFIG_TCP_CONG_ADVANCED is not set 252 + CONFIG_TCP_CONG_BIC=y 253 + 254 + # 255 + # IP: Virtual Server Configuration 256 + # 257 + # CONFIG_IP_VS is not set 258 + CONFIG_IPV6=m 259 + # CONFIG_IPV6_PRIVACY is not set 260 + # CONFIG_IPV6_ROUTER_PREF is not set 261 + # CONFIG_INET6_AH is not set 262 + # CONFIG_INET6_ESP is not set 263 + # CONFIG_INET6_IPCOMP is not set 264 + # CONFIG_INET6_XFRM_TUNNEL is not set 265 + # CONFIG_INET6_TUNNEL is not set 266 + # CONFIG_IPV6_TUNNEL is not set 267 + CONFIG_NETFILTER=y 268 + # CONFIG_NETFILTER_DEBUG is not set 269 + 270 + # 271 + # Core Netfilter Configuration 272 + # 273 + # CONFIG_NETFILTER_NETLINK is not set 274 + # CONFIG_NETFILTER_XTABLES is not set 275 + 276 + # 277 + # IP: Netfilter Configuration 278 + # 279 + CONFIG_IP_NF_CONNTRACK=m 280 + CONFIG_IP_NF_CT_ACCT=y 281 + CONFIG_IP_NF_CONNTRACK_MARK=y 282 + # CONFIG_IP_NF_CONNTRACK_EVENTS is not set 283 + # CONFIG_IP_NF_CT_PROTO_SCTP is not set 284 + CONFIG_IP_NF_FTP=m 285 + CONFIG_IP_NF_IRC=m 286 + # CONFIG_IP_NF_NETBIOS_NS is not set 287 + CONFIG_IP_NF_TFTP=m 288 + CONFIG_IP_NF_AMANDA=m 289 + # CONFIG_IP_NF_PPTP is not set 290 + # CONFIG_IP_NF_H323 is not set 291 + CONFIG_IP_NF_QUEUE=m 292 + 293 + # 294 + # IPv6: Netfilter Configuration (EXPERIMENTAL) 295 + # 296 + # CONFIG_IP6_NF_QUEUE is not set 297 + 298 + # 299 + # DCCP Configuration (EXPERIMENTAL) 300 + # 301 + # CONFIG_IP_DCCP is not set 302 + 303 + # 304 + # SCTP Configuration (EXPERIMENTAL) 305 + # 306 + # CONFIG_IP_SCTP is not set 307 + 308 + # 309 + # TIPC Configuration (EXPERIMENTAL) 310 + # 311 + # CONFIG_TIPC is not set 312 + # CONFIG_ATM is not set 313 + # CONFIG_BRIDGE is not set 314 + CONFIG_VLAN_8021Q=m 315 + # CONFIG_DECNET is not set 316 + # CONFIG_LLC2 is not set 317 + # CONFIG_IPX is not set 318 + # CONFIG_ATALK is not set 319 + # CONFIG_X25 is not set 320 + # CONFIG_LAPB is not set 321 + # CONFIG_NET_DIVERT is not set 322 + # CONFIG_ECONET is not set 323 + # CONFIG_WAN_ROUTER is not set 324 + 325 + # 326 + # QoS and/or fair queueing 327 + # 328 + # CONFIG_NET_SCHED is not set 329 + 330 + # 331 + # Network testing 332 + # 333 + # CONFIG_NET_PKTGEN is not set 334 + # CONFIG_HAMRADIO is not set 335 + CONFIG_IRDA=m 336 + 337 + # 338 + # IrDA protocols 339 + # 340 + CONFIG_IRLAN=m 341 + CONFIG_IRNET=m 342 + CONFIG_IRCOMM=m 343 + CONFIG_IRDA_ULTRA=y 344 + 345 + # 346 + # IrDA options 347 + # 348 + CONFIG_IRDA_CACHE_LAST_LSAP=y 349 + CONFIG_IRDA_FAST_RR=y 350 + # CONFIG_IRDA_DEBUG is not set 351 + 352 + # 353 + # Infrared-port device drivers 354 + # 355 + 356 + # 357 + # SIR device drivers 358 + # 359 + CONFIG_IRTTY_SIR=m 360 + 361 + # 362 + # Dongle support 363 + # 364 + # CONFIG_DONGLE is not set 365 + 366 + # 367 + # Old SIR device drivers 368 + # 369 + # CONFIG_IRPORT_SIR is not set 370 + 371 + # 372 + # Old Serial dongle support 373 + # 374 + 375 + # 376 + # FIR device drivers 377 + # 378 + # CONFIG_USB_IRDA is not set 379 + # CONFIG_SIGMATEL_FIR is not set 380 + # CONFIG_PXA_FICP is not set 381 + CONFIG_BT=m 382 + CONFIG_BT_L2CAP=m 383 + CONFIG_BT_SCO=m 384 + CONFIG_BT_RFCOMM=m 385 + CONFIG_BT_RFCOMM_TTY=y 386 + CONFIG_BT_BNEP=m 387 + CONFIG_BT_BNEP_MC_FILTER=y 388 + CONFIG_BT_BNEP_PROTO_FILTER=y 389 + CONFIG_BT_HIDP=m 390 + 391 + # 392 + # Bluetooth device drivers 393 + # 394 + # CONFIG_BT_HCIUSB is not set 395 + # CONFIG_BT_HCIUART is not set 396 + # CONFIG_BT_HCIBCM203X is not set 397 + # CONFIG_BT_HCIBPA10X is not set 398 + # CONFIG_BT_HCIBFUSB is not set 399 + # CONFIG_BT_HCIDTL1 is not set 400 + # CONFIG_BT_HCIBT3C is not set 401 + # CONFIG_BT_HCIBLUECARD is not set 402 + # CONFIG_BT_HCIBTUART is not set 403 + # CONFIG_BT_HCIVHCI is not set 404 + CONFIG_IEEE80211=m 405 + # CONFIG_IEEE80211_DEBUG is not set 406 + CONFIG_IEEE80211_CRYPT_WEP=m 407 + CONFIG_IEEE80211_CRYPT_CCMP=m 408 + CONFIG_IEEE80211_CRYPT_TKIP=m 409 + CONFIG_IEEE80211_SOFTMAC=m 410 + # CONFIG_IEEE80211_SOFTMAC_DEBUG is not set 411 + CONFIG_WIRELESS_EXT=y 412 + 413 + # 414 + # Device Drivers 415 + # 416 + 417 + # 418 + # Generic Driver Options 419 + # 420 + CONFIG_STANDALONE=y 421 + CONFIG_PREVENT_FIRMWARE_BUILD=y 422 + CONFIG_FW_LOADER=y 423 + 424 + # 425 + # Connector - unified userspace <-> kernelspace linker 426 + # 427 + CONFIG_CONNECTOR=y 428 + CONFIG_PROC_EVENTS=y 429 + 430 + # 431 + # Memory Technology Devices (MTD) 432 + # 433 + CONFIG_MTD=y 434 + # CONFIG_MTD_DEBUG is not set 435 + CONFIG_MTD_CONCAT=y 436 + CONFIG_MTD_PARTITIONS=y 437 + CONFIG_MTD_REDBOOT_PARTS=y 438 + CONFIG_MTD_REDBOOT_DIRECTORY_BLOCK=-1 439 + CONFIG_MTD_REDBOOT_PARTS_UNALLOCATED=y 440 + CONFIG_MTD_REDBOOT_PARTS_READONLY=y 441 + # CONFIG_MTD_CMDLINE_PARTS is not set 442 + # CONFIG_MTD_AFS_PARTS is not set 443 + 444 + # 445 + # User Modules And Translation Layers 446 + # 447 + CONFIG_MTD_CHAR=y 448 + CONFIG_MTD_BLOCK=y 449 + # CONFIG_FTL is not set 450 + CONFIG_NFTL=y 451 + CONFIG_NFTL_RW=y 452 + CONFIG_INFTL=y 453 + # CONFIG_RFD_FTL is not set 454 + 455 + # 456 + # RAM/ROM/Flash chip drivers 457 + # 458 + CONFIG_MTD_CFI=y 459 + CONFIG_MTD_JEDECPROBE=y 460 + CONFIG_MTD_GEN_PROBE=y 461 + CONFIG_MTD_CFI_ADV_OPTIONS=y 462 + # CONFIG_MTD_CFI_NOSWAP is not set 463 + # CONFIG_MTD_CFI_BE_BYTE_SWAP is not set 464 + CONFIG_MTD_CFI_LE_BYTE_SWAP=y 465 + CONFIG_MTD_CFI_GEOMETRY=y 466 + CONFIG_MTD_MAP_BANK_WIDTH_1=y 467 + CONFIG_MTD_MAP_BANK_WIDTH_2=y 468 + CONFIG_MTD_MAP_BANK_WIDTH_4=y 469 + # CONFIG_MTD_MAP_BANK_WIDTH_8 is not set 470 + # CONFIG_MTD_MAP_BANK_WIDTH_16 is not set 471 + # CONFIG_MTD_MAP_BANK_WIDTH_32 is not set 472 + CONFIG_MTD_CFI_I1=y 473 + CONFIG_MTD_CFI_I2=y 474 + # CONFIG_MTD_CFI_I4 is not set 475 + # CONFIG_MTD_CFI_I8 is not set 476 + # CONFIG_MTD_OTP is not set 477 + CONFIG_MTD_CFI_INTELEXT=y 478 + CONFIG_MTD_CFI_AMDSTD=y 479 + # CONFIG_MTD_CFI_STAA is not set 480 + CONFIG_MTD_CFI_UTIL=y 481 + # CONFIG_MTD_RAM is not set 482 + # CONFIG_MTD_ROM is not set 483 + # CONFIG_MTD_ABSENT is not set 484 + # CONFIG_MTD_OBSOLETE_CHIPS is not set 485 + # CONFIG_MTD_XIP is not set 486 + 487 + # 488 + # Mapping drivers for chip access 489 + # 490 + CONFIG_MTD_COMPLEX_MAPPINGS=y 491 + CONFIG_MTD_PHYSMAP=y 492 + CONFIG_MTD_PHYSMAP_START=0x0 493 + CONFIG_MTD_PHYSMAP_LEN=0x4000000 494 + CONFIG_MTD_PHYSMAP_BANKWIDTH=2 495 + # CONFIG_MTD_TRIZEPS4 is not set 496 + # CONFIG_MTD_ARM_INTEGRATOR is not set 497 + # CONFIG_MTD_IMPA7 is not set 498 + # CONFIG_MTD_SHARP_SL is not set 499 + # CONFIG_MTD_PLATRAM is not set 500 + 501 + # 502 + # Self-contained MTD device drivers 503 + # 504 + # CONFIG_MTD_DATAFLASH is not set 505 + # CONFIG_MTD_M25P80 is not set 506 + # CONFIG_MTD_SLRAM is not set 507 + # CONFIG_MTD_PHRAM is not set 508 + # CONFIG_MTD_MTDRAM is not set 509 + # CONFIG_MTD_BLOCK2MTD is not set 510 + 511 + # 512 + # Disk-On-Chip Device Drivers 513 + # 514 + # CONFIG_MTD_DOC2000 is not set 515 + # CONFIG_MTD_DOC2001 is not set 516 + CONFIG_MTD_DOC2001PLUS=y 517 + CONFIG_MTD_DOCPROBE=y 518 + CONFIG_MTD_DOCECC=y 519 + # CONFIG_MTD_DOCPROBE_ADVANCED is not set 520 + CONFIG_MTD_DOCPROBE_ADDRESS=0 521 + 522 + # 523 + # NAND Flash Device Drivers 524 + # 525 + CONFIG_MTD_NAND=y 526 + # CONFIG_MTD_NAND_VERIFY_WRITE is not set 527 + # CONFIG_MTD_NAND_H1900 is not set 528 + CONFIG_MTD_NAND_IDS=y 529 + CONFIG_MTD_NAND_DISKONCHIP=y 530 + # CONFIG_MTD_NAND_DISKONCHIP_PROBE_ADVANCED is not set 531 + CONFIG_MTD_NAND_DISKONCHIP_PROBE_ADDRESS=0 532 + # CONFIG_MTD_NAND_DISKONCHIP_BBTWRITE is not set 533 + # CONFIG_MTD_NAND_SHARPSL is not set 534 + # CONFIG_MTD_NAND_NANDSIM is not set 535 + 536 + # 537 + # OneNAND Flash Device Drivers 538 + # 539 + # CONFIG_MTD_ONENAND is not set 540 + 541 + # 542 + # Parallel port support 543 + # 544 + # CONFIG_PARPORT is not set 545 + 546 + # 547 + # Plug and Play support 548 + # 549 + 550 + # 551 + # Block devices 552 + # 553 + # CONFIG_BLK_DEV_COW_COMMON is not set 554 + CONFIG_BLK_DEV_LOOP=y 555 + CONFIG_BLK_DEV_CRYPTOLOOP=m 556 + CONFIG_BLK_DEV_NBD=y 557 + # CONFIG_BLK_DEV_UB is not set 558 + CONFIG_BLK_DEV_RAM=y 559 + CONFIG_BLK_DEV_RAM_COUNT=4 560 + CONFIG_BLK_DEV_RAM_SIZE=4096 561 + CONFIG_BLK_DEV_INITRD=y 562 + # CONFIG_CDROM_PKTCDVD is not set 563 + # CONFIG_ATA_OVER_ETH is not set 564 + 565 + # 566 + # ATA/ATAPI/MFM/RLL support 567 + # 568 + CONFIG_IDE=y 569 + CONFIG_BLK_DEV_IDE=y 570 + 571 + # 572 + # Please see Documentation/ide.txt for help/info on IDE drives 573 + # 574 + # CONFIG_BLK_DEV_IDE_SATA is not set 575 + CONFIG_BLK_DEV_IDEDISK=y 576 + CONFIG_IDEDISK_MULTI_MODE=y 577 + CONFIG_BLK_DEV_IDECS=m 578 + # CONFIG_BLK_DEV_IDECD is not set 579 + # CONFIG_BLK_DEV_IDETAPE is not set 580 + # CONFIG_BLK_DEV_IDEFLOPPY is not set 581 + # CONFIG_BLK_DEV_IDESCSI is not set 582 + # CONFIG_IDE_TASK_IOCTL is not set 583 + 584 + # 585 + # IDE chipset support/bugfixes 586 + # 587 + CONFIG_IDE_GENERIC=y 588 + CONFIG_IDE_PXA_CF=y 589 + CONFIG_IDE_ARM=y 590 + # CONFIG_BLK_DEV_IDEDMA is not set 591 + # CONFIG_IDEDMA_AUTO is not set 592 + # CONFIG_BLK_DEV_HD is not set 593 + 594 + # 595 + # SCSI device support 596 + # 597 + # CONFIG_RAID_ATTRS is not set 598 + CONFIG_SCSI=m 599 + CONFIG_SCSI_PROC_FS=y 600 + 601 + # 602 + # SCSI support type (disk, tape, CD-ROM) 603 + # 604 + CONFIG_BLK_DEV_SD=m 605 + # CONFIG_CHR_DEV_ST is not set 606 + # CONFIG_CHR_DEV_OSST is not set 607 + # CONFIG_BLK_DEV_SR is not set 608 + CONFIG_CHR_DEV_SG=m 609 + # CONFIG_CHR_DEV_SCH is not set 610 + 611 + # 612 + # Some SCSI devices (e.g. CD jukebox) support multiple LUNs 613 + # 614 + CONFIG_SCSI_MULTI_LUN=y 615 + # CONFIG_SCSI_CONSTANTS is not set 616 + # CONFIG_SCSI_LOGGING is not set 617 + 618 + # 619 + # SCSI Transport Attributes 620 + # 621 + # CONFIG_SCSI_SPI_ATTRS is not set 622 + # CONFIG_SCSI_FC_ATTRS is not set 623 + # CONFIG_SCSI_ISCSI_ATTRS is not set 624 + # CONFIG_SCSI_SAS_ATTRS is not set 625 + 626 + # 627 + # SCSI low-level drivers 628 + # 629 + # CONFIG_ISCSI_TCP is not set 630 + # CONFIG_SCSI_SATA is not set 631 + # CONFIG_SCSI_DEBUG is not set 632 + 633 + # 634 + # PCMCIA SCSI adapter support 635 + # 636 + # CONFIG_PCMCIA_AHA152X is not set 637 + # CONFIG_PCMCIA_FDOMAIN is not set 638 + # CONFIG_PCMCIA_NINJA_SCSI is not set 639 + # CONFIG_PCMCIA_QLOGIC is not set 640 + # CONFIG_PCMCIA_SYM53C500 is not set 641 + 642 + # 643 + # Multi-device support (RAID and LVM) 644 + # 645 + # CONFIG_MD is not set 646 + 647 + # 648 + # Fusion MPT device support 649 + # 650 + # CONFIG_FUSION is not set 651 + 652 + # 653 + # IEEE 1394 (FireWire) support 654 + # 655 + 656 + # 657 + # I2O device support 658 + # 659 + 660 + # 661 + # Network device support 662 + # 663 + CONFIG_NETDEVICES=y 664 + # CONFIG_DUMMY is not set 665 + # CONFIG_BONDING is not set 666 + # CONFIG_EQUALIZER is not set 667 + # CONFIG_TUN is not set 668 + 669 + # 670 + # PHY device support 671 + # 672 + CONFIG_PHYLIB=y 673 + 674 + # 675 + # MII PHY device drivers 676 + # 677 + # CONFIG_MARVELL_PHY is not set 678 + CONFIG_DAVICOM_PHY=y 679 + # CONFIG_QSEMI_PHY is not set 680 + # CONFIG_LXT_PHY is not set 681 + # CONFIG_CICADA_PHY is not set 682 + 683 + # 684 + # Ethernet (10 or 100Mbit) 685 + # 686 + CONFIG_NET_ETHERNET=y 687 + CONFIG_MII=y 688 + # CONFIG_SMC91X is not set 689 + CONFIG_DM9000=y 690 + 691 + # 692 + # Ethernet (1000 Mbit) 693 + # 694 + 695 + # 696 + # Ethernet (10000 Mbit) 697 + # 698 + 699 + # 700 + # Token Ring devices 701 + # 702 + 703 + # 704 + # Wireless LAN (non-hamradio) 705 + # 706 + CONFIG_NET_RADIO=y 707 + # CONFIG_NET_WIRELESS_RTNETLINK is not set 708 + 709 + # 710 + # Obsolete Wireless cards support (pre-802.11) 711 + # 712 + # CONFIG_STRIP is not set 713 + # CONFIG_PCMCIA_WAVELAN is not set 714 + # CONFIG_PCMCIA_NETWAVE is not set 715 + 716 + # 717 + # Wireless 802.11 Frequency Hopping cards support 718 + # 719 + # CONFIG_PCMCIA_RAYCS is not set 720 + 721 + # 722 + # Wireless 802.11b ISA/PCI cards support 723 + # 724 + CONFIG_HERMES=m 725 + # CONFIG_ATMEL is not set 726 + 727 + # 728 + # Wireless 802.11b Pcmcia/Cardbus cards support 729 + # 730 + CONFIG_PCMCIA_HERMES=m 731 + # CONFIG_PCMCIA_SPECTRUM is not set 732 + CONFIG_AIRO_CS=m 733 + # CONFIG_PCMCIA_WL3501 is not set 734 + CONFIG_HOSTAP=m 735 + CONFIG_HOSTAP_FIRMWARE=y 736 + CONFIG_HOSTAP_FIRMWARE_NVRAM=y 737 + CONFIG_HOSTAP_CS=m 738 + CONFIG_NET_WIRELESS=y 739 + 740 + # 741 + # PCMCIA network device support 742 + # 743 + # CONFIG_NET_PCMCIA is not set 744 + 745 + # 746 + # Wan interfaces 747 + # 748 + # CONFIG_WAN is not set 749 + CONFIG_PPP=m 750 + CONFIG_PPP_MULTILINK=y 751 + CONFIG_PPP_FILTER=y 752 + CONFIG_PPP_ASYNC=m 753 + CONFIG_PPP_SYNC_TTY=m 754 + CONFIG_PPP_DEFLATE=m 755 + CONFIG_PPP_BSDCOMP=m 756 + CONFIG_PPP_MPPE=m 757 + # CONFIG_PPPOE is not set 758 + # CONFIG_SLIP is not set 759 + # CONFIG_SHAPER is not set 760 + # CONFIG_NETCONSOLE is not set 761 + # CONFIG_NETPOLL is not set 762 + # CONFIG_NET_POLL_CONTROLLER is not set 763 + 764 + # 765 + # ISDN subsystem 766 + # 767 + # CONFIG_ISDN is not set 768 + 769 + # 770 + # Input device support 771 + # 772 + CONFIG_INPUT=y 773 + 774 + # 775 + # Userland interfaces 776 + # 777 + CONFIG_INPUT_MOUSEDEV=y 778 + CONFIG_INPUT_MOUSEDEV_PSAUX=y 779 + CONFIG_INPUT_MOUSEDEV_SCREEN_X=640 780 + CONFIG_INPUT_MOUSEDEV_SCREEN_Y=480 781 + # CONFIG_INPUT_JOYDEV is not set 782 + CONFIG_INPUT_TSDEV=y 783 + CONFIG_INPUT_TSDEV_SCREEN_X=640 784 + CONFIG_INPUT_TSDEV_SCREEN_Y=480 785 + CONFIG_INPUT_EVDEV=y 786 + # CONFIG_INPUT_EVBUG is not set 787 + 788 + # 789 + # Input Device Drivers 790 + # 791 + CONFIG_INPUT_KEYBOARD=y 792 + CONFIG_KEYBOARD_ATKBD=y 793 + # CONFIG_KEYBOARD_SUNKBD is not set 794 + # CONFIG_KEYBOARD_LKKBD is not set 795 + # CONFIG_KEYBOARD_XTKBD is not set 796 + # CONFIG_KEYBOARD_NEWTON is not set 797 + CONFIG_INPUT_MOUSE=y 798 + # CONFIG_MOUSE_PS2 is not set 799 + CONFIG_MOUSE_SERIAL=y 800 + # CONFIG_MOUSE_VSXXXAA is not set 801 + # CONFIG_INPUT_JOYSTICK is not set 802 + CONFIG_INPUT_TOUCHSCREEN=y 803 + # CONFIG_TOUCHSCREEN_ADS7846 is not set 804 + # CONFIG_TOUCHSCREEN_GUNZE is not set 805 + # CONFIG_TOUCHSCREEN_ELO is not set 806 + # CONFIG_TOUCHSCREEN_MTOUCH is not set 807 + # CONFIG_TOUCHSCREEN_MK712 is not set 808 + CONFIG_INPUT_MISC=y 809 + CONFIG_INPUT_UINPUT=m 810 + 811 + # 812 + # Hardware I/O ports 813 + # 814 + CONFIG_SERIO=y 815 + CONFIG_SERIO_SERPORT=y 816 + CONFIG_SERIO_LIBPS2=y 817 + # CONFIG_SERIO_RAW is not set 818 + # CONFIG_GAMEPORT is not set 819 + 820 + # 821 + # Character devices 822 + # 823 + CONFIG_VT=y 824 + CONFIG_VT_CONSOLE=y 825 + CONFIG_HW_CONSOLE=y 826 + # CONFIG_SERIAL_NONSTANDARD is not set 827 + 828 + # 829 + # Serial drivers 830 + # 831 + # CONFIG_SERIAL_8250 is not set 832 + 833 + # 834 + # Non-8250 serial port support 835 + # 836 + CONFIG_SERIAL_PXA=y 837 + CONFIG_SERIAL_PXA_CONSOLE=y 838 + CONFIG_SERIAL_CORE=y 839 + CONFIG_SERIAL_CORE_CONSOLE=y 840 + CONFIG_UNIX98_PTYS=y 841 + CONFIG_LEGACY_PTYS=y 842 + CONFIG_LEGACY_PTY_COUNT=256 843 + 844 + # 845 + # IPMI 846 + # 847 + # CONFIG_IPMI_HANDLER is not set 848 + 849 + # 850 + # Watchdog Cards 851 + # 852 + CONFIG_WATCHDOG=y 853 + # CONFIG_WATCHDOG_NOWAYOUT is not set 854 + 855 + # 856 + # Watchdog Device Drivers 857 + # 858 + # CONFIG_SOFT_WATCHDOG is not set 859 + CONFIG_SA1100_WATCHDOG=y 860 + 861 + # 862 + # USB-based Watchdog Cards 863 + # 864 + # CONFIG_USBPCWATCHDOG is not set 865 + # CONFIG_NVRAM is not set 866 + # CONFIG_DTLK is not set 867 + # CONFIG_R3964 is not set 868 + 869 + # 870 + # Ftape, the floppy tape device driver 871 + # 872 + 873 + # 874 + # PCMCIA character devices 875 + # 876 + # CONFIG_SYNCLINK_CS is not set 877 + # CONFIG_CARDMAN_4000 is not set 878 + # CONFIG_CARDMAN_4040 is not set 879 + # CONFIG_RAW_DRIVER is not set 880 + 881 + # 882 + # TPM devices 883 + # 884 + # CONFIG_TCG_TPM is not set 885 + # CONFIG_TELCLOCK is not set 886 + 887 + # 888 + # I2C support 889 + # 890 + CONFIG_I2C=y 891 + CONFIG_I2C_CHARDEV=y 892 + 893 + # 894 + # I2C Algorithms 895 + # 896 + # CONFIG_I2C_ALGOBIT is not set 897 + # CONFIG_I2C_ALGOPCF is not set 898 + # CONFIG_I2C_ALGOPCA is not set 899 + 900 + # 901 + # I2C Hardware Bus support 902 + # 903 + CONFIG_I2C_PXA=y 904 + CONFIG_I2C_PXA_SLAVE=y 905 + # CONFIG_I2C_PARPORT_LIGHT is not set 906 + # CONFIG_I2C_STUB is not set 907 + # CONFIG_I2C_PCA_ISA is not set 908 + 909 + # 910 + # Miscellaneous I2C Chip support 911 + # 912 + # CONFIG_SENSORS_DS1337 is not set 913 + # CONFIG_SENSORS_DS1374 is not set 914 + CONFIG_SENSORS_EEPROM=m 915 + # CONFIG_SENSORS_PCF8574 is not set 916 + # CONFIG_SENSORS_PCA9539 is not set 917 + # CONFIG_SENSORS_PCF8591 is not set 918 + # CONFIG_SENSORS_MAX6875 is not set 919 + # CONFIG_I2C_DEBUG_CORE is not set 920 + # CONFIG_I2C_DEBUG_ALGO is not set 921 + # CONFIG_I2C_DEBUG_BUS is not set 922 + # CONFIG_I2C_DEBUG_CHIP is not set 923 + 924 + # 925 + # SPI support 926 + # 927 + CONFIG_SPI=y 928 + CONFIG_SPI_MASTER=y 929 + 930 + # 931 + # SPI Master Controller Drivers 932 + # 933 + # CONFIG_SPI_BITBANG is not set 934 + CONFIG_SPI_PXA2XX=m 935 + 936 + # 937 + # SPI Protocol Masters 938 + # 939 + 940 + # 941 + # Dallas's 1-wire bus 942 + # 943 + # CONFIG_W1 is not set 944 + 945 + # 946 + # Hardware Monitoring support 947 + # 948 + CONFIG_HWMON=y 949 + # CONFIG_HWMON_VID is not set 950 + # CONFIG_SENSORS_ADM1021 is not set 951 + # CONFIG_SENSORS_ADM1025 is not set 952 + # CONFIG_SENSORS_ADM1026 is not set 953 + # CONFIG_SENSORS_ADM1031 is not set 954 + # CONFIG_SENSORS_ADM9240 is not set 955 + # CONFIG_SENSORS_ASB100 is not set 956 + # CONFIG_SENSORS_ATXP1 is not set 957 + # CONFIG_SENSORS_DS1621 is not set 958 + # CONFIG_SENSORS_F71805F is not set 959 + # CONFIG_SENSORS_FSCHER is not set 960 + # CONFIG_SENSORS_FSCPOS is not set 961 + # CONFIG_SENSORS_GL518SM is not set 962 + # CONFIG_SENSORS_GL520SM is not set 963 + # CONFIG_SENSORS_IT87 is not set 964 + # CONFIG_SENSORS_LM63 is not set 965 + # CONFIG_SENSORS_LM75 is not set 966 + # CONFIG_SENSORS_LM77 is not set 967 + # CONFIG_SENSORS_LM78 is not set 968 + # CONFIG_SENSORS_LM80 is not set 969 + # CONFIG_SENSORS_LM83 is not set 970 + # CONFIG_SENSORS_LM85 is not set 971 + # CONFIG_SENSORS_LM87 is not set 972 + # CONFIG_SENSORS_LM90 is not set 973 + # CONFIG_SENSORS_LM92 is not set 974 + # CONFIG_SENSORS_MAX1619 is not set 975 + # CONFIG_SENSORS_PC87360 is not set 976 + # CONFIG_SENSORS_SMSC47M1 is not set 977 + # CONFIG_SENSORS_SMSC47B397 is not set 978 + # CONFIG_SENSORS_W83781D is not set 979 + # CONFIG_SENSORS_W83792D is not set 980 + # CONFIG_SENSORS_W83L785TS is not set 981 + # CONFIG_SENSORS_W83627HF is not set 982 + # CONFIG_SENSORS_W83627EHF is not set 983 + # CONFIG_HWMON_DEBUG_CHIP is not set 984 + 985 + # 986 + # Misc devices 987 + # 988 + 989 + # 990 + # Multimedia Capabilities Port drivers 991 + # 992 + CONFIG_UCB1400=y 993 + CONFIG_UCB1400_TS=y 994 + 995 + # 996 + # LED devices 997 + # 998 + CONFIG_NEW_LEDS=y 999 + CONFIG_LEDS_CLASS=y 1000 + 1001 + # 1002 + # LED drivers 1003 + # 1004 + 1005 + # 1006 + # LED Triggers 1007 + # 1008 + CONFIG_LEDS_TRIGGERS=y 1009 + CONFIG_LEDS_TRIGGER_TIMER=y 1010 + CONFIG_LEDS_TRIGGER_IDE_DISK=y 1011 + 1012 + # 1013 + # Multimedia devices 1014 + # 1015 + # CONFIG_VIDEO_DEV is not set 1016 + CONFIG_VIDEO_V4L2=y 1017 + 1018 + # 1019 + # Digital Video Broadcasting Devices 1020 + # 1021 + # CONFIG_DVB is not set 1022 + # CONFIG_USB_DABUSB is not set 1023 + 1024 + # 1025 + # Graphics support 1026 + # 1027 + CONFIG_FB=y 1028 + CONFIG_FB_CFB_FILLRECT=y 1029 + CONFIG_FB_CFB_COPYAREA=y 1030 + CONFIG_FB_CFB_IMAGEBLIT=y 1031 + # CONFIG_FB_MACMODES is not set 1032 + CONFIG_FB_FIRMWARE_EDID=y 1033 + # CONFIG_FB_MODE_HELPERS is not set 1034 + # CONFIG_FB_TILEBLITTING is not set 1035 + # CONFIG_FB_S1D13XXX is not set 1036 + CONFIG_FB_PXA=y 1037 + # CONFIG_FB_PXA_PARAMETERS is not set 1038 + # CONFIG_FB_VIRTUAL is not set 1039 + 1040 + # 1041 + # Console display driver support 1042 + # 1043 + # CONFIG_VGA_CONSOLE is not set 1044 + CONFIG_DUMMY_CONSOLE=y 1045 + CONFIG_FRAMEBUFFER_CONSOLE=y 1046 + CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y 1047 + CONFIG_FONTS=y 1048 + CONFIG_FONT_8x8=y 1049 + CONFIG_FONT_8x16=y 1050 + # CONFIG_FONT_6x11 is not set 1051 + # CONFIG_FONT_7x14 is not set 1052 + # CONFIG_FONT_PEARL_8x8 is not set 1053 + # CONFIG_FONT_ACORN_8x8 is not set 1054 + # CONFIG_FONT_MINI_4x6 is not set 1055 + # CONFIG_FONT_SUN8x16 is not set 1056 + # CONFIG_FONT_SUN12x22 is not set 1057 + # CONFIG_FONT_10x18 is not set 1058 + 1059 + # 1060 + # Logo configuration 1061 + # 1062 + CONFIG_LOGO=y 1063 + CONFIG_LOGO_LINUX_MONO=y 1064 + CONFIG_LOGO_LINUX_VGA16=y 1065 + CONFIG_LOGO_LINUX_CLUT224=y 1066 + CONFIG_BACKLIGHT_LCD_SUPPORT=y 1067 + CONFIG_BACKLIGHT_CLASS_DEVICE=y 1068 + CONFIG_BACKLIGHT_DEVICE=y 1069 + CONFIG_LCD_CLASS_DEVICE=y 1070 + CONFIG_LCD_DEVICE=y 1071 + 1072 + # 1073 + # Sound 1074 + # 1075 + CONFIG_SOUND=y 1076 + 1077 + # 1078 + # Advanced Linux Sound Architecture 1079 + # 1080 + CONFIG_SND=y 1081 + CONFIG_SND_TIMER=y 1082 + CONFIG_SND_PCM=y 1083 + CONFIG_SND_HWDEP=m 1084 + CONFIG_SND_RAWMIDI=m 1085 + CONFIG_SND_SEQUENCER=m 1086 + # CONFIG_SND_SEQ_DUMMY is not set 1087 + CONFIG_SND_OSSEMUL=y 1088 + CONFIG_SND_MIXER_OSS=y 1089 + CONFIG_SND_PCM_OSS=y 1090 + CONFIG_SND_PCM_OSS_PLUGINS=y 1091 + # CONFIG_SND_SEQUENCER_OSS is not set 1092 + # CONFIG_SND_DYNAMIC_MINORS is not set 1093 + CONFIG_SND_SUPPORT_OLD_API=y 1094 + CONFIG_SND_VERBOSE_PROCFS=y 1095 + CONFIG_SND_VERBOSE_PRINTK=y 1096 + # CONFIG_SND_DEBUG is not set 1097 + 1098 + # 1099 + # Generic devices 1100 + # 1101 + CONFIG_SND_AC97_CODEC=y 1102 + CONFIG_SND_AC97_BUS=y 1103 + # CONFIG_SND_DUMMY is not set 1104 + # CONFIG_SND_VIRMIDI is not set 1105 + # CONFIG_SND_MTPAV is not set 1106 + # CONFIG_SND_SERIAL_U16550 is not set 1107 + # CONFIG_SND_MPU401 is not set 1108 + 1109 + # 1110 + # ALSA ARM devices 1111 + # 1112 + CONFIG_SND_PXA2XX_PCM=y 1113 + CONFIG_SND_PXA2XX_AC97=y 1114 + 1115 + # 1116 + # USB devices 1117 + # 1118 + CONFIG_SND_USB_AUDIO=m 1119 + 1120 + # 1121 + # PCMCIA devices 1122 + # 1123 + # CONFIG_SND_VXPOCKET is not set 1124 + # CONFIG_SND_PDAUDIOCF is not set 1125 + 1126 + # 1127 + # Open Sound System 1128 + # 1129 + # CONFIG_SOUND_PRIME is not set 1130 + 1131 + # 1132 + # USB support 1133 + # 1134 + CONFIG_USB_ARCH_HAS_HCD=y 1135 + CONFIG_USB_ARCH_HAS_OHCI=y 1136 + # CONFIG_USB_ARCH_HAS_EHCI is not set 1137 + CONFIG_USB=y 1138 + # CONFIG_USB_DEBUG is not set 1139 + 1140 + # 1141 + # Miscellaneous USB options 1142 + # 1143 + CONFIG_USB_DEVICEFS=y 1144 + # CONFIG_USB_BANDWIDTH is not set 1145 + # CONFIG_USB_DYNAMIC_MINORS is not set 1146 + # CONFIG_USB_SUSPEND is not set 1147 + # CONFIG_USB_OTG is not set 1148 + 1149 + # 1150 + # USB Host Controller Drivers 1151 + # 1152 + # CONFIG_USB_ISP116X_HCD is not set 1153 + CONFIG_USB_OHCI_HCD=y 1154 + # CONFIG_USB_OHCI_BIG_ENDIAN is not set 1155 + CONFIG_USB_OHCI_LITTLE_ENDIAN=y 1156 + # CONFIG_USB_SL811_HCD is not set 1157 + 1158 + # 1159 + # USB Device Class drivers 1160 + # 1161 + # CONFIG_USB_ACM is not set 1162 + # CONFIG_USB_PRINTER is not set 1163 + 1164 + # 1165 + # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' 1166 + # 1167 + 1168 + # 1169 + # may also be needed; see USB_STORAGE Help for more information 1170 + # 1171 + CONFIG_USB_STORAGE=m 1172 + # CONFIG_USB_STORAGE_DEBUG is not set 1173 + # CONFIG_USB_STORAGE_DATAFAB is not set 1174 + # CONFIG_USB_STORAGE_FREECOM is not set 1175 + # CONFIG_USB_STORAGE_ISD200 is not set 1176 + # CONFIG_USB_STORAGE_DPCM is not set 1177 + # CONFIG_USB_STORAGE_USBAT is not set 1178 + # CONFIG_USB_STORAGE_SDDR09 is not set 1179 + # CONFIG_USB_STORAGE_SDDR55 is not set 1180 + # CONFIG_USB_STORAGE_JUMPSHOT is not set 1181 + # CONFIG_USB_STORAGE_ALAUDA is not set 1182 + # CONFIG_USB_LIBUSUAL is not set 1183 + 1184 + # 1185 + # USB Input Devices 1186 + # 1187 + CONFIG_USB_HID=m 1188 + CONFIG_USB_HIDINPUT=y 1189 + # CONFIG_USB_HIDINPUT_POWERBOOK is not set 1190 + # CONFIG_HID_FF is not set 1191 + # CONFIG_USB_HIDDEV is not set 1192 + 1193 + # 1194 + # USB HID Boot Protocol drivers 1195 + # 1196 + # CONFIG_USB_KBD is not set 1197 + # CONFIG_USB_MOUSE is not set 1198 + # CONFIG_USB_AIPTEK is not set 1199 + # CONFIG_USB_WACOM is not set 1200 + # CONFIG_USB_ACECAD is not set 1201 + # CONFIG_USB_KBTAB is not set 1202 + # CONFIG_USB_POWERMATE is not set 1203 + CONFIG_USB_TOUCHSCREEN=m 1204 + # CONFIG_USB_TOUCHSCREEN_EGALAX is not set 1205 + # CONFIG_USB_TOUCHSCREEN_PANJIT is not set 1206 + # CONFIG_USB_TOUCHSCREEN_3M is not set 1207 + # CONFIG_USB_TOUCHSCREEN_ITM is not set 1208 + # CONFIG_USB_YEALINK is not set 1209 + # CONFIG_USB_XPAD is not set 1210 + # CONFIG_USB_ATI_REMOTE is not set 1211 + # CONFIG_USB_ATI_REMOTE2 is not set 1212 + # CONFIG_USB_KEYSPAN_REMOTE is not set 1213 + # CONFIG_USB_APPLETOUCH is not set 1214 + 1215 + # 1216 + # USB Imaging devices 1217 + # 1218 + # CONFIG_USB_MDC800 is not set 1219 + # CONFIG_USB_MICROTEK is not set 1220 + 1221 + # 1222 + # USB Network Adapters 1223 + # 1224 + # CONFIG_USB_CATC is not set 1225 + # CONFIG_USB_KAWETH is not set 1226 + # CONFIG_USB_PEGASUS is not set 1227 + # CONFIG_USB_RTL8150 is not set 1228 + # CONFIG_USB_USBNET is not set 1229 + # CONFIG_USB_ZD1201 is not set 1230 + CONFIG_USB_MON=y 1231 + 1232 + # 1233 + # USB port drivers 1234 + # 1235 + 1236 + # 1237 + # USB Serial Converter support 1238 + # 1239 + # CONFIG_USB_SERIAL is not set 1240 + 1241 + # 1242 + # USB Miscellaneous drivers 1243 + # 1244 + # CONFIG_USB_EMI62 is not set 1245 + # CONFIG_USB_EMI26 is not set 1246 + # CONFIG_USB_AUERSWALD is not set 1247 + # CONFIG_USB_RIO500 is not set 1248 + # CONFIG_USB_LEGOTOWER is not set 1249 + # CONFIG_USB_LCD is not set 1250 + # CONFIG_USB_LED is not set 1251 + # CONFIG_USB_CYTHERM is not set 1252 + # CONFIG_USB_PHIDGETKIT is not set 1253 + # CONFIG_USB_PHIDGETSERVO is not set 1254 + # CONFIG_USB_IDMOUSE is not set 1255 + # CONFIG_USB_LD is not set 1256 + # CONFIG_USB_TEST is not set 1257 + 1258 + # 1259 + # USB DSL modem support 1260 + # 1261 + 1262 + # 1263 + # USB Gadget Support 1264 + # 1265 + CONFIG_USB_GADGET=y 1266 + # CONFIG_USB_GADGET_DEBUG_FILES is not set 1267 + CONFIG_USB_GADGET_SELECTED=y 1268 + # CONFIG_USB_GADGET_NET2280 is not set 1269 + # CONFIG_USB_GADGET_PXA2XX is not set 1270 + # CONFIG_USB_GADGET_GOKU is not set 1271 + # CONFIG_USB_GADGET_LH7A40X is not set 1272 + # CONFIG_USB_GADGET_OMAP is not set 1273 + # CONFIG_USB_GADGET_AT91 is not set 1274 + CONFIG_USB_GADGET_DUMMY_HCD=y 1275 + CONFIG_USB_DUMMY_HCD=y 1276 + CONFIG_USB_GADGET_DUALSPEED=y 1277 + # CONFIG_USB_ZERO is not set 1278 + CONFIG_USB_ETH=m 1279 + CONFIG_USB_ETH_RNDIS=y 1280 + CONFIG_USB_GADGETFS=m 1281 + CONFIG_USB_FILE_STORAGE=m 1282 + # CONFIG_USB_FILE_STORAGE_TEST is not set 1283 + CONFIG_USB_G_SERIAL=m 1284 + 1285 + # 1286 + # MMC/SD Card support 1287 + # 1288 + CONFIG_MMC=y 1289 + # CONFIG_MMC_DEBUG is not set 1290 + CONFIG_MMC_BLOCK=y 1291 + CONFIG_MMC_PXA=y 1292 + 1293 + # 1294 + # Real Time Clock 1295 + # 1296 + CONFIG_RTC_LIB=y 1297 + CONFIG_RTC_CLASS=y 1298 + CONFIG_RTC_HCTOSYS=y 1299 + CONFIG_RTC_HCTOSYS_DEVICE="rtc0" 1300 + 1301 + # 1302 + # RTC interfaces 1303 + # 1304 + CONFIG_RTC_INTF_SYSFS=y 1305 + CONFIG_RTC_INTF_PROC=y 1306 + CONFIG_RTC_INTF_DEV=y 1307 + 1308 + # 1309 + # RTC drivers 1310 + # 1311 + # CONFIG_RTC_DRV_X1205 is not set 1312 + # CONFIG_RTC_DRV_DS1672 is not set 1313 + # CONFIG_RTC_DRV_PCF8563 is not set 1314 + # CONFIG_RTC_DRV_RS5C372 is not set 1315 + # CONFIG_RTC_DRV_M48T86 is not set 1316 + CONFIG_RTC_DRV_SA1100=y 1317 + # CONFIG_RTC_DRV_TEST is not set 1318 + 1319 + # 1320 + # File systems 1321 + # 1322 + CONFIG_EXT2_FS=y 1323 + CONFIG_EXT2_FS_XATTR=y 1324 + CONFIG_EXT2_FS_POSIX_ACL=y 1325 + CONFIG_EXT2_FS_SECURITY=y 1326 + # CONFIG_EXT2_FS_XIP is not set 1327 + CONFIG_EXT3_FS=y 1328 + CONFIG_EXT3_FS_XATTR=y 1329 + CONFIG_EXT3_FS_POSIX_ACL=y 1330 + CONFIG_EXT3_FS_SECURITY=y 1331 + CONFIG_JBD=y 1332 + # CONFIG_JBD_DEBUG is not set 1333 + CONFIG_FS_MBCACHE=y 1334 + # CONFIG_REISERFS_FS is not set 1335 + # CONFIG_JFS_FS is not set 1336 + CONFIG_FS_POSIX_ACL=y 1337 + # CONFIG_XFS_FS is not set 1338 + # CONFIG_OCFS2_FS is not set 1339 + # CONFIG_MINIX_FS is not set 1340 + # CONFIG_ROMFS_FS is not set 1341 + CONFIG_INOTIFY=y 1342 + # CONFIG_QUOTA is not set 1343 + CONFIG_DNOTIFY=y 1344 + # CONFIG_AUTOFS_FS is not set 1345 + CONFIG_AUTOFS4_FS=y 1346 + # CONFIG_FUSE_FS is not set 1347 + 1348 + # 1349 + # CD-ROM/DVD Filesystems 1350 + # 1351 + # CONFIG_ISO9660_FS is not set 1352 + # CONFIG_UDF_FS is not set 1353 + 1354 + # 1355 + # DOS/FAT/NT Filesystems 1356 + # 1357 + CONFIG_FAT_FS=m 1358 + CONFIG_MSDOS_FS=m 1359 + CONFIG_VFAT_FS=m 1360 + CONFIG_FAT_DEFAULT_CODEPAGE=437 1361 + CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-15" 1362 + # CONFIG_NTFS_FS is not set 1363 + 1364 + # 1365 + # Pseudo filesystems 1366 + # 1367 + CONFIG_PROC_FS=y 1368 + CONFIG_SYSFS=y 1369 + CONFIG_TMPFS=y 1370 + # CONFIG_HUGETLB_PAGE is not set 1371 + CONFIG_RAMFS=y 1372 + # CONFIG_CONFIGFS_FS is not set 1373 + 1374 + # 1375 + # Miscellaneous filesystems 1376 + # 1377 + # CONFIG_ADFS_FS is not set 1378 + # CONFIG_AFFS_FS is not set 1379 + # CONFIG_HFS_FS is not set 1380 + # CONFIG_HFSPLUS_FS is not set 1381 + # CONFIG_BEFS_FS is not set 1382 + # CONFIG_BFS_FS is not set 1383 + # CONFIG_EFS_FS is not set 1384 + CONFIG_JFFS_FS=y 1385 + CONFIG_JFFS_FS_VERBOSE=0 1386 + CONFIG_JFFS_PROC_FS=y 1387 + CONFIG_JFFS2_FS=y 1388 + CONFIG_JFFS2_FS_DEBUG=0 1389 + CONFIG_JFFS2_FS_WRITEBUFFER=y 1390 + # CONFIG_JFFS2_SUMMARY is not set 1391 + CONFIG_JFFS2_COMPRESSION_OPTIONS=y 1392 + CONFIG_JFFS2_ZLIB=y 1393 + CONFIG_JFFS2_RTIME=y 1394 + # CONFIG_JFFS2_RUBIN is not set 1395 + # CONFIG_JFFS2_CMODE_NONE is not set 1396 + CONFIG_JFFS2_CMODE_PRIORITY=y 1397 + # CONFIG_JFFS2_CMODE_SIZE is not set 1398 + # CONFIG_CRAMFS is not set 1399 + # CONFIG_VXFS_FS is not set 1400 + # CONFIG_HPFS_FS is not set 1401 + # CONFIG_QNX4FS_FS is not set 1402 + # CONFIG_SYSV_FS is not set 1403 + # CONFIG_UFS_FS is not set 1404 + 1405 + # 1406 + # Network File Systems 1407 + # 1408 + CONFIG_NFS_FS=y 1409 + CONFIG_NFS_V3=y 1410 + CONFIG_NFS_V3_ACL=y 1411 + CONFIG_NFS_V4=y 1412 + # CONFIG_NFS_DIRECTIO is not set 1413 + CONFIG_NFSD=y 1414 + CONFIG_NFSD_V2_ACL=y 1415 + CONFIG_NFSD_V3=y 1416 + CONFIG_NFSD_V3_ACL=y 1417 + CONFIG_NFSD_V4=y 1418 + CONFIG_NFSD_TCP=y 1419 + CONFIG_ROOT_NFS=y 1420 + CONFIG_LOCKD=y 1421 + CONFIG_LOCKD_V4=y 1422 + CONFIG_EXPORTFS=y 1423 + CONFIG_NFS_ACL_SUPPORT=y 1424 + CONFIG_NFS_COMMON=y 1425 + CONFIG_SUNRPC=y 1426 + CONFIG_SUNRPC_GSS=y 1427 + CONFIG_RPCSEC_GSS_KRB5=y 1428 + # CONFIG_RPCSEC_GSS_SPKM3 is not set 1429 + CONFIG_SMB_FS=m 1430 + # CONFIG_SMB_NLS_DEFAULT is not set 1431 + CONFIG_CIFS=m 1432 + # CONFIG_CIFS_STATS is not set 1433 + # CONFIG_CIFS_XATTR is not set 1434 + # CONFIG_CIFS_EXPERIMENTAL is not set 1435 + # CONFIG_NCP_FS is not set 1436 + # CONFIG_CODA_FS is not set 1437 + # CONFIG_AFS_FS is not set 1438 + # CONFIG_9P_FS is not set 1439 + 1440 + # 1441 + # Partition Types 1442 + # 1443 + CONFIG_PARTITION_ADVANCED=y 1444 + # CONFIG_ACORN_PARTITION is not set 1445 + # CONFIG_OSF_PARTITION is not set 1446 + # CONFIG_AMIGA_PARTITION is not set 1447 + # CONFIG_ATARI_PARTITION is not set 1448 + # CONFIG_MAC_PARTITION is not set 1449 + CONFIG_MSDOS_PARTITION=y 1450 + # CONFIG_BSD_DISKLABEL is not set 1451 + # CONFIG_MINIX_SUBPARTITION is not set 1452 + # CONFIG_SOLARIS_X86_PARTITION is not set 1453 + # CONFIG_UNIXWARE_DISKLABEL is not set 1454 + CONFIG_LDM_PARTITION=y 1455 + # CONFIG_LDM_DEBUG is not set 1456 + # CONFIG_SGI_PARTITION is not set 1457 + # CONFIG_ULTRIX_PARTITION is not set 1458 + # CONFIG_SUN_PARTITION is not set 1459 + # CONFIG_KARMA_PARTITION is not set 1460 + # CONFIG_EFI_PARTITION is not set 1461 + 1462 + # 1463 + # Native Language Support 1464 + # 1465 + CONFIG_NLS=y 1466 + CONFIG_NLS_DEFAULT="iso8859-15" 1467 + CONFIG_NLS_CODEPAGE_437=y 1468 + # CONFIG_NLS_CODEPAGE_737 is not set 1469 + # CONFIG_NLS_CODEPAGE_775 is not set 1470 + CONFIG_NLS_CODEPAGE_850=y 1471 + # CONFIG_NLS_CODEPAGE_852 is not set 1472 + # CONFIG_NLS_CODEPAGE_855 is not set 1473 + # CONFIG_NLS_CODEPAGE_857 is not set 1474 + # CONFIG_NLS_CODEPAGE_860 is not set 1475 + # CONFIG_NLS_CODEPAGE_861 is not set 1476 + # CONFIG_NLS_CODEPAGE_862 is not set 1477 + # CONFIG_NLS_CODEPAGE_863 is not set 1478 + # CONFIG_NLS_CODEPAGE_864 is not set 1479 + # CONFIG_NLS_CODEPAGE_865 is not set 1480 + # CONFIG_NLS_CODEPAGE_866 is not set 1481 + # CONFIG_NLS_CODEPAGE_869 is not set 1482 + # CONFIG_NLS_CODEPAGE_936 is not set 1483 + # CONFIG_NLS_CODEPAGE_950 is not set 1484 + # CONFIG_NLS_CODEPAGE_932 is not set 1485 + # CONFIG_NLS_CODEPAGE_949 is not set 1486 + # CONFIG_NLS_CODEPAGE_874 is not set 1487 + # CONFIG_NLS_ISO8859_8 is not set 1488 + # CONFIG_NLS_CODEPAGE_1250 is not set 1489 + # CONFIG_NLS_CODEPAGE_1251 is not set 1490 + CONFIG_NLS_ASCII=y 1491 + CONFIG_NLS_ISO8859_1=m 1492 + # CONFIG_NLS_ISO8859_2 is not set 1493 + # CONFIG_NLS_ISO8859_3 is not set 1494 + # CONFIG_NLS_ISO8859_4 is not set 1495 + # CONFIG_NLS_ISO8859_5 is not set 1496 + # CONFIG_NLS_ISO8859_6 is not set 1497 + # CONFIG_NLS_ISO8859_7 is not set 1498 + # CONFIG_NLS_ISO8859_9 is not set 1499 + # CONFIG_NLS_ISO8859_13 is not set 1500 + # CONFIG_NLS_ISO8859_14 is not set 1501 + CONFIG_NLS_ISO8859_15=m 1502 + # CONFIG_NLS_KOI8_R is not set 1503 + # CONFIG_NLS_KOI8_U is not set 1504 + CONFIG_NLS_UTF8=m 1505 + 1506 + # 1507 + # Profiling support 1508 + # 1509 + CONFIG_PROFILING=y 1510 + CONFIG_OPROFILE=y 1511 + 1512 + # 1513 + # Kernel hacking 1514 + # 1515 + # CONFIG_PRINTK_TIME is not set 1516 + CONFIG_MAGIC_SYSRQ=y 1517 + # CONFIG_DEBUG_KERNEL is not set 1518 + CONFIG_LOG_BUF_SHIFT=14 1519 + # CONFIG_DEBUG_BUGVERBOSE is not set 1520 + # CONFIG_DEBUG_FS is not set 1521 + CONFIG_FRAME_POINTER=y 1522 + # CONFIG_UNWIND_INFO is not set 1523 + CONFIG_DEBUG_USER=y 1524 + 1525 + # 1526 + # Security options 1527 + # 1528 + CONFIG_KEYS=y 1529 + CONFIG_KEYS_DEBUG_PROC_KEYS=y 1530 + CONFIG_SECURITY=y 1531 + # CONFIG_SECURITY_NETWORK is not set 1532 + CONFIG_SECURITY_CAPABILITIES=y 1533 + # CONFIG_SECURITY_ROOTPLUG is not set 1534 + # CONFIG_SECURITY_SECLVL is not set 1535 + 1536 + # 1537 + # Cryptographic options 1538 + # 1539 + CONFIG_CRYPTO=y 1540 + # CONFIG_CRYPTO_HMAC is not set 1541 + # CONFIG_CRYPTO_NULL is not set 1542 + CONFIG_CRYPTO_MD4=y 1543 + CONFIG_CRYPTO_MD5=y 1544 + CONFIG_CRYPTO_SHA1=m 1545 + CONFIG_CRYPTO_SHA256=m 1546 + CONFIG_CRYPTO_SHA512=m 1547 + # CONFIG_CRYPTO_WP512 is not set 1548 + # CONFIG_CRYPTO_TGR192 is not set 1549 + CONFIG_CRYPTO_DES=y 1550 + # CONFIG_CRYPTO_BLOWFISH is not set 1551 + # CONFIG_CRYPTO_TWOFISH is not set 1552 + # CONFIG_CRYPTO_SERPENT is not set 1553 + CONFIG_CRYPTO_AES=m 1554 + # CONFIG_CRYPTO_CAST5 is not set 1555 + # CONFIG_CRYPTO_CAST6 is not set 1556 + # CONFIG_CRYPTO_TEA is not set 1557 + CONFIG_CRYPTO_ARC4=m 1558 + # CONFIG_CRYPTO_KHAZAD is not set 1559 + # CONFIG_CRYPTO_ANUBIS is not set 1560 + CONFIG_CRYPTO_DEFLATE=m 1561 + CONFIG_CRYPTO_MICHAEL_MIC=m 1562 + CONFIG_CRYPTO_CRC32C=y 1563 + # CONFIG_CRYPTO_TEST is not set 1564 + 1565 + # 1566 + # Hardware crypto devices 1567 + # 1568 + 1569 + # 1570 + # Library routines 1571 + # 1572 + CONFIG_CRC_CCITT=y 1573 + CONFIG_CRC16=y 1574 + CONFIG_CRC32=y 1575 + CONFIG_LIBCRC32C=y 1576 + CONFIG_ZLIB_INFLATE=y 1577 + CONFIG_ZLIB_DEFLATE=y 1578 + CONFIG_REED_SOLOMON=y 1579 + CONFIG_REED_SOLOMON_DEC16=y
+1 -1
arch/arm/kernel/Makefile
··· 25 25 obj-$(CONFIG_CRUNCH) += crunch.o crunch-bits.o 26 26 AFLAGS_crunch-bits.o := -Wa,-mcpu=ep9312 27 27 28 - obj-$(CONFIG_IWMMXT) += iwmmxt.o 28 + obj-$(CONFIG_IWMMXT) += iwmmxt.o iwmmxt-notifier.o 29 29 AFLAGS_iwmmxt.o := -Wa,-mcpu=iwmmxt 30 30 31 31 ifneq ($(CONFIG_ARCH_EBSA110),y)
+2 -1
arch/arm/kernel/asm-offsets.c
··· 105 105 BLANK(); 106 106 DEFINE(PROC_INFO_SZ, sizeof(struct proc_info_list)); 107 107 DEFINE(PROCINFO_INITFUNC, offsetof(struct proc_info_list, __cpu_flush)); 108 - DEFINE(PROCINFO_MMUFLAGS, offsetof(struct proc_info_list, __cpu_mmu_flags)); 108 + DEFINE(PROCINFO_MM_MMUFLAGS, offsetof(struct proc_info_list, __cpu_mm_mmu_flags)); 109 + DEFINE(PROCINFO_IO_MMUFLAGS, offsetof(struct proc_info_list, __cpu_io_mmu_flags)); 109 110 return 0; 110 111 }
+1 -3
arch/arm/kernel/entry-armv.S
··· 589 589 #ifdef CONFIG_MMU 590 590 mcr p15, 0, r6, c3, c0, 0 @ Set domain register 591 591 #endif 592 - #if defined(CONFIG_IWMMXT) 593 - bl iwmmxt_task_switch 594 - #elif defined(CONFIG_CPU_XSCALE) 592 + #if defined(CONFIG_CPU_XSCALE) && !defined(CONFIG_IWMMXT) 595 593 add r4, r2, #TI_CPU_DOMAIN + 40 @ cpu_context_save->extra 596 594 ldmib r4, {r4, r5} 597 595 mar acc0, r4, r5
+2 -3
arch/arm/kernel/head.S
··· 220 220 teq r0, r6 221 221 bne 1b 222 222 223 - ldr r7, [r10, #PROCINFO_MMUFLAGS] @ mmuflags 223 + ldr r7, [r10, #PROCINFO_MM_MMUFLAGS] @ mm_mmuflags 224 224 225 225 /* 226 226 * Create identity mapping for first MB of kernel to ··· 271 271 #endif 272 272 273 273 #ifdef CONFIG_DEBUG_LL 274 - bic r7, r7, #0x0c @ turn off cacheable 275 - @ and bufferable bits 274 + ldr r7, [r10, #PROCINFO_IO_MMUFLAGS] @ io_mmuflags 276 275 /* 277 276 * Map in IO space for serial debugging. 278 277 * This allows debug messages to be output
+64
arch/arm/kernel/iwmmxt-notifier.c
··· 1 + /* 2 + * linux/arch/arm/kernel/iwmmxt-notifier.c 3 + * 4 + * XScale iWMMXt (Concan) context switching and handling 5 + * 6 + * Initial code: 7 + * Copyright (c) 2003, Intel Corporation 8 + * 9 + * Full lazy switching support, optimizations and more, by Nicolas Pitre 10 + * Copyright (c) 2003-2004, MontaVista Software, Inc. 11 + * 12 + * This program is free software; you can redistribute it and/or modify 13 + * it under the terms of the GNU General Public License version 2 as 14 + * published by the Free Software Foundation. 15 + */ 16 + 17 + #include <linux/module.h> 18 + #include <linux/config.h> 19 + #include <linux/types.h> 20 + #include <linux/kernel.h> 21 + #include <linux/signal.h> 22 + #include <linux/sched.h> 23 + #include <linux/init.h> 24 + #include <asm/thread_notify.h> 25 + #include <asm/io.h> 26 + 27 + static int iwmmxt_do(struct notifier_block *self, unsigned long cmd, void *t) 28 + { 29 + struct thread_info *thread = t; 30 + 31 + switch (cmd) { 32 + case THREAD_NOTIFY_FLUSH: 33 + /* 34 + * flush_thread() zeroes thread->fpstate, so no need 35 + * to do anything here. 36 + * 37 + * FALLTHROUGH: Ensure we don't try to overwrite our newly 38 + * initialised state information on the first fault. 39 + */ 40 + 41 + case THREAD_NOTIFY_RELEASE: 42 + iwmmxt_task_release(thread); 43 + break; 44 + 45 + case THREAD_NOTIFY_SWITCH: 46 + iwmmxt_task_switch(thread); 47 + break; 48 + } 49 + 50 + return NOTIFY_DONE; 51 + } 52 + 53 + static struct notifier_block iwmmxt_notifier_block = { 54 + .notifier_call = iwmmxt_do, 55 + }; 56 + 57 + static int __init iwmmxt_init(void) 58 + { 59 + thread_register_notifier(&iwmmxt_notifier_block); 60 + 61 + return 0; 62 + } 63 + 64 + late_initcall(iwmmxt_init);
+12 -15
arch/arm/kernel/iwmmxt.S
··· 271 271 /* 272 272 * Concan handling on task switch 273 273 * 274 - * r0 = previous task_struct pointer (must be preserved) 275 - * r1 = previous thread_info pointer 276 - * r2 = next thread_info pointer (must be preserved) 274 + * r0 = next thread_info pointer 277 275 * 278 - * Called only from __switch_to with task preemption disabled. 279 - * No need to care about preserving r4 and above. 276 + * Called only from the iwmmxt notifier with task preemption disabled. 280 277 */ 281 278 ENTRY(iwmmxt_task_switch) 282 279 283 - mrc p15, 0, r4, c15, c1, 0 284 - tst r4, #0x3 @ CP0 and CP1 accessible? 280 + mrc p15, 0, r1, c15, c1, 0 281 + tst r1, #0x3 @ CP0 and CP1 accessible? 285 282 bne 1f @ yes: block them for next task 286 283 287 - ldr r5, =concan_owner 288 - add r6, r2, #TI_IWMMXT_STATE @ get next task Concan save area 289 - ldr r5, [r5] @ get current Concan owner 290 - teq r5, r6 @ next task owns it? 284 + ldr r2, =concan_owner 285 + add r3, r0, #TI_IWMMXT_STATE @ get next task Concan save area 286 + ldr r2, [r2] @ get current Concan owner 287 + teq r2, r3 @ next task owns it? 291 288 movne pc, lr @ no: leave Concan disabled 292 289 293 - 1: eor r4, r4, #3 @ flip Concan access 294 - mcr p15, 0, r4, c15, c1, 0 290 + 1: eor r1, r1, #3 @ flip Concan access 291 + mcr p15, 0, r1, c15, c1, 0 295 292 296 - mrc p15, 0, r4, c2, c0, 0 297 - sub pc, lr, r4, lsr #32 @ cpwait and return 293 + mrc p15, 0, r1, c2, c0, 0 294 + sub pc, lr, r1, lsr #32 @ cpwait and return 298 295 299 296 /* 300 297 * Remove Concan ownership of given task
-6
arch/arm/kernel/process.c
··· 352 352 memset(&thread->fpstate, 0, sizeof(union fp_state)); 353 353 354 354 thread_notify(THREAD_NOTIFY_FLUSH, thread); 355 - #if defined(CONFIG_IWMMXT) 356 - iwmmxt_task_release(thread); 357 - #endif 358 355 } 359 356 360 357 void release_thread(struct task_struct *dead_task) ··· 359 362 struct thread_info *thread = task_thread_info(dead_task); 360 363 361 364 thread_notify(THREAD_NOTIFY_RELEASE, thread); 362 - #if defined(CONFIG_IWMMXT) 363 - iwmmxt_task_release(thread); 364 - #endif 365 365 } 366 366 367 367 asmlinkage void ret_from_fork(void) __asm__("ret_from_fork");
+2 -2
arch/arm/kernel/setup.c
··· 344 344 cpu_cache = *list->cache; 345 345 #endif 346 346 347 - printk("CPU: %s [%08x] revision %d (ARMv%s)\n", 347 + printk("CPU: %s [%08x] revision %d (ARMv%s), cr=%08x\n", 348 348 cpu_name, processor_id, (int)processor_id & 15, 349 - proc_arch[cpu_architecture()]); 349 + proc_arch[cpu_architecture()], cr_alignment); 350 350 351 351 sprintf(system_utsname.machine, "%s%c", list->arch_name, ENDIANNESS); 352 352 sprintf(elf_platform, "%s%c", list->elf_name, ENDIANNESS);
+65 -21
arch/arm/mach-at91rm9200/Kconfig
··· 1 - if ARCH_AT91RM9200 1 + if ARCH_AT91 2 2 3 - menu "AT91RM9200 Implementations" 3 + menu "Atmel AT91 System-on-Chip" 4 + 5 + comment "Atmel AT91 Processors" 6 + 7 + config ARCH_AT91RM9200 8 + bool "AT91RM9200" 9 + 10 + config ARCH_AT91SAM9260 11 + bool "AT91SAM9260" 12 + 13 + config ARCH_AT91SAM9261 14 + bool "AT91SAM9261" 15 + 16 + # ---------------------------------------------------------- 17 + 18 + if ARCH_AT91RM9200 4 19 5 20 comment "AT91RM9200 Board Type" 6 21 ··· 23 8 bool "Ajeco 1ARM Single Board Computer" 24 9 depends on ARCH_AT91RM9200 25 10 help 26 - Select this if you are using Ajeco's 1ARM Single Board Computer 11 + Select this if you are using Ajeco's 1ARM Single Board Computer. 12 + <http://www.ajeco.fi/products.htm> 27 13 28 14 config ARCH_AT91RM9200DK 29 15 bool "Atmel AT91RM9200-DK Development board" 30 16 depends on ARCH_AT91RM9200 31 17 help 32 - Select this if you are using Atmel's AT91RM9200-DK Development board 18 + Select this if you are using Atmel's AT91RM9200-DK Development board. 19 + (Discontinued) 20 + 33 21 34 22 config MACH_AT91RM9200EK 35 23 bool "Atmel AT91RM9200-EK Evaluation Kit" 36 24 depends on ARCH_AT91RM9200 37 25 help 38 - Select this if you are using Atmel's AT91RM9200-EK Evaluation Kit 26 + Select this if you are using Atmel's AT91RM9200-EK Evaluation Kit. 27 + <http://www.atmel.com/dyn/products/tools_card.asp?tool_id=3507> 39 28 40 29 config MACH_CSB337 41 - bool "Cogent CSB337 board" 30 + bool "Cogent CSB337" 42 31 depends on ARCH_AT91RM9200 43 32 help 44 - Select this if you are using Cogent's CSB337 board 33 + Select this if you are using Cogent's CSB337 board. 34 + <http://www.cogcomp.com/csb_csb337.htm> 45 35 46 36 config MACH_CSB637 47 - bool "Cogent CSB637 board" 37 + bool "Cogent CSB637" 48 38 depends on ARCH_AT91RM9200 49 39 help 50 - Select this if you are using Cogent's CSB637 board 40 + Select this if you are using Cogent's CSB637 board. 41 + <http://www.cogcomp.com/csb_csb637.htm> 51 42 52 43 config MACH_CARMEVA 53 - bool "Conitec's ARM&EVA" 44 + bool "Conitec ARM&EVA" 54 45 depends on ARCH_AT91RM9200 55 46 help 56 - Select this if you are using Conitec's AT91RM9200-MCU-Module 57 - 58 - config MACH_KB9200 59 - bool "KwikByte's KB920x" 60 - depends on ARCH_AT91RM9200 61 - help 62 - Select this if you are using KwikByte's KB920x board 47 + Select this if you are using Conitec's AT91RM9200-MCU-Module. 48 + <http://www.conitec.net/english/linuxboard.htm> 63 49 64 50 config MACH_ATEB9200 65 - bool "Embest's ATEB9200" 51 + bool "Embest ATEB9200" 66 52 depends on ARCH_AT91RM9200 67 53 help 68 - Select this if you are using Embest's ATEB9200 board 54 + Select this if you are using Embest's ATEB9200 board. 55 + <http://www.embedinfo.com/english/product/ATEB9200.asp> 56 + 57 + config MACH_KB9200 58 + bool "KwikByte KB920x" 59 + depends on ARCH_AT91RM9200 60 + help 61 + Select this if you are using KwikByte's KB920x board. 62 + <http://kwikbyte.com/KB9202_description_new.htm> 69 63 70 64 config MACH_KAFA 71 65 bool "Sperry-Sun KAFA board" 72 66 depends on ARCH_AT91RM9200 73 67 help 74 - Select this if you are using Sperry-Sun's KAFA board 68 + Select this if you are using Sperry-Sun's KAFA board. 69 + 70 + endif 71 + 72 + # ---------------------------------------------------------- 73 + 74 + if ARCH_AT91SAM9260 75 + 76 + comment "AT91SAM9260 Board Type" 77 + 78 + endif 79 + 80 + # ---------------------------------------------------------- 81 + 82 + if ARCH_AT91SAM9261 83 + 84 + comment "AT91SAM9261 Board Type" 85 + 86 + endif 75 87 76 88 77 - comment "AT91RM9200 Feature Selections" 89 + # ---------------------------------------------------------- 90 + 91 + comment "AT91 Feature Selections" 78 92 79 93 config AT91_PROGRAMMABLE_CLOCKS 80 94 bool "Programmable Clocks"
+11 -2
arch/arm/mach-at91rm9200/Makefile
··· 2 2 # Makefile for the linux kernel. 3 3 # 4 4 5 - obj-y := clock.o irq.o time.o gpio.o common.o devices.o 5 + obj-y := clock.o irq.o gpio.o devices.o 6 6 obj-m := 7 7 obj-n := 8 8 obj- := 9 9 10 10 obj-$(CONFIG_PM) += pm.o 11 11 12 - # Board-specific support 12 + # CPU-specific support 13 + obj-$(CONFIG_ARCH_AT91RM9200) += at91rm9200.o at91rm9200_time.o 14 + obj-$(CONFIG_ARCH_AT91SAM9260) += 15 + obj-$(CONFIG_ARCH_AT91SAM9261) += 16 + 17 + # AT91RM9200 Board-specific support 13 18 obj-$(CONFIG_MACH_ONEARM) += board-1arm.o 14 19 obj-$(CONFIG_ARCH_AT91RM9200DK) += board-dk.o 15 20 obj-$(CONFIG_MACH_AT91RM9200EK) += board-ek.o ··· 24 19 obj-$(CONFIG_MACH_KB9200) += board-kb9202.o 25 20 obj-$(CONFIG_MACH_ATEB9200) += board-eb9200.o 26 21 obj-$(CONFIG_MACH_KAFA) += board-kafa.o 22 + 23 + # AT91SAM9260 board-specific support 24 + 25 + # AT91SAM9261 board-specific support 27 26 28 27 # LEDs support 29 28 led-$(CONFIG_ARCH_AT91RM9200DK) += leds.o
+1 -1
arch/arm/mach-at91rm9200/common.c arch/arm/mach-at91rm9200/at91rm9200.c
··· 1 1 /* 2 - * arch/arm/mach-at91rm9200/common.c 2 + * arch/arm/mach-at91rm9200/at91rm9200.c 3 3 * 4 4 * Copyright (C) 2005 SAN People 5 5 *
+1 -1
arch/arm/mach-at91rm9200/time.c arch/arm/mach-at91rm9200/at91rm9200_time.c
··· 1 1 /* 2 - * linux/arch/arm/mach-at91rm9200/time.c 2 + * linux/arch/arm/mach-at91rm9200/at91rm9200_time.c 3 3 * 4 4 * Copyright (C) 2003 SAN People 5 5 * Copyright (C) 2003 ATMEL
+12
arch/arm/mach-ep93xx/Kconfig
··· 9 9 10 10 comment "EP93xx Platforms" 11 11 12 + config MACH_EDB9302 13 + bool "Support Cirrus Logic EDB9302" 14 + help 15 + Say 'Y' here if you want your kernel to support the Cirrus 16 + Logic EDB9302 Evaluation Board. 17 + 12 18 config MACH_EDB9315 13 19 bool "Support Cirrus Logic EDB9315" 14 20 help 15 21 Say 'Y' here if you want your kernel to support the Cirrus 16 22 Logic EDB9315 Evaluation Board. 23 + 24 + config MACH_EDB9315A 25 + bool "Support Cirrus Logic EDB9315A" 26 + help 27 + Say 'Y' here if you want your kernel to support the Cirrus 28 + Logic EDB9315A Evaluation Board. 17 29 18 30 config MACH_GESBC9312 19 31 bool "Support Glomation GESBC-9312-sx"
+2
arch/arm/mach-ep93xx/Makefile
··· 6 6 obj-n := 7 7 obj- := 8 8 9 + obj-$(CONFIG_MACH_EDB9302) += edb9302.o 9 10 obj-$(CONFIG_MACH_EDB9315) += edb9315.o 11 + obj-$(CONFIG_MACH_EDB9315A) += edb9315a.o 10 12 obj-$(CONFIG_MACH_GESBC9312) += gesbc9312.o 11 13 obj-$(CONFIG_MACH_TS72XX) += ts72xx.o
+62
arch/arm/mach-ep93xx/edb9302.c
··· 1 + /* 2 + * arch/arm/mach-ep93xx/edb9302.c 3 + * Cirrus Logic EDB9302 support. 4 + * 5 + * Copyright (C) 2006 George Kashperko <george@chas.com.ua> 6 + * 7 + * This program is free software; you can redistribute it and/or modify 8 + * it under the terms of the GNU General Public License as published by 9 + * the Free Software Foundation; either version 2 of the License, or (at 10 + * your option) any later version. 11 + */ 12 + 13 + #include <linux/config.h> 14 + #include <linux/kernel.h> 15 + #include <linux/init.h> 16 + #include <linux/mm.h> 17 + #include <linux/sched.h> 18 + #include <linux/interrupt.h> 19 + #include <linux/ioport.h> 20 + #include <linux/mtd/physmap.h> 21 + #include <linux/platform_device.h> 22 + #include <asm/io.h> 23 + #include <asm/hardware.h> 24 + #include <asm/mach-types.h> 25 + #include <asm/mach/arch.h> 26 + 27 + static struct physmap_flash_data edb9302_flash_data = { 28 + .width = 2, 29 + }; 30 + 31 + static struct resource edb9302_flash_resource = { 32 + .start = 0x60000000, 33 + .end = 0x60ffffff, 34 + .flags = IORESOURCE_MEM, 35 + }; 36 + 37 + static struct platform_device edb9302_flash = { 38 + .name = "physmap-flash", 39 + .id = 0, 40 + .dev = { 41 + .platform_data = &edb9302_flash_data, 42 + }, 43 + .num_resources = 1, 44 + .resource = &edb9302_flash_resource, 45 + }; 46 + 47 + static void __init edb9302_init_machine(void) 48 + { 49 + ep93xx_init_devices(); 50 + platform_device_register(&edb9302_flash); 51 + } 52 + 53 + MACHINE_START(EDB9302, "Cirrus Logic EDB9302 Evaluation Board") 54 + /* Maintainer: George Kashperko <george@chas.com.ua> */ 55 + .phys_io = EP93XX_APB_PHYS_BASE, 56 + .io_pg_offst = ((EP93XX_APB_VIRT_BASE) >> 18) & 0xfffc, 57 + .boot_params = 0x00000100, 58 + .map_io = ep93xx_map_io, 59 + .init_irq = ep93xx_init_irq, 60 + .timer = &ep93xx_timer, 61 + .init_machine = edb9302_init_machine, 62 + MACHINE_END
+62
arch/arm/mach-ep93xx/edb9315a.c
··· 1 + /* 2 + * arch/arm/mach-ep93xx/edb9315a.c 3 + * Cirrus Logic EDB9315A support. 4 + * 5 + * Copyright (C) 2006 Lennert Buytenhek <buytenh@wantstofly.org> 6 + * 7 + * This program is free software; you can redistribute it and/or modify 8 + * it under the terms of the GNU General Public License as published by 9 + * the Free Software Foundation; either version 2 of the License, or (at 10 + * your option) any later version. 11 + */ 12 + 13 + #include <linux/config.h> 14 + #include <linux/kernel.h> 15 + #include <linux/init.h> 16 + #include <linux/mm.h> 17 + #include <linux/sched.h> 18 + #include <linux/interrupt.h> 19 + #include <linux/ioport.h> 20 + #include <linux/mtd/physmap.h> 21 + #include <linux/platform_device.h> 22 + #include <asm/io.h> 23 + #include <asm/hardware.h> 24 + #include <asm/mach-types.h> 25 + #include <asm/mach/arch.h> 26 + 27 + static struct physmap_flash_data edb9315a_flash_data = { 28 + .width = 2, 29 + }; 30 + 31 + static struct resource edb9315a_flash_resource = { 32 + .start = 0x60000000, 33 + .end = 0x60ffffff, 34 + .flags = IORESOURCE_MEM, 35 + }; 36 + 37 + static struct platform_device edb9315a_flash = { 38 + .name = "physmap-flash", 39 + .id = 0, 40 + .dev = { 41 + .platform_data = &edb9315a_flash_data, 42 + }, 43 + .num_resources = 1, 44 + .resource = &edb9315a_flash_resource, 45 + }; 46 + 47 + static void __init edb9315a_init_machine(void) 48 + { 49 + ep93xx_init_devices(); 50 + platform_device_register(&edb9315a_flash); 51 + } 52 + 53 + MACHINE_START(EDB9315A, "Cirrus Logic EDB9315A Evaluation Board") 54 + /* Maintainer: Lennert Buytenhek <buytenh@wantstofly.org> */ 55 + .phys_io = EP93XX_APB_PHYS_BASE, 56 + .io_pg_offst = ((EP93XX_APB_VIRT_BASE) >> 18) & 0xfffc, 57 + .boot_params = 0xc0000100, 58 + .map_io = ep93xx_map_io, 59 + .init_irq = ep93xx_init_irq, 60 + .timer = &ep93xx_timer, 61 + .init_machine = edb9315a_init_machine, 62 + MACHINE_END
+9 -6
arch/arm/mach-iop3xx/Kconfig
··· 30 30 select ARCH_IOP331 31 31 help 32 32 Say Y here if you want to run your kernel on the Intel IQ80332 33 - evaluation kit for the IOP332 chipset 33 + evaluation kit for the IOP332 chipset. 34 34 35 35 config ARCH_EP80219 36 - bool "Enable support for EP80219" 37 - select ARCH_IOP321 38 - select ARCH_IQ31244 36 + bool "Enable support for EP80219" 37 + select ARCH_IOP321 38 + select ARCH_IQ31244 39 + help 40 + Say Y here if you want to run your kernel on the Intel EP80219 41 + evaluation kit for the Intel 80219 chipset (a IOP321 variant). 39 42 40 43 # Which IOP variant are we running? 41 44 config ARCH_IOP321 ··· 59 56 bool "Chip stepping D of the IOP80331 processor or IOP80333" 60 57 depends on (ARCH_IOP331) 61 58 help 62 - Say Y here if you have StepD of the IOP80331 or IOP8033 63 - based platforms. 59 + Say Y here if you have StepD of the IOP80331 or IOP8033 60 + based platforms. 64 61 65 62 endmenu 66 63 endif
+7
arch/arm/mach-omap1/Kconfig
··· 62 62 Support for TI OMAP 730 Perseus2 board. Say Y here if you have such 63 63 a board. 64 64 65 + config MACH_OMAP_FSAMPLE 66 + bool "TI F-Sample" 67 + depends on ARCH_OMAP1 && ARCH_OMAP730 68 + help 69 + Support for TI OMAP 850 F-Sample board. Say Y here if you have such 70 + a board. 71 + 65 72 config MACH_VOICEBLUE 66 73 bool "Voiceblue" 67 74 depends on ARCH_OMAP1 && ARCH_OMAP15XX
+1
arch/arm/mach-omap1/Makefile
··· 17 17 obj-$(CONFIG_MACH_OMAP_INNOVATOR) += board-innovator.o 18 18 obj-$(CONFIG_MACH_OMAP_GENERIC) += board-generic.o 19 19 obj-$(CONFIG_MACH_OMAP_PERSEUS2) += board-perseus2.o 20 + obj-$(CONFIG_MACH_OMAP_FSAMPLE) += board-fsample.o 20 21 obj-$(CONFIG_MACH_OMAP_OSK) += board-osk.o 21 22 obj-$(CONFIG_MACH_OMAP_H3) += board-h3.o 22 23 obj-$(CONFIG_MACH_VOICEBLUE) += board-voiceblue.o
+7
arch/arm/mach-omap1/board-ams-delta.c
··· 80 80 .enabled_uarts = 1, 81 81 }; 82 82 83 + static struct omap_usb_config ams_delta_usb_config __initdata = { 84 + .register_host = 1, 85 + .hmc_mode = 16, 86 + .pins[0] = 2, 87 + }; 88 + 83 89 static struct omap_board_config_kernel ams_delta_config[] = { 84 90 { OMAP_TAG_UART, &ams_delta_uart_config }, 91 + { OMAP_TAG_USB, &ams_delta_usb_config }, 85 92 }; 86 93 87 94 static struct platform_device ams_delta_led_device = {
+319
arch/arm/mach-omap1/board-fsample.c
··· 1 + /* 2 + * linux/arch/arm/mach-omap1/board-fsample.c 3 + * 4 + * Modified from board-perseus2.c 5 + * 6 + * Original OMAP730 support by Jean Pihet <j-pihet@ti.com> 7 + * Updated for 2.6 by Kevin Hilman <kjh@hilman.org> 8 + * 9 + * This program is free software; you can redistribute it and/or modify 10 + * it under the terms of the GNU General Public License version 2 as 11 + * published by the Free Software Foundation. 12 + */ 13 + 14 + #include <linux/kernel.h> 15 + #include <linux/init.h> 16 + #include <linux/platform_device.h> 17 + #include <linux/delay.h> 18 + #include <linux/mtd/mtd.h> 19 + #include <linux/mtd/nand.h> 20 + #include <linux/mtd/partitions.h> 21 + #include <linux/input.h> 22 + 23 + #include <asm/hardware.h> 24 + #include <asm/mach-types.h> 25 + #include <asm/mach/arch.h> 26 + #include <asm/mach/flash.h> 27 + #include <asm/mach/map.h> 28 + 29 + #include <asm/arch/tc.h> 30 + #include <asm/arch/gpio.h> 31 + #include <asm/arch/mux.h> 32 + #include <asm/arch/fpga.h> 33 + #include <asm/arch/keypad.h> 34 + #include <asm/arch/common.h> 35 + #include <asm/arch/board.h> 36 + #include <asm/arch/board-fsample.h> 37 + 38 + static int fsample_keymap[] = { 39 + KEY(0,0,KEY_UP), 40 + KEY(0,1,KEY_RIGHT), 41 + KEY(0,2,KEY_LEFT), 42 + KEY(0,3,KEY_DOWN), 43 + KEY(0,4,KEY_CENTER), 44 + KEY(0,5,KEY_0_5), 45 + KEY(1,0,KEY_SOFT2), 46 + KEY(1,1,KEY_SEND), 47 + KEY(1,2,KEY_END), 48 + KEY(1,3,KEY_VOLUMEDOWN), 49 + KEY(1,4,KEY_VOLUMEUP), 50 + KEY(1,5,KEY_RECORD), 51 + KEY(2,0,KEY_SOFT1), 52 + KEY(2,1,KEY_3), 53 + KEY(2,2,KEY_6), 54 + KEY(2,3,KEY_9), 55 + KEY(2,4,KEY_SHARP), 56 + KEY(2,5,KEY_2_5), 57 + KEY(3,0,KEY_BACK), 58 + KEY(3,1,KEY_2), 59 + KEY(3,2,KEY_5), 60 + KEY(3,3,KEY_8), 61 + KEY(3,4,KEY_0), 62 + KEY(3,5,KEY_HEADSETHOOK), 63 + KEY(4,0,KEY_HOME), 64 + KEY(4,1,KEY_1), 65 + KEY(4,2,KEY_4), 66 + KEY(4,3,KEY_7), 67 + KEY(4,4,KEY_STAR), 68 + KEY(4,5,KEY_POWER), 69 + 0 70 + }; 71 + 72 + static struct resource smc91x_resources[] = { 73 + [0] = { 74 + .start = H2P2_DBG_FPGA_ETHR_START, /* Physical */ 75 + .end = H2P2_DBG_FPGA_ETHR_START + 0xf, 76 + .flags = IORESOURCE_MEM, 77 + }, 78 + [1] = { 79 + .start = INT_730_MPU_EXT_NIRQ, 80 + .end = 0, 81 + .flags = IORESOURCE_IRQ, 82 + }, 83 + }; 84 + 85 + static struct mtd_partition nor_partitions[] = { 86 + /* bootloader (U-Boot, etc) in first sector */ 87 + { 88 + .name = "bootloader", 89 + .offset = 0, 90 + .size = SZ_128K, 91 + .mask_flags = MTD_WRITEABLE, /* force read-only */ 92 + }, 93 + /* bootloader params in the next sector */ 94 + { 95 + .name = "params", 96 + .offset = MTDPART_OFS_APPEND, 97 + .size = SZ_128K, 98 + .mask_flags = 0, 99 + }, 100 + /* kernel */ 101 + { 102 + .name = "kernel", 103 + .offset = MTDPART_OFS_APPEND, 104 + .size = SZ_2M, 105 + .mask_flags = 0 106 + }, 107 + /* rest of flash is a file system */ 108 + { 109 + .name = "rootfs", 110 + .offset = MTDPART_OFS_APPEND, 111 + .size = MTDPART_SIZ_FULL, 112 + .mask_flags = 0 113 + }, 114 + }; 115 + 116 + static struct flash_platform_data nor_data = { 117 + .map_name = "cfi_probe", 118 + .width = 2, 119 + .parts = nor_partitions, 120 + .nr_parts = ARRAY_SIZE(nor_partitions), 121 + }; 122 + 123 + static struct resource nor_resource = { 124 + .start = OMAP_CS0_PHYS, 125 + .end = OMAP_CS0_PHYS + SZ_32M - 1, 126 + .flags = IORESOURCE_MEM, 127 + }; 128 + 129 + static struct platform_device nor_device = { 130 + .name = "omapflash", 131 + .id = 0, 132 + .dev = { 133 + .platform_data = &nor_data, 134 + }, 135 + .num_resources = 1, 136 + .resource = &nor_resource, 137 + }; 138 + 139 + static struct nand_platform_data nand_data = { 140 + .options = NAND_SAMSUNG_LP_OPTIONS, 141 + }; 142 + 143 + static struct resource nand_resource = { 144 + .start = OMAP_CS3_PHYS, 145 + .end = OMAP_CS3_PHYS + SZ_4K - 1, 146 + .flags = IORESOURCE_MEM, 147 + }; 148 + 149 + static struct platform_device nand_device = { 150 + .name = "omapnand", 151 + .id = 0, 152 + .dev = { 153 + .platform_data = &nand_data, 154 + }, 155 + .num_resources = 1, 156 + .resource = &nand_resource, 157 + }; 158 + 159 + static struct platform_device smc91x_device = { 160 + .name = "smc91x", 161 + .id = 0, 162 + .num_resources = ARRAY_SIZE(smc91x_resources), 163 + .resource = smc91x_resources, 164 + }; 165 + 166 + static struct resource kp_resources[] = { 167 + [0] = { 168 + .start = INT_730_MPUIO_KEYPAD, 169 + .end = INT_730_MPUIO_KEYPAD, 170 + .flags = IORESOURCE_IRQ, 171 + }, 172 + }; 173 + 174 + static struct omap_kp_platform_data kp_data = { 175 + .rows = 8, 176 + .cols = 8, 177 + .keymap = fsample_keymap, 178 + }; 179 + 180 + static struct platform_device kp_device = { 181 + .name = "omap-keypad", 182 + .id = -1, 183 + .dev = { 184 + .platform_data = &kp_data, 185 + }, 186 + .num_resources = ARRAY_SIZE(kp_resources), 187 + .resource = kp_resources, 188 + }; 189 + 190 + static struct platform_device lcd_device = { 191 + .name = "lcd_p2", 192 + .id = -1, 193 + }; 194 + 195 + static struct platform_device *devices[] __initdata = { 196 + &nor_device, 197 + &nand_device, 198 + &smc91x_device, 199 + &kp_device, 200 + &lcd_device, 201 + }; 202 + 203 + #define P2_NAND_RB_GPIO_PIN 62 204 + 205 + static int nand_dev_ready(struct nand_platform_data *data) 206 + { 207 + return omap_get_gpio_datain(P2_NAND_RB_GPIO_PIN); 208 + } 209 + 210 + static struct omap_uart_config fsample_uart_config __initdata = { 211 + .enabled_uarts = ((1 << 0) | (1 << 1)), 212 + }; 213 + 214 + static struct omap_lcd_config fsample_lcd_config __initdata = { 215 + .ctrl_name = "internal", 216 + }; 217 + 218 + static struct omap_board_config_kernel fsample_config[] = { 219 + { OMAP_TAG_UART, &fsample_uart_config }, 220 + { OMAP_TAG_LCD, &fsample_lcd_config }, 221 + }; 222 + 223 + static void __init omap_fsample_init(void) 224 + { 225 + if (!(omap_request_gpio(P2_NAND_RB_GPIO_PIN))) 226 + nand_data.dev_ready = nand_dev_ready; 227 + 228 + omap_cfg_reg(L3_1610_FLASH_CS2B_OE); 229 + omap_cfg_reg(M8_1610_FLASH_CS2B_WE); 230 + 231 + platform_add_devices(devices, ARRAY_SIZE(devices)); 232 + 233 + omap_board_config = fsample_config; 234 + omap_board_config_size = ARRAY_SIZE(fsample_config); 235 + omap_serial_init(); 236 + } 237 + 238 + static void __init fsample_init_smc91x(void) 239 + { 240 + fpga_write(1, H2P2_DBG_FPGA_LAN_RESET); 241 + mdelay(50); 242 + fpga_write(fpga_read(H2P2_DBG_FPGA_LAN_RESET) & ~1, 243 + H2P2_DBG_FPGA_LAN_RESET); 244 + mdelay(50); 245 + } 246 + 247 + void omap_fsample_init_irq(void) 248 + { 249 + omap1_init_common_hw(); 250 + omap_init_irq(); 251 + omap_gpio_init(); 252 + fsample_init_smc91x(); 253 + } 254 + 255 + /* Only FPGA needs to be mapped here. All others are done with ioremap */ 256 + static struct map_desc omap_fsample_io_desc[] __initdata = { 257 + { 258 + .virtual = H2P2_DBG_FPGA_BASE, 259 + .pfn = __phys_to_pfn(H2P2_DBG_FPGA_START), 260 + .length = H2P2_DBG_FPGA_SIZE, 261 + .type = MT_DEVICE 262 + }, 263 + { 264 + .virtual = FSAMPLE_CPLD_BASE, 265 + .pfn = __phys_to_pfn(FSAMPLE_CPLD_START), 266 + .length = FSAMPLE_CPLD_SIZE, 267 + .type = MT_DEVICE 268 + } 269 + }; 270 + 271 + static void __init omap_fsample_map_io(void) 272 + { 273 + omap1_map_common_io(); 274 + iotable_init(omap_fsample_io_desc, 275 + ARRAY_SIZE(omap_fsample_io_desc)); 276 + 277 + /* Early, board-dependent init */ 278 + 279 + /* 280 + * Hold GSM Reset until needed 281 + */ 282 + omap_writew(omap_readw(OMAP730_DSP_M_CTL) & ~1, OMAP730_DSP_M_CTL); 283 + 284 + /* 285 + * UARTs -> done automagically by 8250 driver 286 + */ 287 + 288 + /* 289 + * CSx timings, GPIO Mux ... setup 290 + */ 291 + 292 + /* Flash: CS0 timings setup */ 293 + omap_writel(0x0000fff3, OMAP730_FLASH_CFG_0); 294 + omap_writel(0x00000088, OMAP730_FLASH_ACFG_0); 295 + 296 + /* 297 + * Ethernet support through the debug board 298 + * CS1 timings setup 299 + */ 300 + omap_writel(0x0000fff3, OMAP730_FLASH_CFG_1); 301 + omap_writel(0x00000000, OMAP730_FLASH_ACFG_1); 302 + 303 + /* 304 + * Configure MPU_EXT_NIRQ IO in IO_CONF9 register, 305 + * It is used as the Ethernet controller interrupt 306 + */ 307 + omap_writel(omap_readl(OMAP730_IO_CONF_9) & 0x1FFFFFFF, OMAP730_IO_CONF_9); 308 + } 309 + 310 + MACHINE_START(OMAP_FSAMPLE, "OMAP730 F-Sample") 311 + /* Maintainer: Brian Swetland <swetland@google.com> */ 312 + .phys_io = 0xfff00000, 313 + .io_pg_offst = ((0xfef00000) >> 18) & 0xfffc, 314 + .boot_params = 0x10000100, 315 + .map_io = omap_fsample_map_io, 316 + .init_irq = omap_fsample_init_irq, 317 + .init_machine = omap_fsample_init, 318 + .timer = &omap_timer, 319 + MACHINE_END
+75
arch/arm/mach-omap1/board-innovator.c
··· 37 37 #include <asm/arch/usb.h> 38 38 #include <asm/arch/keypad.h> 39 39 #include <asm/arch/common.h> 40 + #include <asm/arch/mcbsp.h> 41 + #include <asm/arch/omap-alsa.h> 40 42 41 43 static int innovator_keymap[] = { 42 44 KEY(0, 0, KEY_F1), ··· 114 112 .resource = &innovator_flash_resource, 115 113 }; 116 114 115 + #define DEFAULT_BITPERSAMPLE 16 116 + 117 + static struct omap_mcbsp_reg_cfg mcbsp_regs = { 118 + .spcr2 = FREE | FRST | GRST | XRST | XINTM(3), 119 + .spcr1 = RINTM(3) | RRST, 120 + .rcr2 = RPHASE | RFRLEN2(OMAP_MCBSP_WORD_8) | 121 + RWDLEN2(OMAP_MCBSP_WORD_16) | RDATDLY(0), 122 + .rcr1 = RFRLEN1(OMAP_MCBSP_WORD_8) | RWDLEN1(OMAP_MCBSP_WORD_16), 123 + .xcr2 = XPHASE | XFRLEN2(OMAP_MCBSP_WORD_8) | 124 + XWDLEN2(OMAP_MCBSP_WORD_16) | XDATDLY(0) | XFIG, 125 + .xcr1 = XFRLEN1(OMAP_MCBSP_WORD_8) | XWDLEN1(OMAP_MCBSP_WORD_16), 126 + .srgr1 = FWID(DEFAULT_BITPERSAMPLE - 1), 127 + .srgr2 = GSYNC | CLKSP | FSGM | FPER(DEFAULT_BITPERSAMPLE * 2 - 1), 128 + /*.pcr0 = FSXM | FSRM | CLKXM | CLKRM | CLKXP | CLKRP,*/ /* mcbsp: master */ 129 + .pcr0 = CLKXP | CLKRP, /* mcbsp: slave */ 130 + }; 131 + 132 + static struct omap_alsa_codec_config alsa_config = { 133 + .name = "OMAP Innovator AIC23", 134 + .mcbsp_regs_alsa = &mcbsp_regs, 135 + .codec_configure_dev = NULL, // aic23_configure, 136 + .codec_set_samplerate = NULL, // aic23_set_samplerate, 137 + .codec_clock_setup = NULL, // aic23_clock_setup, 138 + .codec_clock_on = NULL, // aic23_clock_on, 139 + .codec_clock_off = NULL, // aic23_clock_off, 140 + .get_default_samplerate = NULL, // aic23_get_default_samplerate, 141 + }; 142 + 143 + static struct platform_device innovator_mcbsp1_device = { 144 + .name = "omap_alsa_mcbsp", 145 + .id = 1, 146 + .dev = { 147 + .platform_data = &alsa_config, 148 + }, 149 + }; 150 + 117 151 static struct resource innovator_kp_resources[] = { 118 152 [0] = { 119 153 .start = INT_KEYBOARD, ··· 176 138 177 139 178 140 #ifdef CONFIG_ARCH_OMAP15XX 141 + 142 + #include <linux/spi/spi.h> 143 + #include <linux/spi/ads7846.h> 144 + 179 145 180 146 /* Only FPGA needs to be mapped here. All others are done with ioremap */ 181 147 static struct map_desc innovator1510_io_desc[] __initdata = { ··· 216 174 .id = -1, 217 175 }; 218 176 177 + static struct platform_device innovator1510_spi_device = { 178 + .name = "spi_inn1510", 179 + .id = -1, 180 + }; 181 + 219 182 static struct platform_device *innovator1510_devices[] __initdata = { 220 183 &innovator_flash_device, 221 184 &innovator1510_smc91x_device, 185 + &innovator_mcbsp1_device, 222 186 &innovator_kp_device, 223 187 &innovator1510_lcd_device, 188 + &innovator1510_spi_device, 224 189 }; 190 + 191 + static int innovator_get_pendown_state(void) 192 + { 193 + return !(fpga_read(OMAP1510_FPGA_TOUCHSCREEN) & (1 << 5)); 194 + } 195 + 196 + static const struct ads7846_platform_data innovator1510_ts_info = { 197 + .model = 7846, 198 + .vref_delay_usecs = 100, /* internal, no capacitor */ 199 + .x_plate_ohms = 419, 200 + .y_plate_ohms = 486, 201 + .get_pendown_state = innovator_get_pendown_state, 202 + }; 203 + 204 + static struct spi_board_info __initdata innovator1510_boardinfo[] = { { 205 + /* FPGA (bus "10") CS0 has an ads7846e */ 206 + .modalias = "ads7846", 207 + .platform_data = &innovator1510_ts_info, 208 + .irq = OMAP1510_INT_FPGA_TS, 209 + .max_speed_hz = 120000 /* max sample rate at 3V */ 210 + * 26 /* command + data + overhead */, 211 + .bus_num = 10, 212 + .chip_select = 0, 213 + } }; 225 214 226 215 #endif /* CONFIG_ARCH_OMAP15XX */ 227 216 ··· 384 311 #ifdef CONFIG_ARCH_OMAP15XX 385 312 if (cpu_is_omap1510()) { 386 313 platform_add_devices(innovator1510_devices, ARRAY_SIZE(innovator1510_devices)); 314 + spi_register_board_info(innovator1510_boardinfo, 315 + ARRAY_SIZE(innovator1510_boardinfo)); 387 316 } 388 317 #endif 389 318 #ifdef CONFIG_ARCH_OMAP16XX
+94 -53
arch/arm/mach-omap1/board-osk.c
··· 33 33 34 34 #include <linux/mtd/mtd.h> 35 35 #include <linux/mtd/partitions.h> 36 - #include <linux/input.h> 37 36 38 37 #include <asm/hardware.h> 39 38 #include <asm/mach-types.h> ··· 44 45 #include <asm/arch/usb.h> 45 46 #include <asm/arch/mux.h> 46 47 #include <asm/arch/tc.h> 47 - #include <asm/arch/keypad.h> 48 48 #include <asm/arch/common.h> 49 49 #include <asm/arch/mcbsp.h> 50 50 #include <asm/arch/omap-alsa.h> 51 - 52 - static int osk_keymap[] = { 53 - KEY(0, 0, KEY_F1), 54 - KEY(0, 3, KEY_UP), 55 - KEY(1, 1, KEY_LEFTCTRL), 56 - KEY(1, 2, KEY_LEFT), 57 - KEY(2, 0, KEY_SPACE), 58 - KEY(2, 1, KEY_ESC), 59 - KEY(2, 2, KEY_DOWN), 60 - KEY(3, 2, KEY_ENTER), 61 - KEY(3, 3, KEY_RIGHT), 62 - 0 63 - }; 64 - 65 51 66 52 static struct mtd_partition osk_partitions[] = { 67 53 /* bootloader (U-Boot, etc) in first sector */ ··· 165 181 166 182 static struct platform_device osk5912_mcbsp1_device = { 167 183 .name = "omap_alsa_mcbsp", 168 - .id = 1, 184 + .id = 1, 169 185 .dev = { 170 186 .platform_data = &alsa_config, 171 187 }, 172 - }; 173 - 174 - static struct resource osk5912_kp_resources[] = { 175 - [0] = { 176 - .start = INT_KEYBOARD, 177 - .end = INT_KEYBOARD, 178 - .flags = IORESOURCE_IRQ, 179 - }, 180 - }; 181 - 182 - static struct omap_kp_platform_data osk_kp_data = { 183 - .rows = 8, 184 - .cols = 8, 185 - .keymap = osk_keymap, 186 - }; 187 - 188 - static struct platform_device osk5912_kp_device = { 189 - .name = "omap-keypad", 190 - .id = -1, 191 - .dev = { 192 - .platform_data = &osk_kp_data, 193 - }, 194 - .num_resources = ARRAY_SIZE(osk5912_kp_resources), 195 - .resource = osk5912_kp_resources, 196 - }; 197 - 198 - static struct platform_device osk5912_lcd_device = { 199 - .name = "lcd_osk", 200 - .id = -1, 201 188 }; 202 189 203 190 static struct platform_device *osk5912_devices[] __initdata = { ··· 176 221 &osk5912_smc91x_device, 177 222 &osk5912_cf_device, 178 223 &osk5912_mcbsp1_device, 179 - &osk5912_kp_device, 180 - &osk5912_lcd_device, 181 224 }; 182 225 183 226 static void __init osk_init_smc91x(void) ··· 229 276 .enabled_uarts = (1 << 0), 230 277 }; 231 278 279 + #ifdef CONFIG_OMAP_OSK_MISTRAL 232 280 static struct omap_lcd_config osk_lcd_config __initdata = { 233 281 .ctrl_name = "internal", 234 282 }; 283 + #endif 235 284 236 285 static struct omap_board_config_kernel osk_config[] = { 237 286 { OMAP_TAG_USB, &osk_usb_config }, 238 287 { OMAP_TAG_UART, &osk_uart_config }, 288 + #ifdef CONFIG_OMAP_OSK_MISTRAL 239 289 { OMAP_TAG_LCD, &osk_lcd_config }, 290 + #endif 240 291 }; 241 292 242 293 #ifdef CONFIG_OMAP_OSK_MISTRAL 294 + 295 + #include <linux/input.h> 296 + #include <linux/spi/spi.h> 297 + #include <linux/spi/ads7846.h> 298 + 299 + #include <asm/arch/keypad.h> 300 + 301 + static const int osk_keymap[] = { 302 + /* KEY(col, row, code) */ 303 + KEY(0, 0, KEY_F1), /* SW4 */ 304 + KEY(0, 3, KEY_UP), /* (sw2/up) */ 305 + KEY(1, 1, KEY_LEFTCTRL), /* SW5 */ 306 + KEY(1, 2, KEY_LEFT), /* (sw2/left) */ 307 + KEY(2, 0, KEY_SPACE), /* SW3 */ 308 + KEY(2, 1, KEY_ESC), /* SW6 */ 309 + KEY(2, 2, KEY_DOWN), /* (sw2/down) */ 310 + KEY(3, 2, KEY_ENTER), /* (sw2/select) */ 311 + KEY(3, 3, KEY_RIGHT), /* (sw2/right) */ 312 + 0 313 + }; 314 + 315 + static struct omap_kp_platform_data osk_kp_data = { 316 + .rows = 8, 317 + .cols = 8, 318 + .keymap = (int *) osk_keymap, 319 + }; 320 + 321 + static struct resource osk5912_kp_resources[] = { 322 + [0] = { 323 + .start = INT_KEYBOARD, 324 + .end = INT_KEYBOARD, 325 + .flags = IORESOURCE_IRQ, 326 + }, 327 + }; 328 + 329 + static struct platform_device osk5912_kp_device = { 330 + .name = "omap-keypad", 331 + .id = -1, 332 + .dev = { 333 + .platform_data = &osk_kp_data, 334 + }, 335 + .num_resources = ARRAY_SIZE(osk5912_kp_resources), 336 + .resource = osk5912_kp_resources, 337 + }; 338 + 339 + static struct platform_device osk5912_lcd_device = { 340 + .name = "lcd_osk", 341 + .id = -1, 342 + }; 343 + 344 + static struct platform_device *mistral_devices[] __initdata = { 345 + &osk5912_kp_device, 346 + &osk5912_lcd_device, 347 + }; 348 + 349 + static int mistral_get_pendown_state(void) 350 + { 351 + return !omap_get_gpio_datain(4); 352 + } 353 + 354 + static const struct ads7846_platform_data mistral_ts_info = { 355 + .model = 7846, 356 + .vref_delay_usecs = 100, /* internal, no capacitor */ 357 + .x_plate_ohms = 419, 358 + .y_plate_ohms = 486, 359 + .get_pendown_state = mistral_get_pendown_state, 360 + }; 361 + 362 + static struct spi_board_info __initdata mistral_boardinfo[] = { { 363 + /* MicroWire (bus 2) CS0 has an ads7846e */ 364 + .modalias = "ads7846", 365 + .platform_data = &mistral_ts_info, 366 + .irq = OMAP_GPIO_IRQ(4), 367 + .max_speed_hz = 120000 /* max sample rate at 3V */ 368 + * 26 /* command + data + overhead */, 369 + .bus_num = 2, 370 + .chip_select = 0, 371 + } }; 243 372 244 373 #ifdef CONFIG_PM 245 374 static irqreturn_t ··· 333 298 334 299 static void __init osk_mistral_init(void) 335 300 { 336 - /* FIXME here's where to feed in framebuffer, touchpad, and 337 - * keyboard setup ... not in the drivers for those devices! 338 - * 339 - * NOTE: we could actually tell if there's a Mistral board 301 + /* NOTE: we could actually tell if there's a Mistral board 340 302 * attached, e.g. by trying to read something from the ads7846. 341 - * But this is too early for that... 303 + * But this arch_init() code is too early for that, since we 304 + * can't talk to the ads or even the i2c eeprom. 342 305 */ 306 + 307 + // omap_cfg_reg(P19_1610_GPIO6); // BUSY 308 + omap_cfg_reg(P20_1610_GPIO4); // PENIRQ 309 + set_irq_type(OMAP_GPIO_IRQ(4), IRQT_FALLING); 310 + spi_register_board_info(mistral_boardinfo, 311 + ARRAY_SIZE(mistral_boardinfo)); 343 312 344 313 /* the sideways button (SW1) is for use as a "wakeup" button */ 345 314 omap_cfg_reg(N15_1610_MPUIO2); ··· 368 329 #endif 369 330 } else 370 331 printk(KERN_ERR "OSK+Mistral: wakeup button is awol\n"); 332 + 333 + platform_add_devices(mistral_devices, ARRAY_SIZE(mistral_devices)); 371 334 } 372 335 #else 373 336 static void __init osk_mistral_init(void) { }
+14 -4
arch/arm/mach-omap1/clock.c
··· 1 + //kernel/linux-omap-fsample/arch/arm/mach-omap1/clock.c#2 - edit change 3808 (text) 1 2 /* 2 3 * linux/arch/arm/mach-omap1/clock.c 3 4 * ··· 21 20 22 21 #include <asm/io.h> 23 22 23 + #include <asm/arch/cpu.h> 24 24 #include <asm/arch/usb.h> 25 25 #include <asm/arch/clock.h> 26 26 #include <asm/arch/sram.h> ··· 272 270 /* 273 271 * In most cases we should not need to reprogram DPLL. 274 272 * Reprogramming the DPLL is tricky, it must be done from SRAM. 273 + * (on 730, bit 13 must always be 1) 275 274 */ 276 - omap_sram_reprogram_clock(ptr->dpllctl_val, ptr->ckctl_val); 275 + if (cpu_is_omap730()) 276 + omap_sram_reprogram_clock(ptr->dpllctl_val, ptr->ckctl_val | 0x2000); 277 + else 278 + omap_sram_reprogram_clock(ptr->dpllctl_val, ptr->ckctl_val); 277 279 278 280 ck_dpll1.rate = ptr->pll_rate; 279 281 propagate_rate(&ck_dpll1); ··· 754 748 printk(KERN_ERR "System frequencies not set. Check your config.\n"); 755 749 /* Guess sane values (60MHz) */ 756 750 omap_writew(0x2290, DPLL_CTL); 757 - omap_writew(0x1005, ARM_CKCTL); 751 + omap_writew(cpu_is_omap730() ? 0x3005 : 0x1005, ARM_CKCTL); 758 752 ck_dpll1.rate = 60000000; 759 753 propagate_rate(&ck_dpll1); 760 754 } ··· 767 761 ck_dpll1.rate / 1000000, (ck_dpll1.rate / 100000) % 10, 768 762 arm_ck.rate / 1000000, (arm_ck.rate / 100000) % 10); 769 763 770 - #ifdef CONFIG_MACH_OMAP_PERSEUS2 764 + #if defined(CONFIG_MACH_OMAP_PERSEUS2) || defined(CONFIG_MACH_OMAP_FSAMPLE) 771 765 /* Select slicer output as OMAP input clock */ 772 766 omap_writew(omap_readw(OMAP730_PCC_UPLD_CTRL) & ~0x1, OMAP730_PCC_UPLD_CTRL); 773 767 #endif 774 768 775 769 /* Turn off DSP and ARM_TIMXO. Make sure ARM_INTHCK is not divided */ 776 - omap_writew(omap_readw(ARM_CKCTL) & 0x0fff, ARM_CKCTL); 770 + /* (on 730, bit 13 must not be cleared) */ 771 + if (cpu_is_omap730()) 772 + omap_writew(omap_readw(ARM_CKCTL) & 0x2fff, ARM_CKCTL); 773 + else 774 + omap_writew(omap_readw(ARM_CKCTL) & 0x0fff, ARM_CKCTL); 777 775 778 776 /* Put DSP/MPUI into reset until needed */ 779 777 omap_writew(0, ARM_RSTCT1);
+5 -2
arch/arm/mach-omap1/pm.c
··· 1 + //kernel/linux-omap-fsample/arch/arm/mach-omap1/pm.c#3 - integrate change 4545 (text) 1 2 /* 2 3 * linux/arch/arm/mach-omap1/pm.c 3 4 * ··· 51 50 #include <asm/mach/irq.h> 52 51 #include <asm/mach-types.h> 53 52 53 + #include <asm/arch/cpu.h> 54 54 #include <asm/arch/irqs.h> 55 55 #include <asm/arch/clock.h> 56 56 #include <asm/arch/sram.h> ··· 328 326 /* stop DSP */ 329 327 omap_writew(omap_readw(ARM_RSTCT1) & ~(1 << DSP_EN), ARM_RSTCT1); 330 328 331 - /* shut down dsp_ck */ 332 - omap_writew(omap_readw(ARM_CKCTL) & ~(1 << EN_DSPCK), ARM_CKCTL); 329 + /* shut down dsp_ck */ 330 + if (!cpu_is_omap730()) 331 + omap_writew(omap_readw(ARM_CKCTL) & ~(1 << EN_DSPCK), ARM_CKCTL); 333 332 334 333 /* temporarily enabling api_ck to access DSP registers */ 335 334 omap_writew(omap_readw(ARM_IDLECT2) | 1 << EN_APICK, ARM_IDLECT2);
+1 -1
arch/arm/mach-omap1/time.c
··· 93 93 * will break. On P2, the timer count rate is 6.5 MHz after programming PTV 94 94 * with 0. This divides the 13MHz input by 2, and is undocumented. 95 95 */ 96 - #ifdef CONFIG_MACH_OMAP_PERSEUS2 96 + #if defined(CONFIG_MACH_OMAP_PERSEUS2) || defined(CONFIG_MACH_OMAP_FSAMPLE) 97 97 /* REVISIT: This ifdef construct should be replaced by a query to clock 98 98 * framework to see if timer base frequency is 12.0, 13.0 or 19.2 MHz. 99 99 */
+1
arch/arm/mach-omap2/Kconfig
··· 8 8 config ARCH_OMAP2420 9 9 bool "OMAP2420 support" 10 10 depends on ARCH_OMAP24XX 11 + select OMAP_DM_TIMER 11 12 12 13 comment "OMAP Board Type" 13 14 depends on ARCH_OMAP2
+3 -2
arch/arm/mach-omap2/Makefile
··· 3 3 # 4 4 5 5 # Common support 6 - obj-y := irq.o id.o io.o sram-fn.o memory.o prcm.o clock.o mux.o devices.o serial.o 6 + obj-y := irq.o id.o io.o sram-fn.o memory.o prcm.o clock.o mux.o devices.o \ 7 + serial.o gpmc.o 7 8 8 9 obj-$(CONFIG_OMAP_MPU_TIMER) += timer-gp.o 9 10 10 11 # Power Management 11 - obj-$(CONFIG_PM) += pm.o sleep.o 12 + obj-$(CONFIG_PM) += pm.o pm-domain.o sleep.o 12 13 13 14 # Specific board support 14 15 obj-$(CONFIG_MACH_OMAP_GENERIC) += board-generic.o
+23 -14
arch/arm/mach-omap2/clock.c
··· 659 659 660 660 /* Isolate control register */ 661 661 div_sel = (SRC_RATE_SEL_MASK & clk->flags); 662 - div_off = clk->src_offset; 662 + div_off = clk->rate_offset; 663 663 664 664 validrate = omap2_clksel_round_rate(clk, rate, &new_div); 665 - if(validrate != rate) 665 + if (validrate != rate) 666 666 return(ret); 667 667 668 668 field_val = omap2_get_clksel(&div_sel, &field_mask, clk); 669 669 if (div_sel == 0) 670 670 return ret; 671 671 672 - if(clk->flags & CM_SYSCLKOUT_SEL1){ 673 - switch(new_div){ 674 - case 16: field_val = 4; break; 675 - case 8: field_val = 3; break; 676 - case 4: field_val = 2; break; 677 - case 2: field_val = 1; break; 678 - case 1: field_val = 0; break; 672 + if (clk->flags & CM_SYSCLKOUT_SEL1) { 673 + switch (new_div) { 674 + case 16: 675 + field_val = 4; 676 + break; 677 + case 8: 678 + field_val = 3; 679 + break; 680 + case 4: 681 + field_val = 2; 682 + break; 683 + case 2: 684 + field_val = 1; 685 + break; 686 + case 1: 687 + field_val = 0; 688 + break; 679 689 } 680 - } 681 - else 690 + } else 682 691 field_val = new_div; 683 692 684 693 reg = (void __iomem *)div_sel; ··· 752 743 val = 0x2; 753 744 break; 754 745 case CM_WKUP_SEL1: 755 - src_reg_addr = (u32)&CM_CLKSEL2_CORE; 746 + src_reg_addr = (u32)&CM_CLKSEL_WKUP; 756 747 mask = 0x3; 757 748 if (src_clk == &func_32k_ck) 758 749 val = 0x0; ··· 792 783 val = 0; 793 784 if (src_clk == &sys_ck) 794 785 val = 1; 795 - if (src_clk == &func_54m_ck) 796 - val = 2; 797 786 if (src_clk == &func_96m_ck) 787 + val = 2; 788 + if (src_clk == &func_54m_ck) 798 789 val = 3; 799 790 break; 800 791 }
+1 -1
arch/arm/mach-omap2/clock.h
··· 1062 1062 .parent = &l4_ck, 1063 1063 .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, 1064 1064 .enable_reg = (void __iomem *)&CM_ICLKEN1_CORE, /* Bit4 */ 1065 - .enable_bit = 0, 1065 + .enable_bit = 4, 1066 1066 .recalc = &omap2_followparent_recalc, 1067 1067 }; 1068 1068
+46
arch/arm/mach-omap2/devices.c
··· 104 104 static inline void omap_init_sti(void) {} 105 105 #endif 106 106 107 + #if defined(CONFIG_SPI_OMAP24XX) 108 + 109 + #include <asm/arch/mcspi.h> 110 + 111 + #define OMAP2_MCSPI1_BASE 0x48098000 112 + #define OMAP2_MCSPI2_BASE 0x4809a000 113 + 114 + /* FIXME: use resources instead */ 115 + 116 + static struct omap2_mcspi_platform_config omap2_mcspi1_config = { 117 + .base = io_p2v(OMAP2_MCSPI1_BASE), 118 + .num_cs = 4, 119 + }; 120 + 121 + struct platform_device omap2_mcspi1 = { 122 + .name = "omap2_mcspi", 123 + .id = 1, 124 + .dev = { 125 + .platform_data = &omap2_mcspi1_config, 126 + }, 127 + }; 128 + 129 + static struct omap2_mcspi_platform_config omap2_mcspi2_config = { 130 + .base = io_p2v(OMAP2_MCSPI2_BASE), 131 + .num_cs = 2, 132 + }; 133 + 134 + struct platform_device omap2_mcspi2 = { 135 + .name = "omap2_mcspi", 136 + .id = 2, 137 + .dev = { 138 + .platform_data = &omap2_mcspi2_config, 139 + }, 140 + }; 141 + 142 + static void omap_init_mcspi(void) 143 + { 144 + platform_device_register(&omap2_mcspi1); 145 + platform_device_register(&omap2_mcspi2); 146 + } 147 + 148 + #else 149 + static inline void omap_init_mcspi(void) {} 150 + #endif 151 + 107 152 /*-------------------------------------------------------------------------*/ 108 153 109 154 static int __init omap2_init_devices(void) ··· 157 112 * in alphabetical order so they're easier to sort through. 158 113 */ 159 114 omap_init_i2c(); 115 + omap_init_mcspi(); 160 116 omap_init_sti(); 161 117 162 118 return 0;
+209
arch/arm/mach-omap2/gpmc.c
··· 1 + /* 2 + * GPMC support functions 3 + * 4 + * Copyright (C) 2005-2006 Nokia Corporation 5 + * 6 + * Author: Juha Yrjola 7 + * 8 + * This program is free software; you can redistribute it and/or modify 9 + * it under the terms of the GNU General Public License version 2 as 10 + * published by the Free Software Foundation. 11 + */ 12 + #include <linux/kernel.h> 13 + #include <linux/init.h> 14 + #include <linux/err.h> 15 + #include <linux/clk.h> 16 + 17 + #include <asm/io.h> 18 + #include <asm/arch/gpmc.h> 19 + 20 + #undef DEBUG 21 + 22 + #define GPMC_BASE 0x6800a000 23 + #define GPMC_REVISION 0x00 24 + #define GPMC_SYSCONFIG 0x10 25 + #define GPMC_SYSSTATUS 0x14 26 + #define GPMC_IRQSTATUS 0x18 27 + #define GPMC_IRQENABLE 0x1c 28 + #define GPMC_TIMEOUT_CONTROL 0x40 29 + #define GPMC_ERR_ADDRESS 0x44 30 + #define GPMC_ERR_TYPE 0x48 31 + #define GPMC_CONFIG 0x50 32 + #define GPMC_STATUS 0x54 33 + #define GPMC_PREFETCH_CONFIG1 0x1e0 34 + #define GPMC_PREFETCH_CONFIG2 0x1e4 35 + #define GPMC_PREFETCH_CONTROL 0x1e8 36 + #define GPMC_PREFETCH_STATUS 0x1f0 37 + #define GPMC_ECC_CONFIG 0x1f4 38 + #define GPMC_ECC_CONTROL 0x1f8 39 + #define GPMC_ECC_SIZE_CONFIG 0x1fc 40 + 41 + #define GPMC_CS0 0x60 42 + #define GPMC_CS_SIZE 0x30 43 + 44 + static void __iomem *gpmc_base = 45 + (void __iomem *) IO_ADDRESS(GPMC_BASE); 46 + static void __iomem *gpmc_cs_base = 47 + (void __iomem *) IO_ADDRESS(GPMC_BASE) + GPMC_CS0; 48 + 49 + static struct clk *gpmc_l3_clk; 50 + 51 + static void gpmc_write_reg(int idx, u32 val) 52 + { 53 + __raw_writel(val, gpmc_base + idx); 54 + } 55 + 56 + static u32 gpmc_read_reg(int idx) 57 + { 58 + return __raw_readl(gpmc_base + idx); 59 + } 60 + 61 + void gpmc_cs_write_reg(int cs, int idx, u32 val) 62 + { 63 + void __iomem *reg_addr; 64 + 65 + reg_addr = gpmc_cs_base + (cs * GPMC_CS_SIZE) + idx; 66 + __raw_writel(val, reg_addr); 67 + } 68 + 69 + u32 gpmc_cs_read_reg(int cs, int idx) 70 + { 71 + return __raw_readl(gpmc_cs_base + (cs * GPMC_CS_SIZE) + idx); 72 + } 73 + 74 + /* TODO: Add support for gpmc_fck to clock framework and use it */ 75 + static unsigned long gpmc_get_fclk_period(void) 76 + { 77 + /* In picoseconds */ 78 + return 1000000000 / ((clk_get_rate(gpmc_l3_clk)) / 1000); 79 + } 80 + 81 + unsigned int gpmc_ns_to_ticks(unsigned int time_ns) 82 + { 83 + unsigned long tick_ps; 84 + 85 + /* Calculate in picosecs to yield more exact results */ 86 + tick_ps = gpmc_get_fclk_period(); 87 + 88 + return (time_ns * 1000 + tick_ps - 1) / tick_ps; 89 + } 90 + 91 + #ifdef DEBUG 92 + static int set_gpmc_timing_reg(int cs, int reg, int st_bit, int end_bit, 93 + int time, const char *name) 94 + #else 95 + static int set_gpmc_timing_reg(int cs, int reg, int st_bit, int end_bit, 96 + int time) 97 + #endif 98 + { 99 + u32 l; 100 + int ticks, mask, nr_bits; 101 + 102 + if (time == 0) 103 + ticks = 0; 104 + else 105 + ticks = gpmc_ns_to_ticks(time); 106 + nr_bits = end_bit - st_bit + 1; 107 + if (ticks >= 1 << nr_bits) 108 + return -1; 109 + 110 + mask = (1 << nr_bits) - 1; 111 + l = gpmc_cs_read_reg(cs, reg); 112 + #ifdef DEBUG 113 + printk(KERN_INFO "GPMC CS%d: %-10s: %d ticks, %3lu ns (was %i ticks)\n", 114 + cs, name, ticks, gpmc_get_fclk_period() * ticks / 1000, 115 + (l >> st_bit) & mask); 116 + #endif 117 + l &= ~(mask << st_bit); 118 + l |= ticks << st_bit; 119 + gpmc_cs_write_reg(cs, reg, l); 120 + 121 + return 0; 122 + } 123 + 124 + #ifdef DEBUG 125 + #define GPMC_SET_ONE(reg, st, end, field) \ 126 + if (set_gpmc_timing_reg(cs, (reg), (st), (end), \ 127 + t->field, #field) < 0) \ 128 + return -1 129 + #else 130 + #define GPMC_SET_ONE(reg, st, end, field) \ 131 + if (set_gpmc_timing_reg(cs, (reg), (st), (end), t->field) < 0) \ 132 + return -1 133 + #endif 134 + 135 + int gpmc_cs_calc_divider(int cs, unsigned int sync_clk) 136 + { 137 + int div; 138 + u32 l; 139 + 140 + l = sync_clk * 1000 + (gpmc_get_fclk_period() - 1); 141 + div = l / gpmc_get_fclk_period(); 142 + if (div > 4) 143 + return -1; 144 + if (div < 0) 145 + div = 1; 146 + 147 + return div; 148 + } 149 + 150 + int gpmc_cs_set_timings(int cs, const struct gpmc_timings *t) 151 + { 152 + int div; 153 + u32 l; 154 + 155 + div = gpmc_cs_calc_divider(cs, t->sync_clk); 156 + if (div < 0) 157 + return -1; 158 + 159 + GPMC_SET_ONE(GPMC_CS_CONFIG2, 0, 3, cs_on); 160 + GPMC_SET_ONE(GPMC_CS_CONFIG2, 8, 12, cs_rd_off); 161 + GPMC_SET_ONE(GPMC_CS_CONFIG2, 16, 20, cs_wr_off); 162 + 163 + GPMC_SET_ONE(GPMC_CS_CONFIG3, 0, 3, adv_on); 164 + GPMC_SET_ONE(GPMC_CS_CONFIG3, 8, 12, adv_rd_off); 165 + GPMC_SET_ONE(GPMC_CS_CONFIG3, 16, 20, adv_wr_off); 166 + 167 + GPMC_SET_ONE(GPMC_CS_CONFIG4, 0, 3, oe_on); 168 + GPMC_SET_ONE(GPMC_CS_CONFIG4, 8, 12, oe_off); 169 + GPMC_SET_ONE(GPMC_CS_CONFIG4, 16, 19, we_on); 170 + GPMC_SET_ONE(GPMC_CS_CONFIG4, 24, 28, we_off); 171 + 172 + GPMC_SET_ONE(GPMC_CS_CONFIG5, 0, 4, rd_cycle); 173 + GPMC_SET_ONE(GPMC_CS_CONFIG5, 8, 12, wr_cycle); 174 + GPMC_SET_ONE(GPMC_CS_CONFIG5, 16, 20, access); 175 + 176 + GPMC_SET_ONE(GPMC_CS_CONFIG5, 24, 27, page_burst_access); 177 + 178 + #ifdef DEBUG 179 + printk(KERN_INFO "GPMC CS%d CLK period is %lu (div %d)\n", 180 + cs, gpmc_get_fclk_period(), div); 181 + #endif 182 + 183 + l = gpmc_cs_read_reg(cs, GPMC_CS_CONFIG1); 184 + l &= ~0x03; 185 + l |= (div - 1); 186 + 187 + return 0; 188 + } 189 + 190 + unsigned long gpmc_cs_get_base_addr(int cs) 191 + { 192 + return (gpmc_cs_read_reg(cs, GPMC_CS_CONFIG7) & 0x1f) << 24; 193 + } 194 + 195 + void __init gpmc_init(void) 196 + { 197 + u32 l; 198 + 199 + gpmc_l3_clk = clk_get(NULL, "core_l3_ck"); 200 + BUG_ON(IS_ERR(gpmc_l3_clk)); 201 + 202 + l = gpmc_read_reg(GPMC_REVISION); 203 + printk(KERN_INFO "GPMC revision %d.%d\n", (l >> 4) & 0x0f, l & 0x0f); 204 + /* Set smart idle mode and automatic L3 clock gating */ 205 + l = gpmc_read_reg(GPMC_SYSCONFIG); 206 + l &= 0x03 << 3; 207 + l |= (0x02 << 3) | (1 << 0); 208 + gpmc_write_reg(GPMC_SYSCONFIG, l); 209 + }
+2
arch/arm/mach-omap2/io.c
··· 26 26 extern void omap_sram_init(void); 27 27 extern int omap2_clk_init(void); 28 28 extern void omap2_check_revision(void); 29 + extern void gpmc_init(void); 29 30 30 31 /* 31 32 * The machine specific code may provide the extra mapping besides the ··· 67 66 { 68 67 omap2_mux_init(); 69 68 omap2_clk_init(); 69 + gpmc_init(); 70 70 }
+32 -6
arch/arm/mach-omap2/mux.c
··· 52 52 /* 24xx clocks */ 53 53 MUX_CFG_24XX("W14_24XX_SYS_CLKOUT", 0x137, 0, 1, 1, 1) 54 54 55 + /* 24xx GPMC wait pin monitoring */ 56 + MUX_CFG_24XX("L3_GPMC_WAIT0", 0x09a, 0, 1, 1, 1) 57 + MUX_CFG_24XX("N7_GPMC_WAIT1", 0x09b, 0, 1, 1, 1) 58 + MUX_CFG_24XX("M1_GPMC_WAIT2", 0x09c, 0, 1, 1, 1) 59 + MUX_CFG_24XX("P1_GPMC_WAIT3", 0x09d, 0, 1, 1, 1) 60 + 55 61 /* 24xx McBSP */ 56 62 MUX_CFG_24XX("Y15_24XX_MCBSP2_CLKX", 0x124, 1, 1, 0, 1) 57 63 MUX_CFG_24XX("R14_24XX_MCBSP2_FSX", 0x125, 1, 1, 0, 1) ··· 65 59 MUX_CFG_24XX("V15_24XX_MCBSP2_DX", 0x127, 1, 1, 0, 1) 66 60 67 61 /* 24xx GPIO */ 68 - MUX_CFG_24XX("M21_242X_GPIO11", 0x0c9, 3, 1, 1, 1) 62 + MUX_CFG_24XX("M21_242X_GPIO11", 0x0c9, 3, 1, 1, 1) 69 63 MUX_CFG_24XX("AA10_242X_GPIO13", 0x0e5, 3, 0, 0, 1) 70 - MUX_CFG_24XX("AA6_242X_GPIO14", 0x0e6, 3, 0, 0, 1) 71 - MUX_CFG_24XX("AA4_242X_GPIO15", 0x0e7, 3, 0, 0, 1) 72 - MUX_CFG_24XX("Y11_242X_GPIO16", 0x0e8, 3, 0, 0, 1) 64 + MUX_CFG_24XX("AA6_242X_GPIO14", 0x0e6, 3, 0, 0, 1) 65 + MUX_CFG_24XX("AA4_242X_GPIO15", 0x0e7, 3, 0, 0, 1) 66 + MUX_CFG_24XX("Y11_242X_GPIO16", 0x0e8, 3, 0, 0, 1) 73 67 MUX_CFG_24XX("AA12_242X_GPIO17", 0x0e9, 3, 0, 0, 1) 74 - MUX_CFG_24XX("AA8_242X_GPIO58", 0x0ea, 3, 0, 0, 1) 68 + MUX_CFG_24XX("AA8_242X_GPIO58", 0x0ea, 3, 0, 0, 1) 75 69 MUX_CFG_24XX("Y20_24XX_GPIO60", 0x12c, 3, 0, 0, 1) 76 - MUX_CFG_24XX("W4__24XX_GPIO74", 0x0f2, 3, 0, 0, 1) 70 + MUX_CFG_24XX("W4__24XX_GPIO74", 0x0f2, 3, 0, 0, 1) 77 71 MUX_CFG_24XX("M15_24XX_GPIO92", 0x10a, 3, 0, 0, 1) 78 72 MUX_CFG_24XX("V14_24XX_GPIO117", 0x128, 3, 1, 0, 1) 73 + 74 + /* 242x DBG GPIO */ 75 + MUX_CFG_24XX("V4_242X_GPIO49", 0xd3, 3, 0, 0, 1) 76 + MUX_CFG_24XX("W2_242X_GPIO50", 0xd4, 3, 0, 0, 1) 77 + MUX_CFG_24XX("U4_242X_GPIO51", 0xd5, 3, 0, 0, 1) 78 + MUX_CFG_24XX("V3_242X_GPIO52", 0xd6, 3, 0, 0, 1) 79 + MUX_CFG_24XX("V2_242X_GPIO53", 0xd7, 3, 0, 0, 1) 80 + MUX_CFG_24XX("V6_242X_GPIO53", 0xcf, 3, 0, 0, 1) 81 + MUX_CFG_24XX("T4_242X_GPIO54", 0xd8, 3, 0, 0, 1) 82 + MUX_CFG_24XX("Y4_242X_GPIO54", 0xd0, 3, 0, 0, 1) 83 + MUX_CFG_24XX("T3_242X_GPIO55", 0xd9, 3, 0, 0, 1) 84 + MUX_CFG_24XX("U2_242X_GPIO56", 0xda, 3, 0, 0, 1) 85 + 86 + /* 24xx external DMA requests */ 87 + MUX_CFG_24XX("AA10_242X_DMAREQ0", 0x0e5, 2, 0, 0, 1) 88 + MUX_CFG_24XX("AA6_242X_DMAREQ1", 0x0e6, 2, 0, 0, 1) 89 + MUX_CFG_24XX("E4_242X_DMAREQ2", 0x074, 2, 0, 0, 1) 90 + MUX_CFG_24XX("G4_242X_DMAREQ3", 0x073, 2, 0, 0, 1) 91 + MUX_CFG_24XX("D3_242X_DMAREQ4", 0x072, 2, 0, 0, 1) 92 + MUX_CFG_24XX("E3_242X_DMAREQ5", 0x071, 2, 0, 0, 1) 79 93 80 94 /* TSC IRQ */ 81 95 MUX_CFG_24XX("P20_24XX_TSC_IRQ", 0x108, 0, 0, 0, 1)
+300
arch/arm/mach-omap2/pm-domain.c
··· 1 + /* 2 + * linux/arch/arm/mach-omap2/pm-domain.c 3 + * 4 + * Power domain functions for OMAP2 5 + * 6 + * Copyright (C) 2006 Nokia Corporation 7 + * Tony Lindgren <tony@atomide.com> 8 + * 9 + * Some code based on earlier OMAP2 sample PM code 10 + * Copyright (C) 2005 Texas Instruments, Inc. 11 + * Richard Woodruff <r-woodruff2@ti.com> 12 + * 13 + * This program is free software; you can redistribute it and/or modify 14 + * it under the terms of the GNU General Public License version 2 as 15 + * published by the Free Software Foundation. 16 + */ 17 + 18 + #include <linux/config.h> 19 + #include <linux/module.h> 20 + #include <linux/init.h> 21 + #include <linux/clk.h> 22 + 23 + #include <asm/io.h> 24 + 25 + #include "prcm-regs.h" 26 + 27 + /* Power domain offsets */ 28 + #define PM_MPU_OFFSET 0x100 29 + #define PM_CORE_OFFSET 0x200 30 + #define PM_GFX_OFFSET 0x300 31 + #define PM_WKUP_OFFSET 0x400 /* Autoidle only */ 32 + #define PM_PLL_OFFSET 0x500 /* Autoidle only */ 33 + #define PM_DSP_OFFSET 0x800 34 + #define PM_MDM_OFFSET 0xc00 35 + 36 + /* Power domain wake-up dependency control register */ 37 + #define PM_WKDEP_OFFSET 0xc8 38 + #define EN_MDM (1 << 5) 39 + #define EN_WKUP (1 << 4) 40 + #define EN_GFX (1 << 3) 41 + #define EN_DSP (1 << 2) 42 + #define EN_MPU (1 << 1) 43 + #define EN_CORE (1 << 0) 44 + 45 + /* Core power domain state transition control register */ 46 + #define PM_PWSTCTRL_OFFSET 0xe0 47 + #define FORCESTATE (1 << 18) /* Only for DSP & GFX */ 48 + #define MEM4RETSTATE (1 << 6) 49 + #define MEM3RETSTATE (1 << 5) 50 + #define MEM2RETSTATE (1 << 4) 51 + #define MEM1RETSTATE (1 << 3) 52 + #define LOGICRETSTATE (1 << 2) /* Logic is retained */ 53 + #define POWERSTATE_OFF 0x3 54 + #define POWERSTATE_RETENTION 0x1 55 + #define POWERSTATE_ON 0x0 56 + 57 + /* Power domain state register */ 58 + #define PM_PWSTST_OFFSET 0xe4 59 + 60 + /* Hardware supervised state transition control register */ 61 + #define CM_CLKSTCTRL_OFFSET 0x48 62 + #define AUTOSTAT_MPU (1 << 0) /* MPU */ 63 + #define AUTOSTAT_DSS (1 << 2) /* Core */ 64 + #define AUTOSTAT_L4 (1 << 1) /* Core */ 65 + #define AUTOSTAT_L3 (1 << 0) /* Core */ 66 + #define AUTOSTAT_GFX (1 << 0) /* GFX */ 67 + #define AUTOSTAT_IVA (1 << 8) /* 2420 IVA in DSP domain */ 68 + #define AUTOSTAT_DSP (1 << 0) /* DSP */ 69 + #define AUTOSTAT_MDM (1 << 0) /* MDM */ 70 + 71 + /* Automatic control of interface clock idling */ 72 + #define CM_AUTOIDLE1_OFFSET 0x30 73 + #define CM_AUTOIDLE2_OFFSET 0x34 /* Core only */ 74 + #define CM_AUTOIDLE3_OFFSET 0x38 /* Core only */ 75 + #define CM_AUTOIDLE4_OFFSET 0x3c /* Core only */ 76 + #define AUTO_54M(x) (((x) & 0x3) << 6) 77 + #define AUTO_96M(x) (((x) & 0x3) << 2) 78 + #define AUTO_DPLL(x) (((x) & 0x3) << 0) 79 + #define AUTO_STOPPED 0x3 80 + #define AUTO_BYPASS_FAST 0x2 /* DPLL only */ 81 + #define AUTO_BYPASS_LOW_POWER 0x1 /* DPLL only */ 82 + #define AUTO_DISABLED 0x0 83 + 84 + /* Voltage control PRCM_VOLTCTRL bits */ 85 + #define AUTO_EXTVOLT (1 << 15) 86 + #define FORCE_EXTVOLT (1 << 14) 87 + #define SETOFF_LEVEL(x) (((x) & 0x3) << 12) 88 + #define MEMRETCTRL (1 << 8) 89 + #define SETRET_LEVEL(x) (((x) & 0x3) << 6) 90 + #define VOLT_LEVEL(x) (((x) & 0x3) << 0) 91 + 92 + #define OMAP24XX_PRCM_VBASE IO_ADDRESS(OMAP24XX_PRCM_BASE) 93 + #define prcm_readl(r) __raw_readl(OMAP24XX_PRCM_VBASE + (r)) 94 + #define prcm_writel(v, r) __raw_writel((v), OMAP24XX_PRCM_VBASE + (r)) 95 + 96 + static u32 pmdomain_get_wakeup_dependencies(int domain_offset) 97 + { 98 + return prcm_readl(domain_offset + PM_WKDEP_OFFSET); 99 + } 100 + 101 + static void pmdomain_set_wakeup_dependencies(u32 state, int domain_offset) 102 + { 103 + prcm_writel(state, domain_offset + PM_WKDEP_OFFSET); 104 + } 105 + 106 + static u32 pmdomain_get_powerstate(int domain_offset) 107 + { 108 + return prcm_readl(domain_offset + PM_PWSTCTRL_OFFSET); 109 + } 110 + 111 + static void pmdomain_set_powerstate(u32 state, int domain_offset) 112 + { 113 + prcm_writel(state, domain_offset + PM_PWSTCTRL_OFFSET); 114 + } 115 + 116 + static u32 pmdomain_get_clock_autocontrol(int domain_offset) 117 + { 118 + return prcm_readl(domain_offset + CM_CLKSTCTRL_OFFSET); 119 + } 120 + 121 + static void pmdomain_set_clock_autocontrol(u32 state, int domain_offset) 122 + { 123 + prcm_writel(state, domain_offset + CM_CLKSTCTRL_OFFSET); 124 + } 125 + 126 + static u32 pmdomain_get_clock_autoidle1(int domain_offset) 127 + { 128 + return prcm_readl(domain_offset + CM_AUTOIDLE1_OFFSET); 129 + } 130 + 131 + /* Core domain only */ 132 + static u32 pmdomain_get_clock_autoidle2(int domain_offset) 133 + { 134 + return prcm_readl(domain_offset + CM_AUTOIDLE2_OFFSET); 135 + } 136 + 137 + /* Core domain only */ 138 + static u32 pmdomain_get_clock_autoidle3(int domain_offset) 139 + { 140 + return prcm_readl(domain_offset + CM_AUTOIDLE3_OFFSET); 141 + } 142 + 143 + /* Core domain only */ 144 + static u32 pmdomain_get_clock_autoidle4(int domain_offset) 145 + { 146 + return prcm_readl(domain_offset + CM_AUTOIDLE4_OFFSET); 147 + } 148 + 149 + static void pmdomain_set_clock_autoidle1(u32 state, int domain_offset) 150 + { 151 + prcm_writel(state, CM_AUTOIDLE1_OFFSET + domain_offset); 152 + } 153 + 154 + /* Core domain only */ 155 + static void pmdomain_set_clock_autoidle2(u32 state, int domain_offset) 156 + { 157 + prcm_writel(state, CM_AUTOIDLE2_OFFSET + domain_offset); 158 + } 159 + 160 + /* Core domain only */ 161 + static void pmdomain_set_clock_autoidle3(u32 state, int domain_offset) 162 + { 163 + prcm_writel(state, CM_AUTOIDLE3_OFFSET + domain_offset); 164 + } 165 + 166 + /* Core domain only */ 167 + static void pmdomain_set_clock_autoidle4(u32 state, int domain_offset) 168 + { 169 + prcm_writel(state, CM_AUTOIDLE4_OFFSET + domain_offset); 170 + } 171 + 172 + /* 173 + * Configures power management domains to idle clocks automatically. 174 + */ 175 + void pmdomain_set_autoidle(void) 176 + { 177 + u32 val; 178 + 179 + /* Set PLL auto stop for 54M, 96M & DPLL */ 180 + pmdomain_set_clock_autoidle1(AUTO_54M(AUTO_STOPPED) | 181 + AUTO_96M(AUTO_STOPPED) | 182 + AUTO_DPLL(AUTO_STOPPED), PM_PLL_OFFSET); 183 + 184 + /* External clock input control 185 + * REVISIT: Should this be in clock framework? 186 + */ 187 + PRCM_CLKSRC_CTRL |= (0x3 << 3); 188 + 189 + /* Configure number of 32KHz clock cycles for sys_clk */ 190 + PRCM_CLKSSETUP = 0x00ff; 191 + 192 + /* Configure automatic voltage transition */ 193 + PRCM_VOLTSETUP = 0; 194 + val = PRCM_VOLTCTRL; 195 + val &= ~(SETOFF_LEVEL(0x3) | VOLT_LEVEL(0x3)); 196 + val |= SETOFF_LEVEL(1) | VOLT_LEVEL(1) | AUTO_EXTVOLT; 197 + PRCM_VOLTCTRL = val; 198 + 199 + /* Disable emulation tools functional clock */ 200 + PRCM_CLKEMUL_CTRL = 0x0; 201 + 202 + /* Set core memory retention state */ 203 + val = pmdomain_get_powerstate(PM_CORE_OFFSET); 204 + if (cpu_is_omap2420()) { 205 + val &= ~(0x7 << 3); 206 + val |= (MEM3RETSTATE | MEM2RETSTATE | MEM1RETSTATE); 207 + } else { 208 + val &= ~(0xf << 3); 209 + val |= (MEM4RETSTATE | MEM3RETSTATE | MEM2RETSTATE | 210 + MEM1RETSTATE); 211 + } 212 + pmdomain_set_powerstate(val, PM_CORE_OFFSET); 213 + 214 + /* OCP interface smart idle. REVISIT: Enable autoidle bit0 ? */ 215 + val = SMS_SYSCONFIG; 216 + val &= ~(0x3 << 3); 217 + val |= (0x2 << 3) | (1 << 0); 218 + SMS_SYSCONFIG |= val; 219 + 220 + val = SDRC_SYSCONFIG; 221 + val &= ~(0x3 << 3); 222 + val |= (0x2 << 3); 223 + SDRC_SYSCONFIG = val; 224 + 225 + /* Configure L3 interface for smart idle. 226 + * REVISIT: Enable autoidle bit0 ? 227 + */ 228 + val = GPMC_SYSCONFIG; 229 + val &= ~(0x3 << 3); 230 + val |= (0x2 << 3) | (1 << 0); 231 + GPMC_SYSCONFIG = val; 232 + 233 + pmdomain_set_powerstate(LOGICRETSTATE | POWERSTATE_RETENTION, 234 + PM_MPU_OFFSET); 235 + pmdomain_set_powerstate(POWERSTATE_RETENTION, PM_CORE_OFFSET); 236 + if (!cpu_is_omap2420()) 237 + pmdomain_set_powerstate(POWERSTATE_RETENTION, PM_MDM_OFFSET); 238 + 239 + /* Assume suspend function has saved the state for DSP and GFX */ 240 + pmdomain_set_powerstate(FORCESTATE | POWERSTATE_OFF, PM_DSP_OFFSET); 241 + pmdomain_set_powerstate(FORCESTATE | POWERSTATE_OFF, PM_GFX_OFFSET); 242 + 243 + #if 0 244 + /* REVISIT: Internal USB needs special handling */ 245 + force_standby_usb(); 246 + if (cpu_is_omap2430()) 247 + force_hsmmc(); 248 + sdram_self_refresh_on_idle_req(1); 249 + #endif 250 + 251 + /* Enable clock auto control for all domains. 252 + * Note that CORE domain includes also DSS, L4 & L3. 253 + */ 254 + pmdomain_set_clock_autocontrol(AUTOSTAT_MPU, PM_MPU_OFFSET); 255 + pmdomain_set_clock_autocontrol(AUTOSTAT_GFX, PM_GFX_OFFSET); 256 + pmdomain_set_clock_autocontrol(AUTOSTAT_DSS | AUTOSTAT_L4 | AUTOSTAT_L3, 257 + PM_CORE_OFFSET); 258 + if (cpu_is_omap2420()) 259 + pmdomain_set_clock_autocontrol(AUTOSTAT_IVA | AUTOSTAT_DSP, 260 + PM_DSP_OFFSET); 261 + else { 262 + pmdomain_set_clock_autocontrol(AUTOSTAT_DSP, PM_DSP_OFFSET); 263 + pmdomain_set_clock_autocontrol(AUTOSTAT_MDM, PM_MDM_OFFSET); 264 + } 265 + 266 + /* Enable clock autoidle for all domains */ 267 + pmdomain_set_clock_autoidle1(0x2, PM_DSP_OFFSET); 268 + if (cpu_is_omap2420()) { 269 + pmdomain_set_clock_autoidle1(0xfffffff9, PM_CORE_OFFSET); 270 + pmdomain_set_clock_autoidle2(0x7, PM_CORE_OFFSET); 271 + pmdomain_set_clock_autoidle1(0x3f, PM_WKUP_OFFSET); 272 + } else { 273 + pmdomain_set_clock_autoidle1(0xeafffff1, PM_CORE_OFFSET); 274 + pmdomain_set_clock_autoidle2(0xfff, PM_CORE_OFFSET); 275 + pmdomain_set_clock_autoidle1(0x7f, PM_WKUP_OFFSET); 276 + pmdomain_set_clock_autoidle1(0x3, PM_MDM_OFFSET); 277 + } 278 + pmdomain_set_clock_autoidle3(0x7, PM_CORE_OFFSET); 279 + pmdomain_set_clock_autoidle4(0x1f, PM_CORE_OFFSET); 280 + } 281 + 282 + /* 283 + * Initializes power domains by removing wake-up dependencies and powering 284 + * down DSP and GFX. Gets called from PM init. Note that DSP and IVA code 285 + * must re-enable DSP and GFX when used. 286 + */ 287 + void __init pmdomain_init(void) 288 + { 289 + /* Remove all domain wakeup dependencies */ 290 + pmdomain_set_wakeup_dependencies(EN_WKUP | EN_CORE, PM_MPU_OFFSET); 291 + pmdomain_set_wakeup_dependencies(0, PM_DSP_OFFSET); 292 + pmdomain_set_wakeup_dependencies(0, PM_GFX_OFFSET); 293 + pmdomain_set_wakeup_dependencies(EN_WKUP | EN_MPU, PM_CORE_OFFSET); 294 + if (cpu_is_omap2430()) 295 + pmdomain_set_wakeup_dependencies(0, PM_MDM_OFFSET); 296 + 297 + /* Power down DSP and GFX */ 298 + pmdomain_set_powerstate(POWERSTATE_OFF | FORCESTATE, PM_DSP_OFFSET); 299 + pmdomain_set_powerstate(POWERSTATE_OFF | FORCESTATE, PM_GFX_OFFSET); 300 + }
+265 -6
arch/arm/mach-omap2/pm.c
··· 23 23 #include <linux/interrupt.h> 24 24 #include <linux/sysfs.h> 25 25 #include <linux/module.h> 26 + #include <linux/delay.h> 26 27 27 28 #include <asm/io.h> 28 29 #include <asm/irq.h> ··· 37 36 #include <asm/arch/sram.h> 38 37 #include <asm/arch/pm.h> 39 38 39 + #include "prcm-regs.h" 40 + 40 41 static struct clk *vclk; 41 42 static void (*omap2_sram_idle)(void); 42 43 static void (*omap2_sram_suspend)(int dllctrl, int cpu_rev); 43 44 static void (*saved_idle)(void); 45 + 46 + extern void __init pmdomain_init(void); 47 + extern void pmdomain_set_autoidle(void); 48 + 49 + static unsigned int omap24xx_sleep_save[OMAP24XX_SLEEP_SAVE_SIZE]; 44 50 45 51 void omap2_pm_idle(void) 46 52 { ··· 95 87 return error; 96 88 } 97 89 90 + #define INT0_WAKE_MASK (OMAP_IRQ_BIT(INT_24XX_GPIO_BANK1) | \ 91 + OMAP_IRQ_BIT(INT_24XX_GPIO_BANK2) | \ 92 + OMAP_IRQ_BIT(INT_24XX_GPIO_BANK3)) 93 + 94 + #define INT1_WAKE_MASK (OMAP_IRQ_BIT(INT_24XX_GPIO_BANK4)) 95 + 96 + #define INT2_WAKE_MASK (OMAP_IRQ_BIT(INT_24XX_UART1_IRQ) | \ 97 + OMAP_IRQ_BIT(INT_24XX_UART2_IRQ) | \ 98 + OMAP_IRQ_BIT(INT_24XX_UART3_IRQ)) 99 + 100 + #define preg(reg) printk("%s\t(0x%p):\t0x%08x\n", #reg, &reg, reg); 101 + 102 + static void omap2_pm_debug(char * desc) 103 + { 104 + printk("%s:\n", desc); 105 + 106 + preg(CM_CLKSTCTRL_MPU); 107 + preg(CM_CLKSTCTRL_CORE); 108 + preg(CM_CLKSTCTRL_GFX); 109 + preg(CM_CLKSTCTRL_DSP); 110 + preg(CM_CLKSTCTRL_MDM); 111 + 112 + preg(PM_PWSTCTRL_MPU); 113 + preg(PM_PWSTCTRL_CORE); 114 + preg(PM_PWSTCTRL_GFX); 115 + preg(PM_PWSTCTRL_DSP); 116 + preg(PM_PWSTCTRL_MDM); 117 + 118 + preg(PM_PWSTST_MPU); 119 + preg(PM_PWSTST_CORE); 120 + preg(PM_PWSTST_GFX); 121 + preg(PM_PWSTST_DSP); 122 + preg(PM_PWSTST_MDM); 123 + 124 + preg(CM_AUTOIDLE1_CORE); 125 + preg(CM_AUTOIDLE2_CORE); 126 + preg(CM_AUTOIDLE3_CORE); 127 + preg(CM_AUTOIDLE4_CORE); 128 + preg(CM_AUTOIDLE_WKUP); 129 + preg(CM_AUTOIDLE_PLL); 130 + preg(CM_AUTOIDLE_DSP); 131 + preg(CM_AUTOIDLE_MDM); 132 + 133 + preg(CM_ICLKEN1_CORE); 134 + preg(CM_ICLKEN2_CORE); 135 + preg(CM_ICLKEN3_CORE); 136 + preg(CM_ICLKEN4_CORE); 137 + preg(CM_ICLKEN_GFX); 138 + preg(CM_ICLKEN_WKUP); 139 + preg(CM_ICLKEN_DSP); 140 + preg(CM_ICLKEN_MDM); 141 + 142 + preg(CM_IDLEST1_CORE); 143 + preg(CM_IDLEST2_CORE); 144 + preg(CM_IDLEST3_CORE); 145 + preg(CM_IDLEST4_CORE); 146 + preg(CM_IDLEST_GFX); 147 + preg(CM_IDLEST_WKUP); 148 + preg(CM_IDLEST_CKGEN); 149 + preg(CM_IDLEST_DSP); 150 + preg(CM_IDLEST_MDM); 151 + 152 + preg(RM_RSTST_MPU); 153 + preg(RM_RSTST_GFX); 154 + preg(RM_RSTST_WKUP); 155 + preg(RM_RSTST_DSP); 156 + preg(RM_RSTST_MDM); 157 + 158 + preg(PM_WKDEP_MPU); 159 + preg(PM_WKDEP_CORE); 160 + preg(PM_WKDEP_GFX); 161 + preg(PM_WKDEP_DSP); 162 + preg(PM_WKDEP_MDM); 163 + 164 + preg(CM_FCLKEN_WKUP); 165 + preg(CM_ICLKEN_WKUP); 166 + preg(CM_IDLEST_WKUP); 167 + preg(CM_AUTOIDLE_WKUP); 168 + preg(CM_CLKSEL_WKUP); 169 + 170 + preg(PM_WKEN_WKUP); 171 + preg(PM_WKST_WKUP); 172 + } 173 + 174 + static inline void omap2_pm_save_registers(void) 175 + { 176 + /* Save interrupt registers */ 177 + OMAP24XX_SAVE(INTC_MIR0); 178 + OMAP24XX_SAVE(INTC_MIR1); 179 + OMAP24XX_SAVE(INTC_MIR2); 180 + 181 + /* Save power control registers */ 182 + OMAP24XX_SAVE(CM_CLKSTCTRL_MPU); 183 + OMAP24XX_SAVE(CM_CLKSTCTRL_CORE); 184 + OMAP24XX_SAVE(CM_CLKSTCTRL_GFX); 185 + OMAP24XX_SAVE(CM_CLKSTCTRL_DSP); 186 + OMAP24XX_SAVE(CM_CLKSTCTRL_MDM); 187 + 188 + /* Save power state registers */ 189 + OMAP24XX_SAVE(PM_PWSTCTRL_MPU); 190 + OMAP24XX_SAVE(PM_PWSTCTRL_CORE); 191 + OMAP24XX_SAVE(PM_PWSTCTRL_GFX); 192 + OMAP24XX_SAVE(PM_PWSTCTRL_DSP); 193 + OMAP24XX_SAVE(PM_PWSTCTRL_MDM); 194 + 195 + /* Save autoidle registers */ 196 + OMAP24XX_SAVE(CM_AUTOIDLE1_CORE); 197 + OMAP24XX_SAVE(CM_AUTOIDLE2_CORE); 198 + OMAP24XX_SAVE(CM_AUTOIDLE3_CORE); 199 + OMAP24XX_SAVE(CM_AUTOIDLE4_CORE); 200 + OMAP24XX_SAVE(CM_AUTOIDLE_WKUP); 201 + OMAP24XX_SAVE(CM_AUTOIDLE_PLL); 202 + OMAP24XX_SAVE(CM_AUTOIDLE_DSP); 203 + OMAP24XX_SAVE(CM_AUTOIDLE_MDM); 204 + 205 + /* Save idle state registers */ 206 + OMAP24XX_SAVE(CM_IDLEST1_CORE); 207 + OMAP24XX_SAVE(CM_IDLEST2_CORE); 208 + OMAP24XX_SAVE(CM_IDLEST3_CORE); 209 + OMAP24XX_SAVE(CM_IDLEST4_CORE); 210 + OMAP24XX_SAVE(CM_IDLEST_GFX); 211 + OMAP24XX_SAVE(CM_IDLEST_WKUP); 212 + OMAP24XX_SAVE(CM_IDLEST_CKGEN); 213 + OMAP24XX_SAVE(CM_IDLEST_DSP); 214 + OMAP24XX_SAVE(CM_IDLEST_MDM); 215 + 216 + /* Save clock registers */ 217 + OMAP24XX_SAVE(CM_FCLKEN1_CORE); 218 + OMAP24XX_SAVE(CM_FCLKEN2_CORE); 219 + OMAP24XX_SAVE(CM_ICLKEN1_CORE); 220 + OMAP24XX_SAVE(CM_ICLKEN2_CORE); 221 + OMAP24XX_SAVE(CM_ICLKEN3_CORE); 222 + OMAP24XX_SAVE(CM_ICLKEN4_CORE); 223 + } 224 + 225 + static inline void omap2_pm_restore_registers(void) 226 + { 227 + /* Restore clock state registers */ 228 + OMAP24XX_RESTORE(CM_CLKSTCTRL_MPU); 229 + OMAP24XX_RESTORE(CM_CLKSTCTRL_CORE); 230 + OMAP24XX_RESTORE(CM_CLKSTCTRL_GFX); 231 + OMAP24XX_RESTORE(CM_CLKSTCTRL_DSP); 232 + OMAP24XX_RESTORE(CM_CLKSTCTRL_MDM); 233 + 234 + /* Restore power state registers */ 235 + OMAP24XX_RESTORE(PM_PWSTCTRL_MPU); 236 + OMAP24XX_RESTORE(PM_PWSTCTRL_CORE); 237 + OMAP24XX_RESTORE(PM_PWSTCTRL_GFX); 238 + OMAP24XX_RESTORE(PM_PWSTCTRL_DSP); 239 + OMAP24XX_RESTORE(PM_PWSTCTRL_MDM); 240 + 241 + /* Restore idle state registers */ 242 + OMAP24XX_RESTORE(CM_IDLEST1_CORE); 243 + OMAP24XX_RESTORE(CM_IDLEST2_CORE); 244 + OMAP24XX_RESTORE(CM_IDLEST3_CORE); 245 + OMAP24XX_RESTORE(CM_IDLEST4_CORE); 246 + OMAP24XX_RESTORE(CM_IDLEST_GFX); 247 + OMAP24XX_RESTORE(CM_IDLEST_WKUP); 248 + OMAP24XX_RESTORE(CM_IDLEST_CKGEN); 249 + OMAP24XX_RESTORE(CM_IDLEST_DSP); 250 + OMAP24XX_RESTORE(CM_IDLEST_MDM); 251 + 252 + /* Restore autoidle registers */ 253 + OMAP24XX_RESTORE(CM_AUTOIDLE1_CORE); 254 + OMAP24XX_RESTORE(CM_AUTOIDLE2_CORE); 255 + OMAP24XX_RESTORE(CM_AUTOIDLE3_CORE); 256 + OMAP24XX_RESTORE(CM_AUTOIDLE4_CORE); 257 + OMAP24XX_RESTORE(CM_AUTOIDLE_WKUP); 258 + OMAP24XX_RESTORE(CM_AUTOIDLE_PLL); 259 + OMAP24XX_RESTORE(CM_AUTOIDLE_DSP); 260 + OMAP24XX_RESTORE(CM_AUTOIDLE_MDM); 261 + 262 + /* Restore clock registers */ 263 + OMAP24XX_RESTORE(CM_FCLKEN1_CORE); 264 + OMAP24XX_RESTORE(CM_FCLKEN2_CORE); 265 + OMAP24XX_RESTORE(CM_ICLKEN1_CORE); 266 + OMAP24XX_RESTORE(CM_ICLKEN2_CORE); 267 + OMAP24XX_RESTORE(CM_ICLKEN3_CORE); 268 + OMAP24XX_RESTORE(CM_ICLKEN4_CORE); 269 + 270 + /* REVISIT: Clear interrupts here */ 271 + 272 + /* Restore interrupt registers */ 273 + OMAP24XX_RESTORE(INTC_MIR0); 274 + OMAP24XX_RESTORE(INTC_MIR1); 275 + OMAP24XX_RESTORE(INTC_MIR2); 276 + } 277 + 278 + static int omap2_pm_suspend(void) 279 + { 280 + int processor_type = 0; 281 + 282 + /* REVISIT: 0x21 or 0x26? */ 283 + if (cpu_is_omap2420()) 284 + processor_type = 0x21; 285 + 286 + if (!processor_type) 287 + return -ENOTSUPP; 288 + 289 + local_irq_disable(); 290 + local_fiq_disable(); 291 + 292 + omap2_pm_save_registers(); 293 + 294 + /* Disable interrupts except for the wake events */ 295 + INTC_MIR_SET0 = 0xffffffff & ~INT0_WAKE_MASK; 296 + INTC_MIR_SET1 = 0xffffffff & ~INT1_WAKE_MASK; 297 + INTC_MIR_SET2 = 0xffffffff & ~INT2_WAKE_MASK; 298 + 299 + pmdomain_set_autoidle(); 300 + 301 + /* Clear old wake-up events */ 302 + PM_WKST1_CORE = 0; 303 + PM_WKST2_CORE = 0; 304 + PM_WKST_WKUP = 0; 305 + 306 + /* Enable wake-up events */ 307 + PM_WKEN1_CORE = (1 << 22) | (1 << 21); /* UART1 & 2 */ 308 + PM_WKEN2_CORE = (1 << 2); /* UART3 */ 309 + PM_WKEN_WKUP = (1 << 2) | (1 << 0); /* GPIO & GPT1 */ 310 + 311 + /* Disable clocks except for CM_ICLKEN2_CORE. It gets disabled 312 + * in the SRAM suspend code */ 313 + CM_FCLKEN1_CORE = 0; 314 + CM_FCLKEN2_CORE = 0; 315 + CM_ICLKEN1_CORE = 0; 316 + CM_ICLKEN3_CORE = 0; 317 + CM_ICLKEN4_CORE = 0; 318 + 319 + omap2_pm_debug("Status before suspend"); 320 + 321 + /* Must wait for serial buffers to clear */ 322 + mdelay(200); 323 + 324 + /* Jump to SRAM suspend code 325 + * REVISIT: When is this SDRC_DLLB_CTRL? 326 + */ 327 + omap2_sram_suspend(SDRC_DLLA_CTRL, processor_type); 328 + 329 + /* Back from sleep */ 330 + omap2_pm_restore_registers(); 331 + 332 + local_fiq_enable(); 333 + local_irq_enable(); 334 + 335 + return 0; 336 + } 337 + 98 338 static int omap2_pm_enter(suspend_state_t state) 99 339 { 340 + int ret = 0; 341 + 100 342 switch (state) 101 343 { 102 344 case PM_SUSPEND_STANDBY: 103 345 case PM_SUSPEND_MEM: 104 - /* FIXME: Add suspend */ 346 + ret = omap2_pm_suspend(); 105 347 break; 106 - 107 348 case PM_SUSPEND_DISK: 108 - return -ENOTSUPP; 109 - 349 + ret = -ENOTSUPP; 350 + break; 110 351 default: 111 - return -EINVAL; 352 + ret = -EINVAL; 112 353 } 113 354 114 - return 0; 355 + return ret; 115 356 } 116 357 117 358 static int omap2_pm_finish(suspend_state_t state) ··· 399 142 400 143 pm_set_ops(&omap_pm_ops); 401 144 pm_idle = omap2_pm_idle; 145 + 146 + pmdomain_init(); 402 147 403 148 return 0; 404 149 }
+18 -68
arch/arm/mach-omap2/timer-gp.c
··· 6 6 * Copyright (C) 2005 Nokia Corporation 7 7 * Author: Paul Mundt <paul.mundt@nokia.com> 8 8 * Juha Yrj�l� <juha.yrjola@nokia.com> 9 + * OMAP Dual-mode timer framework support by Timo Teras 9 10 * 10 11 * Some parts based off of TI's 24xx code: 11 12 * ··· 23 22 #include <linux/interrupt.h> 24 23 #include <linux/err.h> 25 24 #include <linux/clk.h> 25 + #include <linux/delay.h> 26 26 27 27 #include <asm/mach/time.h> 28 - #include <asm/delay.h> 29 - #include <asm/io.h> 28 + #include <asm/arch/dmtimer.h> 30 29 31 - #define OMAP2_GP_TIMER1_BASE 0x48028000 32 - #define OMAP2_GP_TIMER2_BASE 0x4802a000 33 - #define OMAP2_GP_TIMER3_BASE 0x48078000 34 - #define OMAP2_GP_TIMER4_BASE 0x4807a000 30 + static struct omap_dm_timer *gptimer; 35 31 36 - #define GP_TIMER_TIDR 0x00 37 - #define GP_TIMER_TISR 0x18 38 - #define GP_TIMER_TIER 0x1c 39 - #define GP_TIMER_TCLR 0x24 40 - #define GP_TIMER_TCRR 0x28 41 - #define GP_TIMER_TLDR 0x2c 42 - #define GP_TIMER_TSICR 0x40 43 - 44 - #define OS_TIMER_NR 1 /* GP timer 2 */ 45 - 46 - static unsigned long timer_base[] = { 47 - IO_ADDRESS(OMAP2_GP_TIMER1_BASE), 48 - IO_ADDRESS(OMAP2_GP_TIMER2_BASE), 49 - IO_ADDRESS(OMAP2_GP_TIMER3_BASE), 50 - IO_ADDRESS(OMAP2_GP_TIMER4_BASE), 51 - }; 52 - 53 - static inline unsigned int timer_read_reg(int nr, unsigned int reg) 32 + static inline void omap2_gp_timer_start(unsigned long load_val) 54 33 { 55 - return __raw_readl(timer_base[nr] + reg); 56 - } 57 - 58 - static inline void timer_write_reg(int nr, unsigned int reg, unsigned int val) 59 - { 60 - __raw_writel(val, timer_base[nr] + reg); 61 - } 62 - 63 - /* Note that we always enable the clock prescale divider bit */ 64 - static inline void omap2_gp_timer_start(int nr, unsigned long load_val) 65 - { 66 - unsigned int tmp; 67 - 68 - tmp = 0xffffffff - load_val; 69 - 70 - timer_write_reg(nr, GP_TIMER_TLDR, tmp); 71 - timer_write_reg(nr, GP_TIMER_TCRR, tmp); 72 - timer_write_reg(nr, GP_TIMER_TIER, 1 << 1); 73 - timer_write_reg(nr, GP_TIMER_TCLR, (1 << 5) | (1 << 1) | 1); 34 + omap_dm_timer_set_load(gptimer, 1, 0xffffffff - load_val); 35 + omap_dm_timer_set_int_enable(gptimer, OMAP_TIMER_INT_OVERFLOW); 36 + omap_dm_timer_start(gptimer); 74 37 } 75 38 76 39 static irqreturn_t omap2_gp_timer_interrupt(int irq, void *dev_id, ··· 42 77 { 43 78 write_seqlock(&xtime_lock); 44 79 45 - timer_write_reg(OS_TIMER_NR, GP_TIMER_TISR, 1 << 1); 80 + omap_dm_timer_write_status(gptimer, OMAP_TIMER_INT_OVERFLOW); 46 81 timer_tick(regs); 47 82 48 83 write_sequnlock(&xtime_lock); ··· 52 87 53 88 static struct irqaction omap2_gp_timer_irq = { 54 89 .name = "gp timer", 55 - .flags = SA_INTERRUPT, 90 + .flags = SA_INTERRUPT | SA_TIMER, 56 91 .handler = omap2_gp_timer_interrupt, 57 92 }; 58 93 59 94 static void __init omap2_gp_timer_init(void) 60 95 { 61 - struct clk * sys_ck; 62 - u32 tick_period = 120000; 63 - u32 l; 96 + u32 tick_period; 64 97 65 - /* Reset clock and prescale value */ 66 - timer_write_reg(OS_TIMER_NR, GP_TIMER_TCLR, 0); 98 + omap_dm_timer_init(); 99 + gptimer = omap_dm_timer_request_specific(1); 100 + BUG_ON(gptimer == NULL); 67 101 68 - sys_ck = clk_get(NULL, "sys_ck"); 69 - if (IS_ERR(sys_ck)) 70 - printk(KERN_ERR "Could not get sys_ck\n"); 71 - else { 72 - clk_enable(sys_ck); 73 - tick_period = clk_get_rate(sys_ck) / 100; 74 - clk_put(sys_ck); 75 - } 76 - 77 - tick_period /= 2; /* Minimum prescale divider is 2 */ 102 + omap_dm_timer_set_source(gptimer, OMAP_TIMER_SRC_SYS_CLK); 103 + tick_period = clk_get_rate(omap_dm_timer_get_fclk(gptimer)) / 100; 78 104 tick_period -= 1; 79 105 80 - l = timer_read_reg(OS_TIMER_NR, GP_TIMER_TIDR); 81 - printk(KERN_INFO "OMAP2 GP timer (HW version %d.%d)\n", 82 - (l >> 4) & 0x0f, l & 0x0f); 83 - 84 - setup_irq(38, &omap2_gp_timer_irq); 85 - 86 - omap2_gp_timer_start(OS_TIMER_NR, tick_period); 106 + setup_irq(omap_dm_timer_get_irq(gptimer), &omap2_gp_timer_irq); 107 + omap2_gp_timer_start(tick_period); 87 108 } 88 109 89 110 struct sys_timer omap_timer = { 90 111 .init = omap2_gp_timer_init, 91 112 }; 92 -
+19
arch/arm/mach-pxa/Kconfig
··· 35 35 SL-C3000 (Spitz), SL-C3100 (Borzoi) or SL-C6000x (Tosa) 36 36 handheld computer. 37 37 38 + config MACH_TRIZEPS4 39 + bool "Keith und Koep Trizeps4 DIMM-Module" 40 + select PXA27x 41 + 38 42 endchoice 39 43 40 44 if PXA_SHARPSL ··· 54 50 bool "Sharp PXA270 models (SL-Cxx00)" 55 51 select PXA27x 56 52 select IWMMXT 53 + 54 + endchoice 55 + 56 + endif 57 + 58 + if MACH_TRIZEPS4 59 + 60 + choice 61 + prompt "Select base board for Trizeps 4 module" 62 + 63 + config MACH_TRIZEPS4_CONXS 64 + bool "ConXS Eval Board" 65 + 66 + config MACH_TRIZEPS4_ANY 67 + bool "another Board" 57 68 58 69 endchoice 59 70
+2
arch/arm/mach-pxa/Makefile
··· 12 12 obj-$(CONFIG_MACH_LOGICPD_PXA270) += lpd270.o 13 13 obj-$(CONFIG_MACH_MAINSTONE) += mainstone.o 14 14 obj-$(CONFIG_ARCH_PXA_IDP) += idp.o 15 + obj-$(CONFIG_MACH_TRIZEPS4) += trizeps4.o 15 16 obj-$(CONFIG_PXA_SHARP_C7xx) += corgi.o corgi_ssp.o corgi_lcd.o sharpsl_pm.o corgi_pm.o 16 17 obj-$(CONFIG_PXA_SHARP_Cxx00) += spitz.o corgi_ssp.o corgi_lcd.o sharpsl_pm.o spitz_pm.o 17 18 obj-$(CONFIG_MACH_AKITA) += akita-ioexp.o ··· 24 23 led-$(CONFIG_ARCH_LUBBOCK) += leds-lubbock.o 25 24 led-$(CONFIG_MACH_MAINSTONE) += leds-mainstone.o 26 25 led-$(CONFIG_ARCH_PXA_IDP) += leds-idp.o 26 + led-$(CONFIG_MACH_TRIZEPS4) += leds-trizeps4.o 27 27 28 28 obj-$(CONFIG_LEDS) += $(led-y) 29 29
+134
arch/arm/mach-pxa/leds-trizeps4.c
··· 1 + /* 2 + * linux/arch/arm/mach-pxa/leds-trizeps4.c 3 + * 4 + * Author: Jürgen Schindele 5 + * Created: 20 02, 2006 6 + * Copyright: Jürgen Schindele 7 + * 8 + * This program is free software; you can redistribute it and/or modify 9 + * it under the terms of the GNU General Public License version 2 as 10 + * published by the Free Software Foundation. 11 + */ 12 + 13 + #include <linux/config.h> 14 + #include <linux/init.h> 15 + 16 + #include <asm/hardware.h> 17 + #include <asm/system.h> 18 + #include <asm/types.h> 19 + #include <asm/leds.h> 20 + 21 + #include <asm/arch/pxa-regs.h> 22 + #include <asm/arch/trizeps4.h> 23 + 24 + #include "leds.h" 25 + 26 + #define LED_STATE_ENABLED 1 27 + #define LED_STATE_CLAIMED 2 28 + 29 + #define SYS_BUSY 0x01 30 + #define HEARTBEAT 0x02 31 + #define BLINK 0x04 32 + 33 + static unsigned int led_state; 34 + static unsigned int hw_led_state; 35 + 36 + void trizeps4_leds_event(led_event_t evt) 37 + { 38 + unsigned long flags; 39 + 40 + local_irq_save(flags); 41 + 42 + switch (evt) { 43 + case led_start: 44 + hw_led_state = 0; 45 + pxa_gpio_mode( GPIO_SYS_BUSY_LED | GPIO_OUT); /* LED1 */ 46 + pxa_gpio_mode( GPIO_HEARTBEAT_LED | GPIO_OUT); /* LED2 */ 47 + led_state = LED_STATE_ENABLED; 48 + break; 49 + 50 + case led_stop: 51 + led_state &= ~LED_STATE_ENABLED; 52 + break; 53 + 54 + case led_claim: 55 + led_state |= LED_STATE_CLAIMED; 56 + hw_led_state = 0; 57 + break; 58 + 59 + case led_release: 60 + led_state &= ~LED_STATE_CLAIMED; 61 + hw_led_state = 0; 62 + break; 63 + 64 + #ifdef CONFIG_LEDS_TIMER 65 + case led_timer: 66 + hw_led_state ^= HEARTBEAT; 67 + break; 68 + #endif 69 + 70 + #ifdef CONFIG_LEDS_CPU 71 + case led_idle_start: 72 + hw_led_state &= ~SYS_BUSY; 73 + break; 74 + 75 + case led_idle_end: 76 + hw_led_state |= SYS_BUSY; 77 + break; 78 + #endif 79 + 80 + case led_halted: 81 + break; 82 + 83 + case led_green_on: 84 + hw_led_state |= BLINK; 85 + break; 86 + 87 + case led_green_off: 88 + hw_led_state &= ~BLINK; 89 + break; 90 + 91 + case led_amber_on: 92 + break; 93 + 94 + case led_amber_off: 95 + break; 96 + 97 + case led_red_on: 98 + break; 99 + 100 + case led_red_off: 101 + break; 102 + 103 + default: 104 + break; 105 + } 106 + 107 + if (led_state & LED_STATE_ENABLED) { 108 + switch (hw_led_state) { 109 + case 0: 110 + GPSR(GPIO_SYS_BUSY_LED) |= GPIO_bit(GPIO_SYS_BUSY_LED); 111 + GPSR(GPIO_HEARTBEAT_LED) |= GPIO_bit(GPIO_HEARTBEAT_LED); 112 + break; 113 + case 1: 114 + GPCR(GPIO_SYS_BUSY_LED) |= GPIO_bit(GPIO_SYS_BUSY_LED); 115 + GPSR(GPIO_HEARTBEAT_LED) |= GPIO_bit(GPIO_HEARTBEAT_LED); 116 + break; 117 + case 2: 118 + GPSR(GPIO_SYS_BUSY_LED) |= GPIO_bit(GPIO_SYS_BUSY_LED); 119 + GPCR(GPIO_HEARTBEAT_LED) |= GPIO_bit(GPIO_HEARTBEAT_LED); 120 + break; 121 + case 3: 122 + GPCR(GPIO_SYS_BUSY_LED) |= GPIO_bit(GPIO_SYS_BUSY_LED); 123 + GPCR(GPIO_HEARTBEAT_LED) |= GPIO_bit(GPIO_HEARTBEAT_LED); 124 + break; 125 + } 126 + } 127 + else { 128 + /* turn all off */ 129 + GPSR(GPIO_SYS_BUSY_LED) |= GPIO_bit(GPIO_SYS_BUSY_LED); 130 + GPSR(GPIO_HEARTBEAT_LED) |= GPIO_bit(GPIO_HEARTBEAT_LED); 131 + } 132 + 133 + local_irq_restore(flags); 134 + }
+2
arch/arm/mach-pxa/leds.c
··· 24 24 leds_event = mainstone_leds_event; 25 25 if (machine_is_pxa_idp()) 26 26 leds_event = idp_leds_event; 27 + if (machine_is_trizeps4()) 28 + leds_event = trizeps4_leds_event; 27 29 28 30 leds_event(led_start); 29 31 return 0;
+1
arch/arm/mach-pxa/leds.h
··· 10 10 extern void idp_leds_event(led_event_t evt); 11 11 extern void lubbock_leds_event(led_event_t evt); 12 12 extern void mainstone_leds_event(led_event_t evt); 13 + extern void trizeps4_leds_event(led_event_t evt);
+102 -24
arch/arm/mach-pxa/lpd270.c
··· 248 248 249 249 /* 5.7" TFT QVGA (LoLo display number 1) */ 250 250 static struct pxafb_mach_info sharp_lq057q3dc02 __initdata = { 251 - .pixclock = 100000, 252 - .xres = 240, 253 - .yres = 320, 251 + .pixclock = 150000, 252 + .xres = 320, 253 + .yres = 240, 254 254 .bpp = 16, 255 - .hsync_len = 64, 256 - .left_margin = 0x27, 257 - .right_margin = 0x09, 258 - .vsync_len = 0x04, 255 + .hsync_len = 0x14, 256 + .left_margin = 0x28, 257 + .right_margin = 0x0a, 258 + .vsync_len = 0x02, 259 259 .upper_margin = 0x08, 260 260 .lower_margin = 0x14, 261 - .sync = 0, 261 + .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, 262 262 .lccr0 = 0x07800080, 263 - .lccr3 = 0x04400007, 263 + .lccr3 = 0x00400000, 264 + .pxafb_backlight_power = lpd270_backlight_power, 265 + }; 266 + 267 + /* 12.1" TFT SVGA (LoLo display number 2) */ 268 + static struct pxafb_mach_info sharp_lq121s1dg31 __initdata = { 269 + .pixclock = 50000, 270 + .xres = 800, 271 + .yres = 600, 272 + .bpp = 16, 273 + .hsync_len = 0x05, 274 + .left_margin = 0x52, 275 + .right_margin = 0x05, 276 + .vsync_len = 0x04, 277 + .upper_margin = 0x14, 278 + .lower_margin = 0x0a, 279 + .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, 280 + .lccr0 = 0x07800080, 281 + .lccr3 = 0x00400000, 282 + .pxafb_backlight_power = lpd270_backlight_power, 283 + }; 284 + 285 + /* 3.6" TFT QVGA (LoLo display number 3) */ 286 + static struct pxafb_mach_info sharp_lq036q1da01 __initdata = { 287 + .pixclock = 150000, 288 + .xres = 320, 289 + .yres = 240, 290 + .bpp = 16, 291 + .hsync_len = 0x0e, 292 + .left_margin = 0x04, 293 + .right_margin = 0x0a, 294 + .vsync_len = 0x03, 295 + .upper_margin = 0x03, 296 + .lower_margin = 0x03, 297 + .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, 298 + .lccr0 = 0x07800080, 299 + .lccr3 = 0x00400000, 264 300 .pxafb_backlight_power = lpd270_backlight_power, 265 301 }; 266 302 267 303 /* 6.4" TFT VGA (LoLo display number 5) */ 268 304 static struct pxafb_mach_info sharp_lq64d343 __initdata = { 269 - .pixclock = 20000, 305 + .pixclock = 25000, 270 306 .xres = 640, 271 307 .yres = 480, 272 308 .bpp = 16, 273 - .hsync_len = 49, 309 + .hsync_len = 0x31, 274 310 .left_margin = 0x89, 275 311 .right_margin = 0x19, 276 - .vsync_len = 18, 312 + .vsync_len = 0x12, 277 313 .upper_margin = 0x22, 278 - .lower_margin = 0, 314 + .lower_margin = 0x00, 279 315 .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, 280 316 .lccr0 = 0x07800080, 281 - .lccr3 = 0x04400001, 317 + .lccr3 = 0x00400000, 318 + .pxafb_backlight_power = lpd270_backlight_power, 319 + }; 320 + 321 + /* 10.4" TFT VGA (LoLo display number 7) */ 322 + static struct pxafb_mach_info sharp_lq10d368 __initdata = { 323 + .pixclock = 25000, 324 + .xres = 640, 325 + .yres = 480, 326 + .bpp = 16, 327 + .hsync_len = 0x31, 328 + .left_margin = 0x89, 329 + .right_margin = 0x19, 330 + .vsync_len = 0x12, 331 + .upper_margin = 0x22, 332 + .lower_margin = 0x00, 333 + .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, 334 + .lccr0 = 0x07800080, 335 + .lccr3 = 0x00400000, 282 336 .pxafb_backlight_power = lpd270_backlight_power, 283 337 }; 284 338 285 339 /* 3.5" TFT QVGA (LoLo display number 8) */ 286 340 static struct pxafb_mach_info sharp_lq035q7db02_20 __initdata = { 287 - .pixclock = 100000, 341 + .pixclock = 150000, 288 342 .xres = 240, 289 343 .yres = 320, 290 344 .bpp = 16, 291 - .hsync_len = 0x34, 292 - .left_margin = 0x09, 293 - .right_margin = 0x09, 294 - .vsync_len = 0x08, 345 + .hsync_len = 0x0e, 346 + .left_margin = 0x0a, 347 + .right_margin = 0x0a, 348 + .vsync_len = 0x03, 295 349 .upper_margin = 0x05, 296 350 .lower_margin = 0x14, 297 - .sync = 0, 351 + .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, 298 352 .lccr0 = 0x07800080, 299 - .lccr3 = 0x04400007, 353 + .lccr3 = 0x00400000, 300 354 .pxafb_backlight_power = lpd270_backlight_power, 301 355 }; 356 + 357 + static struct pxafb_mach_info *lpd270_lcd_to_use; 358 + 359 + static int __init lpd270_set_lcd(char *str) 360 + { 361 + if (!strnicmp(str, "lq057q3dc02", 11)) { 362 + lpd270_lcd_to_use = &sharp_lq057q3dc02; 363 + } else if (!strnicmp(str, "lq121s1dg31", 11)) { 364 + lpd270_lcd_to_use = &sharp_lq121s1dg31; 365 + } else if (!strnicmp(str, "lq036q1da01", 11)) { 366 + lpd270_lcd_to_use = &sharp_lq036q1da01; 367 + } else if (!strnicmp(str, "lq64d343", 8)) { 368 + lpd270_lcd_to_use = &sharp_lq64d343; 369 + } else if (!strnicmp(str, "lq10d368", 8)) { 370 + lpd270_lcd_to_use = &sharp_lq10d368; 371 + } else if (!strnicmp(str, "lq035q7db02-20", 14)) { 372 + lpd270_lcd_to_use = &sharp_lq035q7db02_20; 373 + } else { 374 + printk(KERN_INFO "lpd270: unknown lcd panel [%s]\n", str); 375 + } 376 + 377 + return 1; 378 + } 379 + 380 + __setup("lcd=", lpd270_set_lcd); 302 381 303 382 static struct platform_device *platform_devices[] __initdata = { 304 383 &smc91x_device, ··· 424 345 425 346 platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices)); 426 347 427 - // set_pxa_fb_info(&sharp_lq057q3dc02); 428 - set_pxa_fb_info(&sharp_lq64d343); 429 - // set_pxa_fb_info(&sharp_lq035q7db02_20); 348 + if (lpd270_lcd_to_use != NULL) 349 + set_pxa_fb_info(lpd270_lcd_to_use); 430 350 431 351 pxa_set_ohci_info(&lpd270_ohci_platform_data); 432 352 }
+471
arch/arm/mach-pxa/trizeps4.c
··· 1 + /* 2 + * linux/arch/arm/mach-pxa/trizeps4.c 3 + * 4 + * Support for the Keith und Koep Trizeps4 Module Platform. 5 + * 6 + * Author: Jürgen Schindele 7 + * Created: 20 02, 2006 8 + * Copyright: Jürgen Schindele 9 + * 10 + * This program is free software; you can redistribute it and/or modify 11 + * it under the terms of the GNU General Public License version 2 as 12 + * published by the Free Software Foundation. 13 + */ 14 + 15 + #include <linux/init.h> 16 + #include <linux/kernel.h> 17 + #include <linux/platform_device.h> 18 + #include <linux/sysdev.h> 19 + #include <linux/interrupt.h> 20 + #include <linux/sched.h> 21 + #include <linux/bitops.h> 22 + #include <linux/fb.h> 23 + #include <linux/ioport.h> 24 + #include <linux/delay.h> 25 + #include <linux/serial_8250.h> 26 + #include <linux/mtd/mtd.h> 27 + #include <linux/mtd/partitions.h> 28 + 29 + #include <asm/types.h> 30 + #include <asm/setup.h> 31 + #include <asm/memory.h> 32 + #include <asm/mach-types.h> 33 + #include <asm/hardware.h> 34 + #include <asm/irq.h> 35 + #include <asm/sizes.h> 36 + 37 + #include <asm/mach/arch.h> 38 + #include <asm/mach/map.h> 39 + #include <asm/mach/irq.h> 40 + #include <asm/mach/flash.h> 41 + 42 + #include <asm/arch/pxa-regs.h> 43 + #include <asm/arch/trizeps4.h> 44 + #include <asm/arch/audio.h> 45 + #include <asm/arch/pxafb.h> 46 + #include <asm/arch/mmc.h> 47 + #include <asm/arch/irda.h> 48 + #include <asm/arch/ohci.h> 49 + 50 + #include "generic.h" 51 + 52 + /******************************************************************************************** 53 + * ONBOARD FLASH 54 + ********************************************************************************************/ 55 + static struct mtd_partition trizeps4_partitions[] = { 56 + { 57 + .name = "Bootloader", 58 + .size = 0x00040000, 59 + .offset = 0, 60 + .mask_flags = MTD_WRITEABLE /* force read-only */ 61 + },{ 62 + .name = "Kernel", 63 + .size = 0x00400000, 64 + .offset = 0x00040000 65 + },{ 66 + .name = "Filesystem", 67 + .size = MTDPART_SIZ_FULL, 68 + .offset = 0x00440000 69 + } 70 + }; 71 + 72 + static struct flash_platform_data trizeps4_flash_data[] = { 73 + { 74 + .map_name = "cfi_probe", 75 + .parts = trizeps4_partitions, 76 + .nr_parts = ARRAY_SIZE(trizeps4_partitions) 77 + } 78 + }; 79 + 80 + static struct resource flash_resource = { 81 + .start = PXA_CS0_PHYS, 82 + .end = PXA_CS0_PHYS + SZ_64M - 1, 83 + .flags = IORESOURCE_MEM, 84 + }; 85 + 86 + static struct platform_device flash_device = { 87 + .name = "pxa2xx-flash", 88 + .id = 0, 89 + .dev = { 90 + .platform_data = &trizeps4_flash_data, 91 + }, 92 + .resource = &flash_resource, 93 + .num_resources = 1, 94 + }; 95 + 96 + /******************************************************************************************** 97 + * DAVICOM DM9000 Ethernet 98 + ********************************************************************************************/ 99 + static struct resource dm9000_resources[] = { 100 + [0] = { 101 + .start = TRIZEPS4_ETH_PHYS+0x300, 102 + .end = TRIZEPS4_ETH_PHYS+0x400-1, 103 + .flags = IORESOURCE_MEM, 104 + }, 105 + [1] = { 106 + .start = TRIZEPS4_ETH_PHYS+0x8300, 107 + .end = TRIZEPS4_ETH_PHYS+0x8400-1, 108 + .flags = IORESOURCE_MEM, 109 + }, 110 + [2] = { 111 + .start = TRIZEPS4_ETH_IRQ, 112 + .end = TRIZEPS4_ETH_IRQ, 113 + .flags = (IORESOURCE_IRQ | IRQT_RISING), 114 + }, 115 + }; 116 + 117 + static struct platform_device dm9000_device = { 118 + .name = "dm9000", 119 + .id = -1, 120 + .num_resources = ARRAY_SIZE(dm9000_resources), 121 + .resource = dm9000_resources, 122 + }; 123 + 124 + /******************************************************************************************** 125 + * PXA270 serial ports 126 + ********************************************************************************************/ 127 + static struct plat_serial8250_port tri_serial_ports[] = { 128 + #ifdef CONFIG_SERIAL_PXA 129 + /* this uses the own PXA driver */ 130 + { 131 + 0, 132 + }, 133 + #else 134 + /* this uses the generic 8520 driver */ 135 + [0] = { 136 + .membase = (void *)&FFUART, 137 + .irq = IRQ_FFUART, 138 + .flags = UPF_BOOT_AUTOCONF, 139 + .iotype = UPIO_MEM32, 140 + .regshift = 2, 141 + .uartclk = (921600*16), 142 + }, 143 + [1] = { 144 + .membase = (void *)&BTUART, 145 + .irq = IRQ_BTUART, 146 + .flags = UPF_BOOT_AUTOCONF, 147 + .iotype = UPIO_MEM32, 148 + .regshift = 2, 149 + .uartclk = (921600*16), 150 + }, 151 + { 152 + 0, 153 + }, 154 + #endif 155 + }; 156 + 157 + static struct platform_device uart_devices = { 158 + .name = "serial8250", 159 + .id = 0, 160 + .dev = { 161 + .platform_data = tri_serial_ports, 162 + }, 163 + .num_resources = 0, 164 + .resource = NULL, 165 + }; 166 + 167 + /******************************************************************************************** 168 + * PXA270 ac97 sound codec 169 + ********************************************************************************************/ 170 + static struct platform_device ac97_audio_device = { 171 + .name = "pxa2xx-ac97", 172 + .id = -1, 173 + }; 174 + 175 + static struct platform_device * trizeps4_devices[] __initdata = { 176 + &flash_device, 177 + &uart_devices, 178 + &dm9000_device, 179 + &ac97_audio_device, 180 + }; 181 + 182 + #ifdef CONFIG_MACH_TRIZEPS4_CONXS 183 + static short trizeps_conxs_bcr; 184 + 185 + /* PCCARD power switching supports only 3,3V */ 186 + void board_pcmcia_power(int power) 187 + { 188 + if (power) { 189 + /* switch power on, put in reset and enable buffers */ 190 + trizeps_conxs_bcr |= power; 191 + trizeps_conxs_bcr |= ConXS_BCR_CF_RESET; 192 + trizeps_conxs_bcr &= ~(ConXS_BCR_CF_BUF_EN); 193 + ConXS_BCR = trizeps_conxs_bcr; 194 + /* wait a little */ 195 + udelay(2000); 196 + /* take reset away */ 197 + trizeps_conxs_bcr &= ~(ConXS_BCR_CF_RESET); 198 + ConXS_BCR = trizeps_conxs_bcr; 199 + udelay(2000); 200 + } else { 201 + /* put in reset */ 202 + trizeps_conxs_bcr |= ConXS_BCR_CF_RESET; 203 + ConXS_BCR = trizeps_conxs_bcr; 204 + udelay(1000); 205 + /* switch power off */ 206 + trizeps_conxs_bcr &= ~(0xf); 207 + ConXS_BCR = trizeps_conxs_bcr; 208 + 209 + } 210 + pr_debug("%s: o%s 0x%x\n", __FUNCTION__, power ? "n": "ff", trizeps_conxs_bcr); 211 + } 212 + 213 + /* backlight power switching for LCD panel */ 214 + static void board_backlight_power(int on) 215 + { 216 + if (on) { 217 + trizeps_conxs_bcr |= ConXS_BCR_L_DISP; 218 + } else { 219 + trizeps_conxs_bcr &= ~ConXS_BCR_L_DISP; 220 + } 221 + pr_debug("%s: o%s 0x%x\n", __FUNCTION__, on ? "n" : "ff", trizeps_conxs_bcr); 222 + ConXS_BCR = trizeps_conxs_bcr; 223 + } 224 + 225 + /* Powersupply for MMC/SD cardslot */ 226 + static void board_mci_power(struct device *dev, unsigned int vdd) 227 + { 228 + struct pxamci_platform_data* p_d = dev->platform_data; 229 + 230 + if (( 1 << vdd) & p_d->ocr_mask) { 231 + pr_debug("%s: on\n", __FUNCTION__); 232 + /* FIXME fill in values here */ 233 + } else { 234 + pr_debug("%s: off\n", __FUNCTION__); 235 + /* FIXME fill in values here */ 236 + } 237 + } 238 + 239 + static short trizeps_conxs_ircr; 240 + 241 + /* Switch modes and Power for IRDA receiver */ 242 + static void board_irda_mode(struct device *dev, int mode) 243 + { 244 + unsigned long flags; 245 + 246 + local_irq_save(flags); 247 + if (mode & IR_SIRMODE) { 248 + /* Slow mode */ 249 + trizeps_conxs_ircr &= ~ConXS_IRCR_MODE; 250 + } else if (mode & IR_FIRMODE) { 251 + /* Fast mode */ 252 + trizeps_conxs_ircr |= ConXS_IRCR_MODE; 253 + } 254 + if (mode & IR_OFF) { 255 + trizeps_conxs_ircr |= ConXS_IRCR_SD; 256 + } else { 257 + trizeps_conxs_ircr &= ~ConXS_IRCR_SD; 258 + } 259 + /* FIXME write values to register */ 260 + local_irq_restore(flags); 261 + } 262 + 263 + #else 264 + /* for other baseboards define dummies */ 265 + void board_pcmcia_power(int power) {;} 266 + #define board_backlight_power NULL 267 + #define board_mci_power NULL 268 + #define board_irda_mode NULL 269 + 270 + #endif /* CONFIG_MACH_TRIZEPS4_CONXS */ 271 + EXPORT_SYMBOL(board_pcmcia_power); 272 + 273 + static int trizeps4_mci_init(struct device *dev, irqreturn_t (*mci_detect_int)(int, void *, struct pt_regs *), void *data) 274 + { 275 + int err; 276 + /* setup GPIO for PXA27x MMC controller */ 277 + pxa_gpio_mode(GPIO32_MMCCLK_MD); 278 + pxa_gpio_mode(GPIO112_MMCCMD_MD); 279 + pxa_gpio_mode(GPIO92_MMCDAT0_MD); 280 + pxa_gpio_mode(GPIO109_MMCDAT1_MD); 281 + pxa_gpio_mode(GPIO110_MMCDAT2_MD); 282 + pxa_gpio_mode(GPIO111_MMCDAT3_MD); 283 + 284 + pxa_gpio_mode(GPIO_MMC_DET | GPIO_IN); 285 + 286 + err = request_irq(TRIZEPS4_MMC_IRQ, mci_detect_int, SA_INTERRUPT | SA_TRIGGER_RISING, "MMC card detect", data); 287 + if (err) { 288 + printk(KERN_ERR "trizeps4_mci_init: MMC/SD: can't request MMC card detect IRQ\n"); 289 + return -1; 290 + } 291 + return 0; 292 + } 293 + 294 + static void trizeps4_mci_exit(struct device *dev, void *data) 295 + { 296 + free_irq(TRIZEPS4_MMC_IRQ, data); 297 + } 298 + 299 + static struct pxamci_platform_data trizeps4_mci_platform_data = { 300 + .ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34, 301 + .init = trizeps4_mci_init, 302 + .exit = trizeps4_mci_exit, 303 + .setpower = board_mci_power, 304 + }; 305 + 306 + static struct pxaficp_platform_data trizeps4_ficp_platform_data = { 307 + .transceiver_cap = IR_SIRMODE | IR_FIRMODE | IR_OFF, 308 + .transceiver_mode = board_irda_mode, 309 + }; 310 + 311 + static int trizeps4_ohci_init(struct device *dev) 312 + { 313 + /* setup Port1 GPIO pin. */ 314 + pxa_gpio_mode( 88 | GPIO_ALT_FN_1_IN); /* USBHPWR1 */ 315 + pxa_gpio_mode( 89 | GPIO_ALT_FN_2_OUT); /* USBHPEN1 */ 316 + 317 + /* Set the Power Control Polarity Low and Power Sense 318 + Polarity Low to active low. */ 319 + UHCHR = (UHCHR | UHCHR_PCPL | UHCHR_PSPL) & 320 + ~(UHCHR_SSEP1 | UHCHR_SSEP2 | UHCHR_SSEP3 | UHCHR_SSE); 321 + 322 + return 0; 323 + } 324 + 325 + static void trizeps4_ohci_exit(struct device *dev) 326 + { 327 + ; 328 + } 329 + 330 + static struct pxaohci_platform_data trizeps4_ohci_platform_data = { 331 + .port_mode = PMM_PERPORT_MODE, 332 + .init = trizeps4_ohci_init, 333 + .exit = trizeps4_ohci_exit, 334 + }; 335 + 336 + static struct map_desc trizeps4_io_desc[] __initdata = { 337 + { /* ConXS CFSR */ 338 + .virtual = TRIZEPS4_CFSR_VIRT, 339 + .pfn = __phys_to_pfn(TRIZEPS4_CFSR_PHYS), 340 + .length = 0x00001000, 341 + .type = MT_DEVICE 342 + }, 343 + { /* ConXS BCR */ 344 + .virtual = TRIZEPS4_BOCR_VIRT, 345 + .pfn = __phys_to_pfn(TRIZEPS4_BOCR_PHYS), 346 + .length = 0x00001000, 347 + .type = MT_DEVICE 348 + }, 349 + { /* ConXS IRCR */ 350 + .virtual = TRIZEPS4_IRCR_VIRT, 351 + .pfn = __phys_to_pfn(TRIZEPS4_IRCR_PHYS), 352 + .length = 0x00001000, 353 + .type = MT_DEVICE 354 + }, 355 + { /* ConXS DCR */ 356 + .virtual = TRIZEPS4_DICR_VIRT, 357 + .pfn = __phys_to_pfn(TRIZEPS4_DICR_PHYS), 358 + .length = 0x00001000, 359 + .type = MT_DEVICE 360 + }, 361 + { /* ConXS UPSR */ 362 + .virtual = TRIZEPS4_UPSR_VIRT, 363 + .pfn = __phys_to_pfn(TRIZEPS4_UPSR_PHYS), 364 + .length = 0x00001000, 365 + .type = MT_DEVICE 366 + } 367 + }; 368 + 369 + static struct pxafb_mach_info sharp_lcd __initdata = { 370 + .pixclock = 78000, 371 + .xres = 640, 372 + .yres = 480, 373 + .bpp = 8, 374 + .hsync_len = 4, 375 + .left_margin = 4, 376 + .right_margin = 4, 377 + .vsync_len = 2, 378 + .upper_margin = 0, 379 + .lower_margin = 0, 380 + .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, 381 + .cmap_greyscale = 0, 382 + .cmap_inverse = 0, 383 + .cmap_static = 0, 384 + .lccr0 = LCCR0_Color | LCCR0_Pas | LCCR0_Dual, 385 + .lccr3 = 0x0340ff02, 386 + .pxafb_backlight_power = board_backlight_power, 387 + }; 388 + 389 + static void __init trizeps4_fixup(struct machine_desc *desc, struct tag *tags, char **cmdline, struct meminfo *mi) 390 + { 391 + } 392 + 393 + static void __init trizeps4_init(void) 394 + { 395 + platform_add_devices(trizeps4_devices, ARRAY_SIZE(trizeps4_devices)); 396 + 397 + set_pxa_fb_info(&sharp_lcd); 398 + 399 + pxa_set_mci_info(&trizeps4_mci_platform_data); 400 + pxa_set_ficp_info(&trizeps4_ficp_platform_data); 401 + pxa_set_ohci_info(&trizeps4_ohci_platform_data); 402 + } 403 + 404 + static void __init trizeps4_map_io(void) 405 + { 406 + pxa_map_io(); 407 + iotable_init(trizeps4_io_desc, ARRAY_SIZE(trizeps4_io_desc)); 408 + 409 + /* for DiskOnChip */ 410 + pxa_gpio_mode(GPIO15_nCS_1_MD); 411 + 412 + /* for off-module PIC on ConXS board */ 413 + pxa_gpio_mode(GPIO_PIC | GPIO_IN); 414 + 415 + /* UCB1400 irq */ 416 + pxa_gpio_mode(GPIO_UCB1400 | GPIO_IN); 417 + 418 + /* for DM9000 LAN */ 419 + pxa_gpio_mode(GPIO78_nCS_2_MD); 420 + pxa_gpio_mode(GPIO_DM9000 | GPIO_IN); 421 + 422 + /* for PCMCIA device */ 423 + pxa_gpio_mode(GPIO_PCD | GPIO_IN); 424 + pxa_gpio_mode(GPIO_PRDY | GPIO_IN); 425 + 426 + /* for I2C adapter */ 427 + pxa_gpio_mode(GPIO117_I2CSCL_MD); 428 + pxa_gpio_mode(GPIO118_I2CSDA_MD); 429 + 430 + /* MMC_DET s.o. */ 431 + pxa_gpio_mode(GPIO_MMC_DET | GPIO_IN); 432 + 433 + /* whats that for ??? */ 434 + pxa_gpio_mode(GPIO79_nCS_3_MD); 435 + 436 + pxa_gpio_mode( GPIO_SYS_BUSY_LED | GPIO_OUT); /* LED1 */ 437 + pxa_gpio_mode( GPIO_HEARTBEAT_LED | GPIO_OUT); /* LED2 */ 438 + 439 + #ifdef CONFIG_MACH_TRIZEPS4_CONXS 440 + #ifdef CONFIG_IDE_PXA_CF 441 + /* if boot direct from compact flash dont disable power */ 442 + trizeps_conxs_bcr = 0x0009; 443 + #else 444 + /* this is the reset value */ 445 + trizeps_conxs_bcr = 0x00A0; 446 + #endif 447 + ConXS_BCR = trizeps_conxs_bcr; 448 + #endif 449 + 450 + PWER = 0x00000002; 451 + PFER = 0x00000000; 452 + PRER = 0x00000002; 453 + PGSR0 = 0x0158C000; 454 + PGSR1 = 0x00FF0080; 455 + PGSR2 = 0x0001C004; 456 + /* Stop 3.6MHz and drive HIGH to PCMCIA and CS */ 457 + PCFR |= PCFR_OPDE; 458 + } 459 + 460 + MACHINE_START(TRIZEPS4, "Keith und Koep Trizeps IV module") 461 + /* MAINTAINER("Jürgen Schindele") */ 462 + .phys_io = 0x40000000, 463 + .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc, 464 + .boot_params = TRIZEPS4_SDRAM_BASE + 0x100, 465 + .fixup = trizeps4_fixup, 466 + .init_machine = trizeps4_init, 467 + .map_io = trizeps4_map_io, 468 + .init_irq = pxa_init_irq, 469 + .timer = &pxa_timer, 470 + MACHINE_END 471 +
+76 -55
arch/arm/mach-sa1100/cpu-sa1110.c
··· 15 15 * SDRAM reads (rev A0, B0, B1) 16 16 * 17 17 * We ignore rev. A0 and B0 devices; I don't think they're worth supporting. 18 + * 19 + * The SDRAM type can be passed on the command line as cpu_sa1110.sdram=type 18 20 */ 21 + #include <linux/moduleparam.h> 19 22 #include <linux/types.h> 20 23 #include <linux/kernel.h> 21 24 #include <linux/sched.h> ··· 38 35 static struct cpufreq_driver sa1110_driver; 39 36 40 37 struct sdram_params { 38 + const char name[16]; 41 39 u_char rows; /* bits */ 42 40 u_char cas_latency; /* cycles */ 43 41 u_char tck; /* clock cycle time (ns) */ ··· 54 50 u_int mdcas[3]; 55 51 }; 56 52 57 - static struct sdram_params tc59sm716_cl2_params __initdata = { 58 - .rows = 12, 59 - .tck = 10, 60 - .trcd = 20, 61 - .trp = 20, 62 - .twr = 10, 63 - .refresh = 64000, 64 - .cas_latency = 2, 65 - }; 66 - 67 - static struct sdram_params tc59sm716_cl3_params __initdata = { 68 - .rows = 12, 69 - .tck = 8, 70 - .trcd = 20, 71 - .trp = 20, 72 - .twr = 8, 73 - .refresh = 64000, 74 - .cas_latency = 3, 75 - }; 76 - 77 - static struct sdram_params samsung_k4s641632d_tc75 __initdata = { 78 - .rows = 14, 79 - .tck = 9, 80 - .trcd = 27, 81 - .trp = 20, 82 - .twr = 9, 83 - .refresh = 64000, 84 - .cas_latency = 3, 85 - }; 86 - 87 - static struct sdram_params samsung_km416s4030ct __initdata = { 88 - .rows = 13, 89 - .tck = 8, 90 - .trcd = 24, /* 3 CLKs */ 91 - .trp = 24, /* 3 CLKs */ 92 - .twr = 16, /* Trdl: 2 CLKs */ 93 - .refresh = 64000, 94 - .cas_latency = 3, 95 - }; 96 - 97 - static struct sdram_params wbond_w982516ah75l_cl3_params __initdata = { 98 - .rows = 16, 99 - .tck = 8, 100 - .trcd = 20, 101 - .trp = 20, 102 - .twr = 8, 103 - .refresh = 64000, 104 - .cas_latency = 3, 53 + static struct sdram_params sdram_tbl[] __initdata = { 54 + { /* Toshiba TC59SM716 CL2 */ 55 + .name = "TC59SM716-CL2", 56 + .rows = 12, 57 + .tck = 10, 58 + .trcd = 20, 59 + .trp = 20, 60 + .twr = 10, 61 + .refresh = 64000, 62 + .cas_latency = 2, 63 + }, { /* Toshiba TC59SM716 CL3 */ 64 + .name = "TC59SM716-CL3", 65 + .rows = 12, 66 + .tck = 8, 67 + .trcd = 20, 68 + .trp = 20, 69 + .twr = 8, 70 + .refresh = 64000, 71 + .cas_latency = 3, 72 + }, { /* Samsung K4S641632D TC75 */ 73 + .name = "K4S641632D", 74 + .rows = 14, 75 + .tck = 9, 76 + .trcd = 27, 77 + .trp = 20, 78 + .twr = 9, 79 + .refresh = 64000, 80 + .cas_latency = 3, 81 + }, { /* Samsung KM416S4030CT */ 82 + .name = "KM416S4030CT", 83 + .rows = 13, 84 + .tck = 8, 85 + .trcd = 24, /* 3 CLKs */ 86 + .trp = 24, /* 3 CLKs */ 87 + .twr = 16, /* Trdl: 2 CLKs */ 88 + .refresh = 64000, 89 + .cas_latency = 3, 90 + }, { /* Winbond W982516AH75L CL3 */ 91 + .name = "W982516AH75L", 92 + .rows = 16, 93 + .tck = 8, 94 + .trcd = 20, 95 + .trp = 20, 96 + .twr = 8, 97 + .refresh = 64000, 98 + .cas_latency = 3, 99 + }, 105 100 }; 106 101 107 102 static struct sdram_params sdram_params; ··· 339 336 .name = "sa1110", 340 337 }; 341 338 339 + static struct sdram_params *sa1110_find_sdram(const char *name) 340 + { 341 + struct sdram_params *sdram; 342 + 343 + for (sdram = sdram_tbl; sdram < sdram_tbl + ARRAY_SIZE(sdram_tbl); sdram++) 344 + if (strcmp(name, sdram->name) == 0) 345 + return sdram; 346 + 347 + return NULL; 348 + } 349 + 350 + static char sdram_name[16]; 351 + 342 352 static int __init sa1110_clk_init(void) 343 353 { 344 - struct sdram_params *sdram = NULL; 354 + struct sdram_params *sdram; 355 + const char *name = sdram_name; 345 356 346 - if (machine_is_assabet()) 347 - sdram = &tc59sm716_cl3_params; 357 + if (!name[0]) { 358 + if (machine_is_assabet()) 359 + name = "TC59SM716-CL3"; 348 360 349 - if (machine_is_pt_system3()) 350 - sdram = &samsung_k4s641632d_tc75; 361 + if (machine_is_pt_system3()) 362 + name = "K4S641632D"; 351 363 352 - if (machine_is_h3100()) 353 - sdram = &samsung_km416s4030ct; 364 + if (machine_is_h3100()) 365 + name = "KM416S4030CT"; 366 + } 354 367 368 + sdram = sa1110_find_sdram(name); 355 369 if (sdram) { 356 370 printk(KERN_DEBUG "SDRAM: tck: %d trcd: %d trp: %d" 357 371 " twr: %d refresh: %d cas_latency: %d\n", ··· 383 363 return 0; 384 364 } 385 365 366 + module_param_string(sdram, sdram_name, sizeof(sdram_name), 0); 386 367 arch_initcall(sa1110_clk_init);
+2 -2
arch/arm/mm/Kconfig
··· 121 121 # ARM926T 122 122 config CPU_ARM926T 123 123 bool "Support ARM926T processor" 124 - depends on ARCH_INTEGRATOR || ARCH_VERSATILE_PB || MACH_VERSATILE_AB || ARCH_OMAP730 || ARCH_OMAP16XX || MACH_REALVIEW_EB || ARCH_PNX4008 || ARCH_NETX || CPU_S3C2412 125 - default y if ARCH_VERSATILE_PB || MACH_VERSATILE_AB || ARCH_OMAP730 || ARCH_OMAP16XX || ARCH_PNX4008 || ARCH_NETX || CPU_S3C2412 124 + depends on ARCH_INTEGRATOR || ARCH_VERSATILE_PB || MACH_VERSATILE_AB || ARCH_OMAP730 || ARCH_OMAP16XX || MACH_REALVIEW_EB || ARCH_PNX4008 || ARCH_NETX || CPU_S3C2412 || ARCH_AT91SAM9260 || ARCH_AT91SAM9261 125 + default y if ARCH_VERSATILE_PB || MACH_VERSATILE_AB || ARCH_OMAP730 || ARCH_OMAP16XX || ARCH_PNX4008 || ARCH_NETX || CPU_S3C2412 || ARCH_AT91SAM9260 || ARCH_AT91SAM9261 126 126 select CPU_32v5 127 127 select CPU_ABRT_EV5TJ 128 128 select CPU_CACHE_VIVT
+223 -4
arch/arm/mm/ioremap.c
··· 27 27 28 28 #include <asm/cacheflush.h> 29 29 #include <asm/io.h> 30 + #include <asm/mmu_context.h> 31 + #include <asm/pgalloc.h> 30 32 #include <asm/tlbflush.h> 33 + #include <asm/sizes.h> 34 + 35 + /* 36 + * Used by ioremap() and iounmap() code to mark (super)section-mapped 37 + * I/O regions in vm_struct->flags field. 38 + */ 39 + #define VM_ARM_SECTION_MAPPING 0x80000000 31 40 32 41 static inline void 33 42 remap_area_pte(pte_t * pte, unsigned long address, unsigned long size, ··· 122 113 dir++; 123 114 } while (address && (address < end)); 124 115 125 - flush_cache_vmap(start, end); 126 116 return err; 127 117 } 118 + 119 + 120 + void __check_kvm_seq(struct mm_struct *mm) 121 + { 122 + unsigned int seq; 123 + 124 + do { 125 + seq = init_mm.context.kvm_seq; 126 + memcpy(pgd_offset(mm, VMALLOC_START), 127 + pgd_offset_k(VMALLOC_START), 128 + sizeof(pgd_t) * (pgd_index(VMALLOC_END) - 129 + pgd_index(VMALLOC_START))); 130 + mm->context.kvm_seq = seq; 131 + } while (seq != init_mm.context.kvm_seq); 132 + } 133 + 134 + #ifndef CONFIG_SMP 135 + /* 136 + * Section support is unsafe on SMP - If you iounmap and ioremap a region, 137 + * the other CPUs will not see this change until their next context switch. 138 + * Meanwhile, (eg) if an interrupt comes in on one of those other CPUs 139 + * which requires the new ioremap'd region to be referenced, the CPU will 140 + * reference the _old_ region. 141 + * 142 + * Note that get_vm_area() allocates a guard 4K page, so we need to mask 143 + * the size back to 1MB aligned or we will overflow in the loop below. 144 + */ 145 + static void unmap_area_sections(unsigned long virt, unsigned long size) 146 + { 147 + unsigned long addr = virt, end = virt + (size & ~SZ_1M); 148 + pgd_t *pgd; 149 + 150 + flush_cache_vunmap(addr, end); 151 + pgd = pgd_offset_k(addr); 152 + do { 153 + pmd_t pmd, *pmdp = pmd_offset(pgd, addr); 154 + 155 + pmd = *pmdp; 156 + if (!pmd_none(pmd)) { 157 + /* 158 + * Clear the PMD from the page table, and 159 + * increment the kvm sequence so others 160 + * notice this change. 161 + * 162 + * Note: this is still racy on SMP machines. 163 + */ 164 + pmd_clear(pmdp); 165 + init_mm.context.kvm_seq++; 166 + 167 + /* 168 + * Free the page table, if there was one. 169 + */ 170 + if ((pmd_val(pmd) & PMD_TYPE_MASK) == PMD_TYPE_TABLE) 171 + pte_free_kernel(pmd_page_kernel(pmd)); 172 + } 173 + 174 + addr += PGDIR_SIZE; 175 + pgd++; 176 + } while (addr < end); 177 + 178 + /* 179 + * Ensure that the active_mm is up to date - we want to 180 + * catch any use-after-iounmap cases. 181 + */ 182 + if (current->active_mm->context.kvm_seq != init_mm.context.kvm_seq) 183 + __check_kvm_seq(current->active_mm); 184 + 185 + flush_tlb_kernel_range(virt, end); 186 + } 187 + 188 + static int 189 + remap_area_sections(unsigned long virt, unsigned long pfn, 190 + unsigned long size, unsigned long flags) 191 + { 192 + unsigned long prot, addr = virt, end = virt + size; 193 + pgd_t *pgd; 194 + 195 + /* 196 + * Remove and free any PTE-based mapping, and 197 + * sync the current kernel mapping. 198 + */ 199 + unmap_area_sections(virt, size); 200 + 201 + prot = PMD_TYPE_SECT | PMD_SECT_AP_WRITE | PMD_DOMAIN(DOMAIN_IO) | 202 + (flags & (L_PTE_CACHEABLE | L_PTE_BUFFERABLE)); 203 + 204 + /* 205 + * ARMv6 and above need XN set to prevent speculative prefetches 206 + * hitting IO. 207 + */ 208 + if (cpu_architecture() >= CPU_ARCH_ARMv6) 209 + prot |= PMD_SECT_XN; 210 + 211 + pgd = pgd_offset_k(addr); 212 + do { 213 + pmd_t *pmd = pmd_offset(pgd, addr); 214 + 215 + pmd[0] = __pmd(__pfn_to_phys(pfn) | prot); 216 + pfn += SZ_1M >> PAGE_SHIFT; 217 + pmd[1] = __pmd(__pfn_to_phys(pfn) | prot); 218 + pfn += SZ_1M >> PAGE_SHIFT; 219 + flush_pmd_entry(pmd); 220 + 221 + addr += PGDIR_SIZE; 222 + pgd++; 223 + } while (addr < end); 224 + 225 + return 0; 226 + } 227 + 228 + static int 229 + remap_area_supersections(unsigned long virt, unsigned long pfn, 230 + unsigned long size, unsigned long flags) 231 + { 232 + unsigned long prot, addr = virt, end = virt + size; 233 + pgd_t *pgd; 234 + 235 + /* 236 + * Remove and free any PTE-based mapping, and 237 + * sync the current kernel mapping. 238 + */ 239 + unmap_area_sections(virt, size); 240 + 241 + prot = PMD_TYPE_SECT | PMD_SECT_SUPER | PMD_SECT_AP_WRITE | 242 + PMD_DOMAIN(DOMAIN_IO) | 243 + (flags & (L_PTE_CACHEABLE | L_PTE_BUFFERABLE)); 244 + 245 + /* 246 + * ARMv6 and above need XN set to prevent speculative prefetches 247 + * hitting IO. 248 + */ 249 + if (cpu_architecture() >= CPU_ARCH_ARMv6) 250 + prot |= PMD_SECT_XN; 251 + 252 + pgd = pgd_offset_k(virt); 253 + do { 254 + unsigned long super_pmd_val, i; 255 + 256 + super_pmd_val = __pfn_to_phys(pfn) | prot; 257 + super_pmd_val |= ((pfn >> (32 - PAGE_SHIFT)) & 0xf) << 20; 258 + 259 + for (i = 0; i < 8; i++) { 260 + pmd_t *pmd = pmd_offset(pgd, addr); 261 + 262 + pmd[0] = __pmd(super_pmd_val); 263 + pmd[1] = __pmd(super_pmd_val); 264 + flush_pmd_entry(pmd); 265 + 266 + addr += PGDIR_SIZE; 267 + pgd++; 268 + } 269 + 270 + pfn += SUPERSECTION_SIZE >> PAGE_SHIFT; 271 + } while (addr < end); 272 + 273 + return 0; 274 + } 275 + #endif 276 + 128 277 129 278 /* 130 279 * Remap an arbitrary physical address space into the kernel virtual ··· 300 133 __ioremap_pfn(unsigned long pfn, unsigned long offset, size_t size, 301 134 unsigned long flags) 302 135 { 136 + int err; 303 137 unsigned long addr; 304 138 struct vm_struct * area; 139 + unsigned int cr = get_cr(); 140 + 141 + /* 142 + * High mappings must be supersection aligned 143 + */ 144 + if (pfn >= 0x100000 && (__pfn_to_phys(pfn) & ~SUPERSECTION_MASK)) 145 + return NULL; 305 146 306 147 area = get_vm_area(size, VM_IOREMAP); 307 148 if (!area) 308 149 return NULL; 309 150 addr = (unsigned long)area->addr; 310 - if (remap_area_pages(addr, pfn, size, flags)) { 151 + 152 + #ifndef CONFIG_SMP 153 + if ((((cpu_architecture() >= CPU_ARCH_ARMv6) && (cr & CR_XP)) || 154 + cpu_is_xsc3()) && 155 + !((__pfn_to_phys(pfn) | size | addr) & ~SUPERSECTION_MASK)) { 156 + area->flags |= VM_ARM_SECTION_MAPPING; 157 + err = remap_area_supersections(addr, pfn, size, flags); 158 + } else if (!((__pfn_to_phys(pfn) | size | addr) & ~PMD_MASK)) { 159 + area->flags |= VM_ARM_SECTION_MAPPING; 160 + err = remap_area_sections(addr, pfn, size, flags); 161 + } else 162 + #endif 163 + err = remap_area_pages(addr, pfn, size, flags); 164 + 165 + if (err) { 311 166 vunmap((void *)addr); 312 167 return NULL; 313 168 } 314 - return (void __iomem *) (offset + (char *)addr); 169 + 170 + flush_cache_vmap(addr, addr + size); 171 + return (void __iomem *) (offset + addr); 315 172 } 316 173 EXPORT_SYMBOL(__ioremap_pfn); 317 174 ··· 364 173 365 174 void __iounmap(void __iomem *addr) 366 175 { 367 - vunmap((void *)(PAGE_MASK & (unsigned long)addr)); 176 + struct vm_struct **p, *tmp; 177 + unsigned int section_mapping = 0; 178 + 179 + addr = (void __iomem *)(PAGE_MASK & (unsigned long)addr); 180 + 181 + /* 182 + * If this is a section based mapping we need to handle it 183 + * specially as the VM subysystem does not know how to handle 184 + * such a beast. We need the lock here b/c we need to clear 185 + * all the mappings before the area can be reclaimed 186 + * by someone else. 187 + */ 188 + write_lock(&vmlist_lock); 189 + for (p = &vmlist ; (tmp = *p) ; p = &tmp->next) { 190 + if((tmp->flags & VM_IOREMAP) && (tmp->addr == addr)) { 191 + if (tmp->flags & VM_ARM_SECTION_MAPPING) { 192 + *p = tmp->next; 193 + unmap_area_sections((unsigned long)tmp->addr, 194 + tmp->size); 195 + kfree(tmp); 196 + section_mapping = 1; 197 + } 198 + break; 199 + } 200 + } 201 + write_unlock(&vmlist_lock); 202 + 203 + if (!section_mapping) 204 + vunmap(addr); 368 205 } 369 206 EXPORT_SYMBOL(__iounmap);
+22 -15
arch/arm/mm/mm-armv.c
··· 302 302 .prot_pte = L_PTE_PRESENT | L_PTE_YOUNG | L_PTE_DIRTY | 303 303 L_PTE_WRITE, 304 304 .prot_l1 = PMD_TYPE_TABLE, 305 - .prot_sect = PMD_TYPE_SECT | PMD_SECT_UNCACHED | 305 + .prot_sect = PMD_TYPE_SECT | PMD_BIT4 | PMD_SECT_UNCACHED | 306 306 PMD_SECT_AP_WRITE, 307 307 .domain = DOMAIN_IO, 308 308 }, 309 309 [MT_CACHECLEAN] = { 310 - .prot_sect = PMD_TYPE_SECT, 310 + .prot_sect = PMD_TYPE_SECT | PMD_BIT4, 311 311 .domain = DOMAIN_KERNEL, 312 312 }, 313 313 [MT_MINICLEAN] = { 314 - .prot_sect = PMD_TYPE_SECT | PMD_SECT_MINICACHE, 314 + .prot_sect = PMD_TYPE_SECT | PMD_BIT4 | PMD_SECT_MINICACHE, 315 315 .domain = DOMAIN_KERNEL, 316 316 }, 317 317 [MT_LOW_VECTORS] = { ··· 327 327 .domain = DOMAIN_USER, 328 328 }, 329 329 [MT_MEMORY] = { 330 - .prot_sect = PMD_TYPE_SECT | PMD_SECT_AP_WRITE, 330 + .prot_sect = PMD_TYPE_SECT | PMD_BIT4 | PMD_SECT_AP_WRITE, 331 331 .domain = DOMAIN_KERNEL, 332 332 }, 333 333 [MT_ROM] = { 334 - .prot_sect = PMD_TYPE_SECT, 334 + .prot_sect = PMD_TYPE_SECT | PMD_BIT4, 335 335 .domain = DOMAIN_KERNEL, 336 336 }, 337 337 [MT_IXP2000_DEVICE] = { /* IXP2400 requires XCB=101 for on-chip I/O */ 338 338 .prot_pte = L_PTE_PRESENT | L_PTE_YOUNG | L_PTE_DIRTY | 339 339 L_PTE_WRITE, 340 340 .prot_l1 = PMD_TYPE_TABLE, 341 - .prot_sect = PMD_TYPE_SECT | PMD_SECT_UNCACHED | 341 + .prot_sect = PMD_TYPE_SECT | PMD_BIT4 | PMD_SECT_UNCACHED | 342 342 PMD_SECT_AP_WRITE | PMD_SECT_BUFFERABLE | 343 343 PMD_SECT_TEX(1), 344 344 .domain = DOMAIN_IO, 345 345 }, 346 346 [MT_NONSHARED_DEVICE] = { 347 347 .prot_l1 = PMD_TYPE_TABLE, 348 - .prot_sect = PMD_TYPE_SECT | PMD_SECT_NONSHARED_DEV | 348 + .prot_sect = PMD_TYPE_SECT | PMD_BIT4 | PMD_SECT_NONSHARED_DEV | 349 349 PMD_SECT_AP_WRITE, 350 350 .domain = DOMAIN_IO, 351 351 } ··· 375 375 ecc_mask = 0; 376 376 } 377 377 378 - if (cpu_arch <= CPU_ARCH_ARMv5TEJ && !cpu_is_xscale()) { 379 - for (i = 0; i < ARRAY_SIZE(mem_types); i++) { 378 + /* 379 + * Xscale must not have PMD bit 4 set for section mappings. 380 + */ 381 + if (cpu_is_xscale()) 382 + for (i = 0; i < ARRAY_SIZE(mem_types); i++) 383 + mem_types[i].prot_sect &= ~PMD_BIT4; 384 + 385 + /* 386 + * ARMv5 and lower, excluding Xscale, bit 4 must be set for 387 + * page tables. 388 + */ 389 + if (cpu_arch < CPU_ARCH_ARMv6 && !cpu_is_xscale()) 390 + for (i = 0; i < ARRAY_SIZE(mem_types); i++) 380 391 if (mem_types[i].prot_l1) 381 392 mem_types[i].prot_l1 |= PMD_BIT4; 382 - if (mem_types[i].prot_sect) 383 - mem_types[i].prot_sect |= PMD_BIT4; 384 - } 385 - } 386 393 387 394 cp = &cache_policies[cachepolicy]; 388 395 kern_pgprot = user_pgprot = cp->pte; ··· 413 406 * bit 4 becomes XN which we must clear for the 414 407 * kernel memory mapping. 415 408 */ 416 - mem_types[MT_MEMORY].prot_sect &= ~PMD_BIT4; 417 - mem_types[MT_ROM].prot_sect &= ~PMD_BIT4; 409 + mem_types[MT_MEMORY].prot_sect &= ~PMD_SECT_XN; 410 + mem_types[MT_ROM].prot_sect &= ~PMD_SECT_XN; 418 411 419 412 /* 420 413 * Mark cache clean areas and XIP ROM read only
+10 -9
arch/arm/mm/proc-arm1020.S
··· 439 439 #ifdef CONFIG_MMU 440 440 mcr p15, 0, r0, c8, c7 @ invalidate I,D TLBs on v4 441 441 #endif 442 + 443 + adr r5, arm1020_crval 444 + ldmia r5, {r5, r6} 442 445 mrc p15, 0, r0, c1, c0 @ get control register v4 443 - ldr r5, arm1020_cr1_clear 444 446 bic r0, r0, r5 445 - ldr r5, arm1020_cr1_set 446 - orr r0, r0, r5 447 + orr r0, r0, r6 447 448 #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 448 449 orr r0, r0, #0x4000 @ .R.. .... .... .... 449 450 #endif ··· 456 455 * .RVI ZFRS BLDP WCAM 457 456 * .011 1001 ..11 0101 458 457 */ 459 - .type arm1020_cr1_clear, #object 460 - .type arm1020_cr1_set, #object 461 - arm1020_cr1_clear: 462 - .word 0x593f 463 - arm1020_cr1_set: 464 - .word 0x3935 458 + .type arm1020_crval, #object 459 + arm1020_crval: 460 + crval clear=0x0000593f, mmuset=0x00003935, ucset=0x00001930 465 461 466 462 __INITDATA 467 463 ··· 521 523 __arm1020_proc_info: 522 524 .long 0x4104a200 @ ARM 1020T (Architecture v5T) 523 525 .long 0xff0ffff0 526 + .long PMD_TYPE_SECT | \ 527 + PMD_SECT_AP_WRITE | \ 528 + PMD_SECT_AP_READ 524 529 .long PMD_TYPE_SECT | \ 525 530 PMD_SECT_AP_WRITE | \ 526 531 PMD_SECT_AP_READ
+11 -28
arch/arm/mm/proc-arm1020e.S
··· 421 421 #ifdef CONFIG_MMU 422 422 mcr p15, 0, r0, c8, c7 @ invalidate I,D TLBs on v4 423 423 #endif 424 + adr r5, arm1020e_crval 425 + ldmia r5, {r5, r6} 424 426 mrc p15, 0, r0, c1, c0 @ get control register v4 425 - ldr r5, arm1020e_cr1_clear 426 427 bic r0, r0, r5 427 - ldr r5, arm1020e_cr1_set 428 - orr r0, r0, r5 428 + orr r0, r0, r6 429 429 #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 430 430 orr r0, r0, #0x4000 @ .R.. .... .... .... 431 431 #endif ··· 437 437 * .RVI ZFRS BLDP WCAM 438 438 * .011 1001 ..11 0101 439 439 */ 440 - .type arm1020e_cr1_clear, #object 441 - .type arm1020e_cr1_set, #object 442 - arm1020e_cr1_clear: 443 - .word 0x5f3f 444 - arm1020e_cr1_set: 445 - .word 0x3935 440 + .type arm1020e_crval, #object 441 + arm1020e_crval: 442 + crval clear=0x00007f3f, mmuset=0x00003935, ucset=0x00001930 446 443 447 444 __INITDATA 448 445 ··· 473 476 474 477 .type cpu_arm1020e_name, #object 475 478 cpu_arm1020e_name: 476 - .ascii "ARM1020E" 477 - #ifndef CONFIG_CPU_ICACHE_DISABLE 478 - .ascii "i" 479 - #endif 480 - #ifndef CONFIG_CPU_DCACHE_DISABLE 481 - .ascii "d" 482 - #ifdef CONFIG_CPU_DCACHE_WRITETHROUGH 483 - .ascii "(wt)" 484 - #else 485 - .ascii "(wb)" 486 - #endif 487 - #endif 488 - #ifndef CONFIG_CPU_BPREDICT_DISABLE 489 - .ascii "B" 490 - #endif 491 - #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 492 - .ascii "RR" 493 - #endif 494 - .ascii "\0" 479 + .asciz "ARM1020E" 495 480 .size cpu_arm1020e_name, . - cpu_arm1020e_name 496 481 497 482 .align ··· 484 505 __arm1020e_proc_info: 485 506 .long 0x4105a200 @ ARM 1020TE (Architecture v5TE) 486 507 .long 0xff0ffff0 508 + .long PMD_TYPE_SECT | \ 509 + PMD_BIT4 | \ 510 + PMD_SECT_AP_WRITE | \ 511 + PMD_SECT_AP_READ 487 512 .long PMD_TYPE_SECT | \ 488 513 PMD_BIT4 | \ 489 514 PMD_SECT_AP_WRITE | \
+11 -28
arch/arm/mm/proc-arm1022.S
··· 403 403 #ifdef CONFIG_MMU 404 404 mcr p15, 0, r0, c8, c7 @ invalidate I,D TLBs on v4 405 405 #endif 406 + adr r5, arm1022_crval 407 + ldmia r5, {r5, r6} 406 408 mrc p15, 0, r0, c1, c0 @ get control register v4 407 - ldr r5, arm1022_cr1_clear 408 409 bic r0, r0, r5 409 - ldr r5, arm1022_cr1_set 410 - orr r0, r0, r5 410 + orr r0, r0, r6 411 411 #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 412 412 orr r0, r0, #0x4000 @ .R.............. 413 413 #endif ··· 420 420 * .011 1001 ..11 0101 421 421 * 422 422 */ 423 - .type arm1022_cr1_clear, #object 424 - .type arm1022_cr1_set, #object 425 - arm1022_cr1_clear: 426 - .word 0x7f3f 427 - arm1022_cr1_set: 428 - .word 0x3935 423 + .type arm1022_crval, #object 424 + arm1022_crval: 425 + crval clear=0x00007f3f, mmuset=0x00003935, ucset=0x00001930 429 426 430 427 __INITDATA 431 428 ··· 456 459 457 460 .type cpu_arm1022_name, #object 458 461 cpu_arm1022_name: 459 - .ascii "arm1022" 460 - #ifndef CONFIG_CPU_ICACHE_DISABLE 461 - .ascii "i" 462 - #endif 463 - #ifndef CONFIG_CPU_DCACHE_DISABLE 464 - .ascii "d" 465 - #ifdef CONFIG_CPU_DCACHE_WRITETHROUGH 466 - .ascii "(wt)" 467 - #else 468 - .ascii "(wb)" 469 - #endif 470 - #endif 471 - #ifndef CONFIG_CPU_BPREDICT_DISABLE 472 - .ascii "B" 473 - #endif 474 - #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 475 - .ascii "RR" 476 - #endif 477 - .ascii "\0" 462 + .asciz "ARM1022" 478 463 .size cpu_arm1022_name, . - cpu_arm1022_name 479 464 480 465 .align ··· 467 488 __arm1022_proc_info: 468 489 .long 0x4105a220 @ ARM 1022E (v5TE) 469 490 .long 0xff0ffff0 491 + .long PMD_TYPE_SECT | \ 492 + PMD_BIT4 | \ 493 + PMD_SECT_AP_WRITE | \ 494 + PMD_SECT_AP_READ 470 495 .long PMD_TYPE_SECT | \ 471 496 PMD_BIT4 | \ 472 497 PMD_SECT_AP_WRITE | \
+11 -28
arch/arm/mm/proc-arm1026.S
··· 398 398 mov r0, #4 @ explicitly disable writeback 399 399 mcr p15, 7, r0, c15, c0, 0 400 400 #endif 401 + adr r5, arm1026_crval 402 + ldmia r5, {r5, r6} 401 403 mrc p15, 0, r0, c1, c0 @ get control register v4 402 - ldr r5, arm1026_cr1_clear 403 404 bic r0, r0, r5 404 - ldr r5, arm1026_cr1_set 405 - orr r0, r0, r5 405 + orr r0, r0, r6 406 406 #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 407 407 orr r0, r0, #0x4000 @ .R.. .... .... .... 408 408 #endif ··· 415 415 * .011 1001 ..11 0101 416 416 * 417 417 */ 418 - .type arm1026_cr1_clear, #object 419 - .type arm1026_cr1_set, #object 420 - arm1026_cr1_clear: 421 - .word 0x7f3f 422 - arm1026_cr1_set: 423 - .word 0x3935 418 + .type arm1026_crval, #object 419 + arm1026_crval: 420 + crval clear=0x00007f3f, mmuset=0x00003935, ucset=0x00001934 424 421 425 422 __INITDATA 426 423 ··· 452 455 453 456 .type cpu_arm1026_name, #object 454 457 cpu_arm1026_name: 455 - .ascii "ARM1026EJ-S" 456 - #ifndef CONFIG_CPU_ICACHE_DISABLE 457 - .ascii "i" 458 - #endif 459 - #ifndef CONFIG_CPU_DCACHE_DISABLE 460 - .ascii "d" 461 - #ifdef CONFIG_CPU_DCACHE_WRITETHROUGH 462 - .ascii "(wt)" 463 - #else 464 - .ascii "(wb)" 465 - #endif 466 - #endif 467 - #ifndef CONFIG_CPU_BPREDICT_DISABLE 468 - .ascii "B" 469 - #endif 470 - #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 471 - .ascii "RR" 472 - #endif 473 - .ascii "\0" 458 + .asciz "ARM1026EJ-S" 474 459 .size cpu_arm1026_name, . - cpu_arm1026_name 475 460 476 461 .align ··· 463 484 __arm1026_proc_info: 464 485 .long 0x4106a260 @ ARM 1026EJ-S (v5TEJ) 465 486 .long 0xff0ffff0 487 + .long PMD_TYPE_SECT | \ 488 + PMD_BIT4 | \ 489 + PMD_SECT_AP_WRITE | \ 490 + PMD_SECT_AP_READ 466 491 .long PMD_TYPE_SECT | \ 467 492 PMD_BIT4 | \ 468 493 PMD_SECT_AP_WRITE | \
+16
arch/arm/mm/proc-arm6_7.S
··· 355 355 .long 0x41560600 356 356 .long 0xfffffff0 357 357 .long 0x00000c1e 358 + .long PMD_TYPE_SECT | \ 359 + PMD_BIT4 | \ 360 + PMD_SECT_AP_WRITE | \ 361 + PMD_SECT_AP_READ 358 362 b __arm6_setup 359 363 .long cpu_arch_name 360 364 .long cpu_elf_name ··· 375 371 .long 0x41560610 376 372 .long 0xfffffff0 377 373 .long 0x00000c1e 374 + .long PMD_TYPE_SECT | \ 375 + PMD_BIT4 | \ 376 + PMD_SECT_AP_WRITE | \ 377 + PMD_SECT_AP_READ 378 378 b __arm6_setup 379 379 .long cpu_arch_name 380 380 .long cpu_elf_name ··· 395 387 .long 0x41007000 396 388 .long 0xffffff00 397 389 .long 0x00000c1e 390 + .long PMD_TYPE_SECT | \ 391 + PMD_BIT4 | \ 392 + PMD_SECT_AP_WRITE | \ 393 + PMD_SECT_AP_READ 398 394 b __arm7_setup 399 395 .long cpu_arch_name 400 396 .long cpu_elf_name ··· 417 405 .long PMD_TYPE_SECT | \ 418 406 PMD_SECT_BUFFERABLE | \ 419 407 PMD_SECT_CACHEABLE | \ 408 + PMD_BIT4 | \ 409 + PMD_SECT_AP_WRITE | \ 410 + PMD_SECT_AP_READ 411 + .long PMD_TYPE_SECT | \ 420 412 PMD_BIT4 | \ 421 413 PMD_SECT_AP_WRITE | \ 422 414 PMD_SECT_AP_READ
+14 -9
arch/arm/mm/proc-arm720.S
··· 169 169 #ifdef CONFIG_MMU 170 170 mcr p15, 0, r0, c8, c7, 0 @ flush TLB (v4) 171 171 #endif 172 + adr r5, arm720_crval 173 + ldmia r5, {r5, r6} 172 174 mrc p15, 0, r0, c1, c0 @ get control register 173 - ldr r5, arm720_cr1_clear 174 175 bic r0, r0, r5 175 - ldr r5, arm720_cr1_set 176 - orr r0, r0, r5 176 + orr r0, r0, r6 177 177 mov pc, lr @ __ret (head.S) 178 178 .size __arm720_setup, . - __arm720_setup 179 179 ··· 183 183 * ..1. 1001 ..11 1101 184 184 * 185 185 */ 186 - .type arm720_cr1_clear, #object 187 - .type arm720_cr1_set, #object 188 - arm720_cr1_clear: 189 - .word 0x2f3f 190 - arm720_cr1_set: 191 - .word 0x213d 186 + .type arm720_crval, #object 187 + arm720_crval: 188 + crval clear=0x00002f3f, mmuset=0x0000213d, ucset=0x00000130 192 189 193 190 __INITDATA 194 191 ··· 243 246 PMD_BIT4 | \ 244 247 PMD_SECT_AP_WRITE | \ 245 248 PMD_SECT_AP_READ 249 + .long PMD_TYPE_SECT | \ 250 + PMD_BIT4 | \ 251 + PMD_SECT_AP_WRITE | \ 252 + PMD_SECT_AP_READ 246 253 b __arm710_setup @ cpu_flush 247 254 .long cpu_arch_name @ arch_name 248 255 .long cpu_elf_name @ elf_name ··· 265 264 .long PMD_TYPE_SECT | \ 266 265 PMD_SECT_BUFFERABLE | \ 267 266 PMD_SECT_CACHEABLE | \ 267 + PMD_BIT4 | \ 268 + PMD_SECT_AP_WRITE | \ 269 + PMD_SECT_AP_READ 270 + .long PMD_TYPE_SECT | \ 268 271 PMD_BIT4 | \ 269 272 PMD_SECT_AP_WRITE | \ 270 273 PMD_SECT_AP_READ
+11 -22
arch/arm/mm/proc-arm920.S
··· 390 390 #ifdef CONFIG_MMU 391 391 mcr p15, 0, r0, c8, c7 @ invalidate I,D TLBs on v4 392 392 #endif 393 + adr r5, arm920_crval 394 + ldmia r5, {r5, r6} 393 395 mrc p15, 0, r0, c1, c0 @ get control register v4 394 - ldr r5, arm920_cr1_clear 395 396 bic r0, r0, r5 396 - ldr r5, arm920_cr1_set 397 - orr r0, r0, r5 397 + orr r0, r0, r6 398 398 mov pc, lr 399 399 .size __arm920_setup, . - __arm920_setup 400 400 ··· 404 404 * ..11 0001 ..11 0101 405 405 * 406 406 */ 407 - .type arm920_cr1_clear, #object 408 - .type arm920_cr1_set, #object 409 - arm920_cr1_clear: 410 - .word 0x3f3f 411 - arm920_cr1_set: 412 - .word 0x3135 407 + .type arm920_crval, #object 408 + arm920_crval: 409 + crval clear=0x00003f3f, mmuset=0x00003135, ucset=0x00001130 413 410 414 411 __INITDATA 415 412 ··· 440 443 441 444 .type cpu_arm920_name, #object 442 445 cpu_arm920_name: 443 - .ascii "ARM920T" 444 - #ifndef CONFIG_CPU_ICACHE_DISABLE 445 - .ascii "i" 446 - #endif 447 - #ifndef CONFIG_CPU_DCACHE_DISABLE 448 - .ascii "d" 449 - #ifdef CONFIG_CPU_DCACHE_WRITETHROUGH 450 - .ascii "(wt)" 451 - #else 452 - .ascii "(wb)" 453 - #endif 454 - #endif 455 - .ascii "\0" 446 + .asciz "ARM920T" 456 447 .size cpu_arm920_name, . - cpu_arm920_name 457 448 458 449 .align ··· 454 469 .long PMD_TYPE_SECT | \ 455 470 PMD_SECT_BUFFERABLE | \ 456 471 PMD_SECT_CACHEABLE | \ 472 + PMD_BIT4 | \ 473 + PMD_SECT_AP_WRITE | \ 474 + PMD_SECT_AP_READ 475 + .long PMD_TYPE_SECT | \ 457 476 PMD_BIT4 | \ 458 477 PMD_SECT_AP_WRITE | \ 459 478 PMD_SECT_AP_READ
+11 -22
arch/arm/mm/proc-arm922.S
··· 394 394 #ifdef CONFIG_MMU 395 395 mcr p15, 0, r0, c8, c7 @ invalidate I,D TLBs on v4 396 396 #endif 397 + adr r5, arm922_crval 398 + ldmia r5, {r5, r6} 397 399 mrc p15, 0, r0, c1, c0 @ get control register v4 398 - ldr r5, arm922_cr1_clear 399 400 bic r0, r0, r5 400 - ldr r5, arm922_cr1_set 401 - orr r0, r0, r5 401 + orr r0, r0, r6 402 402 mov pc, lr 403 403 .size __arm922_setup, . - __arm922_setup 404 404 ··· 408 408 * ..11 0001 ..11 0101 409 409 * 410 410 */ 411 - .type arm922_cr1_clear, #object 412 - .type arm922_cr1_set, #object 413 - arm922_cr1_clear: 414 - .word 0x3f3f 415 - arm922_cr1_set: 416 - .word 0x3135 411 + .type arm922_crval, #object 412 + arm922_crval: 413 + crval clear=0x00003f3f, mmuset=0x00003135, ucset=0x00001130 417 414 418 415 __INITDATA 419 416 ··· 444 447 445 448 .type cpu_arm922_name, #object 446 449 cpu_arm922_name: 447 - .ascii "ARM922T" 448 - #ifndef CONFIG_CPU_ICACHE_DISABLE 449 - .ascii "i" 450 - #endif 451 - #ifndef CONFIG_CPU_DCACHE_DISABLE 452 - .ascii "d" 453 - #ifdef CONFIG_CPU_DCACHE_WRITETHROUGH 454 - .ascii "(wt)" 455 - #else 456 - .ascii "(wb)" 457 - #endif 458 - #endif 459 - .ascii "\0" 450 + .asciz "ARM922T" 460 451 .size cpu_arm922_name, . - cpu_arm922_name 461 452 462 453 .align ··· 458 473 .long PMD_TYPE_SECT | \ 459 474 PMD_SECT_BUFFERABLE | \ 460 475 PMD_SECT_CACHEABLE | \ 476 + PMD_BIT4 | \ 477 + PMD_SECT_AP_WRITE | \ 478 + PMD_SECT_AP_READ 479 + .long PMD_TYPE_SECT | \ 461 480 PMD_BIT4 | \ 462 481 PMD_SECT_AP_WRITE | \ 463 482 PMD_SECT_AP_READ
+14 -25
arch/arm/mm/proc-arm925.S
··· 454 454 mcr p15, 7, r0, c15, c0, 0 455 455 #endif 456 456 457 + adr r5, {r5, r6} 457 458 mrc p15, 0, r0, c1, c0 @ get control register v4 458 - ldr r5, arm925_cr1_clear 459 459 bic r0, r0, r5 460 - ldr r5, arm925_cr1_set 461 - orr r0, r0, r5 460 + orr r0, r0, r6 462 461 #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 463 462 orr r0, r0, #0x4000 @ .1.. .... .... .... 464 463 #endif ··· 470 471 * .011 0001 ..11 1101 471 472 * 472 473 */ 473 - .type arm925_cr1_clear, #object 474 - .type arm925_cr1_set, #object 475 - arm925_cr1_clear: 476 - .word 0x7f3f 477 - arm925_cr1_set: 478 - .word 0x313d 474 + .type arm925_crval, #object 475 + arm925_crval: 476 + crval clear=0x00007f3f, mmuset=0x0000313d, ucset=0x00001130 479 477 480 478 __INITDATA 481 479 ··· 506 510 507 511 .type cpu_arm925_name, #object 508 512 cpu_arm925_name: 509 - .ascii "ARM925T" 510 - #ifndef CONFIG_CPU_ICACHE_DISABLE 511 - .ascii "i" 512 - #endif 513 - #ifndef CONFIG_CPU_DCACHE_DISABLE 514 - .ascii "d" 515 - #ifdef CONFIG_CPU_DCACHE_WRITETHROUGH 516 - .ascii "(wt)" 517 - #else 518 - .ascii "(wb)" 519 - #endif 520 - #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 521 - .ascii "RR" 522 - #endif 523 - #endif 524 - .ascii "\0" 513 + .asciz "ARM925T" 525 514 .size cpu_arm925_name, . - cpu_arm925_name 526 515 527 516 .align ··· 517 536 __arm925_proc_info: 518 537 .long 0x54029250 519 538 .long 0xfffffff0 539 + .long PMD_TYPE_SECT | \ 540 + PMD_BIT4 | \ 541 + PMD_SECT_AP_WRITE | \ 542 + PMD_SECT_AP_READ 520 543 .long PMD_TYPE_SECT | \ 521 544 PMD_BIT4 | \ 522 545 PMD_SECT_AP_WRITE | \ ··· 540 555 __arm915_proc_info: 541 556 .long 0x54029150 542 557 .long 0xfffffff0 558 + .long PMD_TYPE_SECT | \ 559 + PMD_BIT4 | \ 560 + PMD_SECT_AP_WRITE | \ 561 + PMD_SECT_AP_READ 543 562 .long PMD_TYPE_SECT | \ 544 563 PMD_BIT4 | \ 545 564 PMD_SECT_AP_WRITE | \
+11 -25
arch/arm/mm/proc-arm926.S
··· 403 403 mcr p15, 7, r0, c15, c0, 0 404 404 #endif 405 405 406 + adr r5, arm926_crval 407 + ldmia r5, {r5, r6} 406 408 mrc p15, 0, r0, c1, c0 @ get control register v4 407 - ldr r5, arm926_cr1_clear 408 409 bic r0, r0, r5 409 - ldr r5, arm926_cr1_set 410 - orr r0, r0, r5 410 + orr r0, r0, r6 411 411 #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 412 412 orr r0, r0, #0x4000 @ .1.. .... .... .... 413 413 #endif ··· 420 420 * .011 0001 ..11 0101 421 421 * 422 422 */ 423 - .type arm926_cr1_clear, #object 424 - .type arm926_cr1_set, #object 425 - arm926_cr1_clear: 426 - .word 0x7f3f 427 - arm926_cr1_set: 428 - .word 0x3135 423 + .type arm926_crval, #object 424 + arm926_crval: 425 + crval clear=0x00007f3f, mmuset=0x00003135, ucset=0x00001134 429 426 430 427 __INITDATA 431 428 ··· 456 459 457 460 .type cpu_arm926_name, #object 458 461 cpu_arm926_name: 459 - .ascii "ARM926EJ-S" 460 - #ifndef CONFIG_CPU_ICACHE_DISABLE 461 - .ascii "i" 462 - #endif 463 - #ifndef CONFIG_CPU_DCACHE_DISABLE 464 - .ascii "d" 465 - #ifdef CONFIG_CPU_DCACHE_WRITETHROUGH 466 - .ascii "(wt)" 467 - #else 468 - .ascii "(wb)" 469 - #endif 470 - #ifdef CONFIG_CPU_CACHE_ROUND_ROBIN 471 - .ascii "RR" 472 - #endif 473 - #endif 474 - .ascii "\0" 462 + .asciz "ARM926EJ-S" 475 463 .size cpu_arm926_name, . - cpu_arm926_name 476 464 477 465 .align ··· 470 488 .long PMD_TYPE_SECT | \ 471 489 PMD_SECT_BUFFERABLE | \ 472 490 PMD_SECT_CACHEABLE | \ 491 + PMD_BIT4 | \ 492 + PMD_SECT_AP_WRITE | \ 493 + PMD_SECT_AP_READ 494 + .long PMD_TYPE_SECT | \ 473 495 PMD_BIT4 | \ 474 496 PMD_SECT_AP_WRITE | \ 475 497 PMD_SECT_AP_READ
+10
arch/arm/mm/proc-macros.S
··· 49 49 .macro asid, rd, rn 50 50 and \rd, \rn, #255 51 51 .endm 52 + 53 + .macro crval, clear, mmuset, ucset 54 + #ifdef CONFIG_MMU 55 + .word \clear 56 + .word \mmuset 57 + #else 58 + .word \clear 59 + .word \ucset 60 + #endif 61 + .endm
+10 -9
arch/arm/mm/proc-sa110.S
··· 185 185 #ifdef CONFIG_MMU 186 186 mcr p15, 0, r10, c8, c7 @ invalidate I,D TLBs on v4 187 187 #endif 188 + 189 + adr r5, sa110_crval 190 + ldmia r5, {r5, r6} 188 191 mrc p15, 0, r0, c1, c0 @ get control register v4 189 - ldr r5, sa110_cr1_clear 190 192 bic r0, r0, r5 191 - ldr r5, sa110_cr1_set 192 - orr r0, r0, r5 193 + orr r0, r0, r6 193 194 mov pc, lr 194 195 .size __sa110_setup, . - __sa110_setup 195 196 ··· 200 199 * ..01 0001 ..11 1101 201 200 * 202 201 */ 203 - .type sa110_cr1_clear, #object 204 - .type sa110_cr1_set, #object 205 - sa110_cr1_clear: 206 - .word 0x3f3f 207 - sa110_cr1_set: 208 - .word 0x113d 202 + .type sa110_crval, #object 203 + sa110_crval: 204 + crval clear=0x00003f3f, mmuset=0x0000113d, ucset=0x00001130 209 205 210 206 __INITDATA 211 207 ··· 251 253 .long PMD_TYPE_SECT | \ 252 254 PMD_SECT_BUFFERABLE | \ 253 255 PMD_SECT_CACHEABLE | \ 256 + PMD_SECT_AP_WRITE | \ 257 + PMD_SECT_AP_READ 258 + .long PMD_TYPE_SECT | \ 254 259 PMD_SECT_AP_WRITE | \ 255 260 PMD_SECT_AP_READ 256 261 b __sa110_setup
+12 -9
arch/arm/mm/proc-sa1100.S
··· 198 198 #ifdef CONFIG_MMU 199 199 mcr p15, 0, r0, c8, c7 @ invalidate I,D TLBs on v4 200 200 #endif 201 + adr r5, sa1100_crval 202 + ldmia r5, {r5, r6} 201 203 mrc p15, 0, r0, c1, c0 @ get control register v4 202 - ldr r5, sa1100_cr1_clear 203 204 bic r0, r0, r5 204 - ldr r5, sa1100_cr1_set 205 - orr r0, r0, r5 205 + orr r0, r0, r6 206 206 mov pc, lr 207 207 .size __sa1100_setup, . - __sa1100_setup 208 208 ··· 212 212 * ..11 0001 ..11 1101 213 213 * 214 214 */ 215 - .type sa1100_cr1_clear, #object 216 - .type sa1100_cr1_set, #object 217 - sa1100_cr1_clear: 218 - .word 0x3f3f 219 - sa1100_cr1_set: 220 - .word 0x313d 215 + .type sa1100_crval, #object 216 + sa1100_crval: 217 + crval clear=0x00003f3f, mmuset=0x0000313d, ucset=0x00001130 221 218 222 219 __INITDATA 223 220 ··· 273 276 PMD_SECT_CACHEABLE | \ 274 277 PMD_SECT_AP_WRITE | \ 275 278 PMD_SECT_AP_READ 279 + .long PMD_TYPE_SECT | \ 280 + PMD_SECT_AP_WRITE | \ 281 + PMD_SECT_AP_READ 276 282 b __sa1100_setup 277 283 .long cpu_arch_name 278 284 .long cpu_elf_name ··· 294 294 .long PMD_TYPE_SECT | \ 295 295 PMD_SECT_BUFFERABLE | \ 296 296 PMD_SECT_CACHEABLE | \ 297 + PMD_SECT_AP_WRITE | \ 298 + PMD_SECT_AP_READ 299 + .long PMD_TYPE_SECT | \ 297 300 PMD_SECT_AP_WRITE | \ 298 301 PMD_SECT_AP_READ 299 302 b __sa1100_setup
+10 -9
arch/arm/mm/proc-v6.S
··· 212 212 orr r0, r0, #(0xf << 20) 213 213 mcr p15, 0, r0, c1, c0, 2 @ Enable full access to VFP 214 214 #endif 215 + adr r5, v6_crval 216 + ldmia r5, {r5, r6} 215 217 mrc p15, 0, r0, c1, c0, 0 @ read control register 216 - ldr r5, v6_cr1_clear @ get mask for bits to clear 217 218 bic r0, r0, r5 @ clear bits them 218 - ldr r5, v6_cr1_set @ get mask for bits to set 219 - orr r0, r0, r5 @ set them 219 + orr r0, r0, r6 @ set them 220 220 mov pc, lr @ return to head.S:__ret 221 221 222 222 /* ··· 225 225 * rrrr rrrx xxx0 0101 xxxx xxxx x111 xxxx < forced 226 226 * 0 110 0011 1.00 .111 1101 < we want 227 227 */ 228 - .type v6_cr1_clear, #object 229 - .type v6_cr1_set, #object 230 - v6_cr1_clear: 231 - .word 0x01e0fb7f 232 - v6_cr1_set: 233 - .word 0x00c0387d 228 + .type v6_crval, #object 229 + v6_crval: 230 + crval clear=0x01e0fb7f, mmuset=0x00c0387d, ucset=0x00c0187c 234 231 235 232 .type v6_processor_functions, #object 236 233 ENTRY(v6_processor_functions) ··· 264 267 .long PMD_TYPE_SECT | \ 265 268 PMD_SECT_BUFFERABLE | \ 266 269 PMD_SECT_CACHEABLE | \ 270 + PMD_SECT_AP_WRITE | \ 271 + PMD_SECT_AP_READ 272 + .long PMD_TYPE_SECT | \ 273 + PMD_SECT_XN | \ 267 274 PMD_SECT_AP_WRITE | \ 268 275 PMD_SECT_AP_READ 269 276 b __v6_setup
+19 -9
arch/arm/mm/proc-xsc3.S
··· 426 426 orr r0, r0, #(1 << 10) @ enable L2 for LLR cache 427 427 #endif 428 428 mcr p15, 0, r0, c1, c0, 1 @ set auxiliary control reg 429 + 430 + adr r5, xsc3_crval 431 + ldmia r5, {r5, r6} 429 432 mrc p15, 0, r0, c1, c0, 0 @ get control register 430 - bic r0, r0, #0x0002 @ .... .... .... ..A. 431 - orr r0, r0, #0x0005 @ .... .... .... .C.M 433 + bic r0, r0, r5 @ .... .... .... ..A. 434 + orr r0, r0, r6 @ .... .... .... .C.M 432 435 #if BTB_ENABLE 433 - bic r0, r0, #0x0200 @ .... ..R. .... .... 434 - orr r0, r0, #0x3900 @ ..VI Z..S .... .... 435 - #else 436 - bic r0, r0, #0x0a00 @ .... Z.R. .... .... 437 - orr r0, r0, #0x3100 @ ..VI ...S .... .... 436 + orr r0, r0, #0x00000800 @ ..VI Z..S .... .... 438 437 #endif 439 438 #if L2_CACHE_ENABLE 440 - orr r0, r0, #0x4000000 @ L2 enable 439 + orr r0, r0, #0x04000000 @ L2 enable 441 440 #endif 442 441 mov pc, lr 443 442 444 443 .size __xsc3_setup, . - __xsc3_setup 444 + 445 + .type xsc3_crval, #object 446 + xsc3_crval: 447 + crval clear=0x04003b02, mmuset=0x00003105, ucset=0x00001100 445 448 446 449 __INITDATA 447 450 ··· 490 487 __xsc3_proc_info: 491 488 .long 0x69056000 492 489 .long 0xffffe000 493 - .long 0x00000c0e 490 + .long PMD_TYPE_SECT | \ 491 + PMD_SECT_BUFFERABLE | \ 492 + PMD_SECT_CACHEABLE | \ 493 + PMD_SECT_AP_WRITE | \ 494 + PMD_SECT_AP_READ 495 + .long PMD_TYPE_SECT | \ 496 + PMD_SECT_AP_WRITE | \ 497 + PMD_SECT_AP_READ 494 498 b __xsc3_setup 495 499 .long cpu_arch_name 496 500 .long cpu_elf_name
+52 -11
arch/arm/mm/proc-xscale.S
··· 138 138 * to what would be the reset vector. 139 139 * 140 140 * loc: location to jump to for soft reset 141 + * 142 + * Beware PXA270 erratum E7. 141 143 */ 142 144 .align 5 143 145 ENTRY(cpu_xscale_reset) 144 146 mov r1, #PSR_F_BIT|PSR_I_BIT|SVC_MODE 145 147 msr cpsr_c, r1 @ reset CPSR 148 + mcr p15, 0, r1, c10, c4, 1 @ unlock I-TLB 149 + mcr p15, 0, r1, c8, c5, 0 @ invalidate I-TLB 146 150 mrc p15, 0, r1, c1, c0, 0 @ ctrl register 147 151 bic r1, r1, #0x0086 @ ........B....CA. 148 152 bic r1, r1, #0x3900 @ ..VIZ..S........ 153 + sub pc, pc, #4 @ flush pipeline 154 + @ *** cache line aligned *** 149 155 mcr p15, 0, r1, c1, c0, 0 @ ctrl register 150 - mcr p15, 0, ip, c7, c7, 0 @ invalidate I,D caches & BTB 151 156 bic r1, r1, #0x0001 @ ...............M 157 + mcr p15, 0, ip, c7, c7, 0 @ invalidate I,D caches & BTB 152 158 mcr p15, 0, r1, c1, c0, 0 @ ctrl register 153 159 @ CAUTION: MMU turned off from this point. We count on the pipeline 154 160 @ already containing those two last instructions to survive. ··· 481 475 orr r0, r0, #1 << 6 @ cp6 for IOP3xx and Bulverde 482 476 orr r0, r0, #1 << 13 @ Its undefined whether this 483 477 mcr p15, 0, r0, c15, c1, 0 @ affects USR or SVC modes 478 + 479 + adr r5, xscale_crval 480 + ldmia r5, {r5, r6} 484 481 mrc p15, 0, r0, c1, c0, 0 @ get control register 485 - ldr r5, xscale_cr1_clear 486 482 bic r0, r0, r5 487 - ldr r5, xscale_cr1_set 488 - orr r0, r0, r5 483 + orr r0, r0, r6 489 484 mov pc, lr 490 485 .size __xscale_setup, . - __xscale_setup 491 486 ··· 496 489 * ..11 1.01 .... .101 497 490 * 498 491 */ 499 - .type xscale_cr1_clear, #object 500 - .type xscale_cr1_set, #object 501 - xscale_cr1_clear: 502 - .word 0x3b07 503 - xscale_cr1_set: 504 - .word 0x3905 492 + .type xscale_crval, #object 493 + xscale_crval: 494 + crval clear=0x00003b07, mmuset=0x00003905, ucset=0x00001900 505 495 506 496 __INITDATA 507 497 ··· 599 595 PMD_SECT_CACHEABLE | \ 600 596 PMD_SECT_AP_WRITE | \ 601 597 PMD_SECT_AP_READ 598 + .long PMD_TYPE_SECT | \ 599 + PMD_SECT_AP_WRITE | \ 600 + PMD_SECT_AP_READ 602 601 b __xscale_setup 603 602 .long cpu_arch_name 604 603 .long cpu_elf_name ··· 620 613 .long PMD_TYPE_SECT | \ 621 614 PMD_SECT_BUFFERABLE | \ 622 615 PMD_SECT_CACHEABLE | \ 616 + PMD_SECT_AP_WRITE | \ 617 + PMD_SECT_AP_READ 618 + .long PMD_TYPE_SECT | \ 623 619 PMD_SECT_AP_WRITE | \ 624 620 PMD_SECT_AP_READ 625 621 b __xscale_setup ··· 645 635 PMD_SECT_CACHEABLE | \ 646 636 PMD_SECT_AP_WRITE | \ 647 637 PMD_SECT_AP_READ 638 + .long PMD_TYPE_SECT | \ 639 + PMD_SECT_AP_WRITE | \ 640 + PMD_SECT_AP_READ 648 641 b __xscale_setup 649 642 .long cpu_arch_name 650 643 .long cpu_elf_name ··· 666 653 .long PMD_TYPE_SECT | \ 667 654 PMD_SECT_BUFFERABLE | \ 668 655 PMD_SECT_CACHEABLE | \ 656 + PMD_SECT_AP_WRITE | \ 657 + PMD_SECT_AP_READ 658 + .long PMD_TYPE_SECT | \ 669 659 PMD_SECT_AP_WRITE | \ 670 660 PMD_SECT_AP_READ 671 661 b __xscale_setup ··· 691 675 PMD_SECT_CACHEABLE | \ 692 676 PMD_SECT_AP_WRITE | \ 693 677 PMD_SECT_AP_READ 678 + .long PMD_TYPE_SECT | \ 679 + PMD_SECT_AP_WRITE | \ 680 + PMD_SECT_AP_READ 694 681 b __xscale_setup 695 682 .long cpu_arch_name 696 683 .long cpu_elf_name ··· 712 693 .long PMD_TYPE_SECT | \ 713 694 PMD_SECT_BUFFERABLE | \ 714 695 PMD_SECT_CACHEABLE | \ 696 + PMD_SECT_AP_WRITE | \ 697 + PMD_SECT_AP_READ 698 + .long PMD_TYPE_SECT | \ 715 699 PMD_SECT_AP_WRITE | \ 716 700 PMD_SECT_AP_READ 717 701 b __xscale_setup ··· 737 715 PMD_SECT_CACHEABLE | \ 738 716 PMD_SECT_AP_WRITE | \ 739 717 PMD_SECT_AP_READ 718 + .long PMD_TYPE_SECT | \ 719 + PMD_SECT_AP_WRITE | \ 720 + PMD_SECT_AP_READ 740 721 b __xscale_setup 741 722 .long cpu_arch_name 742 723 .long cpu_elf_name ··· 760 735 PMD_SECT_CACHEABLE | \ 761 736 PMD_SECT_AP_WRITE | \ 762 737 PMD_SECT_AP_READ 738 + .long PMD_TYPE_SECT | \ 739 + PMD_SECT_AP_WRITE | \ 740 + PMD_SECT_AP_READ 763 741 b __xscale_setup 764 742 .long cpu_arch_name 765 743 .long cpu_elf_name ··· 778 750 __ixp46x_proc_info: 779 751 .long 0x69054200 780 752 .long 0xffffff00 781 - .long 0x00000c0e 753 + .long PMD_TYPE_SECT | \ 754 + PMD_SECT_BUFFERABLE | \ 755 + PMD_SECT_CACHEABLE | \ 756 + PMD_SECT_AP_WRITE | \ 757 + PMD_SECT_AP_READ 758 + .long PMD_TYPE_SECT | \ 759 + PMD_SECT_AP_WRITE | \ 760 + PMD_SECT_AP_READ 782 761 b __xscale_setup 783 762 .long cpu_arch_name 784 763 .long cpu_elf_name ··· 806 771 PMD_SECT_CACHEABLE | \ 807 772 PMD_SECT_AP_WRITE | \ 808 773 PMD_SECT_AP_READ 774 + .long PMD_TYPE_SECT | \ 775 + PMD_SECT_AP_WRITE | \ 776 + PMD_SECT_AP_READ 809 777 b __xscale_setup 810 778 .long cpu_arch_name 811 779 .long cpu_elf_name ··· 827 789 .long PMD_TYPE_SECT | \ 828 790 PMD_SECT_BUFFERABLE | \ 829 791 PMD_SECT_CACHEABLE | \ 792 + PMD_SECT_AP_WRITE | \ 793 + PMD_SECT_AP_READ 794 + .long PMD_TYPE_SECT | \ 830 795 PMD_SECT_AP_WRITE | \ 831 796 PMD_SECT_AP_READ 832 797 b __xscale_setup
+1 -1
arch/arm/plat-omap/Kconfig
··· 91 91 92 92 config OMAP_DM_TIMER 93 93 bool "Use dual-mode timer" 94 - depends on ARCH_OMAP16XX 94 + depends on ARCH_OMAP16XX || ARCH_OMAP24XX 95 95 help 96 96 Select this option if you want to use OMAP Dual-Mode timers. 97 97
+2 -2
arch/arm/plat-omap/clock.c
··· 27 27 28 28 #include <asm/arch/clock.h> 29 29 30 - LIST_HEAD(clocks); 30 + static LIST_HEAD(clocks); 31 31 static DEFINE_MUTEX(clocks_mutex); 32 - DEFINE_SPINLOCK(clockfw_lock); 32 + static DEFINE_SPINLOCK(clockfw_lock); 33 33 34 34 static struct clk_functions *arch_clock; 35 35
+13 -5
arch/arm/plat-omap/cpu-omap.c
··· 25 25 #include <asm/io.h> 26 26 #include <asm/system.h> 27 27 28 + #define VERY_HI_RATE 900000000 29 + 30 + #ifdef CONFIG_ARCH_OMAP1 31 + #define MPU_CLK "mpu" 32 + #else 33 + #define MPU_CLK "virt_prcm_set" 34 + #endif 35 + 28 36 /* TODO: Add support for SDRAM timing changes */ 29 37 30 38 int omap_verify_speed(struct cpufreq_policy *policy) ··· 44 36 45 37 cpufreq_verify_within_limits(policy, policy->cpuinfo.min_freq, 46 38 policy->cpuinfo.max_freq); 47 - mpu_clk = clk_get(NULL, "mpu"); 39 + mpu_clk = clk_get(NULL, MPU_CLK); 48 40 if (IS_ERR(mpu_clk)) 49 41 return PTR_ERR(mpu_clk); 50 42 policy->min = clk_round_rate(mpu_clk, policy->min * 1000) / 1000; ··· 64 56 if (cpu) 65 57 return 0; 66 58 67 - mpu_clk = clk_get(NULL, "mpu"); 59 + mpu_clk = clk_get(NULL, MPU_CLK); 68 60 if (IS_ERR(mpu_clk)) 69 61 return 0; 70 62 rate = clk_get_rate(mpu_clk) / 1000; ··· 81 73 struct cpufreq_freqs freqs; 82 74 int ret = 0; 83 75 84 - mpu_clk = clk_get(NULL, "mpu"); 76 + mpu_clk = clk_get(NULL, MPU_CLK); 85 77 if (IS_ERR(mpu_clk)) 86 78 return PTR_ERR(mpu_clk); 87 79 ··· 101 93 { 102 94 struct clk * mpu_clk; 103 95 104 - mpu_clk = clk_get(NULL, "mpu"); 96 + mpu_clk = clk_get(NULL, MPU_CLK); 105 97 if (IS_ERR(mpu_clk)) 106 98 return PTR_ERR(mpu_clk); 107 99 ··· 110 102 policy->cur = policy->min = policy->max = omap_getspeed(0); 111 103 policy->governor = CPUFREQ_DEFAULT_GOVERNOR; 112 104 policy->cpuinfo.min_freq = clk_round_rate(mpu_clk, 0) / 1000; 113 - policy->cpuinfo.max_freq = clk_round_rate(mpu_clk, 216000000) / 1000; 105 + policy->cpuinfo.max_freq = clk_round_rate(mpu_clk, VERY_HI_RATE) / 1000; 114 106 policy->cpuinfo.transition_latency = CPUFREQ_ETERNAL; 115 107 clk_put(mpu_clk); 116 108
+5 -5
arch/arm/plat-omap/devices.c
··· 104 104 omap_cfg_reg(E20_1610_KBR3); 105 105 omap_cfg_reg(E19_1610_KBR4); 106 106 omap_cfg_reg(N19_1610_KBR5); 107 - } else if (machine_is_omap_perseus2()) { 107 + } else if (machine_is_omap_perseus2() || machine_is_omap_fsample()) { 108 108 omap_cfg_reg(E2_730_KBR0); 109 109 omap_cfg_reg(J7_730_KBR1); 110 110 omap_cfg_reg(E1_730_KBR2); ··· 161 161 162 162 static struct resource mmc1_resources[] = { 163 163 { 164 - .start = IO_ADDRESS(OMAP_MMC1_BASE), 165 - .end = IO_ADDRESS(OMAP_MMC1_BASE) + 0x7f, 164 + .start = OMAP_MMC1_BASE, 165 + .end = OMAP_MMC1_BASE + 0x7f, 166 166 .flags = IORESOURCE_MEM, 167 167 }, 168 168 { ··· 190 190 191 191 static struct resource mmc2_resources[] = { 192 192 { 193 - .start = IO_ADDRESS(OMAP_MMC2_BASE), 194 - .end = IO_ADDRESS(OMAP_MMC2_BASE) + 0x7f, 193 + .start = OMAP_MMC2_BASE, 194 + .end = OMAP_MMC2_BASE + 0x7f, 195 195 .flags = IORESOURCE_MEM, 196 196 }, 197 197 {
+65 -19
arch/arm/plat-omap/dma.c
··· 43 43 44 44 #define OMAP_DMA_ACTIVE 0x01 45 45 #define OMAP_DMA_CCR_EN (1 << 7) 46 + #define OMAP2_DMA_CSR_CLEAR_MASK 0xffe 46 47 47 48 #define OMAP_FUNC_MUX_ARM_BASE (0xfffe1000 + 0xec) 48 49 ··· 167 166 if (cpu_is_omap24xx() && dma_trigger) { 168 167 u32 val = OMAP_DMA_CCR_REG(lch); 169 168 169 + val &= ~(3 << 19); 170 170 if (dma_trigger > 63) 171 171 val |= 1 << 20; 172 172 if (dma_trigger > 31) 173 173 val |= 1 << 19; 174 174 175 + val &= ~(0x1f); 175 176 val |= (dma_trigger & 0x1f); 176 177 177 178 if (sync_mode & OMAP_DMA_SYNC_FRAME) 178 179 val |= 1 << 5; 180 + else 181 + val &= ~(1 << 5); 179 182 180 183 if (sync_mode & OMAP_DMA_SYNC_BLOCK) 181 184 val |= 1 << 18; 185 + else 186 + val &= ~(1 << 18); 182 187 183 188 if (src_or_dst_synch) 184 189 val |= 1 << 24; /* source synch */ ··· 293 286 294 287 void omap_set_dma_src_burst_mode(int lch, enum omap_dma_burst_mode burst_mode) 295 288 { 289 + unsigned int burst = 0; 296 290 OMAP_DMA_CSDP_REG(lch) &= ~(0x03 << 7); 297 291 298 292 switch (burst_mode) { 299 293 case OMAP_DMA_DATA_BURST_DIS: 300 294 break; 301 295 case OMAP_DMA_DATA_BURST_4: 302 - OMAP_DMA_CSDP_REG(lch) |= (0x02 << 7); 296 + if (cpu_is_omap24xx()) 297 + burst = 0x1; 298 + else 299 + burst = 0x2; 303 300 break; 304 301 case OMAP_DMA_DATA_BURST_8: 305 - /* not supported by current hardware 302 + if (cpu_is_omap24xx()) { 303 + burst = 0x2; 304 + break; 305 + } 306 + /* not supported by current hardware on OMAP1 306 307 * w |= (0x03 << 7); 308 + * fall through 309 + */ 310 + case OMAP_DMA_DATA_BURST_16: 311 + if (cpu_is_omap24xx()) { 312 + burst = 0x3; 313 + break; 314 + } 315 + /* OMAP1 don't support burst 16 307 316 * fall through 308 317 */ 309 318 default: 310 319 BUG(); 311 320 } 321 + OMAP_DMA_CSDP_REG(lch) |= (burst << 7); 312 322 } 313 323 314 324 /* Note that dest_port is only for OMAP1 */ ··· 372 348 373 349 void omap_set_dma_dest_burst_mode(int lch, enum omap_dma_burst_mode burst_mode) 374 350 { 351 + unsigned int burst = 0; 375 352 OMAP_DMA_CSDP_REG(lch) &= ~(0x03 << 14); 376 353 377 354 switch (burst_mode) { 378 355 case OMAP_DMA_DATA_BURST_DIS: 379 356 break; 380 357 case OMAP_DMA_DATA_BURST_4: 381 - OMAP_DMA_CSDP_REG(lch) |= (0x02 << 14); 358 + if (cpu_is_omap24xx()) 359 + burst = 0x1; 360 + else 361 + burst = 0x2; 382 362 break; 383 363 case OMAP_DMA_DATA_BURST_8: 384 - OMAP_DMA_CSDP_REG(lch) |= (0x03 << 14); 364 + if (cpu_is_omap24xx()) 365 + burst = 0x2; 366 + else 367 + burst = 0x3; 385 368 break; 369 + case OMAP_DMA_DATA_BURST_16: 370 + if (cpu_is_omap24xx()) { 371 + burst = 0x3; 372 + break; 373 + } 374 + /* OMAP1 don't support burst 16 375 + * fall through 376 + */ 386 377 default: 387 378 printk(KERN_ERR "Invalid DMA burst mode\n"); 388 379 BUG(); 389 380 return; 390 381 } 382 + OMAP_DMA_CSDP_REG(lch) |= (burst << 14); 391 383 } 392 384 393 385 static inline void omap_enable_channel_irq(int lch) 394 386 { 395 387 u32 status; 396 388 397 - /* Read CSR to make sure it's cleared. */ 398 - status = OMAP_DMA_CSR_REG(lch); 389 + /* Clear CSR */ 390 + if (cpu_class_is_omap1()) 391 + status = OMAP_DMA_CSR_REG(lch); 392 + else if (cpu_is_omap24xx()) 393 + OMAP_DMA_CSR_REG(lch) = OMAP2_DMA_CSR_CLEAR_MASK; 399 394 400 395 /* Enable some nice interrupts. */ 401 396 OMAP_DMA_CICR_REG(lch) = dma_chan[lch].enabled_irqs; ··· 513 470 chan->dev_name = dev_name; 514 471 chan->callback = callback; 515 472 chan->data = data; 516 - chan->enabled_irqs = OMAP_DMA_TOUT_IRQ | OMAP_DMA_DROP_IRQ | 517 - OMAP_DMA_BLOCK_IRQ; 473 + chan->enabled_irqs = OMAP_DMA_DROP_IRQ | OMAP_DMA_BLOCK_IRQ; 518 474 519 - if (cpu_is_omap24xx()) 520 - chan->enabled_irqs |= OMAP2_DMA_TRANS_ERR_IRQ; 475 + if (cpu_class_is_omap1()) 476 + chan->enabled_irqs |= OMAP1_DMA_TOUT_IRQ; 477 + else if (cpu_is_omap24xx()) 478 + chan->enabled_irqs |= OMAP2_DMA_MISALIGNED_ERR_IRQ | 479 + OMAP2_DMA_TRANS_ERR_IRQ; 521 480 522 481 if (cpu_is_omap16xx()) { 523 482 /* If the sync device is set, configure it dynamically. */ ··· 539 494 540 495 omap_enable_channel_irq(free_ch); 541 496 /* Clear the CSR register and IRQ status register */ 542 - OMAP_DMA_CSR_REG(free_ch) = 0x0; 497 + OMAP_DMA_CSR_REG(free_ch) = OMAP2_DMA_CSR_CLEAR_MASK; 543 498 omap_writel(~0x0, OMAP_DMA4_IRQSTATUS_L0); 544 499 } 545 500 ··· 579 534 omap_writel(val, OMAP_DMA4_IRQENABLE_L0); 580 535 581 536 /* Clear the CSR register and IRQ status register */ 582 - OMAP_DMA_CSR_REG(lch) = 0x0; 537 + OMAP_DMA_CSR_REG(lch) = OMAP2_DMA_CSR_CLEAR_MASK; 583 538 584 539 val = omap_readl(OMAP_DMA4_IRQSTATUS_L0); 585 540 val |= 1 << lch; ··· 843 798 "%d (CSR %04x)\n", ch, csr); 844 799 return 0; 845 800 } 846 - if (unlikely(csr & OMAP_DMA_TOUT_IRQ)) 801 + if (unlikely(csr & OMAP1_DMA_TOUT_IRQ)) 847 802 printk(KERN_WARNING "DMA timeout with device %d\n", 848 803 dma_chan[ch].dev_id); 849 804 if (unlikely(csr & OMAP_DMA_DROP_IRQ)) ··· 891 846 return 0; 892 847 if (unlikely(dma_chan[ch].dev_id == -1)) 893 848 return 0; 894 - /* REVISIT: According to 24xx TRM, there's no TOUT_IE */ 895 - if (unlikely(status & OMAP_DMA_TOUT_IRQ)) 896 - printk(KERN_INFO "DMA timeout with device %d\n", 897 - dma_chan[ch].dev_id); 898 849 if (unlikely(status & OMAP_DMA_DROP_IRQ)) 899 850 printk(KERN_INFO 900 851 "DMA synchronization event drop occurred with device " 901 852 "%d\n", dma_chan[ch].dev_id); 902 - 903 853 if (unlikely(status & OMAP2_DMA_TRANS_ERR_IRQ)) 904 854 printk(KERN_INFO "DMA transaction error with device %d\n", 905 855 dma_chan[ch].dev_id); 856 + if (unlikely(status & OMAP2_DMA_SECURE_ERR_IRQ)) 857 + printk(KERN_INFO "DMA secure error with device %d\n", 858 + dma_chan[ch].dev_id); 859 + if (unlikely(status & OMAP2_DMA_MISALIGNED_ERR_IRQ)) 860 + printk(KERN_INFO "DMA misaligned error with device %d\n", 861 + dma_chan[ch].dev_id); 906 862 907 - OMAP_DMA_CSR_REG(ch) = 0x20; 863 + OMAP_DMA_CSR_REG(ch) = OMAP2_DMA_CSR_CLEAR_MASK; 908 864 909 865 val = omap_readl(OMAP_DMA4_IRQSTATUS_L0); 910 866 /* ch in this function is from 0-31 while in register it is 1-32 */
+338 -146
arch/arm/plat-omap/dmtimer.c
··· 4 4 * OMAP Dual-Mode Timers 5 5 * 6 6 * Copyright (C) 2005 Nokia Corporation 7 - * Author: Lauri Leukkunen <lauri.leukkunen@nokia.com> 7 + * OMAP2 support by Juha Yrjola 8 + * API improvements and OMAP2 clock framework support by Timo Teras 8 9 * 9 10 * This program is free software; you can redistribute it and/or modify it 10 11 * under the terms of the GNU General Public License as published by the ··· 27 26 */ 28 27 29 28 #include <linux/init.h> 29 + #include <linux/spinlock.h> 30 + #include <linux/errno.h> 31 + #include <linux/list.h> 32 + #include <linux/clk.h> 33 + #include <linux/delay.h> 30 34 #include <asm/hardware.h> 31 35 #include <asm/arch/dmtimer.h> 32 36 #include <asm/io.h> 33 37 #include <asm/arch/irqs.h> 34 - #include <linux/spinlock.h> 35 - #include <linux/list.h> 36 38 37 - #define OMAP_TIMER_COUNT 8 38 - 39 + /* register offsets */ 39 40 #define OMAP_TIMER_ID_REG 0x00 40 41 #define OMAP_TIMER_OCP_CFG_REG 0x10 41 42 #define OMAP_TIMER_SYS_STAT_REG 0x14 ··· 53 50 #define OMAP_TIMER_CAPTURE_REG 0x3c 54 51 #define OMAP_TIMER_IF_CTRL_REG 0x40 55 52 53 + /* timer control reg bits */ 54 + #define OMAP_TIMER_CTRL_GPOCFG (1 << 14) 55 + #define OMAP_TIMER_CTRL_CAPTMODE (1 << 13) 56 + #define OMAP_TIMER_CTRL_PT (1 << 12) 57 + #define OMAP_TIMER_CTRL_TCM_LOWTOHIGH (0x1 << 8) 58 + #define OMAP_TIMER_CTRL_TCM_HIGHTOLOW (0x2 << 8) 59 + #define OMAP_TIMER_CTRL_TCM_BOTHEDGES (0x3 << 8) 60 + #define OMAP_TIMER_CTRL_SCPWM (1 << 7) 61 + #define OMAP_TIMER_CTRL_CE (1 << 6) /* compare enable */ 62 + #define OMAP_TIMER_CTRL_PRE (1 << 5) /* prescaler enable */ 63 + #define OMAP_TIMER_CTRL_PTV_SHIFT 2 /* how much to shift the prescaler value */ 64 + #define OMAP_TIMER_CTRL_AR (1 << 1) /* auto-reload enable */ 65 + #define OMAP_TIMER_CTRL_ST (1 << 0) /* start timer */ 56 66 57 - static struct dmtimer_info_struct { 58 - struct list_head unused_timers; 59 - struct list_head reserved_timers; 60 - } dm_timer_info; 61 - 62 - static struct omap_dm_timer dm_timers[] = { 63 - { .base=0xfffb1400, .irq=INT_1610_GPTIMER1 }, 64 - { .base=0xfffb1c00, .irq=INT_1610_GPTIMER2 }, 65 - { .base=0xfffb2400, .irq=INT_1610_GPTIMER3 }, 66 - { .base=0xfffb2c00, .irq=INT_1610_GPTIMER4 }, 67 - { .base=0xfffb3400, .irq=INT_1610_GPTIMER5 }, 68 - { .base=0xfffb3c00, .irq=INT_1610_GPTIMER6 }, 69 - { .base=0xfffb4400, .irq=INT_1610_GPTIMER7 }, 70 - { .base=0xfffb4c00, .irq=INT_1610_GPTIMER8 }, 71 - { .base=0x0 }, 67 + struct omap_dm_timer { 68 + unsigned long phys_base; 69 + int irq; 70 + #ifdef CONFIG_ARCH_OMAP2 71 + struct clk *iclk, *fclk; 72 + #endif 73 + void __iomem *io_base; 74 + unsigned reserved:1; 72 75 }; 73 76 77 + #ifdef CONFIG_ARCH_OMAP1 74 78 79 + static struct omap_dm_timer dm_timers[] = { 80 + { .phys_base = 0xfffb1400, .irq = INT_1610_GPTIMER1 }, 81 + { .phys_base = 0xfffb1c00, .irq = INT_1610_GPTIMER2 }, 82 + { .phys_base = 0xfffb2400, .irq = INT_1610_GPTIMER3 }, 83 + { .phys_base = 0xfffb2c00, .irq = INT_1610_GPTIMER4 }, 84 + { .phys_base = 0xfffb3400, .irq = INT_1610_GPTIMER5 }, 85 + { .phys_base = 0xfffb3c00, .irq = INT_1610_GPTIMER6 }, 86 + { .phys_base = 0xfffb4400, .irq = INT_1610_GPTIMER7 }, 87 + { .phys_base = 0xfffb4c00, .irq = INT_1610_GPTIMER8 }, 88 + }; 89 + 90 + #elif defined(CONFIG_ARCH_OMAP2) 91 + 92 + static struct omap_dm_timer dm_timers[] = { 93 + { .phys_base = 0x48028000, .irq = INT_24XX_GPTIMER1 }, 94 + { .phys_base = 0x4802a000, .irq = INT_24XX_GPTIMER2 }, 95 + { .phys_base = 0x48078000, .irq = INT_24XX_GPTIMER3 }, 96 + { .phys_base = 0x4807a000, .irq = INT_24XX_GPTIMER4 }, 97 + { .phys_base = 0x4807c000, .irq = INT_24XX_GPTIMER5 }, 98 + { .phys_base = 0x4807e000, .irq = INT_24XX_GPTIMER6 }, 99 + { .phys_base = 0x48080000, .irq = INT_24XX_GPTIMER7 }, 100 + { .phys_base = 0x48082000, .irq = INT_24XX_GPTIMER8 }, 101 + { .phys_base = 0x48084000, .irq = INT_24XX_GPTIMER9 }, 102 + { .phys_base = 0x48086000, .irq = INT_24XX_GPTIMER10 }, 103 + { .phys_base = 0x48088000, .irq = INT_24XX_GPTIMER11 }, 104 + { .phys_base = 0x4808a000, .irq = INT_24XX_GPTIMER12 }, 105 + }; 106 + 107 + static const char *dm_source_names[] = { 108 + "sys_ck", 109 + "func_32k_ck", 110 + "alt_ck" 111 + }; 112 + 113 + static struct clk *dm_source_clocks[3]; 114 + 115 + #else 116 + 117 + #error OMAP architecture not supported! 118 + 119 + #endif 120 + 121 + static const int dm_timer_count = ARRAY_SIZE(dm_timers); 75 122 static spinlock_t dm_timer_lock; 76 123 77 - 78 - inline void omap_dm_timer_write_reg(struct omap_dm_timer *timer, int reg, u32 value) 124 + static inline u32 omap_dm_timer_read_reg(struct omap_dm_timer *timer, int reg) 79 125 { 80 - omap_writel(value, timer->base + reg); 126 + return readl(timer->io_base + reg); 127 + } 128 + 129 + static void omap_dm_timer_write_reg(struct omap_dm_timer *timer, int reg, u32 value) 130 + { 131 + writel(value, timer->io_base + reg); 81 132 while (omap_dm_timer_read_reg(timer, OMAP_TIMER_WRITE_PEND_REG)) 82 133 ; 83 134 } 84 135 85 - u32 omap_dm_timer_read_reg(struct omap_dm_timer *timer, int reg) 136 + static void omap_dm_timer_wait_for_reset(struct omap_dm_timer *timer) 86 137 { 87 - return omap_readl(timer->base + reg); 138 + int c; 139 + 140 + c = 0; 141 + while (!(omap_dm_timer_read_reg(timer, OMAP_TIMER_SYS_STAT_REG) & 1)) { 142 + c++; 143 + if (c > 100000) { 144 + printk(KERN_ERR "Timer failed to reset\n"); 145 + return; 146 + } 147 + } 88 148 } 89 149 90 - int omap_dm_timers_active(void) 150 + static void omap_dm_timer_reset(struct omap_dm_timer *timer) 151 + { 152 + u32 l; 153 + 154 + if (timer != &dm_timers[0]) { 155 + omap_dm_timer_write_reg(timer, OMAP_TIMER_IF_CTRL_REG, 0x06); 156 + omap_dm_timer_wait_for_reset(timer); 157 + } 158 + omap_dm_timer_set_source(timer, OMAP_TIMER_SRC_SYS_CLK); 159 + 160 + /* Set to smart-idle mode */ 161 + l = omap_dm_timer_read_reg(timer, OMAP_TIMER_OCP_CFG_REG); 162 + l |= 0x02 << 3; 163 + omap_dm_timer_write_reg(timer, OMAP_TIMER_OCP_CFG_REG, l); 164 + } 165 + 166 + static void omap_dm_timer_prepare(struct omap_dm_timer *timer) 167 + { 168 + #ifdef CONFIG_ARCH_OMAP2 169 + clk_enable(timer->iclk); 170 + clk_enable(timer->fclk); 171 + #endif 172 + omap_dm_timer_reset(timer); 173 + } 174 + 175 + struct omap_dm_timer *omap_dm_timer_request(void) 176 + { 177 + struct omap_dm_timer *timer = NULL; 178 + unsigned long flags; 179 + int i; 180 + 181 + spin_lock_irqsave(&dm_timer_lock, flags); 182 + for (i = 0; i < dm_timer_count; i++) { 183 + if (dm_timers[i].reserved) 184 + continue; 185 + 186 + timer = &dm_timers[i]; 187 + timer->reserved = 1; 188 + break; 189 + } 190 + spin_unlock_irqrestore(&dm_timer_lock, flags); 191 + 192 + if (timer != NULL) 193 + omap_dm_timer_prepare(timer); 194 + 195 + return timer; 196 + } 197 + 198 + struct omap_dm_timer *omap_dm_timer_request_specific(int id) 91 199 { 92 200 struct omap_dm_timer *timer; 201 + unsigned long flags; 93 202 94 - for (timer = &dm_timers[0]; timer->base; ++timer) 95 - if (omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG) & 96 - OMAP_TIMER_CTRL_ST) 97 - return 1; 203 + spin_lock_irqsave(&dm_timer_lock, flags); 204 + if (id <= 0 || id > dm_timer_count || dm_timers[id-1].reserved) { 205 + spin_unlock_irqrestore(&dm_timer_lock, flags); 206 + printk("BUG: warning at %s:%d/%s(): unable to get timer %d\n", 207 + __FILE__, __LINE__, __FUNCTION__, id); 208 + dump_stack(); 209 + return NULL; 210 + } 98 211 99 - return 0; 212 + timer = &dm_timers[id-1]; 213 + timer->reserved = 1; 214 + spin_unlock_irqrestore(&dm_timer_lock, flags); 215 + 216 + omap_dm_timer_prepare(timer); 217 + 218 + return timer; 100 219 } 101 220 221 + void omap_dm_timer_free(struct omap_dm_timer *timer) 222 + { 223 + omap_dm_timer_reset(timer); 224 + #ifdef CONFIG_ARCH_OMAP2 225 + clk_disable(timer->iclk); 226 + clk_disable(timer->fclk); 227 + #endif 228 + WARN_ON(!timer->reserved); 229 + timer->reserved = 0; 230 + } 231 + 232 + int omap_dm_timer_get_irq(struct omap_dm_timer *timer) 233 + { 234 + return timer->irq; 235 + } 236 + 237 + #if defined(CONFIG_ARCH_OMAP1) 238 + 239 + struct clk *omap_dm_timer_get_fclk(struct omap_dm_timer *timer) 240 + { 241 + BUG(); 242 + } 102 243 103 244 /** 104 245 * omap_dm_timer_modify_idlect_mask - Check if any running timers use ARMXOR ··· 250 103 */ 251 104 __u32 omap_dm_timer_modify_idlect_mask(__u32 inputmask) 252 105 { 253 - int n; 106 + int i; 254 107 255 108 /* If ARMXOR cannot be idled this function call is unnecessary */ 256 109 if (!(inputmask & (1 << 1))) 257 110 return inputmask; 258 111 259 112 /* If any active timer is using ARMXOR return modified mask */ 260 - for (n = 0; dm_timers[n].base; ++n) 261 - if (omap_dm_timer_read_reg(&dm_timers[n], OMAP_TIMER_CTRL_REG)& 262 - OMAP_TIMER_CTRL_ST) { 263 - if (((omap_readl(MOD_CONF_CTRL_1)>>(n*2)) & 0x03) == 0) 113 + for (i = 0; i < dm_timer_count; i++) { 114 + u32 l; 115 + 116 + l = omap_dm_timer_read_reg(&dm_timers[i], OMAP_TIMER_CTRL_REG); 117 + if (l & OMAP_TIMER_CTRL_ST) { 118 + if (((omap_readl(MOD_CONF_CTRL_1) >> (i * 2)) & 0x03) == 0) 264 119 inputmask &= ~(1 << 1); 265 120 else 266 121 inputmask &= ~(1 << 2); 267 122 } 123 + } 268 124 269 125 return inputmask; 270 126 } 271 127 128 + #elif defined(CONFIG_ARCH_OMAP2) 129 + 130 + struct clk *omap_dm_timer_get_fclk(struct omap_dm_timer *timer) 131 + { 132 + return timer->fclk; 133 + } 134 + 135 + __u32 omap_dm_timer_modify_idlect_mask(__u32 inputmask) 136 + { 137 + BUG(); 138 + } 139 + 140 + #endif 141 + 142 + void omap_dm_timer_trigger(struct omap_dm_timer *timer) 143 + { 144 + omap_dm_timer_write_reg(timer, OMAP_TIMER_TRIGGER_REG, 0); 145 + } 146 + 147 + void omap_dm_timer_start(struct omap_dm_timer *timer) 148 + { 149 + u32 l; 150 + 151 + l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 152 + if (!(l & OMAP_TIMER_CTRL_ST)) { 153 + l |= OMAP_TIMER_CTRL_ST; 154 + omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 155 + } 156 + } 157 + 158 + void omap_dm_timer_stop(struct omap_dm_timer *timer) 159 + { 160 + u32 l; 161 + 162 + l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 163 + if (l & OMAP_TIMER_CTRL_ST) { 164 + l &= ~0x1; 165 + omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 166 + } 167 + } 168 + 169 + #ifdef CONFIG_ARCH_OMAP1 272 170 273 171 void omap_dm_timer_set_source(struct omap_dm_timer *timer, int source) 274 172 { ··· 325 133 omap_writel(l, MOD_CONF_CTRL_1); 326 134 } 327 135 136 + #else 328 137 329 - static void omap_dm_timer_reset(struct omap_dm_timer *timer) 138 + void omap_dm_timer_set_source(struct omap_dm_timer *timer, int source) 330 139 { 331 - /* Reset and set posted mode */ 332 - omap_dm_timer_write_reg(timer, OMAP_TIMER_IF_CTRL_REG, 0x06); 333 - omap_dm_timer_write_reg(timer, OMAP_TIMER_OCP_CFG_REG, 0x02); 140 + if (source < 0 || source >= 3) 141 + return; 334 142 335 - omap_dm_timer_set_source(timer, OMAP_TIMER_SRC_ARMXOR); 143 + clk_disable(timer->fclk); 144 + clk_set_parent(timer->fclk, dm_source_clocks[source]); 145 + clk_enable(timer->fclk); 146 + 147 + /* When the functional clock disappears, too quick writes seem to 148 + * cause an abort. */ 149 + __delay(15000); 150 + } 151 + 152 + #endif 153 + 154 + void omap_dm_timer_set_load(struct omap_dm_timer *timer, int autoreload, 155 + unsigned int load) 156 + { 157 + u32 l; 158 + 159 + l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 160 + if (autoreload) 161 + l |= OMAP_TIMER_CTRL_AR; 162 + else 163 + l &= ~OMAP_TIMER_CTRL_AR; 164 + omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 165 + omap_dm_timer_write_reg(timer, OMAP_TIMER_LOAD_REG, load); 166 + omap_dm_timer_write_reg(timer, OMAP_TIMER_TRIGGER_REG, 0); 167 + } 168 + 169 + void omap_dm_timer_set_match(struct omap_dm_timer *timer, int enable, 170 + unsigned int match) 171 + { 172 + u32 l; 173 + 174 + l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 175 + if (enable) 176 + l |= OMAP_TIMER_CTRL_CE; 177 + else 178 + l &= ~OMAP_TIMER_CTRL_CE; 179 + omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 180 + omap_dm_timer_write_reg(timer, OMAP_TIMER_MATCH_REG, match); 336 181 } 337 182 338 183 339 - 340 - struct omap_dm_timer * omap_dm_timer_request(void) 184 + void omap_dm_timer_set_pwm(struct omap_dm_timer *timer, int def_on, 185 + int toggle, int trigger) 341 186 { 342 - struct omap_dm_timer *timer = NULL; 343 - unsigned long flags; 187 + u32 l; 344 188 345 - spin_lock_irqsave(&dm_timer_lock, flags); 346 - if (!list_empty(&dm_timer_info.unused_timers)) { 347 - timer = (struct omap_dm_timer *) 348 - dm_timer_info.unused_timers.next; 349 - list_move_tail((struct list_head *)timer, 350 - &dm_timer_info.reserved_timers); 189 + l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 190 + l &= ~(OMAP_TIMER_CTRL_GPOCFG | OMAP_TIMER_CTRL_SCPWM | 191 + OMAP_TIMER_CTRL_PT | (0x03 << 10)); 192 + if (def_on) 193 + l |= OMAP_TIMER_CTRL_SCPWM; 194 + if (toggle) 195 + l |= OMAP_TIMER_CTRL_PT; 196 + l |= trigger << 10; 197 + omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 198 + } 199 + 200 + void omap_dm_timer_set_prescaler(struct omap_dm_timer *timer, int prescaler) 201 + { 202 + u32 l; 203 + 204 + l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 205 + l &= ~(OMAP_TIMER_CTRL_PRE | (0x07 << 2)); 206 + if (prescaler >= 0x00 && prescaler <= 0x07) { 207 + l |= OMAP_TIMER_CTRL_PRE; 208 + l |= prescaler << 2; 351 209 } 352 - spin_unlock_irqrestore(&dm_timer_lock, flags); 353 - 354 - return timer; 355 - } 356 - 357 - 358 - void omap_dm_timer_free(struct omap_dm_timer *timer) 359 - { 360 - unsigned long flags; 361 - 362 - omap_dm_timer_reset(timer); 363 - 364 - spin_lock_irqsave(&dm_timer_lock, flags); 365 - list_move_tail((struct list_head *)timer, &dm_timer_info.unused_timers); 366 - spin_unlock_irqrestore(&dm_timer_lock, flags); 210 + omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 367 211 } 368 212 369 213 void omap_dm_timer_set_int_enable(struct omap_dm_timer *timer, 370 - unsigned int value) 214 + unsigned int value) 371 215 { 372 216 omap_dm_timer_write_reg(timer, OMAP_TIMER_INT_EN_REG, value); 373 217 } ··· 418 190 omap_dm_timer_write_reg(timer, OMAP_TIMER_STAT_REG, value); 419 191 } 420 192 421 - void omap_dm_timer_enable_autoreload(struct omap_dm_timer *timer) 422 - { 423 - u32 l; 424 - l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 425 - l |= OMAP_TIMER_CTRL_AR; 426 - omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 427 - } 428 - 429 - void omap_dm_timer_trigger(struct omap_dm_timer *timer) 430 - { 431 - omap_dm_timer_write_reg(timer, OMAP_TIMER_TRIGGER_REG, 1); 432 - } 433 - 434 - void omap_dm_timer_set_trigger(struct omap_dm_timer *timer, unsigned int value) 435 - { 436 - u32 l; 437 - 438 - l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 439 - l |= value & 0x3; 440 - omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 441 - } 442 - 443 - void omap_dm_timer_start(struct omap_dm_timer *timer) 444 - { 445 - u32 l; 446 - 447 - l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 448 - l |= OMAP_TIMER_CTRL_ST; 449 - omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 450 - } 451 - 452 - void omap_dm_timer_stop(struct omap_dm_timer *timer) 453 - { 454 - u32 l; 455 - 456 - l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 457 - l &= ~0x1; 458 - omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 459 - } 460 - 461 193 unsigned int omap_dm_timer_read_counter(struct omap_dm_timer *timer) 462 194 { 463 195 return omap_dm_timer_read_reg(timer, OMAP_TIMER_COUNTER_REG); 464 196 } 465 197 466 - void omap_dm_timer_reset_counter(struct omap_dm_timer *timer) 198 + void omap_dm_timer_write_counter(struct omap_dm_timer *timer, unsigned int value) 467 199 { 468 - omap_dm_timer_write_reg(timer, OMAP_TIMER_COUNTER_REG, 0); 200 + return omap_dm_timer_write_reg(timer, OMAP_TIMER_COUNTER_REG, value); 469 201 } 470 202 471 - void omap_dm_timer_set_load(struct omap_dm_timer *timer, unsigned int load) 203 + int omap_dm_timers_active(void) 472 204 { 473 - omap_dm_timer_write_reg(timer, OMAP_TIMER_LOAD_REG, load); 474 - } 205 + int i; 475 206 476 - void omap_dm_timer_set_match(struct omap_dm_timer *timer, unsigned int match) 477 - { 478 - omap_dm_timer_write_reg(timer, OMAP_TIMER_MATCH_REG, match); 479 - } 207 + for (i = 0; i < dm_timer_count; i++) { 208 + struct omap_dm_timer *timer; 480 209 481 - void omap_dm_timer_enable_compare(struct omap_dm_timer *timer) 482 - { 483 - u32 l; 484 - 485 - l = omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG); 486 - l |= OMAP_TIMER_CTRL_CE; 487 - omap_dm_timer_write_reg(timer, OMAP_TIMER_CTRL_REG, l); 488 - } 489 - 490 - 491 - static inline void __dm_timer_init(void) 492 - { 493 - struct omap_dm_timer *timer; 494 - 495 - spin_lock_init(&dm_timer_lock); 496 - INIT_LIST_HEAD(&dm_timer_info.unused_timers); 497 - INIT_LIST_HEAD(&dm_timer_info.reserved_timers); 498 - 499 - timer = &dm_timers[0]; 500 - while (timer->base) { 501 - list_add_tail((struct list_head *)timer, &dm_timer_info.unused_timers); 502 - omap_dm_timer_reset(timer); 503 - timer++; 210 + timer = &dm_timers[i]; 211 + if (omap_dm_timer_read_reg(timer, OMAP_TIMER_CTRL_REG) & 212 + OMAP_TIMER_CTRL_ST) 213 + return 1; 504 214 } 505 - } 506 - 507 - static int __init omap_dm_timer_init(void) 508 - { 509 - if (cpu_is_omap16xx()) 510 - __dm_timer_init(); 511 215 return 0; 512 216 } 513 217 514 - arch_initcall(omap_dm_timer_init); 218 + int omap_dm_timer_init(void) 219 + { 220 + struct omap_dm_timer *timer; 221 + int i; 222 + 223 + if (!(cpu_is_omap16xx() || cpu_is_omap24xx())) 224 + return -ENODEV; 225 + 226 + spin_lock_init(&dm_timer_lock); 227 + #ifdef CONFIG_ARCH_OMAP2 228 + for (i = 0; i < ARRAY_SIZE(dm_source_names); i++) { 229 + dm_source_clocks[i] = clk_get(NULL, dm_source_names[i]); 230 + BUG_ON(dm_source_clocks[i] == NULL); 231 + } 232 + #endif 233 + 234 + for (i = 0; i < dm_timer_count; i++) { 235 + #ifdef CONFIG_ARCH_OMAP2 236 + char clk_name[16]; 237 + #endif 238 + 239 + timer = &dm_timers[i]; 240 + timer->io_base = (void __iomem *) io_p2v(timer->phys_base); 241 + #ifdef CONFIG_ARCH_OMAP2 242 + sprintf(clk_name, "gpt%d_ick", i + 1); 243 + timer->iclk = clk_get(NULL, clk_name); 244 + sprintf(clk_name, "gpt%d_fck", i + 1); 245 + timer->fclk = clk_get(NULL, clk_name); 246 + #endif 247 + } 248 + 249 + return 0; 250 + }
+94 -9
arch/arm/plat-omap/gpio.c
··· 536 536 _clear_gpio_irqbank(bank, 1 << get_gpio_index(gpio)); 537 537 } 538 538 539 + static u32 _get_gpio_irqbank_mask(struct gpio_bank *bank) 540 + { 541 + void __iomem *reg = bank->base; 542 + int inv = 0; 543 + u32 l; 544 + u32 mask; 545 + 546 + switch (bank->method) { 547 + case METHOD_MPUIO: 548 + reg += OMAP_MPUIO_GPIO_MASKIT; 549 + mask = 0xffff; 550 + inv = 1; 551 + break; 552 + case METHOD_GPIO_1510: 553 + reg += OMAP1510_GPIO_INT_MASK; 554 + mask = 0xffff; 555 + inv = 1; 556 + break; 557 + case METHOD_GPIO_1610: 558 + reg += OMAP1610_GPIO_IRQENABLE1; 559 + mask = 0xffff; 560 + break; 561 + case METHOD_GPIO_730: 562 + reg += OMAP730_GPIO_INT_MASK; 563 + mask = 0xffffffff; 564 + inv = 1; 565 + break; 566 + case METHOD_GPIO_24XX: 567 + reg += OMAP24XX_GPIO_IRQENABLE1; 568 + mask = 0xffffffff; 569 + break; 570 + default: 571 + BUG(); 572 + return 0; 573 + } 574 + 575 + l = __raw_readl(reg); 576 + if (inv) 577 + l = ~l; 578 + l &= mask; 579 + return l; 580 + } 581 + 539 582 static void _enable_gpio_irqbank(struct gpio_bank *bank, int gpio_mask, int enable) 540 583 { 541 584 void __iomem *reg = bank->base; ··· 778 735 u32 isr; 779 736 unsigned int gpio_irq; 780 737 struct gpio_bank *bank; 738 + u32 retrigger = 0; 739 + int unmasked = 0; 781 740 782 741 desc->chip->ack(irq); 783 742 ··· 804 759 #endif 805 760 while(1) { 806 761 u32 isr_saved, level_mask = 0; 762 + u32 enabled; 807 763 808 - isr_saved = isr = __raw_readl(isr_reg); 764 + enabled = _get_gpio_irqbank_mask(bank); 765 + isr_saved = isr = __raw_readl(isr_reg) & enabled; 809 766 810 767 if (cpu_is_omap15xx() && (bank->method == METHOD_MPUIO)) 811 768 isr &= 0x0000ffff; 812 769 813 - if (cpu_is_omap24xx()) 770 + if (cpu_is_omap24xx()) { 814 771 level_mask = 815 772 __raw_readl(bank->base + 816 773 OMAP24XX_GPIO_LEVELDETECT0) | 817 774 __raw_readl(bank->base + 818 775 OMAP24XX_GPIO_LEVELDETECT1); 776 + level_mask &= enabled; 777 + } 819 778 820 779 /* clear edge sensitive interrupts before handler(s) are 821 780 called so that we don't miss any interrupt occurred while ··· 830 781 831 782 /* if there is only edge sensitive GPIO pin interrupts 832 783 configured, we could unmask GPIO bank interrupt immediately */ 833 - if (!level_mask) 784 + if (!level_mask && !unmasked) { 785 + unmasked = 1; 834 786 desc->chip->unmask(irq); 787 + } 835 788 789 + isr |= retrigger; 790 + retrigger = 0; 836 791 if (!isr) 837 792 break; 838 793 839 794 gpio_irq = bank->virtual_irq_start; 840 795 for (; isr != 0; isr >>= 1, gpio_irq++) { 841 796 struct irqdesc *d; 797 + int irq_mask; 842 798 if (!(isr & 1)) 843 799 continue; 844 800 d = irq_desc + gpio_irq; 801 + /* Don't run the handler if it's already running 802 + * or was disabled lazely. 803 + */ 804 + if (unlikely((d->disable_depth || d->running))) { 805 + irq_mask = 1 << 806 + (gpio_irq - bank->virtual_irq_start); 807 + /* The unmasking will be done by 808 + * enable_irq in case it is disabled or 809 + * after returning from the handler if 810 + * it's already running. 811 + */ 812 + _enable_gpio_irqbank(bank, irq_mask, 0); 813 + if (!d->disable_depth) { 814 + /* Level triggered interrupts 815 + * won't ever be reentered 816 + */ 817 + BUG_ON(level_mask & irq_mask); 818 + d->pending = 1; 819 + } 820 + continue; 821 + } 822 + d->running = 1; 845 823 desc_handle_irq(gpio_irq, d, regs); 824 + d->running = 0; 825 + if (unlikely(d->pending && !d->disable_depth)) { 826 + irq_mask = 1 << 827 + (gpio_irq - bank->virtual_irq_start); 828 + d->pending = 0; 829 + _enable_gpio_irqbank(bank, irq_mask, 1); 830 + retrigger |= irq_mask; 831 + } 846 832 } 847 833 848 834 if (cpu_is_omap24xx()) { ··· 887 803 _enable_gpio_irqbank(bank, isr_saved & level_mask, 1); 888 804 } 889 805 890 - /* if bank has any level sensitive GPIO pin interrupt 891 - configured, we must unmask the bank interrupt only after 892 - handler(s) are executed in order to avoid spurious bank 893 - interrupt */ 894 - if (level_mask) 895 - desc->chip->unmask(irq); 896 806 } 807 + /* if bank has any level sensitive GPIO pin interrupt 808 + configured, we must unmask the bank interrupt only after 809 + handler(s) are executed in order to avoid spurious bank 810 + interrupt */ 811 + if (!unmasked) 812 + desc->chip->unmask(irq); 813 + 897 814 } 898 815 899 816 static void gpio_ack_irq(unsigned int irq)
+3 -6
arch/arm/plat-omap/sram.c
··· 157 157 { /* .length gets filled in at runtime */ 158 158 .virtual = OMAP1_SRAM_VA, 159 159 .pfn = __phys_to_pfn(OMAP1_SRAM_PA), 160 - .type = MT_DEVICE 160 + .type = MT_MEMORY 161 161 } 162 162 }; 163 163 164 164 /* 165 - * In order to use last 2kB of SRAM on 1611b, we must round the size 166 - * up to multiple of PAGE_SIZE. We cannot use ioremap for SRAM, as 167 - * clock init needs SRAM early. 165 + * Note that we cannot use ioremap for SRAM, as clock init needs SRAM early. 168 166 */ 169 167 void __init omap_map_sram(void) 170 168 { ··· 182 184 omap_sram_io_desc[0].pfn = __phys_to_pfn(base); 183 185 } 184 186 185 - omap_sram_io_desc[0].length = (omap_sram_size + PAGE_SIZE-1)/PAGE_SIZE; 186 - omap_sram_io_desc[0].length *= PAGE_SIZE; 187 + omap_sram_io_desc[0].length = 1024 * 1024; /* Use section desc */ 187 188 iotable_init(omap_sram_io_desc, ARRAY_SIZE(omap_sram_io_desc)); 188 189 189 190 printk(KERN_INFO "SRAM: Mapped pa 0x%08lx to va 0x%08lx size: 0x%lx\n",
+56 -72
arch/arm/plat-omap/timer32k.c
··· 7 7 * Partial timer rewrite and additional dynamic tick timer support by 8 8 * Tony Lindgen <tony@atomide.com> and 9 9 * Tuukka Tikkanen <tuukka.tikkanen@elektrobit.com> 10 + * OMAP Dual-mode timer framework support by Timo Teras 10 11 * 11 12 * MPU timer code based on the older MPU timer code for OMAP 12 13 * Copyright (C) 2000 RidgeRun, Inc. ··· 50 49 #include <asm/irq.h> 51 50 #include <asm/mach/irq.h> 52 51 #include <asm/mach/time.h> 52 + #include <asm/arch/dmtimer.h> 53 53 54 54 struct sys_timer omap_timer; 55 55 ··· 80 78 #define OMAP1_32K_TIMER_TVR 0x00 81 79 #define OMAP1_32K_TIMER_TCR 0x04 82 80 83 - /* 24xx specific defines */ 84 - #define OMAP2_GP_TIMER_BASE 0x48028000 85 - #define CM_CLKSEL_WKUP 0x48008440 86 - #define GP_TIMER_TIDR 0x00 87 - #define GP_TIMER_TISR 0x18 88 - #define GP_TIMER_TIER 0x1c 89 - #define GP_TIMER_TCLR 0x24 90 - #define GP_TIMER_TCRR 0x28 91 - #define GP_TIMER_TLDR 0x2c 92 - #define GP_TIMER_TTGR 0x30 93 - #define GP_TIMER_TSICR 0x40 94 - 95 81 #define OMAP_32K_TICKS_PER_HZ (32768 / HZ) 96 82 97 83 /* ··· 91 101 #define JIFFIES_TO_HW_TICKS(nr_jiffies, clock_rate) \ 92 102 (((nr_jiffies) * (clock_rate)) / HZ) 93 103 104 + #if defined(CONFIG_ARCH_OMAP1) 105 + 94 106 static inline void omap_32k_timer_write(int val, int reg) 95 107 { 96 - if (cpu_class_is_omap1()) 97 - omap_writew(val, OMAP1_32K_TIMER_BASE + reg); 98 - 99 - if (cpu_is_omap24xx()) 100 - omap_writel(val, OMAP2_GP_TIMER_BASE + reg); 108 + omap_writew(val, OMAP1_32K_TIMER_BASE + reg); 101 109 } 102 110 103 111 static inline unsigned long omap_32k_timer_read(int reg) 104 112 { 105 - if (cpu_class_is_omap1()) 106 - return omap_readl(OMAP1_32K_TIMER_BASE + reg) & 0xffffff; 107 - 108 - if (cpu_is_omap24xx()) 109 - return omap_readl(OMAP2_GP_TIMER_BASE + reg); 113 + return omap_readl(OMAP1_32K_TIMER_BASE + reg) & 0xffffff; 110 114 } 115 + 116 + static inline void omap_32k_timer_start(unsigned long load_val) 117 + { 118 + omap_32k_timer_write(load_val, OMAP1_32K_TIMER_TVR); 119 + omap_32k_timer_write(0x0f, OMAP1_32K_TIMER_CR); 120 + } 121 + 122 + static inline void omap_32k_timer_stop(void) 123 + { 124 + omap_32k_timer_write(0x0, OMAP1_32K_TIMER_CR); 125 + } 126 + 127 + #define omap_32k_timer_ack_irq() 128 + 129 + #elif defined(CONFIG_ARCH_OMAP2) 130 + 131 + static struct omap_dm_timer *gptimer; 132 + 133 + static inline void omap_32k_timer_start(unsigned long load_val) 134 + { 135 + omap_dm_timer_set_load(gptimer, 1, 0xffffffff - load_val); 136 + omap_dm_timer_set_int_enable(gptimer, OMAP_TIMER_INT_OVERFLOW); 137 + omap_dm_timer_start(gptimer); 138 + } 139 + 140 + static inline void omap_32k_timer_stop(void) 141 + { 142 + omap_dm_timer_stop(gptimer); 143 + } 144 + 145 + static inline void omap_32k_timer_ack_irq(void) 146 + { 147 + u32 status = omap_dm_timer_read_status(gptimer); 148 + omap_dm_timer_write_status(gptimer, status); 149 + } 150 + 151 + #endif 111 152 112 153 /* 113 154 * The 32KHz synchronized timer is an additional timer on 16xx. ··· 147 126 static inline unsigned long omap_32k_sync_timer_read(void) 148 127 { 149 128 return omap_readl(TIMER_32K_SYNCHRONIZED); 150 - } 151 - 152 - static inline void omap_32k_timer_start(unsigned long load_val) 153 - { 154 - if (cpu_class_is_omap1()) { 155 - omap_32k_timer_write(load_val, OMAP1_32K_TIMER_TVR); 156 - omap_32k_timer_write(0x0f, OMAP1_32K_TIMER_CR); 157 - } 158 - 159 - if (cpu_is_omap24xx()) { 160 - omap_32k_timer_write(0xffffffff - load_val, GP_TIMER_TCRR); 161 - omap_32k_timer_write((1 << 1), GP_TIMER_TIER); 162 - omap_32k_timer_write((1 << 1) | 1, GP_TIMER_TCLR); 163 - } 164 - } 165 - 166 - static inline void omap_32k_timer_stop(void) 167 - { 168 - if (cpu_class_is_omap1()) 169 - omap_32k_timer_write(0x0, OMAP1_32K_TIMER_CR); 170 - 171 - if (cpu_is_omap24xx()) 172 - omap_32k_timer_write(0x0, GP_TIMER_TCLR); 173 129 } 174 130 175 131 /* ··· 200 202 201 203 write_seqlock_irqsave(&xtime_lock, flags); 202 204 203 - if (cpu_is_omap24xx()) { 204 - u32 status = omap_32k_timer_read(GP_TIMER_TISR); 205 - omap_32k_timer_write(status, GP_TIMER_TISR); 206 - } 207 - 205 + omap_32k_timer_ack_irq(); 208 206 now = omap_32k_sync_timer_read(); 209 207 210 208 while ((signed long)(now - omap_32k_last_tick) ··· 262 268 .handler = omap_32k_timer_interrupt, 263 269 }; 264 270 265 - static struct clk * gpt1_ick; 266 - static struct clk * gpt1_fck; 267 - 268 271 static __init void omap_init_32k_timer(void) 269 272 { 270 273 #ifdef CONFIG_NO_IDLE_HZ ··· 270 279 271 280 if (cpu_class_is_omap1()) 272 281 setup_irq(INT_OS_TIMER, &omap_32k_timer_irq); 273 - if (cpu_is_omap24xx()) 274 - setup_irq(37, &omap_32k_timer_irq); 275 282 omap_timer.offset = omap_32k_timer_gettimeoffset; 276 283 omap_32k_last_tick = omap_32k_sync_timer_read(); 277 284 285 + #ifdef CONFIG_ARCH_OMAP2 278 286 /* REVISIT: Check 24xx TIOCP_CFG settings after idle works */ 279 287 if (cpu_is_omap24xx()) { 280 - omap_32k_timer_write(0, GP_TIMER_TCLR); 281 - omap_writel(0, CM_CLKSEL_WKUP); /* 32KHz clock source */ 288 + gptimer = omap_dm_timer_request_specific(1); 289 + BUG_ON(gptimer == NULL); 282 290 283 - gpt1_ick = clk_get(NULL, "gpt1_ick"); 284 - if (IS_ERR(gpt1_ick)) 285 - printk(KERN_ERR "Could not get gpt1_ick\n"); 286 - else 287 - clk_enable(gpt1_ick); 288 - 289 - gpt1_fck = clk_get(NULL, "gpt1_fck"); 290 - if (IS_ERR(gpt1_fck)) 291 - printk(KERN_ERR "Could not get gpt1_fck\n"); 292 - else 293 - clk_enable(gpt1_fck); 294 - 295 - mdelay(100); /* Wait for clocks to stabilize */ 296 - 297 - omap_32k_timer_write(0x7, GP_TIMER_TISR); 291 + omap_dm_timer_set_source(gptimer, OMAP_TIMER_SRC_32_KHZ); 292 + setup_irq(omap_dm_timer_get_irq(gptimer), &omap_32k_timer_irq); 293 + omap_dm_timer_set_int_enable(gptimer, 294 + OMAP_TIMER_INT_CAPTURE | OMAP_TIMER_INT_OVERFLOW | 295 + OMAP_TIMER_INT_MATCH); 298 296 } 297 + #endif 299 298 300 299 omap_32k_timer_start(OMAP_32K_TIMER_TICK_PERIOD); 301 300 } ··· 297 316 */ 298 317 static void __init omap_timer_init(void) 299 318 { 319 + #ifdef CONFIG_OMAP_DM_TIMER 320 + omap_dm_timer_init(); 321 + #endif 300 322 omap_init_32k_timer(); 301 323 } 302 324
+20 -23
drivers/mmc/omap.c
··· 60 60 unsigned char id; /* 16xx chips have 2 MMC blocks */ 61 61 struct clk * iclk; 62 62 struct clk * fclk; 63 + struct resource *res; 63 64 void __iomem *base; 64 65 int irq; 65 66 unsigned char bus_mode; ··· 340 339 mmc_omap_xfer_data(struct mmc_omap_host *host, int write) 341 340 { 342 341 int n; 343 - void __iomem *reg; 344 - u16 *p; 345 342 346 343 if (host->buffer_bytes_left == 0) { 347 344 host->sg_idx++; ··· 656 657 struct mmc_data *mmcdat = host->data; 657 658 658 659 if (unlikely(host->dma_ch < 0)) { 659 - dev_err(mmc_dev(host->mmc), "DMA callback while DMA not 660 - enabled\n"); 660 + dev_err(mmc_dev(host->mmc), 661 + "DMA callback while DMA not enabled\n"); 661 662 return; 662 663 } 663 664 /* FIXME: We really should do something to _handle_ the errors */ 664 - if (ch_status & OMAP_DMA_TOUT_IRQ) { 665 + if (ch_status & OMAP1_DMA_TOUT_IRQ) { 665 666 dev_err(mmc_dev(host->mmc),"DMA timeout\n"); 666 667 return; 667 668 } ··· 971 972 struct omap_mmc_conf *minfo = pdev->dev.platform_data; 972 973 struct mmc_host *mmc; 973 974 struct mmc_omap_host *host = NULL; 975 + struct resource *r; 974 976 int ret = 0; 977 + int irq; 975 978 976 - if (platform_get_resource(pdev, IORESOURCE_MEM, 0) || 977 - platform_get_irq(pdev, IORESOURCE_IRQ, 0)) { 978 - dev_err(&pdev->dev, "mmc_omap_probe: invalid resource type\n"); 979 - return -ENODEV; 980 - } 979 + r = platform_get_resource(pdev, IORESOURCE_MEM, 0); 980 + irq = platform_get_irq(pdev, 0); 981 + if (!r || irq < 0) 982 + return -ENXIO; 981 983 982 - if (!request_mem_region(pdev->resource[0].start, 984 + r = request_mem_region(pdev->resource[0].start, 983 985 pdev->resource[0].end - pdev->resource[0].start + 1, 984 - pdev->name)) { 985 - dev_dbg(&pdev->dev, "request_mem_region failed\n"); 986 + pdev->name); 987 + if (!r) 986 988 return -EBUSY; 987 - } 988 989 989 990 mmc = mmc_alloc_host(sizeof(struct mmc_omap_host), &pdev->dev); 990 991 if (!mmc) { ··· 1001 1002 host->dma_timer.data = (unsigned long) host; 1002 1003 1003 1004 host->id = pdev->id; 1005 + host->res = r; 1006 + host->irq = irq; 1004 1007 1005 1008 if (cpu_is_omap24xx()) { 1006 1009 host->iclk = clk_get(&pdev->dev, "mmc_ick"); ··· 1032 1031 host->dma_ch = -1; 1033 1032 1034 1033 host->irq = pdev->resource[1].start; 1035 - host->base = ioremap(pdev->res.start, SZ_4K); 1036 - if (!host->base) { 1037 - ret = -ENOMEM; 1038 - goto out; 1039 - } 1034 + host->base = (void __iomem*)IO_ADDRESS(r->start); 1040 1035 1041 - if (minfo->wire4) 1036 + if (minfo->wire4) 1042 1037 mmc->caps |= MMC_CAP_4_BIT_DATA; 1043 1038 1044 1039 mmc->ops = &mmc_omap_ops; ··· 1053 1056 1054 1057 if (host->power_pin >= 0) { 1055 1058 if ((ret = omap_request_gpio(host->power_pin)) != 0) { 1056 - dev_err(mmc_dev(host->mmc), "Unable to get GPIO 1057 - pin for MMC power\n"); 1059 + dev_err(mmc_dev(host->mmc), 1060 + "Unable to get GPIO pin for MMC power\n"); 1058 1061 goto out; 1059 1062 } 1060 1063 omap_set_gpio_direction(host->power_pin, 0); ··· 1096 1099 device_remove_file(&pdev->dev, &dev_attr_cover_switch); 1097 1100 } 1098 1101 if (ret) { 1099 - dev_wan(mmc_dev(host->mmc), "Unable to create sysfs attributes\n"); 1102 + dev_warn(mmc_dev(host->mmc), "Unable to create sysfs attributes\n"); 1100 1103 free_irq(OMAP_GPIO_IRQ(host->switch_pin), host); 1101 1104 omap_free_gpio(host->switch_pin); 1102 1105 host->switch_pin = -1;
+1 -1
drivers/usb/gadget/omap_udc.c
··· 772 772 struct omap_ep *ep = data; 773 773 774 774 /* if ch_status & OMAP_DMA_DROP_IRQ ... */ 775 - /* if ch_status & OMAP_DMA_TOUT_IRQ ... */ 775 + /* if ch_status & OMAP1_DMA_TOUT_IRQ ... */ 776 776 ERR("%s dma error, lch %d status %02x\n", ep->ep.name, lch, ch_status); 777 777 778 778 /* complete current transfer ... */
+51
include/asm-arm/arch-omap/board-fsample.h
··· 1 + /* 2 + * linux/include/asm-arm/arch-omap/board-fsample.h 3 + * 4 + * Board-specific goodies for TI F-Sample. 5 + * 6 + * Copyright (C) 2006 Google, Inc. 7 + * Author: Brian Swetland <swetland@google.com> 8 + * 9 + * This program is free software; you can redistribute it and/or modify 10 + * it under the terms of the GNU General Public License version 2 as 11 + * published by the Free Software Foundation. 12 + */ 13 + 14 + #ifndef __ASM_ARCH_OMAP_FSAMPLE_H 15 + #define __ASM_ARCH_OMAP_FSAMPLE_H 16 + 17 + /* fsample is pretty close to p2-sample */ 18 + #include <asm/arch/board-perseus2.h> 19 + 20 + #define fsample_cpld_read(reg) __raw_readb(reg) 21 + #define fsample_cpld_write(val, reg) __raw_writeb(val, reg) 22 + 23 + #define FSAMPLE_CPLD_BASE 0xE8100000 24 + #define FSAMPLE_CPLD_SIZE SZ_4K 25 + #define FSAMPLE_CPLD_START 0x05080000 26 + 27 + #define FSAMPLE_CPLD_REG_A (FSAMPLE_CPLD_BASE + 0x00) 28 + #define FSAMPLE_CPLD_SWITCH (FSAMPLE_CPLD_BASE + 0x02) 29 + #define FSAMPLE_CPLD_UART (FSAMPLE_CPLD_BASE + 0x02) 30 + #define FSAMPLE_CPLD_REG_B (FSAMPLE_CPLD_BASE + 0x04) 31 + #define FSAMPLE_CPLD_VERSION (FSAMPLE_CPLD_BASE + 0x06) 32 + #define FSAMPLE_CPLD_SET_CLR (FSAMPLE_CPLD_BASE + 0x06) 33 + 34 + #define FSAMPLE_CPLD_BIT_BT_RESET 0 35 + #define FSAMPLE_CPLD_BIT_LCD_RESET 1 36 + #define FSAMPLE_CPLD_BIT_CAM_PWDN 2 37 + #define FSAMPLE_CPLD_BIT_CHARGER_ENABLE 3 38 + #define FSAMPLE_CPLD_BIT_SD_MMC_EN 4 39 + #define FSAMPLE_CPLD_BIT_aGPS_PWREN 5 40 + #define FSAMPLE_CPLD_BIT_BACKLIGHT 6 41 + #define FSAMPLE_CPLD_BIT_aGPS_EN_RESET 7 42 + #define FSAMPLE_CPLD_BIT_aGPS_SLEEPx_N 8 43 + #define FSAMPLE_CPLD_BIT_OTG_RESET 9 44 + 45 + #define fsample_cpld_set(bit) \ 46 + fsample_cpld_write((((bit) & 15) << 4) | 0x0f, FSAMPLE_CPLD_SET_CLR) 47 + 48 + #define fsample_cpld_clear(bit) \ 49 + fsample_cpld_write(0xf0 | ((bit) & 15), FSAMPLE_CPLD_SET_CLR) 50 + 51 + #endif
+7
include/asm-arm/arch-omap/board.h
··· 22 22 #define OMAP_TAG_UART 0x4f07 23 23 #define OMAP_TAG_FBMEM 0x4f08 24 24 #define OMAP_TAG_STI_CONSOLE 0x4f09 25 + #define OMAP_TAG_CAMERA_SENSOR 0x4f0a 25 26 26 27 #define OMAP_TAG_BOOT_REASON 0x4f80 27 28 #define OMAP_TAG_FLASH_PART 0x4f81 ··· 60 59 struct omap_sti_console_config { 61 60 unsigned enable:1; 62 61 u8 channel; 62 + }; 63 + 64 + struct omap_camera_sensor_config { 65 + u16 reset_gpio; 66 + int (*power_on)(void * data); 67 + int (*power_off)(void * data); 63 68 }; 64 69 65 70 struct omap_usb_config {
+9 -6
include/asm-arm/arch-omap/dma.h
··· 185 185 /* DMA channels for 24xx */ 186 186 #define OMAP24XX_DMA_NO_DEVICE 0 187 187 #define OMAP24XX_DMA_XTI_DMA 1 /* S_DMA_0 */ 188 - #define OMAP24XX_DMA_EXT_NDMA_REQ0 2 /* S_DMA_1 */ 189 - #define OMAP24XX_DMA_EXT_NDMA_REQ1 3 /* S_DMA_2 */ 188 + #define OMAP24XX_DMA_EXT_DMAREQ0 2 /* S_DMA_1 */ 189 + #define OMAP24XX_DMA_EXT_DMAREQ1 3 /* S_DMA_2 */ 190 190 #define OMAP24XX_DMA_GPMC 4 /* S_DMA_3 */ 191 191 #define OMAP24XX_DMA_GFX 5 /* S_DMA_4 */ 192 192 #define OMAP24XX_DMA_DSS 6 /* S_DMA_5 */ ··· 197 197 #define OMAP24XX_DMA_DES_TX 11 /* S_DMA_10 */ 198 198 #define OMAP24XX_DMA_DES_RX 12 /* S_DMA_11 */ 199 199 #define OMAP24XX_DMA_SHA1MD5_RX 13 /* S_DMA_12 */ 200 - 200 + #define OMAP24XX_DMA_EXT_DMAREQ2 14 /* S_DMA_13 */ 201 + #define OMAP24XX_DMA_EXT_DMAREQ3 15 /* S_DMA_14 */ 202 + #define OMAP24XX_DMA_EXT_DMAREQ4 16 /* S_DMA_15 */ 201 203 #define OMAP24XX_DMA_EAC_AC_RD 17 /* S_DMA_16 */ 202 204 #define OMAP24XX_DMA_EAC_AC_WR 18 /* S_DMA_17 */ 203 205 #define OMAP24XX_DMA_EAC_MD_UL_RD 19 /* S_DMA_18 */ ··· 246 244 #define OMAP24XX_DMA_MMC1_TX 61 /* SDMA_60 */ 247 245 #define OMAP24XX_DMA_MMC1_RX 62 /* SDMA_61 */ 248 246 #define OMAP24XX_DMA_MS 63 /* SDMA_62 */ 247 + #define OMAP24XX_DMA_EXT_DMAREQ5 64 /* S_DMA_63 */ 249 248 250 249 /*----------------------------------------------------------------------------*/ 251 250 ··· 277 274 #define OMAP1610_DMA_LCD_LCH_CTRL (OMAP1610_DMA_LCD_BASE + 0xea) 278 275 #define OMAP1610_DMA_LCD_SRC_FI_B1_U (OMAP1610_DMA_LCD_BASE + 0xf4) 279 276 280 - #define OMAP_DMA_TOUT_IRQ (1 << 0) /* Only on omap1 */ 277 + #define OMAP1_DMA_TOUT_IRQ (1 << 0) 281 278 #define OMAP_DMA_DROP_IRQ (1 << 1) 282 279 #define OMAP_DMA_HALF_IRQ (1 << 2) 283 280 #define OMAP_DMA_FRAME_IRQ (1 << 3) ··· 318 315 OMAP_LCD_DMA_B2_BOTTOM 319 316 }; 320 317 321 - /* REVISIT: Check if BURST_4 is really 1 (or 2) */ 322 318 enum omap_dma_burst_mode { 323 319 OMAP_DMA_DATA_BURST_DIS = 0, 324 320 OMAP_DMA_DATA_BURST_4, 325 - OMAP_DMA_DATA_BURST_8 321 + OMAP_DMA_DATA_BURST_8, 322 + OMAP_DMA_DATA_BURST_16, 326 323 }; 327 324 328 325 enum omap_dma_color_mode {
+33 -45
include/asm-arm/arch-omap/dmtimer.h
··· 5 5 * 6 6 * Copyright (C) 2005 Nokia Corporation 7 7 * Author: Lauri Leukkunen <lauri.leukkunen@nokia.com> 8 + * PWM and clock framwork support by Timo Teras. 8 9 * 9 10 * This program is free software; you can redistribute it and/or modify it 10 11 * under the terms of the GNU General Public License as published by the ··· 26 25 * 675 Mass Ave, Cambridge, MA 02139, USA. 27 26 */ 28 27 29 - #ifndef __ASM_ARCH_TIMER_H 30 - #define __ASM_ARCH_TIMER_H 28 + #ifndef __ASM_ARCH_DMTIMER_H 29 + #define __ASM_ARCH_DMTIMER_H 31 30 32 - #include <linux/list.h> 33 - 34 - #define OMAP_TIMER_SRC_ARMXOR 0x00 35 - #define OMAP_TIMER_SRC_32_KHZ 0x01 36 - #define OMAP_TIMER_SRC_EXT_CLK 0x02 37 - 38 - /* timer control reg bits */ 39 - #define OMAP_TIMER_CTRL_CAPTMODE (1 << 13) 40 - #define OMAP_TIMER_CTRL_PT (1 << 12) 41 - #define OMAP_TIMER_CTRL_TRG_OVERFLOW (0x1 << 10) 42 - #define OMAP_TIMER_CTRL_TRG_OFANDMATCH (0x2 << 10) 43 - #define OMAP_TIMER_CTRL_TCM_LOWTOHIGH (0x1 << 8) 44 - #define OMAP_TIMER_CTRL_TCM_HIGHTOLOW (0x2 << 8) 45 - #define OMAP_TIMER_CTRL_TCM_BOTHEDGES (0x3 << 8) 46 - #define OMAP_TIMER_CTRL_SCPWM (1 << 7) 47 - #define OMAP_TIMER_CTRL_CE (1 << 6) /* compare enable */ 48 - #define OMAP_TIMER_CTRL_PRE (1 << 5) /* prescaler enable */ 49 - #define OMAP_TIMER_CTRL_PTV_SHIFT 2 /* how much to shift the prescaler value */ 50 - #define OMAP_TIMER_CTRL_AR (1 << 1) /* auto-reload enable */ 51 - #define OMAP_TIMER_CTRL_ST (1 << 0) /* start timer */ 31 + /* clock sources */ 32 + #define OMAP_TIMER_SRC_SYS_CLK 0x00 33 + #define OMAP_TIMER_SRC_32_KHZ 0x01 34 + #define OMAP_TIMER_SRC_EXT_CLK 0x02 52 35 53 36 /* timer interrupt enable bits */ 54 - #define OMAP_TIMER_INT_CAPTURE (1 << 2) 55 - #define OMAP_TIMER_INT_OVERFLOW (1 << 1) 56 - #define OMAP_TIMER_INT_MATCH (1 << 0) 37 + #define OMAP_TIMER_INT_CAPTURE (1 << 2) 38 + #define OMAP_TIMER_INT_OVERFLOW (1 << 1) 39 + #define OMAP_TIMER_INT_MATCH (1 << 0) 57 40 41 + /* trigger types */ 42 + #define OMAP_TIMER_TRIGGER_NONE 0x00 43 + #define OMAP_TIMER_TRIGGER_OVERFLOW 0x01 44 + #define OMAP_TIMER_TRIGGER_OVERFLOW_AND_COMPARE 0x02 58 45 59 - struct omap_dm_timer { 60 - struct list_head timer_list; 46 + struct omap_dm_timer; 47 + struct clk; 61 48 62 - u32 base; 63 - unsigned int irq; 64 - }; 49 + int omap_dm_timer_init(void); 65 50 66 - u32 omap_dm_timer_read_reg(struct omap_dm_timer *timer, int reg); 67 - void omap_dm_timer_write_reg(struct omap_dm_timer *timer, int reg, u32 value); 68 - 69 - struct omap_dm_timer * omap_dm_timer_request(void); 51 + struct omap_dm_timer *omap_dm_timer_request(void); 52 + struct omap_dm_timer *omap_dm_timer_request_specific(int timer_id); 70 53 void omap_dm_timer_free(struct omap_dm_timer *timer); 71 - void omap_dm_timer_set_source(struct omap_dm_timer *timer, int source); 72 54 73 - void omap_dm_timer_set_int_enable(struct omap_dm_timer *timer, unsigned int value); 74 - void omap_dm_timer_set_trigger(struct omap_dm_timer *timer, unsigned int value); 75 - void omap_dm_timer_enable_compare(struct omap_dm_timer *timer); 76 - void omap_dm_timer_enable_autoreload(struct omap_dm_timer *timer); 55 + int omap_dm_timer_get_irq(struct omap_dm_timer *timer); 56 + 57 + u32 omap_dm_timer_modify_idlect_mask(u32 inputmask); 58 + struct clk *omap_dm_timer_get_fclk(struct omap_dm_timer *timer); 77 59 78 60 void omap_dm_timer_trigger(struct omap_dm_timer *timer); 79 61 void omap_dm_timer_start(struct omap_dm_timer *timer); 80 62 void omap_dm_timer_stop(struct omap_dm_timer *timer); 81 63 82 - void omap_dm_timer_set_load(struct omap_dm_timer *timer, unsigned int load); 83 - void omap_dm_timer_set_match(struct omap_dm_timer *timer, unsigned int match); 64 + void omap_dm_timer_set_source(struct omap_dm_timer *timer, int source); 65 + void omap_dm_timer_set_load(struct omap_dm_timer *timer, int autoreload, unsigned int value); 66 + void omap_dm_timer_set_match(struct omap_dm_timer *timer, int enable, unsigned int match); 67 + void omap_dm_timer_set_pwm(struct omap_dm_timer *timer, int def_on, int toggle, int trigger); 68 + void omap_dm_timer_set_prescaler(struct omap_dm_timer *timer, int prescaler); 69 + 70 + void omap_dm_timer_set_int_enable(struct omap_dm_timer *timer, unsigned int value); 84 71 85 72 unsigned int omap_dm_timer_read_status(struct omap_dm_timer *timer); 86 73 void omap_dm_timer_write_status(struct omap_dm_timer *timer, unsigned int value); 87 - 88 74 unsigned int omap_dm_timer_read_counter(struct omap_dm_timer *timer); 89 - void omap_dm_timer_reset_counter(struct omap_dm_timer *timer); 75 + void omap_dm_timer_write_counter(struct omap_dm_timer *timer, unsigned int value); 90 76 91 77 int omap_dm_timers_active(void); 92 - u32 omap_dm_timer_modify_idlect_mask(u32 inputmask); 93 78 94 - #endif /* __ASM_ARCH_TIMER_H */ 79 + 80 + #endif /* __ASM_ARCH_DMTIMER_H */
+91
include/asm-arm/arch-omap/gpmc.h
··· 1 + /* 2 + * General-Purpose Memory Controller for OMAP2 3 + * 4 + * Copyright (C) 2005-2006 Nokia Corporation 5 + * 6 + * This program is free software; you can redistribute it and/or modify 7 + * it under the terms of the GNU General Public License version 2 as 8 + * published by the Free Software Foundation. 9 + */ 10 + 11 + #ifndef __OMAP2_GPMC_H 12 + #define __OMAP2_GPMC_H 13 + 14 + #define GPMC_CS_CONFIG1 0x00 15 + #define GPMC_CS_CONFIG2 0x04 16 + #define GPMC_CS_CONFIG3 0x08 17 + #define GPMC_CS_CONFIG4 0x0c 18 + #define GPMC_CS_CONFIG5 0x10 19 + #define GPMC_CS_CONFIG6 0x14 20 + #define GPMC_CS_CONFIG7 0x18 21 + #define GPMC_CS_NAND_COMMAND 0x1c 22 + #define GPMC_CS_NAND_ADDRESS 0x20 23 + #define GPMC_CS_NAND_DATA 0x24 24 + 25 + #define GPMC_CONFIG1_WRAPBURST_SUPP (1 << 31) 26 + #define GPMC_CONFIG1_READMULTIPLE_SUPP (1 << 20) 27 + #define GPMC_CONFIG1_READTYPE_ASYNC (0 << 29) 28 + #define GPMC_CONFIG1_READTYPE_SYNC (1 << 29) 29 + #define GPMC_CONFIG1_WRITETYPE_ASYNC (0 << 27) 30 + #define GPMC_CONFIG1_WRITETYPE_SYNC (1 << 27) 31 + #define GPMC_CONFIG1_CLKACTIVATIONTIME(val) ((val & 3) << 25) 32 + #define GPMC_CONFIG1_PAGE_LEN(val) ((val & 3) << 23) 33 + #define GPMC_CONFIG1_WAIT_READ_MON (1 << 22) 34 + #define GPMC_CONFIG1_WAIT_WRITE_MON (1 << 21) 35 + #define GPMC_CONFIG1_WAIT_MON_IIME(val) ((val & 3) << 18) 36 + #define GPMC_CONFIG1_WAIT_PIN_SEL(val) ((val & 3) << 16) 37 + #define GPMC_CONFIG1_DEVICESIZE(val) ((val & 3) << 12) 38 + #define GPMC_CONFIG1_DEVICESIZE_16 GPMC_CONFIG1_DEVICESIZE(1) 39 + #define GPMC_CONFIG1_DEVICETYPE(val) ((val & 3) << 10) 40 + #define GPMC_CONFIG1_DEVICETYPE_NOR GPMC_CONFIG1_DEVICETYPE(0) 41 + #define GPMC_CONFIG1_DEVICETYPE_NAND GPMC_CONFIG1_DEVICETYPE(1) 42 + #define GPMC_CONFIG1_MUXADDDATA (1 << 9) 43 + #define GPMC_CONFIG1_TIME_PARA_GRAN (1 << 4) 44 + #define GPMC_CONFIG1_FCLK_DIV(val) (val & 3) 45 + #define GPMC_CONFIG1_FCLK_DIV2 (GPMC_CONFIG1_FCLK_DIV(1)) 46 + #define GPMC_CONFIG1_FCLK_DIV3 (GPMC_CONFIG1_FCLK_DIV(2)) 47 + #define GPMC_CONFIG1_FCLK_DIV4 (GPMC_CONFIG1_FCLK_DIV(3)) 48 + 49 + /* 50 + * Note that all values in this struct are in nanoseconds, while 51 + * the register values are in gpmc_fck cycles. 52 + */ 53 + struct gpmc_timings { 54 + /* Minimum clock period for synchronous mode */ 55 + u16 sync_clk; 56 + 57 + /* Chip-select signal timings corresponding to GPMC_CS_CONFIG2 */ 58 + u16 cs_on; /* Assertion time */ 59 + u16 cs_rd_off; /* Read deassertion time */ 60 + u16 cs_wr_off; /* Write deassertion time */ 61 + 62 + /* ADV signal timings corresponding to GPMC_CONFIG3 */ 63 + u16 adv_on; /* Assertion time */ 64 + u16 adv_rd_off; /* Read deassertion time */ 65 + u16 adv_wr_off; /* Write deassertion time */ 66 + 67 + /* WE signals timings corresponding to GPMC_CONFIG4 */ 68 + u16 we_on; /* WE assertion time */ 69 + u16 we_off; /* WE deassertion time */ 70 + 71 + /* OE signals timings corresponding to GPMC_CONFIG4 */ 72 + u16 oe_on; /* OE assertion time */ 73 + u16 oe_off; /* OE deassertion time */ 74 + 75 + /* Access time and cycle time timings corresponding to GPMC_CONFIG5 */ 76 + u16 page_burst_access; /* Multiple access word delay */ 77 + u16 access; /* Start-cycle to first data valid delay */ 78 + u16 rd_cycle; /* Total read cycle time */ 79 + u16 wr_cycle; /* Total write cycle time */ 80 + }; 81 + 82 + extern unsigned int gpmc_ns_to_ticks(unsigned int time_ns); 83 + 84 + extern void gpmc_cs_write_reg(int cs, int idx, u32 val); 85 + extern u32 gpmc_cs_read_reg(int cs, int idx); 86 + extern int gpmc_cs_calc_divider(int cs, unsigned int sync_clk); 87 + extern int gpmc_cs_set_timings(int cs, const struct gpmc_timings *t); 88 + extern unsigned long gpmc_cs_get_base_addr(int cs); 89 + 90 + 91 + #endif
+4
include/asm-arm/arch-omap/hardware.h
··· 297 297 #include "board-perseus2.h" 298 298 #endif 299 299 300 + #ifdef CONFIG_MACH_OMAP_FSAMPLE 301 + #include "board-fsample.h" 302 + #endif 303 + 300 304 #ifdef CONFIG_MACH_OMAP_H3 301 305 #include "board-h3.h" 302 306 #endif
+14
include/asm-arm/arch-omap/irqs.h
··· 242 242 #define INT_24XX_GPIO_BANK2 30 243 243 #define INT_24XX_GPIO_BANK3 31 244 244 #define INT_24XX_GPIO_BANK4 32 245 + #define INT_24XX_GPTIMER1 37 246 + #define INT_24XX_GPTIMER2 38 247 + #define INT_24XX_GPTIMER3 39 248 + #define INT_24XX_GPTIMER4 40 249 + #define INT_24XX_GPTIMER5 41 250 + #define INT_24XX_GPTIMER6 42 251 + #define INT_24XX_GPTIMER7 43 252 + #define INT_24XX_GPTIMER8 44 253 + #define INT_24XX_GPTIMER9 45 254 + #define INT_24XX_GPTIMER10 46 255 + #define INT_24XX_GPTIMER11 47 256 + #define INT_24XX_GPTIMER12 48 245 257 #define INT_24XX_MCBSP1_IRQ_TX 59 246 258 #define INT_24XX_MCBSP1_IRQ_RX 60 247 259 #define INT_24XX_MCBSP2_IRQ_TX 62 248 260 #define INT_24XX_MCBSP2_IRQ_RX 63 261 + #define INT_24XX_UART1_IRQ 72 262 + #define INT_24XX_UART2_IRQ 73 249 263 #define INT_24XX_UART3_IRQ 74 250 264 251 265 /* Max. 128 level 2 IRQs (OMAP1610), 192 GPIOs (OMAP730) and
+26
include/asm-arm/arch-omap/mux.h
··· 410 410 /* 24xx clock */ 411 411 W14_24XX_SYS_CLKOUT, 412 412 413 + /* 24xx GPMC wait pin monitoring */ 414 + L3_GPMC_WAIT0, 415 + N7_GPMC_WAIT1, 416 + M1_GPMC_WAIT2, 417 + P1_GPMC_WAIT3, 418 + 413 419 /* 242X McBSP */ 414 420 Y15_24XX_MCBSP2_CLKX, 415 421 R14_24XX_MCBSP2_FSX, ··· 434 428 W4__24XX_GPIO74, 435 429 M15_24XX_GPIO92, 436 430 V14_24XX_GPIO117, 431 + 432 + /* 242x DBG GPIO */ 433 + V4_242X_GPIO49, 434 + W2_242X_GPIO50, 435 + U4_242X_GPIO51, 436 + V3_242X_GPIO52, 437 + V2_242X_GPIO53, 438 + V6_242X_GPIO53, 439 + T4_242X_GPIO54, 440 + Y4_242X_GPIO54, 441 + T3_242X_GPIO55, 442 + U2_242X_GPIO56, 443 + 444 + /* 24xx external DMA requests */ 445 + AA10_242X_DMAREQ0, 446 + AA6_242X_DMAREQ1, 447 + E4_242X_DMAREQ2, 448 + G4_242X_DMAREQ3, 449 + D3_242X_DMAREQ4, 450 + E3_242X_DMAREQ5, 437 451 438 452 P20_24XX_TSC_IRQ, 439 453
+33
include/asm-arm/arch-omap/pm.h
··· 299 299 OMAP24XX_SLEEP_SAVE_INTC_MIR0, 300 300 OMAP24XX_SLEEP_SAVE_INTC_MIR1, 301 301 OMAP24XX_SLEEP_SAVE_INTC_MIR2, 302 + 303 + OMAP24XX_SLEEP_SAVE_CM_CLKSTCTRL_MPU, 304 + OMAP24XX_SLEEP_SAVE_CM_CLKSTCTRL_CORE, 305 + OMAP24XX_SLEEP_SAVE_CM_CLKSTCTRL_GFX, 306 + OMAP24XX_SLEEP_SAVE_CM_CLKSTCTRL_DSP, 307 + OMAP24XX_SLEEP_SAVE_CM_CLKSTCTRL_MDM, 308 + 309 + OMAP24XX_SLEEP_SAVE_PM_PWSTCTRL_MPU, 310 + OMAP24XX_SLEEP_SAVE_PM_PWSTCTRL_CORE, 311 + OMAP24XX_SLEEP_SAVE_PM_PWSTCTRL_GFX, 312 + OMAP24XX_SLEEP_SAVE_PM_PWSTCTRL_DSP, 313 + OMAP24XX_SLEEP_SAVE_PM_PWSTCTRL_MDM, 314 + 315 + OMAP24XX_SLEEP_SAVE_CM_IDLEST1_CORE, 316 + OMAP24XX_SLEEP_SAVE_CM_IDLEST2_CORE, 317 + OMAP24XX_SLEEP_SAVE_CM_IDLEST3_CORE, 318 + OMAP24XX_SLEEP_SAVE_CM_IDLEST4_CORE, 319 + OMAP24XX_SLEEP_SAVE_CM_IDLEST_GFX, 320 + OMAP24XX_SLEEP_SAVE_CM_IDLEST_WKUP, 321 + OMAP24XX_SLEEP_SAVE_CM_IDLEST_CKGEN, 322 + OMAP24XX_SLEEP_SAVE_CM_IDLEST_DSP, 323 + OMAP24XX_SLEEP_SAVE_CM_IDLEST_MDM, 324 + 325 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE1_CORE, 326 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE2_CORE, 327 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE3_CORE, 328 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE4_CORE, 329 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE_WKUP, 330 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE_PLL, 331 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE_DSP, 332 + OMAP24XX_SLEEP_SAVE_CM_AUTOIDLE_MDM, 333 + 302 334 OMAP24XX_SLEEP_SAVE_CM_FCLKEN1_CORE, 303 335 OMAP24XX_SLEEP_SAVE_CM_FCLKEN2_CORE, 304 336 OMAP24XX_SLEEP_SAVE_CM_ICLKEN1_CORE, 305 337 OMAP24XX_SLEEP_SAVE_CM_ICLKEN2_CORE, 338 + OMAP24XX_SLEEP_SAVE_CM_ICLKEN3_CORE, 306 339 OMAP24XX_SLEEP_SAVE_CM_ICLKEN4_CORE, 307 340 OMAP24XX_SLEEP_SAVE_GPIO1_IRQENABLE1, 308 341 OMAP24XX_SLEEP_SAVE_GPIO2_IRQENABLE1,
+2
include/asm-arm/arch-pxa/pxa-regs.h
··· 1329 1329 #define GPIO84_NSRXD 84 /* NSSP receive */ 1330 1330 #define GPIO85_nPCE_1 85 /* Card Enable for Card Space (PXA27x) */ 1331 1331 #define GPIO92_MMCDAT0 92 /* MMC DAT0 (PXA27x) */ 1332 + #define GPIO102_nPCE_1 102 /* PCMCIA (PXA27x) */ 1332 1333 #define GPIO109_MMCDAT1 109 /* MMC DAT1 (PXA27x) */ 1333 1334 #define GPIO110_MMCDAT2 110 /* MMC DAT2 (PXA27x) */ 1334 1335 #define GPIO110_MMCCS0 110 /* MMC Chip Select 0 (PXA27x) */ ··· 1472 1471 #define GPIO84_NSSP_RX (84 | GPIO_ALT_FN_2_IN) 1473 1472 #define GPIO85_nPCE_1_MD (85 | GPIO_ALT_FN_1_OUT) 1474 1473 #define GPIO92_MMCDAT0_MD (92 | GPIO_ALT_FN_1_OUT) 1474 + #define GPIO102_nPCE_1_MD (102 | GPIO_ALT_FN_1_OUT) 1475 1475 #define GPIO104_pSKTSEL_MD (104 | GPIO_ALT_FN_1_OUT) 1476 1476 #define GPIO109_MMCDAT1_MD (109 | GPIO_ALT_FN_1_OUT) 1477 1477 #define GPIO110_MMCDAT2_MD (110 | GPIO_ALT_FN_1_OUT)
+106
include/asm-arm/arch-pxa/trizeps4.h
··· 1 + /************************************************************************ 2 + * Include file for TRIZEPS4 SoM and ConXS eval-board 3 + * Copyright (c) Jürgen Schindele 4 + * 2006 5 + ************************************************************************/ 6 + 7 + /* 8 + * Includes/Defines 9 + */ 10 + #ifndef _TRIPEPS4_H_ 11 + #define _TRIPEPS4_H_ 12 + 13 + /* physical memory regions */ 14 + #define TRIZEPS4_FLASH_PHYS (PXA_CS0_PHYS) /* Flash region */ 15 + #define TRIZEPS4_DISK_PHYS (PXA_CS1_PHYS) /* Disk On Chip region */ 16 + #define TRIZEPS4_ETH_PHYS (PXA_CS2_PHYS) /* Ethernet DM9000 region */ 17 + #define TRIZEPS4_PIC_PHYS (PXA_CS3_PHYS) /* Logic chip on ConXS-Board */ 18 + #define TRIZEPS4_SDRAM_BASE 0xa0000000 /* SDRAM region */ 19 + 20 + #define TRIZEPS4_CFSR_PHYS (PXA_CS3_PHYS) /* Logic chip on ConXS-Board CSFR register */ 21 + #define TRIZEPS4_BOCR_PHYS (PXA_CS3_PHYS+0x02000000) /* Logic chip on ConXS-Board BOCR register */ 22 + #define TRIZEPS4_IRCR_PHYS (PXA_CS3_PHYS+0x02400000) /* Logic chip on ConXS-Board IRCR register*/ 23 + #define TRIZEPS4_UPSR_PHYS (PXA_CS3_PHYS+0x02800000) /* Logic chip on ConXS-Board UPSR register*/ 24 + #define TRIZEPS4_DICR_PHYS (PXA_CS3_PHYS+0x03800000) /* Logic chip on ConXS-Board DICR register*/ 25 + 26 + /* virtual memory regions */ 27 + #define TRIZEPS4_DISK_VIRT 0xF0000000 /* Disk On Chip region */ 28 + 29 + #define TRIZEPS4_PIC_VIRT 0xF0100000 /* not used */ 30 + #define TRIZEPS4_CFSR_VIRT 0xF0100000 31 + #define TRIZEPS4_BOCR_VIRT 0xF0200000 32 + #define TRIZEPS4_DICR_VIRT 0xF0300000 33 + #define TRIZEPS4_IRCR_VIRT 0xF0400000 34 + #define TRIZEPS4_UPSR_VIRT 0xF0500000 35 + 36 + /* size of flash */ 37 + #define TRIZEPS4_FLASH_SIZE 0x02000000 /* Flash size 32 MB */ 38 + 39 + /* Ethernet Controller Davicom DM9000 */ 40 + #define GPIO_DM9000 101 41 + #define TRIZEPS4_ETH_IRQ IRQ_GPIO(GPIO_DM9000) 42 + 43 + /* UCB1400 audio / TS-controller */ 44 + #define GPIO_UCB1400 1 45 + #define TRIZEPS4_UCB1400_IRQ IRQ_GPIO(GPIO_UCB1400) 46 + 47 + /* PCMCIA socket Compact Flash */ 48 + #define GPIO_PCD 11 /* PCMCIA Card Detect */ 49 + #define TRIZEPS4_CD_IRQ IRQ_GPIO(GPIO_PCD) 50 + #define GPIO_PRDY 13 /* READY / nINT */ 51 + #define TRIZEPS4_READY_NINT IRQ_GPIO(GPIO_PRDY) 52 + 53 + /* MMC socket */ 54 + #define GPIO_MMC_DET 12 55 + #define TRIZEPS4_MMC_IRQ IRQ_GPIO(GPIO_MMC_DET) 56 + 57 + /* LEDS using tx2 / rx2 */ 58 + #define GPIO_SYS_BUSY_LED 46 59 + #define GPIO_HEARTBEAT_LED 47 60 + 61 + /* Off-module PIC on ConXS board */ 62 + #define GPIO_PIC 0 63 + #define TRIZEPS4_PIC_IRQ IRQ_GPIO(GPIO_PIC) 64 + 65 + #define CFSR_P2V(x) ((x) - TRIZEPS4_CFSR_PHYS + TRIZEPS4_CFSR_VIRT) 66 + #define CFSR_V2P(x) ((x) - TRIZEPS4_CFSR_VIRT + TRIZEPS4_CFSR_PHYS) 67 + 68 + #define BCR_P2V(x) ((x) - TRIZEPS4_BOCR_PHYS + TRIZEPS4_BOCR_VIRT) 69 + #define BCR_V2P(x) ((x) - TRIZEPS4_BOCR_VIRT + TRIZEPS4_BOCR_PHYS) 70 + 71 + #define DCR_P2V(x) ((x) - TRIZEPS4_DICR_PHYS + TRIZEPS4_DICR_VIRT) 72 + #define DCR_V2P(x) ((x) - TRIZEPS4_DICR_VIRT + TRIZEPS4_DICR_PHYS) 73 + 74 + #ifndef __ASSEMBLY__ 75 + #define ConXS_CFSR (*((volatile unsigned short *)CFSR_P2V(0x0C000000))) 76 + #define ConXS_BCR (*((volatile unsigned short *)BCR_P2V(0x0E000000))) 77 + #define ConXS_DCR (*((volatile unsigned short *)DCR_P2V(0x0F800000))) 78 + #else 79 + #define ConXS_CFSR CFSR_P2V(0x0C000000) 80 + #define ConXS_BCR BCR_P2V(0x0E000000) 81 + #define ConXS_DCR DCR_P2V(0x0F800000) 82 + #endif 83 + 84 + #define ConXS_CFSR_BVD_MASK 0x0003 85 + #define ConXS_CFSR_BVD1 (1 << 0) 86 + #define ConXS_CFSR_BVD2 (1 << 1) 87 + #define ConXS_CFSR_VS_MASK 0x000C 88 + #define ConXS_CFSR_VS1 (1 << 2) 89 + #define ConXS_CFSR_VS2 (1 << 3) 90 + #define ConXS_CFSR_VS_5V (0x3 << 2) 91 + #define ConXS_CFSR_VS_3V3 0x0 92 + 93 + #define ConXS_BCR_S0_POW_EN0 (1 << 0) 94 + #define ConXS_BCR_S0_POW_EN1 (1 << 1) 95 + #define ConXS_BCR_L_DISP (1 << 4) 96 + #define ConXS_BCR_CF_BUF_EN (1 << 5) 97 + #define ConXS_BCR_CF_RESET (1 << 7) 98 + #define ConXS_BCR_S0_VCC_3V3 0x1 99 + #define ConXS_BCR_S0_VCC_5V0 0x2 100 + #define ConXS_BCR_S0_VPP_12V 0x4 101 + #define ConXS_BCR_S0_VPP_3V3 0x8 102 + 103 + #define ConXS_IRCR_MODE (1 << 0) 104 + #define ConXS_IRCR_SD (1 << 1) 105 + 106 + #endif /* _TRIPEPS4_H_ */
+5
include/asm-arm/memory.h
··· 68 68 */ 69 69 #define XIP_VIRT_ADDR(physaddr) (MODULE_START + ((physaddr) & 0x000fffff)) 70 70 71 + /* 72 + * Allow 16MB-aligned ioremap pages 73 + */ 74 + #define IOREMAP_MAX_ORDER 24 75 + 71 76 #else /* CONFIG_MMU */ 72 77 73 78 /*
+1
include/asm-arm/mmu.h
··· 7 7 #if __LINUX_ARM_ARCH__ >= 6 8 8 unsigned int id; 9 9 #endif 10 + unsigned int kvm_seq; 10 11 } mm_context_t; 11 12 12 13 #if __LINUX_ARM_ARCH__ >= 6
+11 -1
include/asm-arm/mmu_context.h
··· 17 17 #include <asm/cacheflush.h> 18 18 #include <asm/proc-fns.h> 19 19 20 + void __check_kvm_seq(struct mm_struct *mm); 21 + 20 22 #if __LINUX_ARM_ARCH__ >= 6 21 23 22 24 /* ··· 47 45 { 48 46 if (unlikely((mm->context.id ^ cpu_last_asid) >> ASID_BITS)) 49 47 __new_context(mm); 48 + 49 + if (unlikely(mm->context.kvm_seq != init_mm.context.kvm_seq)) 50 + __check_kvm_seq(mm); 50 51 } 51 52 52 53 #define init_new_context(tsk,mm) (__init_new_context(tsk,mm),0) 53 54 54 55 #else 55 56 56 - #define check_context(mm) do { } while (0) 57 + static inline void check_context(struct mm_struct *mm) 58 + { 59 + if (unlikely(mm->context.kvm_seq != init_mm.context.kvm_seq)) 60 + __check_kvm_seq(mm); 61 + } 62 + 57 63 #define init_new_context(tsk,mm) 0 58 64 59 65 #endif
+1
include/asm-arm/pgtable-hwdef.h
··· 28 28 */ 29 29 #define PMD_SECT_BUFFERABLE (1 << 2) 30 30 #define PMD_SECT_CACHEABLE (1 << 3) 31 + #define PMD_SECT_XN (1 << 4) /* v6 */ 31 32 #define PMD_SECT_AP_WRITE (1 << 10) 32 33 #define PMD_SECT_AP_READ (1 << 11) 33 34 #define PMD_SECT_TEX(x) ((x) << 12) /* v5 */
+2 -1
include/asm-arm/procinfo.h
··· 29 29 struct proc_info_list { 30 30 unsigned int cpu_val; 31 31 unsigned int cpu_mask; 32 - unsigned long __cpu_mmu_flags; /* used by head.S */ 32 + unsigned long __cpu_mm_mmu_flags; /* used by head.S */ 33 + unsigned long __cpu_io_mmu_flags; /* used by head.S */ 33 34 unsigned long __cpu_flush; /* used by head.S */ 34 35 const char *arch_name; 35 36 const char *elf_name;
+1
include/asm-arm/thread_info.h
··· 111 111 extern void iwmmxt_task_copy(struct thread_info *, void *); 112 112 extern void iwmmxt_task_restore(struct thread_info *, void *); 113 113 extern void iwmmxt_task_release(struct thread_info *); 114 + extern void iwmmxt_task_switch(struct thread_info *); 114 115 115 116 #endif 116 117