Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

docs: arm: convert docs to ReST and rename to *.rst

Converts ARM the text files to ReST, preparing them to be an
architecture book.

The conversion is actually:
- add blank lines and identation in order to identify paragraphs;
- fix tables markups;
- add some lists markups;
- mark literal blocks;
- adjust title markups.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Reviewed-by Corentin Labbe <clabbe.montjoie@gmail.com> # For sun4i-ss

+7564 -6999
-218
Documentation/arm/Booting
··· 1 - Booting ARM Linux 2 - ================= 3 - 4 - Author: Russell King 5 - Date : 18 May 2002 6 - 7 - The following documentation is relevant to 2.4.18-rmk6 and beyond. 8 - 9 - In order to boot ARM Linux, you require a boot loader, which is a small 10 - program that runs before the main kernel. The boot loader is expected 11 - to initialise various devices, and eventually call the Linux kernel, 12 - passing information to the kernel. 13 - 14 - Essentially, the boot loader should provide (as a minimum) the 15 - following: 16 - 17 - 1. Setup and initialise the RAM. 18 - 2. Initialise one serial port. 19 - 3. Detect the machine type. 20 - 4. Setup the kernel tagged list. 21 - 5. Load initramfs. 22 - 6. Call the kernel image. 23 - 24 - 25 - 1. Setup and initialise RAM 26 - --------------------------- 27 - 28 - Existing boot loaders: MANDATORY 29 - New boot loaders: MANDATORY 30 - 31 - The boot loader is expected to find and initialise all RAM that the 32 - kernel will use for volatile data storage in the system. It performs 33 - this in a machine dependent manner. (It may use internal algorithms 34 - to automatically locate and size all RAM, or it may use knowledge of 35 - the RAM in the machine, or any other method the boot loader designer 36 - sees fit.) 37 - 38 - 39 - 2. Initialise one serial port 40 - ----------------------------- 41 - 42 - Existing boot loaders: OPTIONAL, RECOMMENDED 43 - New boot loaders: OPTIONAL, RECOMMENDED 44 - 45 - The boot loader should initialise and enable one serial port on the 46 - target. This allows the kernel serial driver to automatically detect 47 - which serial port it should use for the kernel console (generally 48 - used for debugging purposes, or communication with the target.) 49 - 50 - As an alternative, the boot loader can pass the relevant 'console=' 51 - option to the kernel via the tagged lists specifying the port, and 52 - serial format options as described in 53 - 54 - Documentation/admin-guide/kernel-parameters.rst. 55 - 56 - 57 - 3. Detect the machine type 58 - -------------------------- 59 - 60 - Existing boot loaders: OPTIONAL 61 - New boot loaders: MANDATORY except for DT-only platforms 62 - 63 - The boot loader should detect the machine type its running on by some 64 - method. Whether this is a hard coded value or some algorithm that 65 - looks at the connected hardware is beyond the scope of this document. 66 - The boot loader must ultimately be able to provide a MACH_TYPE_xxx 67 - value to the kernel. (see linux/arch/arm/tools/mach-types). This 68 - should be passed to the kernel in register r1. 69 - 70 - For DT-only platforms, the machine type will be determined by device 71 - tree. set the machine type to all ones (~0). This is not strictly 72 - necessary, but assures that it will not match any existing types. 73 - 74 - 4. Setup boot data 75 - ------------------ 76 - 77 - Existing boot loaders: OPTIONAL, HIGHLY RECOMMENDED 78 - New boot loaders: MANDATORY 79 - 80 - The boot loader must provide either a tagged list or a dtb image for 81 - passing configuration data to the kernel. The physical address of the 82 - boot data is passed to the kernel in register r2. 83 - 84 - 4a. Setup the kernel tagged list 85 - -------------------------------- 86 - 87 - The boot loader must create and initialise the kernel tagged list. 88 - A valid tagged list starts with ATAG_CORE and ends with ATAG_NONE. 89 - The ATAG_CORE tag may or may not be empty. An empty ATAG_CORE tag 90 - has the size field set to '2' (0x00000002). The ATAG_NONE must set 91 - the size field to zero. 92 - 93 - Any number of tags can be placed in the list. It is undefined 94 - whether a repeated tag appends to the information carried by the 95 - previous tag, or whether it replaces the information in its 96 - entirety; some tags behave as the former, others the latter. 97 - 98 - The boot loader must pass at a minimum the size and location of 99 - the system memory, and root filesystem location. Therefore, the 100 - minimum tagged list should look: 101 - 102 - +-----------+ 103 - base -> | ATAG_CORE | | 104 - +-----------+ | 105 - | ATAG_MEM | | increasing address 106 - +-----------+ | 107 - | ATAG_NONE | | 108 - +-----------+ v 109 - 110 - The tagged list should be stored in system RAM. 111 - 112 - The tagged list must be placed in a region of memory where neither 113 - the kernel decompressor nor initrd 'bootp' program will overwrite 114 - it. The recommended placement is in the first 16KiB of RAM. 115 - 116 - 4b. Setup the device tree 117 - ------------------------- 118 - 119 - The boot loader must load a device tree image (dtb) into system ram 120 - at a 64bit aligned address and initialize it with the boot data. The 121 - dtb format is documented in Documentation/devicetree/booting-without-of.txt. 122 - The kernel will look for the dtb magic value of 0xd00dfeed at the dtb 123 - physical address to determine if a dtb has been passed instead of a 124 - tagged list. 125 - 126 - The boot loader must pass at a minimum the size and location of the 127 - system memory, and the root filesystem location. The dtb must be 128 - placed in a region of memory where the kernel decompressor will not 129 - overwrite it, while remaining within the region which will be covered 130 - by the kernel's low-memory mapping. 131 - 132 - A safe location is just above the 128MiB boundary from start of RAM. 133 - 134 - 5. Load initramfs. 135 - ------------------ 136 - 137 - Existing boot loaders: OPTIONAL 138 - New boot loaders: OPTIONAL 139 - 140 - If an initramfs is in use then, as with the dtb, it must be placed in 141 - a region of memory where the kernel decompressor will not overwrite it 142 - while also with the region which will be covered by the kernel's 143 - low-memory mapping. 144 - 145 - A safe location is just above the device tree blob which itself will 146 - be loaded just above the 128MiB boundary from the start of RAM as 147 - recommended above. 148 - 149 - 6. Calling the kernel image 150 - --------------------------- 151 - 152 - Existing boot loaders: MANDATORY 153 - New boot loaders: MANDATORY 154 - 155 - There are two options for calling the kernel zImage. If the zImage 156 - is stored in flash, and is linked correctly to be run from flash, 157 - then it is legal for the boot loader to call the zImage in flash 158 - directly. 159 - 160 - The zImage may also be placed in system RAM and called there. The 161 - kernel should be placed in the first 128MiB of RAM. It is recommended 162 - that it is loaded above 32MiB in order to avoid the need to relocate 163 - prior to decompression, which will make the boot process slightly 164 - faster. 165 - 166 - When booting a raw (non-zImage) kernel the constraints are tighter. 167 - In this case the kernel must be loaded at an offset into system equal 168 - to TEXT_OFFSET - PAGE_OFFSET. 169 - 170 - In any case, the following conditions must be met: 171 - 172 - - Quiesce all DMA capable devices so that memory does not get 173 - corrupted by bogus network packets or disk data. This will save 174 - you many hours of debug. 175 - 176 - - CPU register settings 177 - r0 = 0, 178 - r1 = machine type number discovered in (3) above. 179 - r2 = physical address of tagged list in system RAM, or 180 - physical address of device tree block (dtb) in system RAM 181 - 182 - - CPU mode 183 - All forms of interrupts must be disabled (IRQs and FIQs) 184 - 185 - For CPUs which do not include the ARM virtualization extensions, the 186 - CPU must be in SVC mode. (A special exception exists for Angel) 187 - 188 - CPUs which include support for the virtualization extensions can be 189 - entered in HYP mode in order to enable the kernel to make full use of 190 - these extensions. This is the recommended boot method for such CPUs, 191 - unless the virtualisations are already in use by a pre-installed 192 - hypervisor. 193 - 194 - If the kernel is not entered in HYP mode for any reason, it must be 195 - entered in SVC mode. 196 - 197 - - Caches, MMUs 198 - The MMU must be off. 199 - Instruction cache may be on or off. 200 - Data cache must be off. 201 - 202 - If the kernel is entered in HYP mode, the above requirements apply to 203 - the HYP mode configuration in addition to the ordinary PL1 (privileged 204 - kernel modes) configuration. In addition, all traps into the 205 - hypervisor must be disabled, and PL1 access must be granted for all 206 - peripherals and CPU resources for which this is architecturally 207 - possible. Except for entering in HYP mode, the system configuration 208 - should be such that a kernel which does not include support for the 209 - virtualization extensions can boot correctly without extra help. 210 - 211 - - The boot loader is expected to call the kernel image by jumping 212 - directly to the first instruction of the kernel image. 213 - 214 - On CPUs supporting the ARM instruction set, the entry must be 215 - made in ARM state, even for a Thumb-2 kernel. 216 - 217 - On CPUs supporting only the Thumb instruction set such as 218 - Cortex-M class CPUs, the entry must be made in Thumb state.
-172
Documentation/arm/IXP4xx
··· 1 - 2 - ------------------------------------------------------------------------- 3 - Release Notes for Linux on Intel's IXP4xx Network Processor 4 - 5 - Maintained by Deepak Saxena <dsaxena@plexity.net> 6 - ------------------------------------------------------------------------- 7 - 8 - 1. Overview 9 - 10 - Intel's IXP4xx network processor is a highly integrated SOC that 11 - is targeted for network applications, though it has become popular 12 - in industrial control and other areas due to low cost and power 13 - consumption. The IXP4xx family currently consists of several processors 14 - that support different network offload functions such as encryption, 15 - routing, firewalling, etc. The IXP46x family is an updated version which 16 - supports faster speeds, new memory and flash configurations, and more 17 - integration such as an on-chip I2C controller. 18 - 19 - For more information on the various versions of the CPU, see: 20 - 21 - http://developer.intel.com/design/network/products/npfamily/ixp4xx.htm 22 - 23 - Intel also made the IXCP1100 CPU for sometime which is an IXP4xx 24 - stripped of much of the network intelligence. 25 - 26 - 2. Linux Support 27 - 28 - Linux currently supports the following features on the IXP4xx chips: 29 - 30 - - Dual serial ports 31 - - PCI interface 32 - - Flash access (MTD/JFFS) 33 - - I2C through GPIO on IXP42x 34 - - GPIO for input/output/interrupts 35 - See arch/arm/mach-ixp4xx/include/mach/platform.h for access functions. 36 - - Timers (watchdog, OS) 37 - 38 - The following components of the chips are not supported by Linux and 39 - require the use of Intel's proprietary CSR software: 40 - 41 - - USB device interface 42 - - Network interfaces (HSS, Utopia, NPEs, etc) 43 - - Network offload functionality 44 - 45 - If you need to use any of the above, you need to download Intel's 46 - software from: 47 - 48 - http://developer.intel.com/design/network/products/npfamily/ixp425.htm 49 - 50 - DO NOT POST QUESTIONS TO THE LINUX MAILING LISTS REGARDING THE PROPRIETARY 51 - SOFTWARE. 52 - 53 - There are several websites that provide directions/pointers on using 54 - Intel's software: 55 - 56 - http://sourceforge.net/projects/ixp4xx-osdg/ 57 - Open Source Developer's Guide for using uClinux and the Intel libraries 58 - 59 - http://gatewaymaker.sourceforge.net/ 60 - Simple one page summary of building a gateway using an IXP425 and Linux 61 - 62 - http://ixp425.sourceforge.net/ 63 - ATM device driver for IXP425 that relies on Intel's libraries 64 - 65 - 3. Known Issues/Limitations 66 - 67 - 3a. Limited inbound PCI window 68 - 69 - The IXP4xx family allows for up to 256MB of memory but the PCI interface 70 - can only expose 64MB of that memory to the PCI bus. This means that if 71 - you are running with > 64MB, all PCI buffers outside of the accessible 72 - range will be bounced using the routines in arch/arm/common/dmabounce.c. 73 - 74 - 3b. Limited outbound PCI window 75 - 76 - IXP4xx provides two methods of accessing PCI memory space: 77 - 78 - 1) A direct mapped window from 0x48000000 to 0x4bffffff (64MB). 79 - To access PCI via this space, we simply ioremap() the BAR 80 - into the kernel and we can use the standard read[bwl]/write[bwl] 81 - macros. This is the preffered method due to speed but it 82 - limits the system to just 64MB of PCI memory. This can be 83 - problamatic if using video cards and other memory-heavy devices. 84 - 85 - 2) If > 64MB of memory space is required, the IXP4xx can be 86 - configured to use indirect registers to access PCI This allows 87 - for up to 128MB (0x48000000 to 0x4fffffff) of memory on the bus. 88 - The disadvantage of this is that every PCI access requires 89 - three local register accesses plus a spinlock, but in some 90 - cases the performance hit is acceptable. In addition, you cannot 91 - mmap() PCI devices in this case due to the indirect nature 92 - of the PCI window. 93 - 94 - By default, the direct method is used for performance reasons. If 95 - you need more PCI memory, enable the IXP4XX_INDIRECT_PCI config option. 96 - 97 - 3c. GPIO as Interrupts 98 - 99 - Currently the code only handles level-sensitive GPIO interrupts 100 - 101 - 4. Supported platforms 102 - 103 - ADI Engineering Coyote Gateway Reference Platform 104 - http://www.adiengineering.com/productsCoyote.html 105 - 106 - The ADI Coyote platform is reference design for those building 107 - small residential/office gateways. One NPE is connected to a 10/100 108 - interface, one to 4-port 10/100 switch, and the third to and ADSL 109 - interface. In addition, it also supports to POTs interfaces connected 110 - via SLICs. Note that those are not supported by Linux ATM. Finally, 111 - the platform has two mini-PCI slots used for 802.11[bga] cards. 112 - Finally, there is an IDE port hanging off the expansion bus. 113 - 114 - Gateworks Avila Network Platform 115 - http://www.gateworks.com/support/overview.php 116 - 117 - The Avila platform is basically and IXDP425 with the 4 PCI slots 118 - replaced with mini-PCI slots and a CF IDE interface hanging off 119 - the expansion bus. 120 - 121 - Intel IXDP425 Development Platform 122 - http://www.intel.com/design/network/products/npfamily/ixdpg425.htm 123 - 124 - This is Intel's standard reference platform for the IXDP425 and is 125 - also known as the Richfield board. It contains 4 PCI slots, 16MB 126 - of flash, two 10/100 ports and one ADSL port. 127 - 128 - Intel IXDP465 Development Platform 129 - http://www.intel.com/design/network/products/npfamily/ixdp465.htm 130 - 131 - This is basically an IXDP425 with an IXP465 and 32M of flash instead 132 - of just 16. 133 - 134 - Intel IXDPG425 Development Platform 135 - 136 - This is basically and ADI Coyote board with a NEC EHCI controller 137 - added. One issue with this board is that the mini-PCI slots only 138 - have the 3.3v line connected, so you can't use a PCI to mini-PCI 139 - adapter with an E100 card. So to NFS root you need to use either 140 - the CSR or a WiFi card and a ramdisk that BOOTPs and then does 141 - a pivot_root to NFS. 142 - 143 - Motorola PrPMC1100 Processor Mezanine Card 144 - http://www.fountainsys.com 145 - 146 - The PrPMC1100 is based on the IXCP1100 and is meant to plug into 147 - and IXP2400/2800 system to act as the system controller. It simply 148 - contains a CPU and 16MB of flash on the board and needs to be 149 - plugged into a carrier board to function. Currently Linux only 150 - supports the Motorola PrPMC carrier board for this platform. 151 - 152 - 5. TODO LIST 153 - 154 - - Add support for Coyote IDE 155 - - Add support for edge-based GPIO interrupts 156 - - Add support for CF IDE on expansion bus 157 - 158 - 6. Thanks 159 - 160 - The IXP4xx work has been funded by Intel Corp. and MontaVista Software, Inc. 161 - 162 - The following people have contributed patches/comments/etc: 163 - 164 - Lennerty Buytenhek 165 - Lutz Jaenicke 166 - Justin Mayfield 167 - Robert E. Ranslam 168 - [I know I've forgotten others, please email me to be added] 169 - 170 - ------------------------------------------------------------------------- 171 - 172 - Last Update: 01/04/2005
-167
Documentation/arm/Interrupts
··· 1 - 2.5.2-rmk5 2 - ---------- 3 - 4 - This is the first kernel that contains a major shake up of some of the 5 - major architecture-specific subsystems. 6 - 7 - Firstly, it contains some pretty major changes to the way we handle the 8 - MMU TLB. Each MMU TLB variant is now handled completely separately - 9 - we have TLB v3, TLB v4 (without write buffer), TLB v4 (with write buffer), 10 - and finally TLB v4 (with write buffer, with I TLB invalidate entry). 11 - There is more assembly code inside each of these functions, mainly to 12 - allow more flexible TLB handling for the future. 13 - 14 - Secondly, the IRQ subsystem. 15 - 16 - The 2.5 kernels will be having major changes to the way IRQs are handled. 17 - Unfortunately, this means that machine types that touch the irq_desc[] 18 - array (basically all machine types) will break, and this means every 19 - machine type that we currently have. 20 - 21 - Lets take an example. On the Assabet with Neponset, we have: 22 - 23 - GPIO25 IRR:2 24 - SA1100 ------------> Neponset -----------> SA1111 25 - IIR:1 26 - -----------> USAR 27 - IIR:0 28 - -----------> SMC9196 29 - 30 - The way stuff currently works, all SA1111 interrupts are mutually 31 - exclusive of each other - if you're processing one interrupt from the 32 - SA1111 and another comes in, you have to wait for that interrupt to 33 - finish processing before you can service the new interrupt. Eg, an 34 - IDE PIO-based interrupt on the SA1111 excludes all other SA1111 and 35 - SMC9196 interrupts until it has finished transferring its multi-sector 36 - data, which can be a long time. Note also that since we loop in the 37 - SA1111 IRQ handler, SA1111 IRQs can hold off SMC9196 IRQs indefinitely. 38 - 39 - 40 - The new approach brings several new ideas... 41 - 42 - We introduce the concept of a "parent" and a "child". For example, 43 - to the Neponset handler, the "parent" is GPIO25, and the "children"d 44 - are SA1111, SMC9196 and USAR. 45 - 46 - We also bring the idea of an IRQ "chip" (mainly to reduce the size of 47 - the irqdesc array). This doesn't have to be a real "IC"; indeed the 48 - SA11x0 IRQs are handled by two separate "chip" structures, one for 49 - GPIO0-10, and another for all the rest. It is just a container for 50 - the various operations (maybe this'll change to a better name). 51 - This structure has the following operations: 52 - 53 - struct irqchip { 54 - /* 55 - * Acknowledge the IRQ. 56 - * If this is a level-based IRQ, then it is expected to mask the IRQ 57 - * as well. 58 - */ 59 - void (*ack)(unsigned int irq); 60 - /* 61 - * Mask the IRQ in hardware. 62 - */ 63 - void (*mask)(unsigned int irq); 64 - /* 65 - * Unmask the IRQ in hardware. 66 - */ 67 - void (*unmask)(unsigned int irq); 68 - /* 69 - * Re-run the IRQ 70 - */ 71 - void (*rerun)(unsigned int irq); 72 - /* 73 - * Set the type of the IRQ. 74 - */ 75 - int (*type)(unsigned int irq, unsigned int, type); 76 - }; 77 - 78 - ack - required. May be the same function as mask for IRQs 79 - handled by do_level_IRQ. 80 - mask - required. 81 - unmask - required. 82 - rerun - optional. Not required if you're using do_level_IRQ for all 83 - IRQs that use this 'irqchip'. Generally expected to re-trigger 84 - the hardware IRQ if possible. If not, may call the handler 85 - directly. 86 - type - optional. If you don't support changing the type of an IRQ, 87 - it should be null so people can detect if they are unable to 88 - set the IRQ type. 89 - 90 - For each IRQ, we keep the following information: 91 - 92 - - "disable" depth (number of disable_irq()s without enable_irq()s) 93 - - flags indicating what we can do with this IRQ (valid, probe, 94 - noautounmask) as before 95 - - status of the IRQ (probing, enable, etc) 96 - - chip 97 - - per-IRQ handler 98 - - irqaction structure list 99 - 100 - The handler can be one of the 3 standard handlers - "level", "edge" and 101 - "simple", or your own specific handler if you need to do something special. 102 - 103 - The "level" handler is what we currently have - its pretty simple. 104 - "edge" knows about the brokenness of such IRQ implementations - that you 105 - need to leave the hardware IRQ enabled while processing it, and queueing 106 - further IRQ events should the IRQ happen again while processing. The 107 - "simple" handler is very basic, and does not perform any hardware 108 - manipulation, nor state tracking. This is useful for things like the 109 - SMC9196 and USAR above. 110 - 111 - So, what's changed? 112 - 113 - 1. Machine implementations must not write to the irqdesc array. 114 - 115 - 2. New functions to manipulate the irqdesc array. The first 4 are expected 116 - to be useful only to machine specific code. The last is recommended to 117 - only be used by machine specific code, but may be used in drivers if 118 - absolutely necessary. 119 - 120 - set_irq_chip(irq,chip) 121 - 122 - Set the mask/unmask methods for handling this IRQ 123 - 124 - set_irq_handler(irq,handler) 125 - 126 - Set the handler for this IRQ (level, edge, simple) 127 - 128 - set_irq_chained_handler(irq,handler) 129 - 130 - Set a "chained" handler for this IRQ - automatically 131 - enables this IRQ (eg, Neponset and SA1111 handlers). 132 - 133 - set_irq_flags(irq,flags) 134 - 135 - Set the valid/probe/noautoenable flags. 136 - 137 - set_irq_type(irq,type) 138 - 139 - Set active the IRQ edge(s)/level. This replaces the 140 - SA1111 INTPOL manipulation, and the set_GPIO_IRQ_edge() 141 - function. Type should be one of IRQ_TYPE_xxx defined in 142 - <linux/irq.h> 143 - 144 - 3. set_GPIO_IRQ_edge() is obsolete, and should be replaced by set_irq_type. 145 - 146 - 4. Direct access to SA1111 INTPOL is deprecated. Use set_irq_type instead. 147 - 148 - 5. A handler is expected to perform any necessary acknowledgement of the 149 - parent IRQ via the correct chip specific function. For instance, if 150 - the SA1111 is directly connected to a SA1110 GPIO, then you should 151 - acknowledge the SA1110 IRQ each time you re-read the SA1111 IRQ status. 152 - 153 - 6. For any child which doesn't have its own IRQ enable/disable controls 154 - (eg, SMC9196), the handler must mask or acknowledge the parent IRQ 155 - while the child handler is called, and the child handler should be the 156 - "simple" handler (not "edge" nor "level"). After the handler completes, 157 - the parent IRQ should be unmasked, and the status of all children must 158 - be re-checked for pending events. (see the Neponset IRQ handler for 159 - details). 160 - 161 - 7. fixup_irq() is gone, as is arch/arm/mach-*/include/mach/irq.h 162 - 163 - Please note that this will not solve all problems - some of them are 164 - hardware based. Mixing level-based and edge-based IRQs on the same 165 - parent signal (eg neponset) is one such area where a software based 166 - solution can't provide the full answer to low IRQ latency. 167 -
-395
Documentation/arm/Marvell/README
··· 1 - ARM Marvell SoCs 2 - ================ 3 - 4 - This document lists all the ARM Marvell SoCs that are currently 5 - supported in mainline by the Linux kernel. As the Marvell families of 6 - SoCs are large and complex, it is hard to understand where the support 7 - for a particular SoC is available in the Linux kernel. This document 8 - tries to help in understanding where those SoCs are supported, and to 9 - match them with their corresponding public datasheet, when available. 10 - 11 - Orion family 12 - ------------ 13 - 14 - Flavors: 15 - 88F5082 16 - 88F5181 17 - 88F5181L 18 - 88F5182 19 - Datasheet : http://www.embeddedarm.com/documentation/third-party/MV88F5182-datasheet.pdf 20 - Programmer's User Guide : http://www.embeddedarm.com/documentation/third-party/MV88F5182-opensource-manual.pdf 21 - User Manual : http://www.embeddedarm.com/documentation/third-party/MV88F5182-usermanual.pdf 22 - 88F5281 23 - Datasheet : http://www.ocmodshop.com/images/reviews/networking/qnap_ts409u/marvel_88f5281_data_sheet.pdf 24 - 88F6183 25 - Core: Feroceon 88fr331 (88f51xx) or 88fr531-vd (88f52xx) ARMv5 compatible 26 - Linux kernel mach directory: arch/arm/mach-orion5x 27 - Linux kernel plat directory: arch/arm/plat-orion 28 - 29 - Kirkwood family 30 - --------------- 31 - 32 - Flavors: 33 - 88F6282 a.k.a Armada 300 34 - Product Brief : http://www.marvell.com/embedded-processors/armada-300/assets/armada_310.pdf 35 - 88F6283 a.k.a Armada 310 36 - Product Brief : http://www.marvell.com/embedded-processors/armada-300/assets/armada_310.pdf 37 - 88F6190 38 - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6190-003_WEB.pdf 39 - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F619x_OpenSource.pdf 40 - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 41 - 88F6192 42 - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6192-003_ver1.pdf 43 - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F619x_OpenSource.pdf 44 - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 45 - 88F6182 46 - 88F6180 47 - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6180-003_ver1.pdf 48 - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F6180_OpenSource.pdf 49 - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 50 - 88F6281 51 - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6281-004_ver1.pdf 52 - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F6281_OpenSource.pdf 53 - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 54 - Homepage: http://www.marvell.com/embedded-processors/kirkwood/ 55 - Core: Feroceon 88fr131 ARMv5 compatible 56 - Linux kernel mach directory: arch/arm/mach-mvebu 57 - Linux kernel plat directory: none 58 - 59 - Discovery family 60 - ---------------- 61 - 62 - Flavors: 63 - MV78100 64 - Product Brief : http://www.marvell.com/embedded-processors/discovery-innovation/assets/MV78100-003_WEB.pdf 65 - Hardware Spec : http://www.marvell.com/embedded-processors/discovery-innovation/assets/HW_MV78100_OpenSource.pdf 66 - Functional Spec: http://www.marvell.com/embedded-processors/discovery-innovation/assets/FS_MV76100_78100_78200_OpenSource.pdf 67 - MV78200 68 - Product Brief : http://www.marvell.com/embedded-processors/discovery-innovation/assets/MV78200-002_WEB.pdf 69 - Hardware Spec : http://www.marvell.com/embedded-processors/discovery-innovation/assets/HW_MV78200_OpenSource.pdf 70 - Functional Spec: http://www.marvell.com/embedded-processors/discovery-innovation/assets/FS_MV76100_78100_78200_OpenSource.pdf 71 - MV76100 72 - Not supported by the Linux kernel. 73 - 74 - Core: Feroceon 88fr571-vd ARMv5 compatible 75 - 76 - Linux kernel mach directory: arch/arm/mach-mv78xx0 77 - Linux kernel plat directory: arch/arm/plat-orion 78 - 79 - EBU Armada family 80 - ----------------- 81 - 82 - Armada 370 Flavors: 83 - 88F6710 84 - 88F6707 85 - 88F6W11 86 - Product Brief: http://www.marvell.com/embedded-processors/armada-300/assets/Marvell_ARMADA_370_SoC.pdf 87 - Hardware Spec: http://www.marvell.com/embedded-processors/armada-300/assets/ARMADA370-datasheet.pdf 88 - Functional Spec: http://www.marvell.com/embedded-processors/armada-300/assets/ARMADA370-FunctionalSpec-datasheet.pdf 89 - Core: Sheeva ARMv7 compatible PJ4B 90 - 91 - Armada 375 Flavors: 92 - 88F6720 93 - Product Brief: http://www.marvell.com/embedded-processors/armada-300/assets/ARMADA_375_SoC-01_product_brief.pdf 94 - Core: ARM Cortex-A9 95 - 96 - Armada 38x Flavors: 97 - 88F6810 Armada 380 98 - 88F6820 Armada 385 99 - 88F6828 Armada 388 100 - Product infos: http://www.marvell.com/embedded-processors/armada-38x/ 101 - Functional Spec: https://marvellcorp.wufoo.com/forms/marvell-armada-38x-functional-specifications/ 102 - Core: ARM Cortex-A9 103 - 104 - Armada 39x Flavors: 105 - 88F6920 Armada 390 106 - 88F6928 Armada 398 107 - Product infos: http://www.marvell.com/embedded-processors/armada-39x/ 108 - Core: ARM Cortex-A9 109 - 110 - Armada XP Flavors: 111 - MV78230 112 - MV78260 113 - MV78460 114 - NOTE: not to be confused with the non-SMP 78xx0 SoCs 115 - Product Brief: http://www.marvell.com/embedded-processors/armada-xp/assets/Marvell-ArmadaXP-SoC-product%20brief.pdf 116 - Functional Spec: http://www.marvell.com/embedded-processors/armada-xp/assets/ARMADA-XP-Functional-SpecDatasheet.pdf 117 - Hardware Specs: 118 - http://www.marvell.com/embedded-processors/armada-xp/assets/HW_MV78230_OS.PDF 119 - http://www.marvell.com/embedded-processors/armada-xp/assets/HW_MV78260_OS.PDF 120 - http://www.marvell.com/embedded-processors/armada-xp/assets/HW_MV78460_OS.PDF 121 - Core: Sheeva ARMv7 compatible Dual-core or Quad-core PJ4B-MP 122 - 123 - Linux kernel mach directory: arch/arm/mach-mvebu 124 - Linux kernel plat directory: none 125 - 126 - EBU Armada family ARMv8 127 - ----------------------- 128 - 129 - Armada 3710/3720 Flavors: 130 - 88F3710 131 - 88F3720 132 - Core: ARM Cortex A53 (ARMv8) 133 - 134 - Homepage: http://www.marvell.com/embedded-processors/armada-3700/ 135 - Product Brief: http://www.marvell.com/embedded-processors/assets/PB-88F3700-FNL.pdf 136 - Device tree files: arch/arm64/boot/dts/marvell/armada-37* 137 - 138 - Armada 7K Flavors: 139 - 88F7020 (AP806 Dual + one CP110) 140 - 88F7040 (AP806 Quad + one CP110) 141 - Core: ARM Cortex A72 142 - 143 - Homepage: http://www.marvell.com/embedded-processors/armada-70xx/ 144 - Product Brief: http://www.marvell.com/embedded-processors/assets/Armada7020PB-Jan2016.pdf 145 - http://www.marvell.com/embedded-processors/assets/Armada7040PB-Jan2016.pdf 146 - Device tree files: arch/arm64/boot/dts/marvell/armada-70* 147 - 148 - Armada 8K Flavors: 149 - 88F8020 (AP806 Dual + two CP110) 150 - 88F8040 (AP806 Quad + two CP110) 151 - Core: ARM Cortex A72 152 - 153 - Homepage: http://www.marvell.com/embedded-processors/armada-80xx/ 154 - Product Brief: http://www.marvell.com/embedded-processors/assets/Armada8020PB-Jan2016.pdf 155 - http://www.marvell.com/embedded-processors/assets/Armada8040PB-Jan2016.pdf 156 - Device tree files: arch/arm64/boot/dts/marvell/armada-80* 157 - 158 - Avanta family 159 - ------------- 160 - 161 - Flavors: 162 - 88F6510 163 - 88F6530P 164 - 88F6550 165 - 88F6560 166 - Homepage : http://www.marvell.com/broadband/ 167 - Product Brief: http://www.marvell.com/broadband/assets/Marvell_Avanta_88F6510_305_060-001_product_brief.pdf 168 - No public datasheet available. 169 - 170 - Core: ARMv5 compatible 171 - 172 - Linux kernel mach directory: no code in mainline yet, planned for the future 173 - Linux kernel plat directory: no code in mainline yet, planned for the future 174 - 175 - Storage family 176 - -------------- 177 - 178 - Armada SP: 179 - 88RC1580 180 - Product infos: http://www.marvell.com/storage/armada-sp/ 181 - Core: Sheeva ARMv7 comatible Quad-core PJ4C 182 - (not supported in upstream Linux kernel) 183 - 184 - Dove family (application processor) 185 - ----------------------------------- 186 - 187 - Flavors: 188 - 88AP510 a.k.a Armada 510 189 - Product Brief : http://www.marvell.com/application-processors/armada-500/assets/Marvell_Armada510_SoC.pdf 190 - Hardware Spec : http://www.marvell.com/application-processors/armada-500/assets/Armada-510-Hardware-Spec.pdf 191 - Functional Spec : http://www.marvell.com/application-processors/armada-500/assets/Armada-510-Functional-Spec.pdf 192 - Homepage: http://www.marvell.com/application-processors/armada-500/ 193 - Core: ARMv7 compatible 194 - 195 - Directory: arch/arm/mach-mvebu (DT enabled platforms) 196 - arch/arm/mach-dove (non-DT enabled platforms) 197 - 198 - PXA 2xx/3xx/93x/95x family 199 - -------------------------- 200 - 201 - Flavors: 202 - PXA21x, PXA25x, PXA26x 203 - Application processor only 204 - Core: ARMv5 XScale1 core 205 - PXA270, PXA271, PXA272 206 - Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_pb.pdf 207 - Design guide : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_design_guide.pdf 208 - Developers manual : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_dev_man.pdf 209 - Specification : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_emts.pdf 210 - Specification update : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_spec_update.pdf 211 - Application processor only 212 - Core: ARMv5 XScale2 core 213 - PXA300, PXA310, PXA320 214 - PXA 300 Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/PXA300_PB_R4.pdf 215 - PXA 310 Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/PXA310_PB_R4.pdf 216 - PXA 320 Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/PXA320_PB_R4.pdf 217 - Design guide : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_Design_Guide.pdf 218 - Developers manual : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_Developers_Manual.zip 219 - Specifications : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_EMTS.pdf 220 - Specification Update : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_Spec_Update.zip 221 - Reference Manual : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_TavorP_BootROM_Ref_Manual.pdf 222 - Application processor only 223 - Core: ARMv5 XScale3 core 224 - PXA930, PXA935 225 - Application processor with Communication processor 226 - Core: ARMv5 XScale3 core 227 - PXA955 228 - Application processor with Communication processor 229 - Core: ARMv7 compatible Sheeva PJ4 core 230 - 231 - Comments: 232 - 233 - * This line of SoCs originates from the XScale family developed by 234 - Intel and acquired by Marvell in ~2006. The PXA21x, PXA25x, 235 - PXA26x, PXA27x, PXA3xx and PXA93x were developed by Intel, while 236 - the later PXA95x were developed by Marvell. 237 - 238 - * Due to their XScale origin, these SoCs have virtually nothing in 239 - common with the other (Kirkwood, Dove, etc.) families of Marvell 240 - SoCs, except with the MMP/MMP2 family of SoCs. 241 - 242 - Linux kernel mach directory: arch/arm/mach-pxa 243 - Linux kernel plat directory: arch/arm/plat-pxa 244 - 245 - MMP/MMP2/MMP3 family (communication processor) 246 - ----------------------------------------- 247 - 248 - Flavors: 249 - PXA168, a.k.a Armada 168 250 - Homepage : http://www.marvell.com/application-processors/armada-100/armada-168.jsp 251 - Product brief : http://www.marvell.com/application-processors/armada-100/assets/pxa_168_pb.pdf 252 - Hardware manual : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_datasheet.pdf 253 - Software manual : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_software_manual.pdf 254 - Specification update : http://www.marvell.com/application-processors/armada-100/assets/ARMADA16x_Spec_update.pdf 255 - Boot ROM manual : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_ref_manual.pdf 256 - App node package : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_app_note_package.pdf 257 - Application processor only 258 - Core: ARMv5 compatible Marvell PJ1 88sv331 (Mohawk) 259 - PXA910/PXA920 260 - Homepage : http://www.marvell.com/communication-processors/pxa910/ 261 - Product Brief : http://www.marvell.com/communication-processors/pxa910/assets/Marvell_PXA910_Platform-001_PB_final.pdf 262 - Application processor with Communication processor 263 - Core: ARMv5 compatible Marvell PJ1 88sv331 (Mohawk) 264 - PXA688, a.k.a. MMP2, a.k.a Armada 610 265 - Product Brief : http://www.marvell.com/application-processors/armada-600/assets/armada610_pb.pdf 266 - Application processor only 267 - Core: ARMv7 compatible Sheeva PJ4 88sv581x core 268 - PXA2128, a.k.a. MMP3 (OLPC XO4, Linux support not upstream) 269 - Product Brief : http://www.marvell.com/application-processors/armada/pxa2128/assets/Marvell-ARMADA-PXA2128-SoC-PB.pdf 270 - Application processor only 271 - Core: Dual-core ARMv7 compatible Sheeva PJ4C core 272 - PXA960/PXA968/PXA978 (Linux support not upstream) 273 - Application processor with Communication Processor 274 - Core: ARMv7 compatible Sheeva PJ4 core 275 - PXA986/PXA988 (Linux support not upstream) 276 - Application processor with Communication Processor 277 - Core: Dual-core ARMv7 compatible Sheeva PJ4B-MP core 278 - PXA1088/PXA1920 (Linux support not upstream) 279 - Application processor with Communication Processor 280 - Core: quad-core ARMv7 Cortex-A7 281 - PXA1908/PXA1928/PXA1936 282 - Application processor with Communication Processor 283 - Core: multi-core ARMv8 Cortex-A53 284 - 285 - Comments: 286 - 287 - * This line of SoCs originates from the XScale family developed by 288 - Intel and acquired by Marvell in ~2006. All the processors of 289 - this MMP/MMP2 family were developed by Marvell. 290 - 291 - * Due to their XScale origin, these SoCs have virtually nothing in 292 - common with the other (Kirkwood, Dove, etc.) families of Marvell 293 - SoCs, except with the PXA family of SoCs listed above. 294 - 295 - Linux kernel mach directory: arch/arm/mach-mmp 296 - Linux kernel plat directory: arch/arm/plat-pxa 297 - 298 - Berlin family (Multimedia Solutions) 299 - ------------------------------------- 300 - 301 - Flavors: 302 - 88DE3010, Armada 1000 (no Linux support) 303 - Core: Marvell PJ1 (ARMv5TE), Dual-core 304 - Product Brief: http://www.marvell.com.cn/digital-entertainment/assets/armada_1000_pb.pdf 305 - 88DE3005, Armada 1500 Mini 306 - Design name: BG2CD 307 - Core: ARM Cortex-A9, PL310 L2CC 308 - 88DE3006, Armada 1500 Mini Plus 309 - Design name: BG2CDP 310 - Core: Dual Core ARM Cortex-A7 311 - 88DE3100, Armada 1500 312 - Design name: BG2 313 - Core: Marvell PJ4B-MP (ARMv7), Tauros3 L2CC 314 - 88DE3114, Armada 1500 Pro 315 - Design name: BG2Q 316 - Core: Quad Core ARM Cortex-A9, PL310 L2CC 317 - 88DE3214, Armada 1500 Pro 4K 318 - Design name: BG3 319 - Core: ARM Cortex-A15, CA15 integrated L2CC 320 - 88DE3218, ARMADA 1500 Ultra 321 - Core: ARM Cortex-A53 322 - 323 - Homepage: https://www.synaptics.com/products/multimedia-solutions 324 - Directory: arch/arm/mach-berlin 325 - 326 - Comments: 327 - 328 - * This line of SoCs is based on Marvell Sheeva or ARM Cortex CPUs 329 - with Synopsys DesignWare (IRQ, GPIO, Timers, ...) and PXA IP (SDHCI, USB, ETH, ...). 330 - 331 - * The Berlin family was acquired by Synaptics from Marvell in 2017. 332 - 333 - CPU Cores 334 - --------- 335 - 336 - The XScale cores were designed by Intel, and shipped by Marvell in the older 337 - PXA processors. Feroceon is a Marvell designed core that developed in-house, 338 - and that evolved into Sheeva. The XScale and Feroceon cores were phased out 339 - over time and replaced with Sheeva cores in later products, which subsequently 340 - got replaced with licensed ARM Cortex-A cores. 341 - 342 - XScale 1 343 - CPUID 0x69052xxx 344 - ARMv5, iWMMXt 345 - XScale 2 346 - CPUID 0x69054xxx 347 - ARMv5, iWMMXt 348 - XScale 3 349 - CPUID 0x69056xxx or 0x69056xxx 350 - ARMv5, iWMMXt 351 - Feroceon-1850 88fr331 "Mohawk" 352 - CPUID 0x5615331x or 0x41xx926x 353 - ARMv5TE, single issue 354 - Feroceon-2850 88fr531-vd "Jolteon" 355 - CPUID 0x5605531x or 0x41xx926x 356 - ARMv5TE, VFP, dual-issue 357 - Feroceon 88fr571-vd "Jolteon" 358 - CPUID 0x5615571x 359 - ARMv5TE, VFP, dual-issue 360 - Feroceon 88fr131 "Mohawk-D" 361 - CPUID 0x5625131x 362 - ARMv5TE, single-issue in-order 363 - Sheeva PJ1 88sv331 "Mohawk" 364 - CPUID 0x561584xx 365 - ARMv5, single-issue iWMMXt v2 366 - Sheeva PJ4 88sv581x "Flareon" 367 - CPUID 0x560f581x 368 - ARMv7, idivt, optional iWMMXt v2 369 - Sheeva PJ4B 88sv581x 370 - CPUID 0x561f581x 371 - ARMv7, idivt, optional iWMMXt v2 372 - Sheeva PJ4B-MP / PJ4C 373 - CPUID 0x562f584x 374 - ARMv7, idivt/idiva, LPAE, optional iWMMXt v2 and/or NEON 375 - 376 - Long-term plans 377 - --------------- 378 - 379 - * Unify the mach-dove/, mach-mv78xx0/, mach-orion5x/ into the 380 - mach-mvebu/ to support all SoCs from the Marvell EBU (Engineering 381 - Business Unit) in a single mach-<foo> directory. The plat-orion/ 382 - would therefore disappear. 383 - 384 - * Unify the mach-mmp/ and mach-pxa/ into the same mach-pxa 385 - directory. The plat-pxa/ would therefore disappear. 386 - 387 - Credits 388 - ------- 389 - 390 - Maen Suleiman <maen@marvell.com> 391 - Lior Amsalem <alior@marvell.com> 392 - Thomas Petazzoni <thomas.petazzoni@free-electrons.com> 393 - Andrew Lunn <andrew@lunn.ch> 394 - Nicolas Pitre <nico@fluxnic.net> 395 - Eric Miao <eric.y.miao@gmail.com>
-169
Documentation/arm/Microchip/README
··· 1 - ARM Microchip SoCs (aka AT91) 2 - ============================= 3 - 4 - 5 - Introduction 6 - ------------ 7 - This document gives useful information about the ARM Microchip SoCs that are 8 - currently supported in Linux Mainline (you know, the one on kernel.org). 9 - 10 - It is important to note that the Microchip (previously Atmel) ARM-based MPU 11 - product line is historically named "AT91" or "at91" throughout the Linux kernel 12 - development process even if this product prefix has completely disappeared from 13 - the official Microchip product name. Anyway, files, directories, git trees, 14 - git branches/tags and email subject always contain this "at91" sub-string. 15 - 16 - 17 - AT91 SoCs 18 - --------- 19 - Documentation and detailed datasheet for each product are available on 20 - the Microchip website: http://www.microchip.com. 21 - 22 - Flavors: 23 - * ARM 920 based SoC 24 - - at91rm9200 25 - + Datasheet 26 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-1768-32-bit-ARM920T-Embedded-Microprocessor-AT91RM9200_Datasheet.pdf 27 - 28 - * ARM 926 based SoCs 29 - - at91sam9260 30 - + Datasheet 31 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6221-32-bit-ARM926EJ-S-Embedded-Microprocessor-SAM9260_Datasheet.pdf 32 - 33 - - at91sam9xe 34 - + Datasheet 35 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6254-32-bit-ARM926EJ-S-Embedded-Microprocessor-SAM9XE_Datasheet.pdf 36 - 37 - - at91sam9261 38 - + Datasheet 39 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6062-ARM926EJ-S-Microprocessor-SAM9261_Datasheet.pdf 40 - 41 - - at91sam9263 42 - + Datasheet 43 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6249-32-bit-ARM926EJ-S-Embedded-Microprocessor-SAM9263_Datasheet.pdf 44 - 45 - - at91sam9rl 46 - + Datasheet 47 - http://ww1.microchip.com/downloads/en/DeviceDoc/doc6289.pdf 48 - 49 - - at91sam9g20 50 - + Datasheet 51 - http://ww1.microchip.com/downloads/en/DeviceDoc/DS60001516A.pdf 52 - 53 - - at91sam9g45 family 54 - - at91sam9g45 55 - - at91sam9g46 56 - - at91sam9m10 57 - - at91sam9m11 (device superset) 58 - + Datasheet 59 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6437-32-bit-ARM926-Embedded-Microprocessor-SAM9M11_Datasheet.pdf 60 - 61 - - at91sam9x5 family (aka "The 5 series") 62 - - at91sam9g15 63 - - at91sam9g25 64 - - at91sam9g35 65 - - at91sam9x25 66 - - at91sam9x35 67 - + Datasheet (can be considered as covering the whole family) 68 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-11055-32-bit-ARM926EJ-S-Microcontroller-SAM9X35_Datasheet.pdf 69 - 70 - - at91sam9n12 71 - + Datasheet 72 - http://ww1.microchip.com/downloads/en/DeviceDoc/DS60001517A.pdf 73 - 74 - * ARM Cortex-A5 based SoCs 75 - - sama5d3 family 76 - - sama5d31 77 - - sama5d33 78 - - sama5d34 79 - - sama5d35 80 - - sama5d36 (device superset) 81 - + Datasheet 82 - http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-11121-32-bit-Cortex-A5-Microcontroller-SAMA5D3_Datasheet.pdf 83 - 84 - * ARM Cortex-A5 + NEON based SoCs 85 - - sama5d4 family 86 - - sama5d41 87 - - sama5d42 88 - - sama5d43 89 - - sama5d44 (device superset) 90 - + Datasheet 91 - http://ww1.microchip.com/downloads/en/DeviceDoc/60001525A.pdf 92 - 93 - - sama5d2 family 94 - - sama5d21 95 - - sama5d22 96 - - sama5d23 97 - - sama5d24 98 - - sama5d26 99 - - sama5d27 (device superset) 100 - - sama5d28 (device superset + environmental monitors) 101 - + Datasheet 102 - http://ww1.microchip.com/downloads/en/DeviceDoc/DS60001476B.pdf 103 - 104 - * ARM Cortex-M7 MCUs 105 - - sams70 family 106 - - sams70j19 107 - - sams70j20 108 - - sams70j21 109 - - sams70n19 110 - - sams70n20 111 - - sams70n21 112 - - sams70q19 113 - - sams70q20 114 - - sams70q21 115 - 116 - - samv70 family 117 - - samv70j19 118 - - samv70j20 119 - - samv70n19 120 - - samv70n20 121 - - samv70q19 122 - - samv70q20 123 - 124 - - samv71 family 125 - - samv71j19 126 - - samv71j20 127 - - samv71j21 128 - - samv71n19 129 - - samv71n20 130 - - samv71n21 131 - - samv71q19 132 - - samv71q20 133 - - samv71q21 134 - 135 - + Datasheet 136 - http://ww1.microchip.com/downloads/en/DeviceDoc/60001527A.pdf 137 - 138 - 139 - Linux kernel information 140 - ------------------------ 141 - Linux kernel mach directory: arch/arm/mach-at91 142 - MAINTAINERS entry is: "ARM/Microchip (AT91) SoC support" 143 - 144 - 145 - Device Tree for AT91 SoCs and boards 146 - ------------------------------------ 147 - All AT91 SoCs are converted to Device Tree. Since Linux 3.19, these products 148 - must use this method to boot the Linux kernel. 149 - 150 - Work In Progress statement: 151 - Device Tree files and Device Tree bindings that apply to AT91 SoCs and boards are 152 - considered as "Unstable". To be completely clear, any at91 binding can change at 153 - any time. So, be sure to use a Device Tree Binary and a Kernel Image generated from 154 - the same source tree. 155 - Please refer to the Documentation/devicetree/bindings/ABI.txt file for a 156 - definition of a "Stable" binding/ABI. 157 - This statement will be removed by AT91 MAINTAINERS when appropriate. 158 - 159 - Naming conventions and best practice: 160 - - SoCs Device Tree Source Include files are named after the official name of 161 - the product (at91sam9g20.dtsi or sama5d33.dtsi for instance). 162 - - Device Tree Source Include files (.dtsi) are used to collect common nodes that can be 163 - shared across SoCs or boards (sama5d3.dtsi or at91sam9x5cm.dtsi for instance). 164 - When collecting nodes for a particular peripheral or topic, the identifier have to 165 - be placed at the end of the file name, separated with a "_" (at91sam9x5_can.dtsi 166 - or sama5d3_gmac.dtsi for example). 167 - - board Device Tree Source files (.dts) are prefixed by the string "at91-" so 168 - that they can be identified easily. Note that some files are historical exceptions 169 - to this rule (sama5d3[13456]ek.dts, usb_a9g20.dts or animeo_ip.dts for example).
-78
Documentation/arm/Netwinder
··· 1 - NetWinder specific documentation 2 - ================================ 3 - 4 - The NetWinder is a small low-power computer, primarily designed 5 - to run Linux. It is based around the StrongARM RISC processor, 6 - DC21285 PCI bridge, with PC-type hardware glued around it. 7 - 8 - Port usage 9 - ========== 10 - 11 - Min - Max Description 12 - --------------------------- 13 - 0x0000 - 0x000f DMA1 14 - 0x0020 - 0x0021 PIC1 15 - 0x0060 - 0x006f Keyboard 16 - 0x0070 - 0x007f RTC 17 - 0x0080 - 0x0087 DMA1 18 - 0x0088 - 0x008f DMA2 19 - 0x00a0 - 0x00a3 PIC2 20 - 0x00c0 - 0x00df DMA2 21 - 0x0180 - 0x0187 IRDA 22 - 0x01f0 - 0x01f6 ide0 23 - 0x0201 Game port 24 - 0x0203 RWA010 configuration read 25 - 0x0220 - ? SoundBlaster 26 - 0x0250 - ? WaveArtist 27 - 0x0279 RWA010 configuration index 28 - 0x02f8 - 0x02ff Serial ttyS1 29 - 0x0300 - 0x031f Ether10 30 - 0x0338 GPIO1 31 - 0x033a GPIO2 32 - 0x0370 - 0x0371 W83977F configuration registers 33 - 0x0388 - ? AdLib 34 - 0x03c0 - 0x03df VGA 35 - 0x03f6 ide0 36 - 0x03f8 - 0x03ff Serial ttyS0 37 - 0x0400 - 0x0408 DC21143 38 - 0x0480 - 0x0487 DMA1 39 - 0x0488 - 0x048f DMA2 40 - 0x0a79 RWA010 configuration write 41 - 0xe800 - 0xe80f ide0/ide1 BM DMA 42 - 43 - 44 - Interrupt usage 45 - =============== 46 - 47 - IRQ type Description 48 - --------------------------- 49 - 0 ISA 100Hz timer 50 - 1 ISA Keyboard 51 - 2 ISA cascade 52 - 3 ISA Serial ttyS1 53 - 4 ISA Serial ttyS0 54 - 5 ISA PS/2 mouse 55 - 6 ISA IRDA 56 - 7 ISA Printer 57 - 8 ISA RTC alarm 58 - 9 ISA 59 - 10 ISA GP10 (Orange reset button) 60 - 11 ISA 61 - 12 ISA WaveArtist 62 - 13 ISA 63 - 14 ISA hda1 64 - 15 ISA 65 - 66 - DMA usage 67 - ========= 68 - 69 - DMA type Description 70 - --------------------------- 71 - 0 ISA IRDA 72 - 1 ISA 73 - 2 ISA cascade 74 - 3 ISA WaveArtist 75 - 4 ISA 76 - 5 ISA 77 - 6 ISA 78 - 7 ISA WaveArtist
-362
Documentation/arm/OMAP/DSS
··· 1 - OMAP2/3 Display Subsystem 2 - ------------------------- 3 - 4 - This is an almost total rewrite of the OMAP FB driver in drivers/video/omap 5 - (let's call it DSS1). The main differences between DSS1 and DSS2 are DSI, 6 - TV-out and multiple display support, but there are lots of small improvements 7 - also. 8 - 9 - The DSS2 driver (omapdss module) is in arch/arm/plat-omap/dss/, and the FB, 10 - panel and controller drivers are in drivers/video/omap2/. DSS1 and DSS2 live 11 - currently side by side, you can choose which one to use. 12 - 13 - Features 14 - -------- 15 - 16 - Working and tested features include: 17 - 18 - - MIPI DPI (parallel) output 19 - - MIPI DSI output in command mode 20 - - MIPI DBI (RFBI) output 21 - - SDI output 22 - - TV output 23 - - All pieces can be compiled as a module or inside kernel 24 - - Use DISPC to update any of the outputs 25 - - Use CPU to update RFBI or DSI output 26 - - OMAP DISPC planes 27 - - RGB16, RGB24 packed, RGB24 unpacked 28 - - YUV2, UYVY 29 - - Scaling 30 - - Adjusting DSS FCK to find a good pixel clock 31 - - Use DSI DPLL to create DSS FCK 32 - 33 - Tested boards include: 34 - - OMAP3 SDP board 35 - - Beagle board 36 - - N810 37 - 38 - omapdss driver 39 - -------------- 40 - 41 - The DSS driver does not itself have any support for Linux framebuffer, V4L or 42 - such like the current ones, but it has an internal kernel API that upper level 43 - drivers can use. 44 - 45 - The DSS driver models OMAP's overlays, overlay managers and displays in a 46 - flexible way to enable non-common multi-display configuration. In addition to 47 - modelling the hardware overlays, omapdss supports virtual overlays and overlay 48 - managers. These can be used when updating a display with CPU or system DMA. 49 - 50 - omapdss driver support for audio 51 - -------------------------------- 52 - There exist several display technologies and standards that support audio as 53 - well. Hence, it is relevant to update the DSS device driver to provide an audio 54 - interface that may be used by an audio driver or any other driver interested in 55 - the functionality. 56 - 57 - The audio_enable function is intended to prepare the relevant 58 - IP for playback (e.g., enabling an audio FIFO, taking in/out of reset 59 - some IP, enabling companion chips, etc). It is intended to be called before 60 - audio_start. The audio_disable function performs the reverse operation and is 61 - intended to be called after audio_stop. 62 - 63 - While a given DSS device driver may support audio, it is possible that for 64 - certain configurations audio is not supported (e.g., an HDMI display using a 65 - VESA video timing). The audio_supported function is intended to query whether 66 - the current configuration of the display supports audio. 67 - 68 - The audio_config function is intended to configure all the relevant audio 69 - parameters of the display. In order to make the function independent of any 70 - specific DSS device driver, a struct omap_dss_audio is defined. Its purpose 71 - is to contain all the required parameters for audio configuration. At the 72 - moment, such structure contains pointers to IEC-60958 channel status word 73 - and CEA-861 audio infoframe structures. This should be enough to support 74 - HDMI and DisplayPort, as both are based on CEA-861 and IEC-60958. 75 - 76 - The audio_enable/disable, audio_config and audio_supported functions could be 77 - implemented as functions that may sleep. Hence, they should not be called 78 - while holding a spinlock or a readlock. 79 - 80 - The audio_start/audio_stop function is intended to effectively start/stop audio 81 - playback after the configuration has taken place. These functions are designed 82 - to be used in an atomic context. Hence, audio_start should return quickly and be 83 - called only after all the needed resources for audio playback (audio FIFOs, 84 - DMA channels, companion chips, etc) have been enabled to begin data transfers. 85 - audio_stop is designed to only stop the audio transfers. The resources used 86 - for playback are released using audio_disable. 87 - 88 - The enum omap_dss_audio_state may be used to help the implementations of 89 - the interface to keep track of the audio state. The initial state is _DISABLED; 90 - then, the state transitions to _CONFIGURED, and then, when it is ready to 91 - play audio, to _ENABLED. The state _PLAYING is used when the audio is being 92 - rendered. 93 - 94 - 95 - Panel and controller drivers 96 - ---------------------------- 97 - 98 - The drivers implement panel or controller specific functionality and are not 99 - usually visible to users except through omapfb driver. They register 100 - themselves to the DSS driver. 101 - 102 - omapfb driver 103 - ------------- 104 - 105 - The omapfb driver implements arbitrary number of standard linux framebuffers. 106 - These framebuffers can be routed flexibly to any overlays, thus allowing very 107 - dynamic display architecture. 108 - 109 - The driver exports some omapfb specific ioctls, which are compatible with the 110 - ioctls in the old driver. 111 - 112 - The rest of the non standard features are exported via sysfs. Whether the final 113 - implementation will use sysfs, or ioctls, is still open. 114 - 115 - V4L2 drivers 116 - ------------ 117 - 118 - V4L2 is being implemented in TI. 119 - 120 - From omapdss point of view the V4L2 drivers should be similar to framebuffer 121 - driver. 122 - 123 - Architecture 124 - -------------------- 125 - 126 - Some clarification what the different components do: 127 - 128 - - Framebuffer is a memory area inside OMAP's SRAM/SDRAM that contains the 129 - pixel data for the image. Framebuffer has width and height and color 130 - depth. 131 - - Overlay defines where the pixels are read from and where they go on the 132 - screen. The overlay may be smaller than framebuffer, thus displaying only 133 - part of the framebuffer. The position of the overlay may be changed if 134 - the overlay is smaller than the display. 135 - - Overlay manager combines the overlays in to one image and feeds them to 136 - display. 137 - - Display is the actual physical display device. 138 - 139 - A framebuffer can be connected to multiple overlays to show the same pixel data 140 - on all of the overlays. Note that in this case the overlay input sizes must be 141 - the same, but, in case of video overlays, the output size can be different. Any 142 - framebuffer can be connected to any overlay. 143 - 144 - An overlay can be connected to one overlay manager. Also DISPC overlays can be 145 - connected only to DISPC overlay managers, and virtual overlays can be only 146 - connected to virtual overlays. 147 - 148 - An overlay manager can be connected to one display. There are certain 149 - restrictions which kinds of displays an overlay manager can be connected: 150 - 151 - - DISPC TV overlay manager can be only connected to TV display. 152 - - Virtual overlay managers can only be connected to DBI or DSI displays. 153 - - DISPC LCD overlay manager can be connected to all displays, except TV 154 - display. 155 - 156 - Sysfs 157 - ----- 158 - The sysfs interface is mainly used for testing. I don't think sysfs 159 - interface is the best for this in the final version, but I don't quite know 160 - what would be the best interfaces for these things. 161 - 162 - The sysfs interface is divided to two parts: DSS and FB. 163 - 164 - /sys/class/graphics/fb? directory: 165 - mirror 0=off, 1=on 166 - rotate Rotation 0-3 for 0, 90, 180, 270 degrees 167 - rotate_type 0 = DMA rotation, 1 = VRFB rotation 168 - overlays List of overlay numbers to which framebuffer pixels go 169 - phys_addr Physical address of the framebuffer 170 - virt_addr Virtual address of the framebuffer 171 - size Size of the framebuffer 172 - 173 - /sys/devices/platform/omapdss/overlay? directory: 174 - enabled 0=off, 1=on 175 - input_size width,height (ie. the framebuffer size) 176 - manager Destination overlay manager name 177 - name 178 - output_size width,height 179 - position x,y 180 - screen_width width 181 - global_alpha global alpha 0-255 0=transparent 255=opaque 182 - 183 - /sys/devices/platform/omapdss/manager? directory: 184 - display Destination display 185 - name 186 - alpha_blending_enabled 0=off, 1=on 187 - trans_key_enabled 0=off, 1=on 188 - trans_key_type gfx-destination, video-source 189 - trans_key_value transparency color key (RGB24) 190 - default_color default background color (RGB24) 191 - 192 - /sys/devices/platform/omapdss/display? directory: 193 - ctrl_name Controller name 194 - mirror 0=off, 1=on 195 - update_mode 0=off, 1=auto, 2=manual 196 - enabled 0=off, 1=on 197 - name 198 - rotate Rotation 0-3 for 0, 90, 180, 270 degrees 199 - timings Display timings (pixclock,xres/hfp/hbp/hsw,yres/vfp/vbp/vsw) 200 - When writing, two special timings are accepted for tv-out: 201 - "pal" and "ntsc" 202 - panel_name 203 - tear_elim Tearing elimination 0=off, 1=on 204 - output_type Output type (video encoder only): "composite" or "svideo" 205 - 206 - There are also some debugfs files at <debugfs>/omapdss/ which show information 207 - about clocks and registers. 208 - 209 - Examples 210 - -------- 211 - 212 - The following definitions have been made for the examples below: 213 - 214 - ovl0=/sys/devices/platform/omapdss/overlay0 215 - ovl1=/sys/devices/platform/omapdss/overlay1 216 - ovl2=/sys/devices/platform/omapdss/overlay2 217 - 218 - mgr0=/sys/devices/platform/omapdss/manager0 219 - mgr1=/sys/devices/platform/omapdss/manager1 220 - 221 - lcd=/sys/devices/platform/omapdss/display0 222 - dvi=/sys/devices/platform/omapdss/display1 223 - tv=/sys/devices/platform/omapdss/display2 224 - 225 - fb0=/sys/class/graphics/fb0 226 - fb1=/sys/class/graphics/fb1 227 - fb2=/sys/class/graphics/fb2 228 - 229 - Default setup on OMAP3 SDP 230 - -------------------------- 231 - 232 - Here's the default setup on OMAP3 SDP board. All planes go to LCD. DVI 233 - and TV-out are not in use. The columns from left to right are: 234 - framebuffers, overlays, overlay managers, displays. Framebuffers are 235 - handled by omapfb, and the rest by the DSS. 236 - 237 - FB0 --- GFX -\ DVI 238 - FB1 --- VID1 --+- LCD ---- LCD 239 - FB2 --- VID2 -/ TV ----- TV 240 - 241 - Example: Switch from LCD to DVI 242 - ---------------------- 243 - 244 - w=`cat $dvi/timings | cut -d "," -f 2 | cut -d "/" -f 1` 245 - h=`cat $dvi/timings | cut -d "," -f 3 | cut -d "/" -f 1` 246 - 247 - echo "0" > $lcd/enabled 248 - echo "" > $mgr0/display 249 - fbset -fb /dev/fb0 -xres $w -yres $h -vxres $w -vyres $h 250 - # at this point you have to switch the dvi/lcd dip-switch from the omap board 251 - echo "dvi" > $mgr0/display 252 - echo "1" > $dvi/enabled 253 - 254 - After this the configuration looks like: 255 - 256 - FB0 --- GFX -\ -- DVI 257 - FB1 --- VID1 --+- LCD -/ LCD 258 - FB2 --- VID2 -/ TV ----- TV 259 - 260 - Example: Clone GFX overlay to LCD and TV 261 - ------------------------------- 262 - 263 - w=`cat $tv/timings | cut -d "," -f 2 | cut -d "/" -f 1` 264 - h=`cat $tv/timings | cut -d "," -f 3 | cut -d "/" -f 1` 265 - 266 - echo "0" > $ovl0/enabled 267 - echo "0" > $ovl1/enabled 268 - 269 - echo "" > $fb1/overlays 270 - echo "0,1" > $fb0/overlays 271 - 272 - echo "$w,$h" > $ovl1/output_size 273 - echo "tv" > $ovl1/manager 274 - 275 - echo "1" > $ovl0/enabled 276 - echo "1" > $ovl1/enabled 277 - 278 - echo "1" > $tv/enabled 279 - 280 - After this the configuration looks like (only relevant parts shown): 281 - 282 - FB0 +-- GFX ---- LCD ---- LCD 283 - \- VID1 ---- TV ---- TV 284 - 285 - Misc notes 286 - ---------- 287 - 288 - OMAP FB allocates the framebuffer memory using the standard dma allocator. You 289 - can enable Contiguous Memory Allocator (CONFIG_CMA) to improve the dma 290 - allocator, and if CMA is enabled, you use "cma=" kernel parameter to increase 291 - the global memory area for CMA. 292 - 293 - Using DSI DPLL to generate pixel clock it is possible produce the pixel clock 294 - of 86.5MHz (max possible), and with that you get 1280x1024@57 output from DVI. 295 - 296 - Rotation and mirroring currently only supports RGB565 and RGB8888 modes. VRFB 297 - does not support mirroring. 298 - 299 - VRFB rotation requires much more memory than non-rotated framebuffer, so you 300 - probably need to increase your vram setting before using VRFB rotation. Also, 301 - many applications may not work with VRFB if they do not pay attention to all 302 - framebuffer parameters. 303 - 304 - Kernel boot arguments 305 - --------------------- 306 - 307 - omapfb.mode=<display>:<mode>[,...] 308 - - Default video mode for specified displays. For example, 309 - "dvi:800x400MR-24@60". See drivers/video/modedb.c. 310 - There are also two special modes: "pal" and "ntsc" that 311 - can be used to tv out. 312 - 313 - omapfb.vram=<fbnum>:<size>[@<physaddr>][,...] 314 - - VRAM allocated for a framebuffer. Normally omapfb allocates vram 315 - depending on the display size. With this you can manually allocate 316 - more or define the physical address of each framebuffer. For example, 317 - "1:4M" to allocate 4M for fb1. 318 - 319 - omapfb.debug=<y|n> 320 - - Enable debug printing. You have to have OMAPFB debug support enabled 321 - in kernel config. 322 - 323 - omapfb.test=<y|n> 324 - - Draw test pattern to framebuffer whenever framebuffer settings change. 325 - You need to have OMAPFB debug support enabled in kernel config. 326 - 327 - omapfb.vrfb=<y|n> 328 - - Use VRFB rotation for all framebuffers. 329 - 330 - omapfb.rotate=<angle> 331 - - Default rotation applied to all framebuffers. 332 - 0 - 0 degree rotation 333 - 1 - 90 degree rotation 334 - 2 - 180 degree rotation 335 - 3 - 270 degree rotation 336 - 337 - omapfb.mirror=<y|n> 338 - - Default mirror for all framebuffers. Only works with DMA rotation. 339 - 340 - omapdss.def_disp=<display> 341 - - Name of default display, to which all overlays will be connected. 342 - Common examples are "lcd" or "tv". 343 - 344 - omapdss.debug=<y|n> 345 - - Enable debug printing. You have to have DSS debug support enabled in 346 - kernel config. 347 - 348 - TODO 349 - ---- 350 - 351 - DSS locking 352 - 353 - Error checking 354 - - Lots of checks are missing or implemented just as BUG() 355 - 356 - System DMA update for DSI 357 - - Can be used for RGB16 and RGB24P modes. Probably not for RGB24U (how 358 - to skip the empty byte?) 359 - 360 - OMAP1 support 361 - - Not sure if needed 362 -
-11
Documentation/arm/OMAP/README
··· 1 - This file contains documentation for running mainline 2 - kernel on omaps. 3 - 4 - KERNEL NEW DEPENDENCIES 5 - v4.3+ Update is needed for custom .config files to make sure 6 - CONFIG_REGULATOR_PBIAS is enabled for MMC1 to work 7 - properly. 8 - 9 - v4.18+ Update is needed for custom .config files to make sure 10 - CONFIG_MMC_SDHCI_OMAP is enabled for all MMC instances 11 - to work in DRA7 and K2G based boards.
-154
Documentation/arm/OMAP/omap_pm
··· 1 - 2 - The OMAP PM interface 3 - ===================== 4 - 5 - This document describes the temporary OMAP PM interface. Driver 6 - authors use these functions to communicate minimum latency or 7 - throughput constraints to the kernel power management code. 8 - Over time, the intention is to merge features from the OMAP PM 9 - interface into the Linux PM QoS code. 10 - 11 - Drivers need to express PM parameters which: 12 - 13 - - support the range of power management parameters present in the TI SRF; 14 - 15 - - separate the drivers from the underlying PM parameter 16 - implementation, whether it is the TI SRF or Linux PM QoS or Linux 17 - latency framework or something else; 18 - 19 - - specify PM parameters in terms of fundamental units, such as 20 - latency and throughput, rather than units which are specific to OMAP 21 - or to particular OMAP variants; 22 - 23 - - allow drivers which are shared with other architectures (e.g., 24 - DaVinci) to add these constraints in a way which won't affect non-OMAP 25 - systems, 26 - 27 - - can be implemented immediately with minimal disruption of other 28 - architectures. 29 - 30 - 31 - This document proposes the OMAP PM interface, including the following 32 - five power management functions for driver code: 33 - 34 - 1. Set the maximum MPU wakeup latency: 35 - (*pdata->set_max_mpu_wakeup_lat)(struct device *dev, unsigned long t) 36 - 37 - 2. Set the maximum device wakeup latency: 38 - (*pdata->set_max_dev_wakeup_lat)(struct device *dev, unsigned long t) 39 - 40 - 3. Set the maximum system DMA transfer start latency (CORE pwrdm): 41 - (*pdata->set_max_sdma_lat)(struct device *dev, long t) 42 - 43 - 4. Set the minimum bus throughput needed by a device: 44 - (*pdata->set_min_bus_tput)(struct device *dev, u8 agent_id, unsigned long r) 45 - 46 - 5. Return the number of times the device has lost context 47 - (*pdata->get_dev_context_loss_count)(struct device *dev) 48 - 49 - 50 - Further documentation for all OMAP PM interface functions can be 51 - found in arch/arm/plat-omap/include/mach/omap-pm.h. 52 - 53 - 54 - The OMAP PM layer is intended to be temporary 55 - --------------------------------------------- 56 - 57 - The intention is that eventually the Linux PM QoS layer should support 58 - the range of power management features present in OMAP3. As this 59 - happens, existing drivers using the OMAP PM interface can be modified 60 - to use the Linux PM QoS code; and the OMAP PM interface can disappear. 61 - 62 - 63 - Driver usage of the OMAP PM functions 64 - ------------------------------------- 65 - 66 - As the 'pdata' in the above examples indicates, these functions are 67 - exposed to drivers through function pointers in driver .platform_data 68 - structures. The function pointers are initialized by the board-*.c 69 - files to point to the corresponding OMAP PM functions: 70 - .set_max_dev_wakeup_lat will point to 71 - omap_pm_set_max_dev_wakeup_lat(), etc. Other architectures which do 72 - not support these functions should leave these function pointers set 73 - to NULL. Drivers should use the following idiom: 74 - 75 - if (pdata->set_max_dev_wakeup_lat) 76 - (*pdata->set_max_dev_wakeup_lat)(dev, t); 77 - 78 - The most common usage of these functions will probably be to specify 79 - the maximum time from when an interrupt occurs, to when the device 80 - becomes accessible. To accomplish this, driver writers should use the 81 - set_max_mpu_wakeup_lat() function to constrain the MPU wakeup 82 - latency, and the set_max_dev_wakeup_lat() function to constrain the 83 - device wakeup latency (from clk_enable() to accessibility). For 84 - example, 85 - 86 - /* Limit MPU wakeup latency */ 87 - if (pdata->set_max_mpu_wakeup_lat) 88 - (*pdata->set_max_mpu_wakeup_lat)(dev, tc); 89 - 90 - /* Limit device powerdomain wakeup latency */ 91 - if (pdata->set_max_dev_wakeup_lat) 92 - (*pdata->set_max_dev_wakeup_lat)(dev, td); 93 - 94 - /* total wakeup latency in this example: (tc + td) */ 95 - 96 - The PM parameters can be overwritten by calling the function again 97 - with the new value. The settings can be removed by calling the 98 - function with a t argument of -1 (except in the case of 99 - set_max_bus_tput(), which should be called with an r argument of 0). 100 - 101 - The fifth function above, omap_pm_get_dev_context_loss_count(), 102 - is intended as an optimization to allow drivers to determine whether the 103 - device has lost its internal context. If context has been lost, the 104 - driver must restore its internal context before proceeding. 105 - 106 - 107 - Other specialized interface functions 108 - ------------------------------------- 109 - 110 - The five functions listed above are intended to be usable by any 111 - device driver. DSPBridge and CPUFreq have a few special requirements. 112 - DSPBridge expresses target DSP performance levels in terms of OPP IDs. 113 - CPUFreq expresses target MPU performance levels in terms of MPU 114 - frequency. The OMAP PM interface contains functions for these 115 - specialized cases to convert that input information (OPPs/MPU 116 - frequency) into the form that the underlying power management 117 - implementation needs: 118 - 119 - 6. (*pdata->dsp_get_opp_table)(void) 120 - 121 - 7. (*pdata->dsp_set_min_opp)(u8 opp_id) 122 - 123 - 8. (*pdata->dsp_get_opp)(void) 124 - 125 - 9. (*pdata->cpu_get_freq_table)(void) 126 - 127 - 10. (*pdata->cpu_set_freq)(unsigned long f) 128 - 129 - 11. (*pdata->cpu_get_freq)(void) 130 - 131 - Customizing OPP for platform 132 - ============================ 133 - Defining CONFIG_PM should enable OPP layer for the silicon 134 - and the registration of OPP table should take place automatically. 135 - However, in special cases, the default OPP table may need to be 136 - tweaked, for e.g.: 137 - * enable default OPPs which are disabled by default, but which 138 - could be enabled on a platform 139 - * Disable an unsupported OPP on the platform 140 - * Define and add a custom opp table entry 141 - in these cases, the board file needs to do additional steps as follows: 142 - arch/arm/mach-omapx/board-xyz.c 143 - #include "pm.h" 144 - .... 145 - static void __init omap_xyz_init_irq(void) 146 - { 147 - .... 148 - /* Initialize the default table */ 149 - omapx_opp_init(); 150 - /* Do customization to the defaults */ 151 - .... 152 - } 153 - NOTE: omapx_opp_init will be omap3_opp_init or as required 154 - based on the omap family.
-135
Documentation/arm/Porting
··· 1 - Taken from list archive at http://lists.arm.linux.org.uk/pipermail/linux-arm-kernel/2001-July/004064.html 2 - 3 - Initial definitions 4 - ------------------- 5 - 6 - The following symbol definitions rely on you knowing the translation that 7 - __virt_to_phys() does for your machine. This macro converts the passed 8 - virtual address to a physical address. Normally, it is simply: 9 - 10 - phys = virt - PAGE_OFFSET + PHYS_OFFSET 11 - 12 - 13 - Decompressor Symbols 14 - -------------------- 15 - 16 - ZTEXTADDR 17 - Start address of decompressor. There's no point in talking about 18 - virtual or physical addresses here, since the MMU will be off at 19 - the time when you call the decompressor code. You normally call 20 - the kernel at this address to start it booting. This doesn't have 21 - to be located in RAM, it can be in flash or other read-only or 22 - read-write addressable medium. 23 - 24 - ZBSSADDR 25 - Start address of zero-initialised work area for the decompressor. 26 - This must be pointing at RAM. The decompressor will zero initialise 27 - this for you. Again, the MMU will be off. 28 - 29 - ZRELADDR 30 - This is the address where the decompressed kernel will be written, 31 - and eventually executed. The following constraint must be valid: 32 - 33 - __virt_to_phys(TEXTADDR) == ZRELADDR 34 - 35 - The initial part of the kernel is carefully coded to be position 36 - independent. 37 - 38 - INITRD_PHYS 39 - Physical address to place the initial RAM disk. Only relevant if 40 - you are using the bootpImage stuff (which only works on the old 41 - struct param_struct). 42 - 43 - INITRD_VIRT 44 - Virtual address of the initial RAM disk. The following constraint 45 - must be valid: 46 - 47 - __virt_to_phys(INITRD_VIRT) == INITRD_PHYS 48 - 49 - PARAMS_PHYS 50 - Physical address of the struct param_struct or tag list, giving the 51 - kernel various parameters about its execution environment. 52 - 53 - 54 - Kernel Symbols 55 - -------------- 56 - 57 - PHYS_OFFSET 58 - Physical start address of the first bank of RAM. 59 - 60 - PAGE_OFFSET 61 - Virtual start address of the first bank of RAM. During the kernel 62 - boot phase, virtual address PAGE_OFFSET will be mapped to physical 63 - address PHYS_OFFSET, along with any other mappings you supply. 64 - This should be the same value as TASK_SIZE. 65 - 66 - TASK_SIZE 67 - The maximum size of a user process in bytes. Since user space 68 - always starts at zero, this is the maximum address that a user 69 - process can access+1. The user space stack grows down from this 70 - address. 71 - 72 - Any virtual address below TASK_SIZE is deemed to be user process 73 - area, and therefore managed dynamically on a process by process 74 - basis by the kernel. I'll call this the user segment. 75 - 76 - Anything above TASK_SIZE is common to all processes. I'll call 77 - this the kernel segment. 78 - 79 - (In other words, you can't put IO mappings below TASK_SIZE, and 80 - hence PAGE_OFFSET). 81 - 82 - TEXTADDR 83 - Virtual start address of kernel, normally PAGE_OFFSET + 0x8000. 84 - This is where the kernel image ends up. With the latest kernels, 85 - it must be located at 32768 bytes into a 128MB region. Previous 86 - kernels placed a restriction of 256MB here. 87 - 88 - DATAADDR 89 - Virtual address for the kernel data segment. Must not be defined 90 - when using the decompressor. 91 - 92 - VMALLOC_START 93 - VMALLOC_END 94 - Virtual addresses bounding the vmalloc() area. There must not be 95 - any static mappings in this area; vmalloc will overwrite them. 96 - The addresses must also be in the kernel segment (see above). 97 - Normally, the vmalloc() area starts VMALLOC_OFFSET bytes above the 98 - last virtual RAM address (found using variable high_memory). 99 - 100 - VMALLOC_OFFSET 101 - Offset normally incorporated into VMALLOC_START to provide a hole 102 - between virtual RAM and the vmalloc area. We do this to allow 103 - out of bounds memory accesses (eg, something writing off the end 104 - of the mapped memory map) to be caught. Normally set to 8MB. 105 - 106 - Architecture Specific Macros 107 - ---------------------------- 108 - 109 - BOOT_MEM(pram,pio,vio) 110 - `pram' specifies the physical start address of RAM. Must always 111 - be present, and should be the same as PHYS_OFFSET. 112 - 113 - `pio' is the physical address of an 8MB region containing IO for 114 - use with the debugging macros in arch/arm/kernel/debug-armv.S. 115 - 116 - `vio' is the virtual address of the 8MB debugging region. 117 - 118 - It is expected that the debugging region will be re-initialised 119 - by the architecture specific code later in the code (via the 120 - MAPIO function). 121 - 122 - BOOT_PARAMS 123 - Same as, and see PARAMS_PHYS. 124 - 125 - FIXUP(func) 126 - Machine specific fixups, run before memory subsystems have been 127 - initialised. 128 - 129 - MAPIO(func) 130 - Machine specific function to map IO areas (including the debug 131 - region above). 132 - 133 - INITIRQ(func) 134 - Machine specific function to initialise interrupts. 135 -
-204
Documentation/arm/README
··· 1 - ARM Linux 2.6 2 - ============= 3 - 4 - Please check <ftp://ftp.arm.linux.org.uk/pub/armlinux> for 5 - updates. 6 - 7 - Compilation of kernel 8 - --------------------- 9 - 10 - In order to compile ARM Linux, you will need a compiler capable of 11 - generating ARM ELF code with GNU extensions. GCC 3.3 is known to be 12 - a good compiler. Fortunately, you needn't guess. The kernel will report 13 - an error if your compiler is a recognized offender. 14 - 15 - To build ARM Linux natively, you shouldn't have to alter the ARCH = line 16 - in the top level Makefile. However, if you don't have the ARM Linux ELF 17 - tools installed as default, then you should change the CROSS_COMPILE 18 - line as detailed below. 19 - 20 - If you wish to cross-compile, then alter the following lines in the top 21 - level make file: 22 - 23 - ARCH = <whatever> 24 - with 25 - ARCH = arm 26 - 27 - and 28 - 29 - CROSS_COMPILE= 30 - to 31 - CROSS_COMPILE=<your-path-to-your-compiler-without-gcc> 32 - eg. 33 - CROSS_COMPILE=arm-linux- 34 - 35 - Do a 'make config', followed by 'make Image' to build the kernel 36 - (arch/arm/boot/Image). A compressed image can be built by doing a 37 - 'make zImage' instead of 'make Image'. 38 - 39 - 40 - Bug reports etc 41 - --------------- 42 - 43 - Please send patches to the patch system. For more information, see 44 - http://www.arm.linux.org.uk/developer/patches/info.php Always include some 45 - explanation as to what the patch does and why it is needed. 46 - 47 - Bug reports should be sent to linux-arm-kernel@lists.arm.linux.org.uk, 48 - or submitted through the web form at 49 - http://www.arm.linux.org.uk/developer/ 50 - 51 - When sending bug reports, please ensure that they contain all relevant 52 - information, eg. the kernel messages that were printed before/during 53 - the problem, what you were doing, etc. 54 - 55 - 56 - Include files 57 - ------------- 58 - 59 - Several new include directories have been created under include/asm-arm, 60 - which are there to reduce the clutter in the top-level directory. These 61 - directories, and their purpose is listed below: 62 - 63 - arch-* machine/platform specific header files 64 - hardware driver-internal ARM specific data structures/definitions 65 - mach descriptions of generic ARM to specific machine interfaces 66 - proc-* processor dependent header files (currently only two 67 - categories) 68 - 69 - 70 - Machine/Platform support 71 - ------------------------ 72 - 73 - The ARM tree contains support for a lot of different machine types. To 74 - continue supporting these differences, it has become necessary to split 75 - machine-specific parts by directory. For this, the machine category is 76 - used to select which directories and files get included (we will use 77 - $(MACHINE) to refer to the category) 78 - 79 - To this end, we now have arch/arm/mach-$(MACHINE) directories which are 80 - designed to house the non-driver files for a particular machine (eg, PCI, 81 - memory management, architecture definitions etc). For all future 82 - machines, there should be a corresponding arch/arm/mach-$(MACHINE)/include/mach 83 - directory. 84 - 85 - 86 - Modules 87 - ------- 88 - 89 - Although modularisation is supported (and required for the FP emulator), 90 - each module on an ARM2/ARM250/ARM3 machine when is loaded will take 91 - memory up to the next 32k boundary due to the size of the pages. 92 - Therefore, is modularisation on these machines really worth it? 93 - 94 - However, ARM6 and up machines allow modules to take multiples of 4k, and 95 - as such Acorn RiscPCs and other architectures using these processors can 96 - make good use of modularisation. 97 - 98 - 99 - ADFS Image files 100 - ---------------- 101 - 102 - You can access image files on your ADFS partitions by mounting the ADFS 103 - partition, and then using the loopback device driver. You must have 104 - losetup installed. 105 - 106 - Please note that the PCEmulator DOS partitions have a partition table at 107 - the start, and as such, you will have to give '-o offset' to losetup. 108 - 109 - 110 - Request to developers 111 - --------------------- 112 - 113 - When writing device drivers which include a separate assembler file, please 114 - include it in with the C file, and not the arch/arm/lib directory. This 115 - allows the driver to be compiled as a loadable module without requiring 116 - half the code to be compiled into the kernel image. 117 - 118 - In general, try to avoid using assembler unless it is really necessary. It 119 - makes drivers far less easy to port to other hardware. 120 - 121 - 122 - ST506 hard drives 123 - ----------------- 124 - 125 - The ST506 hard drive controllers seem to be working fine (if a little 126 - slowly). At the moment they will only work off the controllers on an 127 - A4x0's motherboard, but for it to work off a Podule just requires 128 - someone with a podule to add the addresses for the IRQ mask and the 129 - HDC base to the source. 130 - 131 - As of 31/3/96 it works with two drives (you should get the ADFS 132 - *configure harddrive set to 2). I've got an internal 20MB and a great 133 - big external 5.25" FH 64MB drive (who could ever want more :-) ). 134 - 135 - I've just got 240K/s off it (a dd with bs=128k); thats about half of what 136 - RiscOS gets; but it's a heck of a lot better than the 50K/s I was getting 137 - last week :-) 138 - 139 - Known bug: Drive data errors can cause a hang; including cases where 140 - the controller has fixed the error using ECC. (Possibly ONLY 141 - in that case...hmm). 142 - 143 - 144 - 1772 Floppy 145 - ----------- 146 - This also seems to work OK, but hasn't been stressed much lately. It 147 - hasn't got any code for disc change detection in there at the moment which 148 - could be a bit of a problem! Suggestions on the correct way to do this 149 - are welcome. 150 - 151 - 152 - CONFIG_MACH_ and CONFIG_ARCH_ 153 - ----------------------------- 154 - A change was made in 2003 to the macro names for new machines. 155 - Historically, CONFIG_ARCH_ was used for the bonafide architecture, 156 - e.g. SA1100, as well as implementations of the architecture, 157 - e.g. Assabet. It was decided to change the implementation macros 158 - to read CONFIG_MACH_ for clarity. Moreover, a retroactive fixup has 159 - not been made because it would complicate patching. 160 - 161 - Previous registrations may be found online. 162 - 163 - <http://www.arm.linux.org.uk/developer/machines/> 164 - 165 - Kernel entry (head.S) 166 - -------------------------- 167 - The initial entry into the kernel is via head.S, which uses machine 168 - independent code. The machine is selected by the value of 'r1' on 169 - entry, which must be kept unique. 170 - 171 - Due to the large number of machines which the ARM port of Linux provides 172 - for, we have a method to manage this which ensures that we don't end up 173 - duplicating large amounts of code. 174 - 175 - We group machine (or platform) support code into machine classes. A 176 - class typically based around one or more system on a chip devices, and 177 - acts as a natural container around the actual implementations. These 178 - classes are given directories - arch/arm/mach-<class> and 179 - arch/arm/mach-<class> - which contain the source files to/include/mach 180 - support the machine class. This directories also contain any machine 181 - specific supporting code. 182 - 183 - For example, the SA1100 class is based upon the SA1100 and SA1110 SoC 184 - devices, and contains the code to support the way the on-board and off- 185 - board devices are used, or the device is setup, and provides that 186 - machine specific "personality." 187 - 188 - For platforms that support device tree (DT), the machine selection is 189 - controlled at runtime by passing the device tree blob to the kernel. At 190 - compile-time, support for the machine type must be selected. This allows for 191 - a single multiplatform kernel build to be used for several machine types. 192 - 193 - For platforms that do not use device tree, this machine selection is 194 - controlled by the machine type ID, which acts both as a run-time and a 195 - compile-time code selection method. You can register a new machine via the 196 - web site at: 197 - 198 - <http://www.arm.linux.org.uk/developer/machines/> 199 - 200 - Note: Please do not register a machine type for DT-only platforms. If your 201 - platform is DT-only, you do not need a registered machine type. 202 - 203 - --- 204 - Russell King (15/03/2004)
-43
Documentation/arm/SA1100/ADSBitsy
··· 1 - ADS Bitsy Single Board Computer 2 - (It is different from Bitsy(iPAQ) of Compaq) 3 - 4 - For more details, contact Applied Data Systems or see 5 - http://www.applieddata.net/products.html 6 - 7 - The Linux support for this product has been provided by 8 - Woojung Huh <whuh@applieddata.net> 9 - 10 - Use 'make adsbitsy_config' before any 'make config'. 11 - This will set up defaults for ADS Bitsy support. 12 - 13 - The kernel zImage is linked to be loaded and executed at 0xc0400000. 14 - 15 - Linux can be used with the ADS BootLoader that ships with the 16 - newer rev boards. See their documentation on how to load Linux. 17 - 18 - Supported peripherals: 19 - - SA1100 LCD frame buffer (8/16bpp...sort of) 20 - - SA1111 USB Master 21 - - SA1100 serial port 22 - - pcmcia, compact flash 23 - - touchscreen(ucb1200) 24 - - console on LCD screen 25 - - serial ports (ttyS[0-2]) 26 - - ttyS0 is default for serial console 27 - 28 - To do: 29 - - everything else! :-) 30 - 31 - Notes: 32 - 33 - - The flash on board is divided into 3 partitions. 34 - You should be careful to use flash on board. 35 - Its partition is different from GraphicsClient Plus and GraphicsMaster 36 - 37 - - 16bpp mode requires a different cable than what ships with the board. 38 - Contact ADS or look through the manual to wire your own. Currently, 39 - if you compile with 16bit mode support and switch into a lower bpp 40 - mode, the timing is off so the image is corrupted. This will be 41 - fixed soon. 42 - 43 - Any contribution can be sent to nico@fluxnic.net and will be greatly welcome!
-300
Documentation/arm/SA1100/Assabet
··· 1 - The Intel Assabet (SA-1110 evaluation) board 2 - ============================================ 3 - 4 - Please see: 5 - http://developer.intel.com 6 - 7 - Also some notes from John G Dorsey <jd5q@andrew.cmu.edu>: 8 - http://www.cs.cmu.edu/~wearable/software/assabet.html 9 - 10 - 11 - Building the kernel 12 - ------------------- 13 - 14 - To build the kernel with current defaults: 15 - 16 - make assabet_config 17 - make oldconfig 18 - make zImage 19 - 20 - The resulting kernel image should be available in linux/arch/arm/boot/zImage. 21 - 22 - 23 - Installing a bootloader 24 - ----------------------- 25 - 26 - A couple of bootloaders able to boot Linux on Assabet are available: 27 - 28 - BLOB (http://www.lartmaker.nl/lartware/blob/) 29 - 30 - BLOB is a bootloader used within the LART project. Some contributed 31 - patches were merged into BLOB to add support for Assabet. 32 - 33 - Compaq's Bootldr + John Dorsey's patch for Assabet support 34 - (http://www.handhelds.org/Compaq/bootldr.html) 35 - (http://www.wearablegroup.org/software/bootldr/) 36 - 37 - Bootldr is the bootloader developed by Compaq for the iPAQ Pocket PC. 38 - John Dorsey has produced add-on patches to add support for Assabet and 39 - the JFFS filesystem. 40 - 41 - RedBoot (http://sources.redhat.com/redboot/) 42 - 43 - RedBoot is a bootloader developed by Red Hat based on the eCos RTOS 44 - hardware abstraction layer. It supports Assabet amongst many other 45 - hardware platforms. 46 - 47 - RedBoot is currently the recommended choice since it's the only one to have 48 - networking support, and is the most actively maintained. 49 - 50 - Brief examples on how to boot Linux with RedBoot are shown below. But first 51 - you need to have RedBoot installed in your flash memory. A known to work 52 - precompiled RedBoot binary is available from the following location: 53 - 54 - ftp://ftp.netwinder.org/users/n/nico/ 55 - ftp://ftp.arm.linux.org.uk/pub/linux/arm/people/nico/ 56 - ftp://ftp.handhelds.org/pub/linux/arm/sa-1100-patches/ 57 - 58 - Look for redboot-assabet*.tgz. Some installation infos are provided in 59 - redboot-assabet*.txt. 60 - 61 - 62 - Initial RedBoot configuration 63 - ----------------------------- 64 - 65 - The commands used here are explained in The RedBoot User's Guide available 66 - on-line at http://sources.redhat.com/ecos/docs.html. 67 - Please refer to it for explanations. 68 - 69 - If you have a CF network card (my Assabet kit contained a CF+ LP-E from 70 - Socket Communications Inc.), you should strongly consider using it for TFTP 71 - file transfers. You must insert it before RedBoot runs since it can't detect 72 - it dynamically. 73 - 74 - To initialize the flash directory: 75 - 76 - fis init -f 77 - 78 - To initialize the non-volatile settings, like whether you want to use BOOTP or 79 - a static IP address, etc, use this command: 80 - 81 - fconfig -i 82 - 83 - 84 - Writing a kernel image into flash 85 - --------------------------------- 86 - 87 - First, the kernel image must be loaded into RAM. If you have the zImage file 88 - available on a TFTP server: 89 - 90 - load zImage -r -b 0x100000 91 - 92 - If you rather want to use Y-Modem upload over the serial port: 93 - 94 - load -m ymodem -r -b 0x100000 95 - 96 - To write it to flash: 97 - 98 - fis create "Linux kernel" -b 0x100000 -l 0xc0000 99 - 100 - 101 - Booting the kernel 102 - ------------------ 103 - 104 - The kernel still requires a filesystem to boot. A ramdisk image can be loaded 105 - as follows: 106 - 107 - load ramdisk_image.gz -r -b 0x800000 108 - 109 - Again, Y-Modem upload can be used instead of TFTP by replacing the file name 110 - by '-y ymodem'. 111 - 112 - Now the kernel can be retrieved from flash like this: 113 - 114 - fis load "Linux kernel" 115 - 116 - or loaded as described previously. To boot the kernel: 117 - 118 - exec -b 0x100000 -l 0xc0000 119 - 120 - The ramdisk image could be stored into flash as well, but there are better 121 - solutions for on-flash filesystems as mentioned below. 122 - 123 - 124 - Using JFFS2 125 - ----------- 126 - 127 - Using JFFS2 (the Second Journalling Flash File System) is probably the most 128 - convenient way to store a writable filesystem into flash. JFFS2 is used in 129 - conjunction with the MTD layer which is responsible for low-level flash 130 - management. More information on the Linux MTD can be found on-line at: 131 - http://www.linux-mtd.infradead.org/. A JFFS howto with some infos about 132 - creating JFFS/JFFS2 images is available from the same site. 133 - 134 - For instance, a sample JFFS2 image can be retrieved from the same FTP sites 135 - mentioned below for the precompiled RedBoot image. 136 - 137 - To load this file: 138 - 139 - load sample_img.jffs2 -r -b 0x100000 140 - 141 - The result should look like: 142 - 143 - RedBoot> load sample_img.jffs2 -r -b 0x100000 144 - Raw file loaded 0x00100000-0x00377424 145 - 146 - Now we must know the size of the unallocated flash: 147 - 148 - fis free 149 - 150 - Result: 151 - 152 - RedBoot> fis free 153 - 0x500E0000 .. 0x503C0000 154 - 155 - The values above may be different depending on the size of the filesystem and 156 - the type of flash. See their usage below as an example and take care of 157 - substituting yours appropriately. 158 - 159 - We must determine some values: 160 - 161 - size of unallocated flash: 0x503c0000 - 0x500e0000 = 0x2e0000 162 - size of the filesystem image: 0x00377424 - 0x00100000 = 0x277424 163 - 164 - We want to fit the filesystem image of course, but we also want to give it all 165 - the remaining flash space as well. To write it: 166 - 167 - fis unlock -f 0x500E0000 -l 0x2e0000 168 - fis erase -f 0x500E0000 -l 0x2e0000 169 - fis write -b 0x100000 -l 0x277424 -f 0x500E0000 170 - fis create "JFFS2" -n -f 0x500E0000 -l 0x2e0000 171 - 172 - Now the filesystem is associated to a MTD "partition" once Linux has discovered 173 - what they are in the boot process. From Redboot, the 'fis list' command 174 - displays them: 175 - 176 - RedBoot> fis list 177 - Name FLASH addr Mem addr Length Entry point 178 - RedBoot 0x50000000 0x50000000 0x00020000 0x00000000 179 - RedBoot config 0x503C0000 0x503C0000 0x00020000 0x00000000 180 - FIS directory 0x503E0000 0x503E0000 0x00020000 0x00000000 181 - Linux kernel 0x50020000 0x00100000 0x000C0000 0x00000000 182 - JFFS2 0x500E0000 0x500E0000 0x002E0000 0x00000000 183 - 184 - However Linux should display something like: 185 - 186 - SA1100 flash: probing 32-bit flash bus 187 - SA1100 flash: Found 2 x16 devices at 0x0 in 32-bit mode 188 - Using RedBoot partition definition 189 - Creating 5 MTD partitions on "SA1100 flash": 190 - 0x00000000-0x00020000 : "RedBoot" 191 - 0x00020000-0x000e0000 : "Linux kernel" 192 - 0x000e0000-0x003c0000 : "JFFS2" 193 - 0x003c0000-0x003e0000 : "RedBoot config" 194 - 0x003e0000-0x00400000 : "FIS directory" 195 - 196 - What's important here is the position of the partition we are interested in, 197 - which is the third one. Within Linux, this correspond to /dev/mtdblock2. 198 - Therefore to boot Linux with the kernel and its root filesystem in flash, we 199 - need this RedBoot command: 200 - 201 - fis load "Linux kernel" 202 - exec -b 0x100000 -l 0xc0000 -c "root=/dev/mtdblock2" 203 - 204 - Of course other filesystems than JFFS might be used, like cramfs for example. 205 - You might want to boot with a root filesystem over NFS, etc. It is also 206 - possible, and sometimes more convenient, to flash a filesystem directly from 207 - within Linux while booted from a ramdisk or NFS. The Linux MTD repository has 208 - many tools to deal with flash memory as well, to erase it for example. JFFS2 209 - can then be mounted directly on a freshly erased partition and files can be 210 - copied over directly. Etc... 211 - 212 - 213 - RedBoot scripting 214 - ----------------- 215 - 216 - All the commands above aren't so useful if they have to be typed in every 217 - time the Assabet is rebooted. Therefore it's possible to automate the boot 218 - process using RedBoot's scripting capability. 219 - 220 - For example, I use this to boot Linux with both the kernel and the ramdisk 221 - images retrieved from a TFTP server on the network: 222 - 223 - RedBoot> fconfig 224 - Run script at boot: false true 225 - Boot script: 226 - Enter script, terminate with empty line 227 - >> load zImage -r -b 0x100000 228 - >> load ramdisk_ks.gz -r -b 0x800000 229 - >> exec -b 0x100000 -l 0xc0000 230 - >> 231 - Boot script timeout (1000ms resolution): 3 232 - Use BOOTP for network configuration: true 233 - GDB connection port: 9000 234 - Network debug at boot time: false 235 - Update RedBoot non-volatile configuration - are you sure (y/n)? y 236 - 237 - Then, rebooting the Assabet is just a matter of waiting for the login prompt. 238 - 239 - 240 - 241 - Nicolas Pitre 242 - nico@fluxnic.net 243 - June 12, 2001 244 - 245 - 246 - Status of peripherals in -rmk tree (updated 14/10/2001) 247 - ------------------------------------------------------- 248 - 249 - Assabet: 250 - Serial ports: 251 - Radio: TX, RX, CTS, DSR, DCD, RI 252 - PM: Not tested. 253 - COM: TX, RX, CTS, DSR, DCD, RTS, DTR, PM 254 - PM: Not tested. 255 - I2C: Implemented, not fully tested. 256 - L3: Fully tested, pass. 257 - PM: Not tested. 258 - 259 - Video: 260 - LCD: Fully tested. PM 261 - (LCD doesn't like being blanked with 262 - neponset connected) 263 - Video out: Not fully 264 - 265 - Audio: 266 - UDA1341: 267 - Playback: Fully tested, pass. 268 - Record: Implemented, not tested. 269 - PM: Not tested. 270 - 271 - UCB1200: 272 - Audio play: Implemented, not heavily tested. 273 - Audio rec: Implemented, not heavily tested. 274 - Telco audio play: Implemented, not heavily tested. 275 - Telco audio rec: Implemented, not heavily tested. 276 - POTS control: No 277 - Touchscreen: Yes 278 - PM: Not tested. 279 - 280 - Other: 281 - PCMCIA: 282 - LPE: Fully tested, pass. 283 - USB: No 284 - IRDA: 285 - SIR: Fully tested, pass. 286 - FIR: Fully tested, pass. 287 - PM: Not tested. 288 - 289 - Neponset: 290 - Serial ports: 291 - COM1,2: TX, RX, CTS, DSR, DCD, RTS, DTR 292 - PM: Not tested. 293 - USB: Implemented, not heavily tested. 294 - PCMCIA: Implemented, not heavily tested. 295 - PM: Not tested. 296 - CF: Implemented, not heavily tested. 297 - PM: Not tested. 298 - 299 - More stuff can be found in the -np (Nicolas Pitre's) tree. 300 -
-66
Documentation/arm/SA1100/Brutus
··· 1 - Brutus is an evaluation platform for the SA1100 manufactured by Intel. 2 - For more details, see: 3 - 4 - http://developer.intel.com 5 - 6 - To compile for Brutus, you must issue the following commands: 7 - 8 - make brutus_config 9 - make config 10 - [accept all the defaults] 11 - make zImage 12 - 13 - The resulting kernel will end up in linux/arch/arm/boot/zImage. This file 14 - must be loaded at 0xc0008000 in Brutus's memory and execution started at 15 - 0xc0008000 as well with the value of registers r0 = 0 and r1 = 16 upon 16 - entry. 17 - 18 - But prior to execute the kernel, a ramdisk image must also be loaded in 19 - memory. Use memory address 0xd8000000 for this. Note that the file 20 - containing the (compressed) ramdisk image must not exceed 4 MB. 21 - 22 - Typically, you'll need angelboot to load the kernel. 23 - The following angelboot.opt file should be used: 24 - 25 - ----- begin angelboot.opt ----- 26 - base 0xc0008000 27 - entry 0xc0008000 28 - r0 0x00000000 29 - r1 0x00000010 30 - device /dev/ttyS0 31 - options "9600 8N1" 32 - baud 115200 33 - otherfile ramdisk_img.gz 34 - otherbase 0xd8000000 35 - ----- end angelboot.opt ----- 36 - 37 - Then load the kernel and ramdisk with: 38 - 39 - angelboot -f angelboot.opt zImage 40 - 41 - The first Brutus serial port (assumed to be linked to /dev/ttyS0 on your 42 - host PC) is used by angel to load the kernel and ramdisk image. The serial 43 - console is provided through the second Brutus serial port. To access it, 44 - you may use minicom configured with /dev/ttyS1, 9600 baud, 8N1, no flow 45 - control. 46 - 47 - Currently supported: 48 - - RS232 serial ports 49 - - audio output 50 - - LCD screen 51 - - keyboard 52 - 53 - The actual Brutus support may not be complete without extra patches. 54 - If such patches exist, they should be found from 55 - ftp.netwinder.org/users/n/nico. 56 - 57 - A full PCMCIA support is still missing, although it's possible to hack 58 - some drivers in order to drive already inserted cards at boot time with 59 - little modifications. 60 - 61 - Any contribution is welcome. 62 - 63 - Please send patches to nico@fluxnic.net 64 - 65 - Have Fun ! 66 -
-29
Documentation/arm/SA1100/CERF
··· 1 - *** The StrongARM version of the CerfBoard/Cube has been discontinued *** 2 - 3 - The Intrinsyc CerfBoard is a StrongARM 1110-based computer on a board 4 - that measures approximately 2" square. It includes an Ethernet 5 - controller, an RS232-compatible serial port, a USB function port, and 6 - one CompactFlash+ slot on the back. Pictures can be found at the 7 - Intrinsyc website, http://www.intrinsyc.com. 8 - 9 - This document describes the support in the Linux kernel for the 10 - Intrinsyc CerfBoard. 11 - 12 - Supported in this version: 13 - - CompactFlash+ slot (select PCMCIA in General Setup and any options 14 - that may be required) 15 - - Onboard Crystal CS8900 Ethernet controller (Cerf CS8900A support in 16 - Network Devices) 17 - - Serial ports with a serial console (hardcoded to 38400 8N1) 18 - 19 - In order to get this kernel onto your Cerf, you need a server that runs 20 - both BOOTP and TFTP. Detailed instructions should have come with your 21 - evaluation kit on how to use the bootloader. This series of commands 22 - will suffice: 23 - 24 - make ARCH=arm CROSS_COMPILE=arm-linux- cerfcube_defconfig 25 - make ARCH=arm CROSS_COMPILE=arm-linux- zImage 26 - make ARCH=arm CROSS_COMPILE=arm-linux- modules 27 - cp arch/arm/boot/zImage <TFTP directory> 28 - 29 - support@intrinsyc.com
-21
Documentation/arm/SA1100/FreeBird
··· 1 - Freebird-1.1 is produced by Legend(C), Inc. 2 - http://web.archive.org/web/*/http://www.legend.com.cn 3 - and software/linux maintained by Coventive(C), Inc. 4 - (http://www.coventive.com) 5 - 6 - Based on the Nicolas's strongarm kernel tree. 7 - 8 - =============================================================== 9 - Maintainer: 10 - 11 - Chester Kuo <chester@coventive.com> 12 - <chester@linux.org.tw> 13 - 14 - Author : 15 - Tim wu <timwu@coventive.com> 16 - CIH <cih@coventive.com> 17 - Eric Peng <ericpeng@coventive.com> 18 - Jeff Lee <jeff_lee@coventive.com> 19 - Allen Cheng 20 - Tony Liu <tonyliu@coventive.com> 21 -
-98
Documentation/arm/SA1100/GraphicsClient
··· 1 - ADS GraphicsClient Plus Single Board Computer 2 - 3 - For more details, contact Applied Data Systems or see 4 - http://www.applieddata.net/products.html 5 - 6 - The original Linux support for this product has been provided by 7 - Nicolas Pitre <nico@fluxnic.net>. Continued development work by 8 - Woojung Huh <whuh@applieddata.net> 9 - 10 - It's currently possible to mount a root filesystem via NFS providing a 11 - complete Linux environment. Otherwise a ramdisk image may be used. The 12 - board supports MTD/JFFS, so you could also mount something on there. 13 - 14 - Use 'make graphicsclient_config' before any 'make config'. This will set up 15 - defaults for GraphicsClient Plus support. 16 - 17 - The kernel zImage is linked to be loaded and executed at 0xc0200000. 18 - Also the following registers should have the specified values upon entry: 19 - 20 - r0 = 0 21 - r1 = 29 (this is the GraphicsClient architecture number) 22 - 23 - Linux can be used with the ADS BootLoader that ships with the 24 - newer rev boards. See their documentation on how to load Linux. 25 - Angel is not available for the GraphicsClient Plus AFAIK. 26 - 27 - There is a board known as just the GraphicsClient that ADS used to 28 - produce but has end of lifed. This code will not work on the older 29 - board with the ADS bootloader, but should still work with Angel, 30 - as outlined below. In any case, if you're planning on deploying 31 - something en masse, you should probably get the newer board. 32 - 33 - If using Angel on the older boards, here is a typical angel.opt option file 34 - if the kernel is loaded through the Angel Debug Monitor: 35 - 36 - ----- begin angelboot.opt ----- 37 - base 0xc0200000 38 - entry 0xc0200000 39 - r0 0x00000000 40 - r1 0x0000001d 41 - device /dev/ttyS1 42 - options "38400 8N1" 43 - baud 115200 44 - #otherfile ramdisk.gz 45 - #otherbase 0xc0800000 46 - exec minicom 47 - ----- end angelboot.opt ----- 48 - 49 - Then the kernel (and ramdisk if otherfile/otherbase lines above are 50 - uncommented) would be loaded with: 51 - 52 - angelboot -f angelboot.opt zImage 53 - 54 - Here it is assumed that the board is connected to ttyS1 on your PC 55 - and that minicom is preconfigured with /dev/ttyS1, 38400 baud, 8N1, no flow 56 - control by default. 57 - 58 - If any other bootloader is used, ensure it accomplish the same, especially 59 - for r0/r1 register values before jumping into the kernel. 60 - 61 - 62 - Supported peripherals: 63 - - SA1100 LCD frame buffer (8/16bpp...sort of) 64 - - on-board SMC 92C96 ethernet NIC 65 - - SA1100 serial port 66 - - flash memory access (MTD/JFFS) 67 - - pcmcia 68 - - touchscreen(ucb1200) 69 - - ps/2 keyboard 70 - - console on LCD screen 71 - - serial ports (ttyS[0-2]) 72 - - ttyS0 is default for serial console 73 - - Smart I/O (ADC, keypad, digital inputs, etc) 74 - See http://www.eurotech-inc.com/linux-sbc.asp for IOCTL documentation 75 - and example user space code. ps/2 keybd is multiplexed through this driver 76 - 77 - To do: 78 - - UCB1200 audio with new ucb_generic layer 79 - - everything else! :-) 80 - 81 - Notes: 82 - 83 - - The flash on board is divided into 3 partitions. mtd0 is where 84 - the ADS boot ROM and zImage is stored. It's been marked as 85 - read-only to keep you from blasting over the bootloader. :) mtd1 is 86 - for the ramdisk.gz image. mtd2 is user flash space and can be 87 - utilized for either JFFS or if you're feeling crazy, running ext2 88 - on top of it. If you're not using the ADS bootloader, you're 89 - welcome to blast over the mtd1 partition also. 90 - 91 - - 16bpp mode requires a different cable than what ships with the board. 92 - Contact ADS or look through the manual to wire your own. Currently, 93 - if you compile with 16bit mode support and switch into a lower bpp 94 - mode, the timing is off so the image is corrupted. This will be 95 - fixed soon. 96 - 97 - Any contribution can be sent to nico@fluxnic.net and will be greatly welcome! 98 -
-53
Documentation/arm/SA1100/GraphicsMaster
··· 1 - ADS GraphicsMaster Single Board Computer 2 - 3 - For more details, contact Applied Data Systems or see 4 - http://www.applieddata.net/products.html 5 - 6 - The original Linux support for this product has been provided by 7 - Nicolas Pitre <nico@fluxnic.net>. Continued development work by 8 - Woojung Huh <whuh@applieddata.net> 9 - 10 - Use 'make graphicsmaster_config' before any 'make config'. 11 - This will set up defaults for GraphicsMaster support. 12 - 13 - The kernel zImage is linked to be loaded and executed at 0xc0400000. 14 - 15 - Linux can be used with the ADS BootLoader that ships with the 16 - newer rev boards. See their documentation on how to load Linux. 17 - 18 - Supported peripherals: 19 - - SA1100 LCD frame buffer (8/16bpp...sort of) 20 - - SA1111 USB Master 21 - - on-board SMC 92C96 ethernet NIC 22 - - SA1100 serial port 23 - - flash memory access (MTD/JFFS) 24 - - pcmcia, compact flash 25 - - touchscreen(ucb1200) 26 - - ps/2 keyboard 27 - - console on LCD screen 28 - - serial ports (ttyS[0-2]) 29 - - ttyS0 is default for serial console 30 - - Smart I/O (ADC, keypad, digital inputs, etc) 31 - See http://www.eurotech-inc.com/linux-sbc.asp for IOCTL documentation 32 - and example user space code. ps/2 keybd is multiplexed through this driver 33 - 34 - To do: 35 - - everything else! :-) 36 - 37 - Notes: 38 - 39 - - The flash on board is divided into 3 partitions. mtd0 is where 40 - the zImage is stored. It's been marked as read-only to keep you 41 - from blasting over the bootloader. :) mtd1 is 42 - for the ramdisk.gz image. mtd2 is user flash space and can be 43 - utilized for either JFFS or if you're feeling crazy, running ext2 44 - on top of it. If you're not using the ADS bootloader, you're 45 - welcome to blast over the mtd1 partition also. 46 - 47 - - 16bpp mode requires a different cable than what ships with the board. 48 - Contact ADS or look through the manual to wire your own. Currently, 49 - if you compile with 16bit mode support and switch into a lower bpp 50 - mode, the timing is off so the image is corrupted. This will be 51 - fixed soon. 52 - 53 - Any contribution can be sent to nico@fluxnic.net and will be greatly welcome!
-17
Documentation/arm/SA1100/HUW_WEBPANEL
··· 1 - The HUW_WEBPANEL is a product of the german company Hoeft & Wessel AG 2 - 3 - If you want more information, please visit 4 - http://www.hoeft-wessel.de 5 - 6 - To build the kernel: 7 - make huw_webpanel_config 8 - make oldconfig 9 - [accept all defaults] 10 - make zImage 11 - 12 - Mostly of the work is done by: 13 - Roman Jordan jor@hoeft-wessel.de 14 - Christoph Schulz schu@hoeft-wessel.de 15 - 16 - 2000/12/18/ 17 -
-39
Documentation/arm/SA1100/Itsy
··· 1 - Itsy is a research project done by the Western Research Lab, and Systems 2 - Research Center in Palo Alto, CA. The Itsy project is one of several 3 - research projects at Compaq that are related to pocket computing. 4 - 5 - For more information, see: 6 - 7 - http://www.hpl.hp.com/downloads/crl/itsy/ 8 - 9 - Notes on initial 2.4 Itsy support (8/27/2000) : 10 - The port was done on an Itsy version 1.5 machine with a daughtercard with 11 - 64 Meg of DRAM and 32 Meg of Flash. The initial work includes support for 12 - serial console (to see what you're doing). No other devices have been 13 - enabled. 14 - 15 - To build, do a "make menuconfig" (or xmenuconfig) and select Itsy support. 16 - Disable Flash and LCD support. and then do a make zImage. 17 - Finally, you will need to cd to arch/arm/boot/tools and execute a make there 18 - to build the params-itsy program used to boot the kernel. 19 - 20 - In order to install the port of 2.4 to the itsy, You will need to set the 21 - configuration parameters in the monitor as follows: 22 - Arg 1:0x08340000, Arg2: 0xC0000000, Arg3:18 (0x12), Arg4:0 23 - Make sure the start-routine address is set to 0x00060000. 24 - 25 - Next, flash the params-itsy program to 0x00060000 ("p 1 0x00060000" in the 26 - flash menu) Flash the kernel in arch/arm/boot/zImage into 0x08340000 27 - ("p 1 0x00340000"). Finally flash an initial ramdisk into 0xC8000000 28 - ("p 2 0x0") We used ramdisk-2-30.gz from the 0.11 version directory on 29 - handhelds.org. 30 - 31 - The serial connection we established was at: 32 - 8-bit data, no parity, 1 stop bit(s), 115200.00 b/s. in the monitor, in the 33 - params-itsy program, and in the kernel itself. This can be changed, but 34 - not easily. The monitor parameters are easily changed, the params program 35 - setup is assembly outl's, and the kernel is a configuration item specific to 36 - the itsy. (i.e. grep for CONFIG_SA1100_ITSY and you'll find where it is.) 37 - 38 - 39 - This should get you a properly booting 2.4 kernel on the itsy.
-14
Documentation/arm/SA1100/LART
··· 1 - Linux Advanced Radio Terminal (LART) 2 - ------------------------------------ 3 - 4 - The LART is a small (7.5 x 10cm) SA-1100 board, designed for embedded 5 - applications. It has 32 MB DRAM, 4MB Flash ROM, double RS232 and all 6 - other StrongARM-gadgets. Almost all SA signals are directly accessible 7 - through a number of connectors. The powersupply accepts voltages 8 - between 3.5V and 16V and is overdimensioned to support a range of 9 - daughterboards. A quad Ethernet / IDE / PS2 / sound daughterboard 10 - is under development, with plenty of others in different stages of 11 - planning. 12 - 13 - The hardware designs for this board have been released under an open license; 14 - see the LART page at http://www.lartmaker.nl/ for more information.
-11
Documentation/arm/SA1100/PLEB
··· 1 - The PLEB project was started as a student initiative at the School of 2 - Computer Science and Engineering, University of New South Wales to make a 3 - pocket computer capable of running the Linux Kernel. 4 - 5 - PLEB support has yet to be fully integrated. 6 - 7 - For more information, see: 8 - 9 - http://www.cse.unsw.edu.au 10 - 11 -
-23
Documentation/arm/SA1100/Pangolin
··· 1 - Pangolin is a StrongARM 1110-based evaluation platform produced 2 - by Dialogue Technology (http://www.dialogue.com.tw/). 3 - It has EISA slots for ease of configuration with SDRAM/Flash 4 - memory card, USB/Serial/Audio card, Compact Flash card, 5 - PCMCIA/IDE card and TFT-LCD card. 6 - 7 - To compile for Pangolin, you must issue the following commands: 8 - 9 - make pangolin_config 10 - make oldconfig 11 - make zImage 12 - 13 - Supported peripherals: 14 - - SA1110 serial port (UART1/UART2/UART3) 15 - - flash memory access 16 - - compact flash driver 17 - - UDA1341 sound driver 18 - - SA1100 LCD controller for 800x600 16bpp TFT-LCD 19 - - MQ-200 driver for 800x600 16bpp TFT-LCD 20 - - Penmount(touch panel) driver 21 - - PCMCIA driver 22 - - SMC91C94 LAN driver 23 - - IDE driver (experimental)
-7
Documentation/arm/SA1100/Tifon
··· 1 - Tifon 2 - ----- 3 - 4 - More info has to come... 5 - 6 - Contact: Peter Danielsson <peter.danielsson@era-t.ericsson.se> 7 -
-2
Documentation/arm/SA1100/Yopy
··· 1 - See http://www.yopydeveloper.org for more. 2 -
-2
Documentation/arm/SA1100/empeg
··· 1 - See ../empeg/README 2 -
-11
Documentation/arm/SA1100/nanoEngine
··· 1 - nanoEngine 2 - ---------- 3 - 4 - "nanoEngine" is a SA1110 based single board computer from 5 - Bright Star Engineering Inc. See www.brightstareng.com/arm 6 - for more info. 7 - (Ref: Stuart Adams <sja@brightstareng.com>) 8 - 9 - Also visit Larry Doolittle's "Linux for the nanoEngine" site: 10 - http://www.brightstareng.com/arm/nanoeng.htm 11 -
-47
Documentation/arm/SA1100/serial_UART
··· 1 - The SA1100 serial port had its major/minor numbers officially assigned: 2 - 3 - > Date: Sun, 24 Sep 2000 21:40:27 -0700 4 - > From: H. Peter Anvin <hpa@transmeta.com> 5 - > To: Nicolas Pitre <nico@CAM.ORG> 6 - > Cc: Device List Maintainer <device@lanana.org> 7 - > Subject: Re: device 8 - > 9 - > Okay. Note that device numbers 204 and 205 are used for "low density 10 - > serial devices", so you will have a range of minors on those majors (the 11 - > tty device layer handles this just fine, so you don't have to worry about 12 - > doing anything special.) 13 - > 14 - > So your assignments are: 15 - > 16 - > 204 char Low-density serial ports 17 - > 5 = /dev/ttySA0 SA1100 builtin serial port 0 18 - > 6 = /dev/ttySA1 SA1100 builtin serial port 1 19 - > 7 = /dev/ttySA2 SA1100 builtin serial port 2 20 - > 21 - > 205 char Low-density serial ports (alternate device) 22 - > 5 = /dev/cusa0 Callout device for ttySA0 23 - > 6 = /dev/cusa1 Callout device for ttySA1 24 - > 7 = /dev/cusa2 Callout device for ttySA2 25 - > 26 - 27 - You must create those inodes in /dev on the root filesystem used 28 - by your SA1100-based device: 29 - 30 - mknod ttySA0 c 204 5 31 - mknod ttySA1 c 204 6 32 - mknod ttySA2 c 204 7 33 - mknod cusa0 c 205 5 34 - mknod cusa1 c 205 6 35 - mknod cusa2 c 205 7 36 - 37 - In addition to the creation of the appropriate device nodes above, you 38 - must ensure your user space applications make use of the correct device 39 - name. The classic example is the content of the /etc/inittab file where 40 - you might have a getty process started on ttyS0. In this case: 41 - 42 - - replace occurrences of ttyS0 with ttySA0, ttyS1 with ttySA1, etc. 43 - 44 - - don't forget to add 'ttySA0', 'console', or the appropriate tty name 45 - in /etc/securetty for root to be allowed to login as well. 46 - 47 -
Documentation/arm/SH-Mobile/.gitignore Documentation/arm/sh-mobile/.gitignore
-63
Documentation/arm/SPEAr/overview.txt
··· 1 - SPEAr ARM Linux Overview 2 - ========================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - SPEAr (Structured Processor Enhanced Architecture). 8 - weblink : http://www.st.com/spear 9 - 10 - The ST Microelectronics SPEAr range of ARM9/CortexA9 System-on-Chip CPUs are 11 - supported by the 'spear' platform of ARM Linux. Currently SPEAr1310, 12 - SPEAr1340, SPEAr300, SPEAr310, SPEAr320 and SPEAr600 SOCs are supported. 13 - 14 - Hierarchy in SPEAr is as follows: 15 - 16 - SPEAr (Platform) 17 - - SPEAr3XX (3XX SOC series, based on ARM9) 18 - - SPEAr300 (SOC) 19 - - SPEAr300 Evaluation Board 20 - - SPEAr310 (SOC) 21 - - SPEAr310 Evaluation Board 22 - - SPEAr320 (SOC) 23 - - SPEAr320 Evaluation Board 24 - - SPEAr6XX (6XX SOC series, based on ARM9) 25 - - SPEAr600 (SOC) 26 - - SPEAr600 Evaluation Board 27 - - SPEAr13XX (13XX SOC series, based on ARM CORTEXA9) 28 - - SPEAr1310 (SOC) 29 - - SPEAr1310 Evaluation Board 30 - - SPEAr1340 (SOC) 31 - - SPEAr1340 Evaluation Board 32 - 33 - Configuration 34 - ------------- 35 - 36 - A generic configuration is provided for each machine, and can be used as the 37 - default by 38 - make spear13xx_defconfig 39 - make spear3xx_defconfig 40 - make spear6xx_defconfig 41 - 42 - Layout 43 - ------ 44 - 45 - The common files for multiple machine families (SPEAr3xx, SPEAr6xx and 46 - SPEAr13xx) are located in the platform code contained in arch/arm/plat-spear 47 - with headers in plat/. 48 - 49 - Each machine series have a directory with name arch/arm/mach-spear followed by 50 - series name. Like mach-spear3xx, mach-spear6xx and mach-spear13xx. 51 - 52 - Common file for machines of spear3xx family is mach-spear3xx/spear3xx.c, for 53 - spear6xx is mach-spear6xx/spear6xx.c and for spear13xx family is 54 - mach-spear13xx/spear13xx.c. mach-spear* also contain soc/machine specific 55 - files, like spear1310.c, spear1340.c spear300.c, spear310.c, spear320.c and 56 - spear600.c. mach-spear* doesn't contains board specific files as they fully 57 - support Flattened Device Tree. 58 - 59 - 60 - Document Author 61 - --------------- 62 - 63 - Viresh Kumar <vireshk@kernel.org>, (c) 2010-2012 ST Microelectronics
-75
Documentation/arm/Samsung-S3C24XX/CPUfreq.txt
··· 1 - S3C24XX CPUfreq support 2 - ======================= 3 - 4 - Introduction 5 - ------------ 6 - 7 - The S3C24XX series support a number of power saving systems, such as 8 - the ability to change the core, memory and peripheral operating 9 - frequencies. The core control is exported via the CPUFreq driver 10 - which has a number of different manual or automatic controls over the 11 - rate the core is running at. 12 - 13 - There are two forms of the driver depending on the specific CPU and 14 - how the clocks are arranged. The first implementation used as single 15 - PLL to feed the ARM, memory and peripherals via a series of dividers 16 - and muxes and this is the implementation that is documented here. A 17 - newer version where there is a separate PLL and clock divider for the 18 - ARM core is available as a separate driver. 19 - 20 - 21 - Layout 22 - ------ 23 - 24 - The code core manages the CPU specific drivers, any data that they 25 - need to register and the interface to the generic drivers/cpufreq 26 - system. Each CPU registers a driver to control the PLL, clock dividers 27 - and anything else associated with it. Any board that wants to use this 28 - framework needs to supply at least basic details of what is required. 29 - 30 - The core registers with drivers/cpufreq at init time if all the data 31 - necessary has been supplied. 32 - 33 - 34 - CPU support 35 - ----------- 36 - 37 - The support for each CPU depends on the facilities provided by the 38 - SoC and the driver as each device has different PLL and clock chains 39 - associated with it. 40 - 41 - 42 - Slow Mode 43 - --------- 44 - 45 - The SLOW mode where the PLL is turned off altogether and the 46 - system is fed by the external crystal input is currently not 47 - supported. 48 - 49 - 50 - sysfs 51 - ----- 52 - 53 - The core code exports extra information via sysfs in the directory 54 - devices/system/cpu/cpu0/arch-freq. 55 - 56 - 57 - Board Support 58 - ------------- 59 - 60 - Each board that wants to use the cpufreq code must register some basic 61 - information with the core driver to provide information about what the 62 - board requires and any restrictions being placed on it. 63 - 64 - The board needs to supply information about whether it needs the IO bank 65 - timings changing, any maximum frequency limits and information about the 66 - SDRAM refresh rate. 67 - 68 - 69 - 70 - 71 - Document Author 72 - --------------- 73 - 74 - Ben Dooks, Copyright 2009 Simtec Electronics 75 - Licensed under GPLv2
-58
Documentation/arm/Samsung-S3C24XX/EB2410ITX.txt
··· 1 - Simtec Electronics EB2410ITX (BAST) 2 - =================================== 3 - 4 - http://www.simtec.co.uk/products/EB2410ITX/ 5 - 6 - Introduction 7 - ------------ 8 - 9 - The EB2410ITX is a S3C2410 based development board with a variety of 10 - peripherals and expansion connectors. This board is also known by 11 - the shortened name of Bast. 12 - 13 - 14 - Configuration 15 - ------------- 16 - 17 - To set the default configuration, use `make bast_defconfig` which 18 - supports the commonly used features of this board. 19 - 20 - 21 - Support 22 - ------- 23 - 24 - Official support information can be found on the Simtec Electronics 25 - website, at the product page http://www.simtec.co.uk/products/EB2410ITX/ 26 - 27 - Useful links: 28 - 29 - - Resources Page http://www.simtec.co.uk/products/EB2410ITX/resources.html 30 - 31 - - Board FAQ at http://www.simtec.co.uk/products/EB2410ITX/faq.html 32 - 33 - - Bootloader info http://www.simtec.co.uk/products/SWABLE/resources.html 34 - and FAQ http://www.simtec.co.uk/products/SWABLE/faq.html 35 - 36 - 37 - MTD 38 - --- 39 - 40 - The NAND and NOR support has been merged from the linux-mtd project. 41 - Any problems, see http://www.linux-mtd.infradead.org/ for more 42 - information or up-to-date versions of linux-mtd. 43 - 44 - 45 - IDE 46 - --- 47 - 48 - Both onboard IDE ports are supported, however there is no support for 49 - changing speed of devices, PIO Mode 4 capable drives should be used. 50 - 51 - 52 - Maintainers 53 - ----------- 54 - 55 - This board is maintained by Simtec Electronics. 56 - 57 - 58 - Copyright 2004 Ben Dooks, Simtec Electronics
-171
Documentation/arm/Samsung-S3C24XX/GPIO.txt
··· 1 - S3C24XX GPIO Control 2 - ==================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - The s3c2410 kernel provides an interface to configure and 8 - manipulate the state of the GPIO pins, and find out other 9 - information about them. 10 - 11 - There are a number of conditions attached to the configuration 12 - of the s3c2410 GPIO system, please read the Samsung provided 13 - data-sheet/users manual to find out the complete list. 14 - 15 - See Documentation/arm/Samsung/GPIO.txt for the core implementation. 16 - 17 - 18 - GPIOLIB 19 - ------- 20 - 21 - With the event of the GPIOLIB in drivers/gpio, support for some 22 - of the GPIO functions such as reading and writing a pin will 23 - be removed in favour of this common access method. 24 - 25 - Once all the extant drivers have been converted, the functions 26 - listed below will be removed (they may be marked as __deprecated 27 - in the near future). 28 - 29 - The following functions now either have a s3c_ specific variant 30 - or are merged into gpiolib. See the definitions in 31 - arch/arm/plat-samsung/include/plat/gpio-cfg.h: 32 - 33 - s3c2410_gpio_setpin() gpio_set_value() or gpio_direction_output() 34 - s3c2410_gpio_getpin() gpio_get_value() or gpio_direction_input() 35 - s3c2410_gpio_getirq() gpio_to_irq() 36 - s3c2410_gpio_cfgpin() s3c_gpio_cfgpin() 37 - s3c2410_gpio_getcfg() s3c_gpio_getcfg() 38 - s3c2410_gpio_pullup() s3c_gpio_setpull() 39 - 40 - 41 - GPIOLIB conversion 42 - ------------------ 43 - 44 - If you need to convert your board or driver to use gpiolib from the phased 45 - out s3c2410 API, then here are some notes on the process. 46 - 47 - 1) If your board is exclusively using an GPIO, say to control peripheral 48 - power, then it will require to claim the gpio with gpio_request() before 49 - it can use it. 50 - 51 - It is recommended to check the return value, with at least WARN_ON() 52 - during initialisation. 53 - 54 - 2) The s3c2410_gpio_cfgpin() can be directly replaced with s3c_gpio_cfgpin() 55 - as they have the same arguments, and can either take the pin specific 56 - values, or the more generic special-function-number arguments. 57 - 58 - 3) s3c2410_gpio_pullup() changes have the problem that while the 59 - s3c2410_gpio_pullup(x, 1) can be easily translated to the 60 - s3c_gpio_setpull(x, S3C_GPIO_PULL_NONE), the s3c2410_gpio_pullup(x, 0) 61 - are not so easy. 62 - 63 - The s3c2410_gpio_pullup(x, 0) case enables the pull-up (or in the case 64 - of some of the devices, a pull-down) and as such the new API distinguishes 65 - between the UP and DOWN case. There is currently no 'just turn on' setting 66 - which may be required if this becomes a problem. 67 - 68 - 4) s3c2410_gpio_setpin() can be replaced by gpio_set_value(), the old call 69 - does not implicitly configure the relevant gpio to output. The gpio 70 - direction should be changed before using gpio_set_value(). 71 - 72 - 5) s3c2410_gpio_getpin() is replaceable by gpio_get_value() if the pin 73 - has been set to input. It is currently unknown what the behaviour is 74 - when using gpio_get_value() on an output pin (s3c2410_gpio_getpin 75 - would return the value the pin is supposed to be outputting). 76 - 77 - 6) s3c2410_gpio_getirq() should be directly replaceable with the 78 - gpio_to_irq() call. 79 - 80 - The s3c2410_gpio and gpio_ calls have always operated on the same gpio 81 - numberspace, so there is no problem with converting the gpio numbering 82 - between the calls. 83 - 84 - 85 - Headers 86 - ------- 87 - 88 - See arch/arm/mach-s3c24xx/include/mach/regs-gpio.h for the list 89 - of GPIO pins, and the configuration values for them. This 90 - is included by using #include <mach/regs-gpio.h> 91 - 92 - 93 - PIN Numbers 94 - ----------- 95 - 96 - Each pin has an unique number associated with it in regs-gpio.h, 97 - e.g. S3C2410_GPA(0) or S3C2410_GPF(1). These defines are used to tell 98 - the GPIO functions which pin is to be used. 99 - 100 - With the conversion to gpiolib, there is no longer a direct conversion 101 - from gpio pin number to register base address as in earlier kernels. This 102 - is due to the number space required for newer SoCs where the later 103 - GPIOs are not contiguous. 104 - 105 - 106 - Configuring a pin 107 - ----------------- 108 - 109 - The following function allows the configuration of a given pin to 110 - be changed. 111 - 112 - void s3c_gpio_cfgpin(unsigned int pin, unsigned int function); 113 - 114 - e.g.: 115 - 116 - s3c_gpio_cfgpin(S3C2410_GPA(0), S3C_GPIO_SFN(1)); 117 - s3c_gpio_cfgpin(S3C2410_GPE(8), S3C_GPIO_SFN(2)); 118 - 119 - which would turn GPA(0) into the lowest Address line A0, and set 120 - GPE(8) to be connected to the SDIO/MMC controller's SDDAT1 line. 121 - 122 - 123 - Reading the current configuration 124 - --------------------------------- 125 - 126 - The current configuration of a pin can be read by using standard 127 - gpiolib function: 128 - 129 - s3c_gpio_getcfg(unsigned int pin); 130 - 131 - The return value will be from the same set of values which can be 132 - passed to s3c_gpio_cfgpin(). 133 - 134 - 135 - Configuring a pull-up resistor 136 - ------------------------------ 137 - 138 - A large proportion of the GPIO pins on the S3C2410 can have weak 139 - pull-up resistors enabled. This can be configured by the following 140 - function: 141 - 142 - void s3c_gpio_setpull(unsigned int pin, unsigned int to); 143 - 144 - Where the to value is S3C_GPIO_PULL_NONE to set the pull-up off, 145 - and S3C_GPIO_PULL_UP to enable the specified pull-up. Any other 146 - values are currently undefined. 147 - 148 - 149 - Getting and setting the state of a PIN 150 - -------------------------------------- 151 - 152 - These calls are now implemented by the relevant gpiolib calls, convert 153 - your board or driver to use gpiolib. 154 - 155 - 156 - Getting the IRQ number associated with a PIN 157 - -------------------------------------------- 158 - 159 - A standard gpiolib function can map the given pin number to an IRQ 160 - number to pass to the IRQ system. 161 - 162 - int gpio_to_irq(unsigned int pin); 163 - 164 - Note, not all pins have an IRQ. 165 - 166 - 167 - Author 168 - ------- 169 - 170 - Ben Dooks, 03 October 2004 171 - Copyright 2004 Ben Dooks, Simtec Electronics
-40
Documentation/arm/Samsung-S3C24XX/H1940.txt
··· 1 - HP IPAQ H1940 2 - ============= 3 - 4 - http://www.handhelds.org/projects/h1940.html 5 - 6 - Introduction 7 - ------------ 8 - 9 - The HP H1940 is a S3C2410 based handheld device, with 10 - bluetooth connectivity. 11 - 12 - 13 - Support 14 - ------- 15 - 16 - A variety of information is available 17 - 18 - handhelds.org project page: 19 - 20 - http://www.handhelds.org/projects/h1940.html 21 - 22 - handhelds.org wiki page: 23 - 24 - http://handhelds.org/moin/moin.cgi/HpIpaqH1940 25 - 26 - Herbert Pötzl pages: 27 - 28 - http://vserver.13thfloor.at/H1940/ 29 - 30 - 31 - Maintainers 32 - ----------- 33 - 34 - This project is being maintained and developed by a variety 35 - of people, including Ben Dooks, Arnaud Patard, and Herbert Pötzl. 36 - 37 - Thanks to the many others who have also provided support. 38 - 39 - 40 - (c) 2005 Ben Dooks
-30
Documentation/arm/Samsung-S3C24XX/NAND.txt
··· 1 - S3C24XX NAND Support 2 - ==================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - Small Page NAND 8 - --------------- 9 - 10 - The driver uses a 512 byte (1 page) ECC code for this setup. The 11 - ECC code is not directly compatible with the default kernel ECC 12 - code, so the driver enforces its own OOB layout and ECC parameters 13 - 14 - Large Page NAND 15 - --------------- 16 - 17 - The driver is capable of handling NAND flash with a 2KiB page 18 - size, with support for hardware ECC generation and correction. 19 - 20 - Unlike the 512byte page mode, the driver generates ECC data for 21 - each 256 byte block in an 2KiB page. This means that more than 22 - one error in a page can be rectified. It also means that the 23 - OOB layout remains the default kernel layout for these flashes. 24 - 25 - 26 - Document Author 27 - --------------- 28 - 29 - Ben Dooks, Copyright 2007 Simtec Electronics 30 -
-318
Documentation/arm/Samsung-S3C24XX/Overview.txt
··· 1 - S3C24XX ARM Linux Overview 2 - ========================== 3 - 4 - 5 - 6 - Introduction 7 - ------------ 8 - 9 - The Samsung S3C24XX range of ARM9 System-on-Chip CPUs are supported 10 - by the 's3c2410' architecture of ARM Linux. Currently the S3C2410, 11 - S3C2412, S3C2413, S3C2416, S3C2440, S3C2442, S3C2443 and S3C2450 devices 12 - are supported. 13 - 14 - Support for the S3C2400 and S3C24A0 series was never completed and the 15 - corresponding code has been removed after a while. If someone wishes to 16 - revive this effort, partial support can be retrieved from earlier Linux 17 - versions. 18 - 19 - The S3C2416 and S3C2450 devices are very similar and S3C2450 support is 20 - included under the arch/arm/mach-s3c2416 directory. Note, while core 21 - support for these SoCs is in, work on some of the extra peripherals 22 - and extra interrupts is still ongoing. 23 - 24 - 25 - Configuration 26 - ------------- 27 - 28 - A generic S3C2410 configuration is provided, and can be used as the 29 - default by `make s3c2410_defconfig`. This configuration has support 30 - for all the machines, and the commonly used features on them. 31 - 32 - Certain machines may have their own default configurations as well, 33 - please check the machine specific documentation. 34 - 35 - 36 - Layout 37 - ------ 38 - 39 - The core support files are located in the platform code contained in 40 - arch/arm/plat-s3c24xx with headers in include/asm-arm/plat-s3c24xx. 41 - This directory should be kept to items shared between the platform 42 - code (arch/arm/plat-s3c24xx) and the arch/arm/mach-s3c24* code. 43 - 44 - Each cpu has a directory with the support files for it, and the 45 - machines that carry the device. For example S3C2410 is contained 46 - in arch/arm/mach-s3c2410 and S3C2440 in arch/arm/mach-s3c2440 47 - 48 - Register, kernel and platform data definitions are held in the 49 - arch/arm/mach-s3c2410 directory./include/mach 50 - 51 - arch/arm/plat-s3c24xx: 52 - 53 - Files in here are either common to all the s3c24xx family, 54 - or are common to only some of them with names to indicate this 55 - status. The files that are not common to all are generally named 56 - with the initial cpu they support in the series to ensure a short 57 - name without any possibility of confusion with newer devices. 58 - 59 - As an example, initially s3c244x would cover s3c2440 and s3c2442, but 60 - with the s3c2443 which does not share many of the same drivers in 61 - this directory, the name becomes invalid. We stick to s3c2440-<x> 62 - to indicate a driver that is s3c2440 and s3c2442 compatible. 63 - 64 - This does mean that to find the status of any given SoC, a number 65 - of directories may need to be searched. 66 - 67 - 68 - Machines 69 - -------- 70 - 71 - The currently supported machines are as follows: 72 - 73 - Simtec Electronics EB2410ITX (BAST) 74 - 75 - A general purpose development board, see EB2410ITX.txt for further 76 - details 77 - 78 - Simtec Electronics IM2440D20 (Osiris) 79 - 80 - CPU Module from Simtec Electronics, with a S3C2440A CPU, nand flash 81 - and a PCMCIA controller. 82 - 83 - Samsung SMDK2410 84 - 85 - Samsung's own development board, geared for PDA work. 86 - 87 - Samsung/Aiji SMDK2412 88 - 89 - The S3C2412 version of the SMDK2440. 90 - 91 - Samsung/Aiji SMDK2413 92 - 93 - The S3C2412 version of the SMDK2440. 94 - 95 - Samsung/Meritech SMDK2440 96 - 97 - The S3C2440 compatible version of the SMDK2440, which has the 98 - option of an S3C2440 or S3C2442 CPU module. 99 - 100 - Thorcom VR1000 101 - 102 - Custom embedded board 103 - 104 - HP IPAQ 1940 105 - 106 - Handheld (IPAQ), available in several varieties 107 - 108 - HP iPAQ rx3715 109 - 110 - S3C2440 based IPAQ, with a number of variations depending on 111 - features shipped. 112 - 113 - Acer N30 114 - 115 - A S3C2410 based PDA from Acer. There is a Wiki page at 116 - http://handhelds.org/moin/moin.cgi/AcerN30Documentation . 117 - 118 - AML M5900 119 - 120 - American Microsystems' M5900 121 - 122 - Nex Vision Nexcoder 123 - Nex Vision Otom 124 - 125 - Two machines by Nex Vision 126 - 127 - 128 - Adding New Machines 129 - ------------------- 130 - 131 - The architecture has been designed to support as many machines as can 132 - be configured for it in one kernel build, and any future additions 133 - should keep this in mind before altering items outside of their own 134 - machine files. 135 - 136 - Machine definitions should be kept in linux/arch/arm/mach-s3c2410, 137 - and there are a number of examples that can be looked at. 138 - 139 - Read the kernel patch submission policies as well as the 140 - Documentation/arm directory before submitting patches. The 141 - ARM kernel series is managed by Russell King, and has a patch system 142 - located at http://www.arm.linux.org.uk/developer/patches/ 143 - as well as mailing lists that can be found from the same site. 144 - 145 - As a courtesy, please notify <ben-linux@fluff.org> of any new 146 - machines or other modifications. 147 - 148 - Any large scale modifications, or new drivers should be discussed 149 - on the ARM kernel mailing list (linux-arm-kernel) before being 150 - attempted. See http://www.arm.linux.org.uk/mailinglists/ for the 151 - mailing list information. 152 - 153 - 154 - I2C 155 - --- 156 - 157 - The hardware I2C core in the CPU is supported in single master 158 - mode, and can be configured via platform data. 159 - 160 - 161 - RTC 162 - --- 163 - 164 - Support for the onboard RTC unit, including alarm function. 165 - 166 - This has recently been upgraded to use the new RTC core, 167 - and the module has been renamed to rtc-s3c to fit in with 168 - the new rtc naming scheme. 169 - 170 - 171 - Watchdog 172 - -------- 173 - 174 - The onchip watchdog is available via the standard watchdog 175 - interface. 176 - 177 - 178 - NAND 179 - ---- 180 - 181 - The current kernels now have support for the s3c2410 NAND 182 - controller. If there are any problems the latest linux-mtd 183 - code can be found from http://www.linux-mtd.infradead.org/ 184 - 185 - For more information see Documentation/arm/Samsung-S3C24XX/NAND.txt 186 - 187 - 188 - SD/MMC 189 - ------ 190 - 191 - The SD/MMC hardware pre S3C2443 is supported in the current 192 - kernel, the driver is drivers/mmc/host/s3cmci.c and supports 193 - 1 and 4 bit SD or MMC cards. 194 - 195 - The SDIO behaviour of this driver has not been fully tested. There is no 196 - current support for hardware SDIO interrupts. 197 - 198 - 199 - Serial 200 - ------ 201 - 202 - The s3c2410 serial driver provides support for the internal 203 - serial ports. These devices appear as /dev/ttySAC0 through 3. 204 - 205 - To create device nodes for these, use the following commands 206 - 207 - mknod ttySAC0 c 204 64 208 - mknod ttySAC1 c 204 65 209 - mknod ttySAC2 c 204 66 210 - 211 - 212 - GPIO 213 - ---- 214 - 215 - The core contains support for manipulating the GPIO, see the 216 - documentation in GPIO.txt in the same directory as this file. 217 - 218 - Newer kernels carry GPIOLIB, and support is being moved towards 219 - this with some of the older support in line to be removed. 220 - 221 - As of v2.6.34, the move towards using gpiolib support is almost 222 - complete, and very little of the old calls are left. 223 - 224 - See Documentation/arm/Samsung-S3C24XX/GPIO.txt for the S3C24XX specific 225 - support and Documentation/arm/Samsung/GPIO.txt for the core Samsung 226 - implementation. 227 - 228 - 229 - Clock Management 230 - ---------------- 231 - 232 - The core provides the interface defined in the header file 233 - include/asm-arm/hardware/clock.h, to allow control over the 234 - various clock units 235 - 236 - 237 - Suspend to RAM 238 - -------------- 239 - 240 - For boards that provide support for suspend to RAM, the 241 - system can be placed into low power suspend. 242 - 243 - See Suspend.txt for more information. 244 - 245 - 246 - SPI 247 - --- 248 - 249 - SPI drivers are available for both the in-built hardware 250 - (although there is no DMA support yet) and a generic 251 - GPIO based solution. 252 - 253 - 254 - LEDs 255 - ---- 256 - 257 - There is support for GPIO based LEDs via a platform driver 258 - in the LED subsystem. 259 - 260 - 261 - Platform Data 262 - ------------- 263 - 264 - Whenever a device has platform specific data that is specified 265 - on a per-machine basis, care should be taken to ensure the 266 - following: 267 - 268 - 1) that default data is not left in the device to confuse the 269 - driver if a machine does not set it at startup 270 - 271 - 2) the data should (if possible) be marked as __initdata, 272 - to ensure that the data is thrown away if the machine is 273 - not the one currently in use. 274 - 275 - The best way of doing this is to make a function that 276 - kmalloc()s an area of memory, and copies the __initdata 277 - and then sets the relevant device's platform data. Making 278 - the function `__init` takes care of ensuring it is discarded 279 - with the rest of the initialisation code 280 - 281 - static __init void s3c24xx_xxx_set_platdata(struct xxx_data *pd) 282 - { 283 - struct s3c2410_xxx_mach_info *npd; 284 - 285 - npd = kmalloc(sizeof(struct s3c2410_xxx_mach_info), GFP_KERNEL); 286 - if (npd) { 287 - memcpy(npd, pd, sizeof(struct s3c2410_xxx_mach_info)); 288 - s3c_device_xxx.dev.platform_data = npd; 289 - } else { 290 - printk(KERN_ERR "no memory for xxx platform data\n"); 291 - } 292 - } 293 - 294 - Note, since the code is marked as __init, it should not be 295 - exported outside arch/arm/mach-s3c2410/, or exported to 296 - modules via EXPORT_SYMBOL() and related functions. 297 - 298 - 299 - Port Contributors 300 - ----------------- 301 - 302 - Ben Dooks (BJD) 303 - Vincent Sanders 304 - Herbert Potzl 305 - Arnaud Patard (RTP) 306 - Roc Wu 307 - Klaus Fetscher 308 - Dimitry Andric 309 - Shannon Holland 310 - Guillaume Gourat (NexVision) 311 - Christer Weinigel (wingel) (Acer N30) 312 - Lucas Correia Villa Real (S3C2400 port) 313 - 314 - 315 - Document Author 316 - --------------- 317 - 318 - Ben Dooks, Copyright 2004-2006 Simtec Electronics
-120
Documentation/arm/Samsung-S3C24XX/S3C2412.txt
··· 1 - S3C2412 ARM Linux Overview 2 - ========================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - The S3C2412 is part of the S3C24XX range of ARM9 System-on-Chip CPUs 8 - from Samsung. This part has an ARM926-EJS core, capable of running up 9 - to 266MHz (see data-sheet for more information) 10 - 11 - 12 - Clock 13 - ----- 14 - 15 - The core clock code provides a set of clocks to the drivers, and allows 16 - for source selection and a number of other features. 17 - 18 - 19 - Power 20 - ----- 21 - 22 - No support for suspend/resume to RAM in the current system. 23 - 24 - 25 - DMA 26 - --- 27 - 28 - No current support for DMA. 29 - 30 - 31 - GPIO 32 - ---- 33 - 34 - There is support for setting the GPIO to input/output/special function 35 - and reading or writing to them. 36 - 37 - 38 - UART 39 - ---- 40 - 41 - The UART hardware is similar to the S3C2440, and is supported by the 42 - s3c2410 driver in the drivers/serial directory. 43 - 44 - 45 - NAND 46 - ---- 47 - 48 - The NAND hardware is similar to the S3C2440, and is supported by the 49 - s3c2410 driver in the drivers/mtd/nand/raw directory. 50 - 51 - 52 - USB Host 53 - -------- 54 - 55 - The USB hardware is similar to the S3C2410, with extended clock source 56 - control. The OHCI portion is supported by the ohci-s3c2410 driver, and 57 - the clock control selection is supported by the core clock code. 58 - 59 - 60 - USB Device 61 - ---------- 62 - 63 - No current support in the kernel 64 - 65 - 66 - IRQs 67 - ---- 68 - 69 - All the standard, and external interrupt sources are supported. The 70 - extra sub-sources are not yet supported. 71 - 72 - 73 - RTC 74 - --- 75 - 76 - The RTC hardware is similar to the S3C2410, and is supported by the 77 - s3c2410-rtc driver. 78 - 79 - 80 - Watchdog 81 - -------- 82 - 83 - The watchdog hardware is the same as the S3C2410, and is supported by 84 - the s3c2410_wdt driver. 85 - 86 - 87 - MMC/SD/SDIO 88 - ----------- 89 - 90 - No current support for the MMC/SD/SDIO block. 91 - 92 - IIC 93 - --- 94 - 95 - The IIC hardware is the same as the S3C2410, and is supported by the 96 - i2c-s3c24xx driver. 97 - 98 - 99 - IIS 100 - --- 101 - 102 - No current support for the IIS interface. 103 - 104 - 105 - SPI 106 - --- 107 - 108 - No current support for the SPI interfaces. 109 - 110 - 111 - ATA 112 - --- 113 - 114 - No current support for the on-board ATA block. 115 - 116 - 117 - Document Author 118 - --------------- 119 - 120 - Ben Dooks, Copyright 2006 Simtec Electronics
-21
Documentation/arm/Samsung-S3C24XX/S3C2413.txt
··· 1 - S3C2413 ARM Linux Overview 2 - ========================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - The S3C2413 is an extended version of the S3C2412, with an camera 8 - interface and mobile DDR memory support. See the S3C2412 support 9 - documentation for more information. 10 - 11 - 12 - Camera Interface 13 - --------------- 14 - 15 - This block is currently not supported. 16 - 17 - 18 - Document Author 19 - --------------- 20 - 21 - Ben Dooks, Copyright 2006 Simtec Electronics
-56
Documentation/arm/Samsung-S3C24XX/SMDK2440.txt
··· 1 - Samsung/Meritech SMDK2440 2 - ========================= 3 - 4 - Introduction 5 - ------------ 6 - 7 - The SMDK2440 is a two part evaluation board for the Samsung S3C2440 8 - processor. It includes support for LCD, SmartMedia, Audio, SD and 9 - 10MBit Ethernet, and expansion headers for various signals, including 10 - the camera and unused GPIO. 11 - 12 - 13 - Configuration 14 - ------------- 15 - 16 - To set the default configuration, use `make smdk2440_defconfig` which 17 - will configure the common features of this board, or use 18 - `make s3c2410_config` to include support for all s3c2410/s3c2440 machines 19 - 20 - 21 - Support 22 - ------- 23 - 24 - Ben Dooks' SMDK2440 site at http://www.fluff.org/ben/smdk2440/ which 25 - includes linux based USB download tools. 26 - 27 - Some of the h1940 patches that can be found from the H1940 project 28 - site at http://www.handhelds.org/projects/h1940.html can also be 29 - applied to this board. 30 - 31 - 32 - Peripherals 33 - ----------- 34 - 35 - There is no current support for any of the extra peripherals on the 36 - base-board itself. 37 - 38 - 39 - MTD 40 - --- 41 - 42 - The NAND flash should be supported by the in kernel MTD NAND support, 43 - NOR flash will be added later. 44 - 45 - 46 - Maintainers 47 - ----------- 48 - 49 - This board is being maintained by Ben Dooks, for more info, see 50 - http://www.fluff.org/ben/smdk2440/ 51 - 52 - Many thanks to Dimitry Andric of TomTom for the loan of the SMDK2440, 53 - and to Simtec Electronics for allowing me time to work on this. 54 - 55 - 56 - (c) 2004 Ben Dooks
-137
Documentation/arm/Samsung-S3C24XX/Suspend.txt
··· 1 - S3C24XX Suspend Support 2 - ======================= 3 - 4 - 5 - Introduction 6 - ------------ 7 - 8 - The S3C24XX supports a low-power suspend mode, where the SDRAM is kept 9 - in Self-Refresh mode, and all but the essential peripheral blocks are 10 - powered down. For more information on how this works, please look 11 - at the relevant CPU datasheet from Samsung. 12 - 13 - 14 - Requirements 15 - ------------ 16 - 17 - 1) A bootloader that can support the necessary resume operation 18 - 19 - 2) Support for at least 1 source for resume 20 - 21 - 3) CONFIG_PM enabled in the kernel 22 - 23 - 4) Any peripherals that are going to be powered down at the same 24 - time require suspend/resume support. 25 - 26 - 27 - Resuming 28 - -------- 29 - 30 - The S3C2410 user manual defines the process of sending the CPU to 31 - sleep and how it resumes. The default behaviour of the Linux code 32 - is to set the GSTATUS3 register to the physical address of the 33 - code to resume Linux operation. 34 - 35 - GSTATUS4 is currently left alone by the sleep code, and is free to 36 - use for any other purposes (for example, the EB2410ITX uses this to 37 - save memory configuration in). 38 - 39 - 40 - Machine Support 41 - --------------- 42 - 43 - The machine specific functions must call the s3c_pm_init() function 44 - to say that its bootloader is capable of resuming. This can be as 45 - simple as adding the following to the machine's definition: 46 - 47 - INITMACHINE(s3c_pm_init) 48 - 49 - A board can do its own setup before calling s3c_pm_init, if it 50 - needs to setup anything else for power management support. 51 - 52 - There is currently no support for over-riding the default method of 53 - saving the resume address, if your board requires it, then contact 54 - the maintainer and discuss what is required. 55 - 56 - Note, the original method of adding an late_initcall() is wrong, 57 - and will end up initialising all compiled machines' pm init! 58 - 59 - The following is an example of code used for testing wakeup from 60 - an falling edge on IRQ_EINT0: 61 - 62 - 63 - static irqreturn_t button_irq(int irq, void *pw) 64 - { 65 - return IRQ_HANDLED; 66 - } 67 - 68 - statuc void __init machine_init(void) 69 - { 70 - ... 71 - 72 - request_irq(IRQ_EINT0, button_irq, IRQF_TRIGGER_FALLING, 73 - "button-irq-eint0", NULL); 74 - 75 - enable_irq_wake(IRQ_EINT0); 76 - 77 - s3c_pm_init(); 78 - } 79 - 80 - 81 - Debugging 82 - --------- 83 - 84 - There are several important things to remember when using PM suspend: 85 - 86 - 1) The uart drivers will disable the clocks to the UART blocks when 87 - suspending, which means that use of printascii() or similar direct 88 - access to the UARTs will cause the debug to stop. 89 - 90 - 2) While the pm code itself will attempt to re-enable the UART clocks, 91 - care should be taken that any external clock sources that the UARTs 92 - rely on are still enabled at that point. 93 - 94 - 3) If any debugging is placed in the resume path, then it must have the 95 - relevant clocks and peripherals setup before use (ie, bootloader). 96 - 97 - For example, if you transmit a character from the UART, the baud 98 - rate and uart controls must be setup beforehand. 99 - 100 - 101 - Configuration 102 - ------------- 103 - 104 - The S3C2410 specific configuration in `System Type` defines various 105 - aspects of how the S3C2410 suspend and resume support is configured 106 - 107 - `S3C2410 PM Suspend debug` 108 - 109 - This option prints messages to the serial console before and after 110 - the actual suspend, giving detailed information on what is 111 - happening 112 - 113 - 114 - `S3C2410 PM Suspend Memory CRC` 115 - 116 - Allows the entire memory to be checksummed before and after the 117 - suspend to see if there has been any corruption of the contents. 118 - 119 - Note, the time to calculate the CRC is dependent on the CPU speed 120 - and the size of memory. For an 64Mbyte RAM area on an 200MHz 121 - S3C2410, this can take approximately 4 seconds to complete. 122 - 123 - This support requires the CRC32 function to be enabled. 124 - 125 - 126 - `S3C2410 PM Suspend CRC Chunksize (KiB)` 127 - 128 - Defines the size of memory each CRC chunk covers. A smaller value 129 - will mean that the CRC data block will take more memory, but will 130 - identify any faults with better precision 131 - 132 - 133 - Document Author 134 - --------------- 135 - 136 - Ben Dooks, Copyright 2004 Simtec Electronics 137 -
-93
Documentation/arm/Samsung-S3C24XX/USB-Host.txt
··· 1 - S3C24XX USB Host support 2 - ======================== 3 - 4 - 5 - 6 - Introduction 7 - ------------ 8 - 9 - This document details the S3C2410/S3C2440 in-built OHCI USB host support. 10 - 11 - Configuration 12 - ------------- 13 - 14 - Enable at least the following kernel options: 15 - 16 - menuconfig: 17 - 18 - Device Drivers ---> 19 - USB support ---> 20 - <*> Support for Host-side USB 21 - <*> OHCI HCD support 22 - 23 - 24 - .config: 25 - CONFIG_USB 26 - CONFIG_USB_OHCI_HCD 27 - 28 - 29 - Once these options are configured, the standard set of USB device 30 - drivers can be configured and used. 31 - 32 - 33 - Board Support 34 - ------------- 35 - 36 - The driver attaches to a platform device, which will need to be 37 - added by the board specific support file in linux/arch/arm/mach-s3c2410, 38 - such as mach-bast.c or mach-smdk2410.c 39 - 40 - The platform device's platform_data field is only needed if the 41 - board implements extra power control or over-current monitoring. 42 - 43 - The OHCI driver does not ensure the state of the S3C2410's MISCCTRL 44 - register, so if both ports are to be used for the host, then it is 45 - the board support file's responsibility to ensure that the second 46 - port is configured to be connected to the OHCI core. 47 - 48 - 49 - Platform Data 50 - ------------- 51 - 52 - See arch/arm/mach-s3c2410/include/mach/usb-control.h for the 53 - descriptions of the platform device data. An implementation 54 - can be found in linux/arch/arm/mach-s3c2410/usb-simtec.c . 55 - 56 - The `struct s3c2410_hcd_info` contains a pair of functions 57 - that get called to enable over-current detection, and to 58 - control the port power status. 59 - 60 - The ports are numbered 0 and 1. 61 - 62 - power_control: 63 - 64 - Called to enable or disable the power on the port. 65 - 66 - enable_oc: 67 - 68 - Called to enable or disable the over-current monitoring. 69 - This should claim or release the resources being used to 70 - check the power condition on the port, such as an IRQ. 71 - 72 - report_oc: 73 - 74 - The OHCI driver fills this field in for the over-current code 75 - to call when there is a change to the over-current state on 76 - an port. The ports argument is a bitmask of 1 bit per port, 77 - with bit X being 1 for an over-current on port X. 78 - 79 - The function s3c2410_usb_report_oc() has been provided to 80 - ensure this is called correctly. 81 - 82 - port[x]: 83 - 84 - This is struct describes each port, 0 or 1. The platform driver 85 - should set the flags field of each port to S3C_HCDFLG_USED if 86 - the port is enabled. 87 - 88 - 89 - 90 - Document Author 91 - --------------- 92 - 93 - Ben Dooks, Copyright 2005 Simtec Electronics
-68
Documentation/arm/Samsung/Bootloader-interface.txt
··· 1 - Interface between kernel and boot loaders on Exynos boards 2 - ========================================================== 3 - 4 - Author: Krzysztof Kozlowski 5 - Date : 6 June 2015 6 - 7 - The document tries to describe currently used interface between Linux kernel 8 - and boot loaders on Samsung Exynos based boards. This is not a definition 9 - of interface but rather a description of existing state, a reference 10 - for information purpose only. 11 - 12 - In the document "boot loader" means any of following: U-boot, proprietary 13 - SBOOT or any other firmware for ARMv7 and ARMv8 initializing the board before 14 - executing kernel. 15 - 16 - 17 - 1. Non-Secure mode 18 - 19 - Address: sysram_ns_base_addr 20 - Offset Value Purpose 21 - ============================================================================= 22 - 0x08 exynos_cpu_resume_ns, mcpm_entry_point System suspend 23 - 0x0c 0x00000bad (Magic cookie) System suspend 24 - 0x1c exynos4_secondary_startup Secondary CPU boot 25 - 0x1c + 4*cpu exynos4_secondary_startup (Exynos4412) Secondary CPU boot 26 - 0x20 0xfcba0d10 (Magic cookie) AFTR 27 - 0x24 exynos_cpu_resume_ns AFTR 28 - 0x28 + 4*cpu 0x8 (Magic cookie, Exynos3250) AFTR 29 - 0x28 0x0 or last value during resume (Exynos542x) System suspend 30 - 31 - 32 - 2. Secure mode 33 - 34 - Address: sysram_base_addr 35 - Offset Value Purpose 36 - ============================================================================= 37 - 0x00 exynos4_secondary_startup Secondary CPU boot 38 - 0x04 exynos4_secondary_startup (Exynos542x) Secondary CPU boot 39 - 4*cpu exynos4_secondary_startup (Exynos4412) Secondary CPU boot 40 - 0x20 exynos_cpu_resume (Exynos4210 r1.0) AFTR 41 - 0x24 0xfcba0d10 (Magic cookie, Exynos4210 r1.0) AFTR 42 - 43 - Address: pmu_base_addr 44 - Offset Value Purpose 45 - ============================================================================= 46 - 0x0800 exynos_cpu_resume AFTR, suspend 47 - 0x0800 mcpm_entry_point (Exynos542x with MCPM) AFTR, suspend 48 - 0x0804 0xfcba0d10 (Magic cookie) AFTR 49 - 0x0804 0x00000bad (Magic cookie) System suspend 50 - 0x0814 exynos4_secondary_startup (Exynos4210 r1.1) Secondary CPU boot 51 - 0x0818 0xfcba0d10 (Magic cookie, Exynos4210 r1.1) AFTR 52 - 0x081C exynos_cpu_resume (Exynos4210 r1.1) AFTR 53 - 54 - 55 - 3. Other (regardless of secure/non-secure mode) 56 - 57 - Address: pmu_base_addr 58 - Offset Value Purpose 59 - ============================================================================= 60 - 0x0908 Non-zero Secondary CPU boot up indicator 61 - on Exynos3250 and Exynos542x 62 - 63 - 64 - 4. Glossary 65 - 66 - AFTR - ARM Off Top Running, a low power mode, Cortex cores and many other 67 - modules are power gated, except the TOP modules 68 - MCPM - Multi-Cluster Power Management
-40
Documentation/arm/Samsung/GPIO.txt
··· 1 - Samsung GPIO implementation 2 - =========================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - This outlines the Samsung GPIO implementation and the architecture 8 - specific calls provided alongside the drivers/gpio core. 9 - 10 - 11 - S3C24XX (Legacy) 12 - ---------------- 13 - 14 - See Documentation/arm/Samsung-S3C24XX/GPIO.txt for more information 15 - about these devices. Their implementation has been brought into line 16 - with the core samsung implementation described in this document. 17 - 18 - 19 - GPIOLIB integration 20 - ------------------- 21 - 22 - The gpio implementation uses gpiolib as much as possible, only providing 23 - specific calls for the items that require Samsung specific handling, such 24 - as pin special-function or pull resistor control. 25 - 26 - GPIO numbering is synchronised between the Samsung and gpiolib system. 27 - 28 - 29 - PIN configuration 30 - ----------------- 31 - 32 - Pin configuration is specific to the Samsung architecture, with each SoC 33 - registering the necessary information for the core gpio configuration 34 - implementation to configure pins as necessary. 35 - 36 - The s3c_gpio_cfgpin() and s3c_gpio_setpull() provide the means for a 37 - driver or machine to change gpio configuration. 38 - 39 - See arch/arm/plat-samsung/include/plat/gpio-cfg.h for more information 40 - on these functions.
-86
Documentation/arm/Samsung/Overview.txt
··· 1 - Samsung ARM Linux Overview 2 - ========================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - The Samsung range of ARM SoCs spans many similar devices, from the initial 8 - ARM9 through to the newest ARM cores. This document shows an overview of 9 - the current kernel support, how to use it and where to find the code 10 - that supports this. 11 - 12 - The currently supported SoCs are: 13 - 14 - - S3C24XX: See Documentation/arm/Samsung-S3C24XX/Overview.txt for full list 15 - - S3C64XX: S3C6400 and S3C6410 16 - - S5PC110 / S5PV210 17 - 18 - 19 - S3C24XX Systems 20 - --------------- 21 - 22 - There is still documentation in Documnetation/arm/Samsung-S3C24XX/ which 23 - deals with the architecture and drivers specific to these devices. 24 - 25 - See Documentation/arm/Samsung-S3C24XX/Overview.txt for more information 26 - on the implementation details and specific support. 27 - 28 - 29 - Configuration 30 - ------------- 31 - 32 - A number of configurations are supplied, as there is no current way of 33 - unifying all the SoCs into one kernel. 34 - 35 - s5pc110_defconfig - S5PC110 specific default configuration 36 - s5pv210_defconfig - S5PV210 specific default configuration 37 - 38 - 39 - Layout 40 - ------ 41 - 42 - The directory layout is currently being restructured, and consists of 43 - several platform directories and then the machine specific directories 44 - of the CPUs being built for. 45 - 46 - plat-samsung provides the base for all the implementations, and is the 47 - last in the line of include directories that are processed for the build 48 - specific information. It contains the base clock, GPIO and device definitions 49 - to get the system running. 50 - 51 - plat-s3c24xx is for s3c24xx specific builds, see the S3C24XX docs. 52 - 53 - plat-s5p is for s5p specific builds, and contains common support for the 54 - S5P specific systems. Not all S5Ps use all the features in this directory 55 - due to differences in the hardware. 56 - 57 - 58 - Layout changes 59 - -------------- 60 - 61 - The old plat-s3c and plat-s5pc1xx directories have been removed, with 62 - support moved to either plat-samsung or plat-s5p as necessary. These moves 63 - where to simplify the include and dependency issues involved with having 64 - so many different platform directories. 65 - 66 - 67 - Port Contributors 68 - ----------------- 69 - 70 - Ben Dooks (BJD) 71 - Vincent Sanders 72 - Herbert Potzl 73 - Arnaud Patard (RTP) 74 - Roc Wu 75 - Klaus Fetscher 76 - Dimitry Andric 77 - Shannon Holland 78 - Guillaume Gourat (NexVision) 79 - Christer Weinigel (wingel) (Acer N30) 80 - Lucas Correia Villa Real (S3C2400 port) 81 - 82 - 83 - Document Author 84 - --------------- 85 - 86 - Copyright 2009-2010 Ben Dooks <ben-linux@fluff.org>
Documentation/arm/Samsung/clksrc-change-registers.awk Documentation/arm/samsung/clksrc-change-registers.awk
-129
Documentation/arm/Setup
··· 1 - Kernel initialisation parameters on ARM Linux 2 - --------------------------------------------- 3 - 4 - The following document describes the kernel initialisation parameter 5 - structure, otherwise known as 'struct param_struct' which is used 6 - for most ARM Linux architectures. 7 - 8 - This structure is used to pass initialisation parameters from the 9 - kernel loader to the Linux kernel proper, and may be short lived 10 - through the kernel initialisation process. As a general rule, it 11 - should not be referenced outside of arch/arm/kernel/setup.c:setup_arch(). 12 - 13 - There are a lot of parameters listed in there, and they are described 14 - below: 15 - 16 - page_size 17 - 18 - This parameter must be set to the page size of the machine, and 19 - will be checked by the kernel. 20 - 21 - nr_pages 22 - 23 - This is the total number of pages of memory in the system. If 24 - the memory is banked, then this should contain the total number 25 - of pages in the system. 26 - 27 - If the system contains separate VRAM, this value should not 28 - include this information. 29 - 30 - ramdisk_size 31 - 32 - This is now obsolete, and should not be used. 33 - 34 - flags 35 - 36 - Various kernel flags, including: 37 - bit 0 - 1 = mount root read only 38 - bit 1 - unused 39 - bit 2 - 0 = load ramdisk 40 - bit 3 - 0 = prompt for ramdisk 41 - 42 - rootdev 43 - 44 - major/minor number pair of device to mount as the root filesystem. 45 - 46 - video_num_cols 47 - video_num_rows 48 - 49 - These two together describe the character size of the dummy console, 50 - or VGA console character size. They should not be used for any other 51 - purpose. 52 - 53 - It's generally a good idea to set these to be either standard VGA, or 54 - the equivalent character size of your fbcon display. This then allows 55 - all the bootup messages to be displayed correctly. 56 - 57 - video_x 58 - video_y 59 - 60 - This describes the character position of cursor on VGA console, and 61 - is otherwise unused. (should not be used for other console types, and 62 - should not be used for other purposes). 63 - 64 - memc_control_reg 65 - 66 - MEMC chip control register for Acorn Archimedes and Acorn A5000 67 - based machines. May be used differently by different architectures. 68 - 69 - sounddefault 70 - 71 - Default sound setting on Acorn machines. May be used differently by 72 - different architectures. 73 - 74 - adfsdrives 75 - 76 - Number of ADFS/MFM disks. May be used differently by different 77 - architectures. 78 - 79 - bytes_per_char_h 80 - bytes_per_char_v 81 - 82 - These are now obsolete, and should not be used. 83 - 84 - pages_in_bank[4] 85 - 86 - Number of pages in each bank of the systems memory (used for RiscPC). 87 - This is intended to be used on systems where the physical memory 88 - is non-contiguous from the processors point of view. 89 - 90 - pages_in_vram 91 - 92 - Number of pages in VRAM (used on Acorn RiscPC). This value may also 93 - be used by loaders if the size of the video RAM can't be obtained 94 - from the hardware. 95 - 96 - initrd_start 97 - initrd_size 98 - 99 - This describes the kernel virtual start address and size of the 100 - initial ramdisk. 101 - 102 - rd_start 103 - 104 - Start address in sectors of the ramdisk image on a floppy disk. 105 - 106 - system_rev 107 - 108 - system revision number. 109 - 110 - system_serial_low 111 - system_serial_high 112 - 113 - system 64-bit serial number 114 - 115 - mem_fclk_21285 116 - 117 - The speed of the external oscillator to the 21285 (footbridge), 118 - which control's the speed of the memory bus, timer & serial port. 119 - Depending upon the speed of the cpu its value can be between 120 - 0-66 MHz. If no params are passed or a value of zero is passed, 121 - then a value of 50 Mhz is the default on 21285 architectures. 122 - 123 - paths[8][128] 124 - 125 - These are now obsolete, and should not be used. 126 - 127 - commandline 128 - 129 - Kernel command line parameters. Details can be found elsewhere.
-55
Documentation/arm/VFP/release-notes.txt
··· 1 - Release notes for Linux Kernel VFP support code 2 - ----------------------------------------------- 3 - 4 - Date: 20 May 2004 5 - Author: Russell King 6 - 7 - This is the first release of the Linux Kernel VFP support code. It 8 - provides support for the exceptions bounced from VFP hardware found 9 - on ARM926EJ-S. 10 - 11 - This release has been validated against the SoftFloat-2b library by 12 - John R. Hauser using the TestFloat-2a test suite. Details of this 13 - library and test suite can be found at: 14 - 15 - http://www.jhauser.us/arithmetic/SoftFloat.html 16 - 17 - The operations which have been tested with this package are: 18 - 19 - - fdiv 20 - - fsub 21 - - fadd 22 - - fmul 23 - - fcmp 24 - - fcmpe 25 - - fcvtd 26 - - fcvts 27 - - fsito 28 - - ftosi 29 - - fsqrt 30 - 31 - All the above pass softfloat tests with the following exceptions: 32 - 33 - - fadd/fsub shows some differences in the handling of +0 / -0 results 34 - when input operands differ in signs. 35 - - the handling of underflow exceptions is slightly different. If a 36 - result underflows before rounding, but becomes a normalised number 37 - after rounding, we do not signal an underflow exception. 38 - 39 - Other operations which have been tested by basic assembly-only tests 40 - are: 41 - 42 - - fcpy 43 - - fabs 44 - - fneg 45 - - ftoui 46 - - ftosiz 47 - - ftouiz 48 - 49 - The combination operations have not been tested: 50 - 51 - - fmac 52 - - fnmac 53 - - fmsc 54 - - fnmsc 55 - - fnmul
+214
Documentation/arm/arm.rst
··· 1 + ======================= 2 + ARM Linux 2.6 and upper 3 + ======================= 4 + 5 + Please check <ftp://ftp.arm.linux.org.uk/pub/armlinux> for 6 + updates. 7 + 8 + Compilation of kernel 9 + --------------------- 10 + 11 + In order to compile ARM Linux, you will need a compiler capable of 12 + generating ARM ELF code with GNU extensions. GCC 3.3 is known to be 13 + a good compiler. Fortunately, you needn't guess. The kernel will report 14 + an error if your compiler is a recognized offender. 15 + 16 + To build ARM Linux natively, you shouldn't have to alter the ARCH = line 17 + in the top level Makefile. However, if you don't have the ARM Linux ELF 18 + tools installed as default, then you should change the CROSS_COMPILE 19 + line as detailed below. 20 + 21 + If you wish to cross-compile, then alter the following lines in the top 22 + level make file:: 23 + 24 + ARCH = <whatever> 25 + 26 + with:: 27 + 28 + ARCH = arm 29 + 30 + and:: 31 + 32 + CROSS_COMPILE= 33 + 34 + to:: 35 + 36 + CROSS_COMPILE=<your-path-to-your-compiler-without-gcc> 37 + 38 + eg.:: 39 + 40 + CROSS_COMPILE=arm-linux- 41 + 42 + Do a 'make config', followed by 'make Image' to build the kernel 43 + (arch/arm/boot/Image). A compressed image can be built by doing a 44 + 'make zImage' instead of 'make Image'. 45 + 46 + 47 + Bug reports etc 48 + --------------- 49 + 50 + Please send patches to the patch system. For more information, see 51 + http://www.arm.linux.org.uk/developer/patches/info.php Always include some 52 + explanation as to what the patch does and why it is needed. 53 + 54 + Bug reports should be sent to linux-arm-kernel@lists.arm.linux.org.uk, 55 + or submitted through the web form at 56 + http://www.arm.linux.org.uk/developer/ 57 + 58 + When sending bug reports, please ensure that they contain all relevant 59 + information, eg. the kernel messages that were printed before/during 60 + the problem, what you were doing, etc. 61 + 62 + 63 + Include files 64 + ------------- 65 + 66 + Several new include directories have been created under include/asm-arm, 67 + which are there to reduce the clutter in the top-level directory. These 68 + directories, and their purpose is listed below: 69 + 70 + ============= ========================================================== 71 + `arch-*` machine/platform specific header files 72 + `hardware` driver-internal ARM specific data structures/definitions 73 + `mach` descriptions of generic ARM to specific machine interfaces 74 + `proc-*` processor dependent header files (currently only two 75 + categories) 76 + ============= ========================================================== 77 + 78 + 79 + Machine/Platform support 80 + ------------------------ 81 + 82 + The ARM tree contains support for a lot of different machine types. To 83 + continue supporting these differences, it has become necessary to split 84 + machine-specific parts by directory. For this, the machine category is 85 + used to select which directories and files get included (we will use 86 + $(MACHINE) to refer to the category) 87 + 88 + To this end, we now have arch/arm/mach-$(MACHINE) directories which are 89 + designed to house the non-driver files for a particular machine (eg, PCI, 90 + memory management, architecture definitions etc). For all future 91 + machines, there should be a corresponding arch/arm/mach-$(MACHINE)/include/mach 92 + directory. 93 + 94 + 95 + Modules 96 + ------- 97 + 98 + Although modularisation is supported (and required for the FP emulator), 99 + each module on an ARM2/ARM250/ARM3 machine when is loaded will take 100 + memory up to the next 32k boundary due to the size of the pages. 101 + Therefore, is modularisation on these machines really worth it? 102 + 103 + However, ARM6 and up machines allow modules to take multiples of 4k, and 104 + as such Acorn RiscPCs and other architectures using these processors can 105 + make good use of modularisation. 106 + 107 + 108 + ADFS Image files 109 + ---------------- 110 + 111 + You can access image files on your ADFS partitions by mounting the ADFS 112 + partition, and then using the loopback device driver. You must have 113 + losetup installed. 114 + 115 + Please note that the PCEmulator DOS partitions have a partition table at 116 + the start, and as such, you will have to give '-o offset' to losetup. 117 + 118 + 119 + Request to developers 120 + --------------------- 121 + 122 + When writing device drivers which include a separate assembler file, please 123 + include it in with the C file, and not the arch/arm/lib directory. This 124 + allows the driver to be compiled as a loadable module without requiring 125 + half the code to be compiled into the kernel image. 126 + 127 + In general, try to avoid using assembler unless it is really necessary. It 128 + makes drivers far less easy to port to other hardware. 129 + 130 + 131 + ST506 hard drives 132 + ----------------- 133 + 134 + The ST506 hard drive controllers seem to be working fine (if a little 135 + slowly). At the moment they will only work off the controllers on an 136 + A4x0's motherboard, but for it to work off a Podule just requires 137 + someone with a podule to add the addresses for the IRQ mask and the 138 + HDC base to the source. 139 + 140 + As of 31/3/96 it works with two drives (you should get the ADFS 141 + `*configure` harddrive set to 2). I've got an internal 20MB and a great 142 + big external 5.25" FH 64MB drive (who could ever want more :-) ). 143 + 144 + I've just got 240K/s off it (a dd with bs=128k); thats about half of what 145 + RiscOS gets; but it's a heck of a lot better than the 50K/s I was getting 146 + last week :-) 147 + 148 + Known bug: Drive data errors can cause a hang; including cases where 149 + the controller has fixed the error using ECC. (Possibly ONLY 150 + in that case...hmm). 151 + 152 + 153 + 1772 Floppy 154 + ----------- 155 + This also seems to work OK, but hasn't been stressed much lately. It 156 + hasn't got any code for disc change detection in there at the moment which 157 + could be a bit of a problem! Suggestions on the correct way to do this 158 + are welcome. 159 + 160 + 161 + `CONFIG_MACH_` and `CONFIG_ARCH_` 162 + --------------------------------- 163 + A change was made in 2003 to the macro names for new machines. 164 + Historically, `CONFIG_ARCH_` was used for the bonafide architecture, 165 + e.g. SA1100, as well as implementations of the architecture, 166 + e.g. Assabet. It was decided to change the implementation macros 167 + to read `CONFIG_MACH_` for clarity. Moreover, a retroactive fixup has 168 + not been made because it would complicate patching. 169 + 170 + Previous registrations may be found online. 171 + 172 + <http://www.arm.linux.org.uk/developer/machines/> 173 + 174 + Kernel entry (head.S) 175 + --------------------- 176 + The initial entry into the kernel is via head.S, which uses machine 177 + independent code. The machine is selected by the value of 'r1' on 178 + entry, which must be kept unique. 179 + 180 + Due to the large number of machines which the ARM port of Linux provides 181 + for, we have a method to manage this which ensures that we don't end up 182 + duplicating large amounts of code. 183 + 184 + We group machine (or platform) support code into machine classes. A 185 + class typically based around one or more system on a chip devices, and 186 + acts as a natural container around the actual implementations. These 187 + classes are given directories - arch/arm/mach-<class> and 188 + arch/arm/mach-<class> - which contain the source files to/include/mach 189 + support the machine class. This directories also contain any machine 190 + specific supporting code. 191 + 192 + For example, the SA1100 class is based upon the SA1100 and SA1110 SoC 193 + devices, and contains the code to support the way the on-board and off- 194 + board devices are used, or the device is setup, and provides that 195 + machine specific "personality." 196 + 197 + For platforms that support device tree (DT), the machine selection is 198 + controlled at runtime by passing the device tree blob to the kernel. At 199 + compile-time, support for the machine type must be selected. This allows for 200 + a single multiplatform kernel build to be used for several machine types. 201 + 202 + For platforms that do not use device tree, this machine selection is 203 + controlled by the machine type ID, which acts both as a run-time and a 204 + compile-time code selection method. You can register a new machine via the 205 + web site at: 206 + 207 + <http://www.arm.linux.org.uk/developer/machines/> 208 + 209 + Note: Please do not register a machine type for DT-only platforms. If your 210 + platform is DT-only, you do not need a registered machine type. 211 + 212 + --- 213 + 214 + Russell King (15/03/2004)
+237
Documentation/arm/booting.rst
··· 1 + ================= 2 + Booting ARM Linux 3 + ================= 4 + 5 + Author: Russell King 6 + 7 + Date : 18 May 2002 8 + 9 + The following documentation is relevant to 2.4.18-rmk6 and beyond. 10 + 11 + In order to boot ARM Linux, you require a boot loader, which is a small 12 + program that runs before the main kernel. The boot loader is expected 13 + to initialise various devices, and eventually call the Linux kernel, 14 + passing information to the kernel. 15 + 16 + Essentially, the boot loader should provide (as a minimum) the 17 + following: 18 + 19 + 1. Setup and initialise the RAM. 20 + 2. Initialise one serial port. 21 + 3. Detect the machine type. 22 + 4. Setup the kernel tagged list. 23 + 5. Load initramfs. 24 + 6. Call the kernel image. 25 + 26 + 27 + 1. Setup and initialise RAM 28 + --------------------------- 29 + 30 + Existing boot loaders: 31 + MANDATORY 32 + New boot loaders: 33 + MANDATORY 34 + 35 + The boot loader is expected to find and initialise all RAM that the 36 + kernel will use for volatile data storage in the system. It performs 37 + this in a machine dependent manner. (It may use internal algorithms 38 + to automatically locate and size all RAM, or it may use knowledge of 39 + the RAM in the machine, or any other method the boot loader designer 40 + sees fit.) 41 + 42 + 43 + 2. Initialise one serial port 44 + ----------------------------- 45 + 46 + Existing boot loaders: 47 + OPTIONAL, RECOMMENDED 48 + New boot loaders: 49 + OPTIONAL, RECOMMENDED 50 + 51 + The boot loader should initialise and enable one serial port on the 52 + target. This allows the kernel serial driver to automatically detect 53 + which serial port it should use for the kernel console (generally 54 + used for debugging purposes, or communication with the target.) 55 + 56 + As an alternative, the boot loader can pass the relevant 'console=' 57 + option to the kernel via the tagged lists specifying the port, and 58 + serial format options as described in 59 + 60 + Documentation/admin-guide/kernel-parameters.rst. 61 + 62 + 63 + 3. Detect the machine type 64 + -------------------------- 65 + 66 + Existing boot loaders: 67 + OPTIONAL 68 + New boot loaders: 69 + MANDATORY except for DT-only platforms 70 + 71 + The boot loader should detect the machine type its running on by some 72 + method. Whether this is a hard coded value or some algorithm that 73 + looks at the connected hardware is beyond the scope of this document. 74 + The boot loader must ultimately be able to provide a MACH_TYPE_xxx 75 + value to the kernel. (see linux/arch/arm/tools/mach-types). This 76 + should be passed to the kernel in register r1. 77 + 78 + For DT-only platforms, the machine type will be determined by device 79 + tree. set the machine type to all ones (~0). This is not strictly 80 + necessary, but assures that it will not match any existing types. 81 + 82 + 4. Setup boot data 83 + ------------------ 84 + 85 + Existing boot loaders: 86 + OPTIONAL, HIGHLY RECOMMENDED 87 + New boot loaders: 88 + MANDATORY 89 + 90 + The boot loader must provide either a tagged list or a dtb image for 91 + passing configuration data to the kernel. The physical address of the 92 + boot data is passed to the kernel in register r2. 93 + 94 + 4a. Setup the kernel tagged list 95 + -------------------------------- 96 + 97 + The boot loader must create and initialise the kernel tagged list. 98 + A valid tagged list starts with ATAG_CORE and ends with ATAG_NONE. 99 + The ATAG_CORE tag may or may not be empty. An empty ATAG_CORE tag 100 + has the size field set to '2' (0x00000002). The ATAG_NONE must set 101 + the size field to zero. 102 + 103 + Any number of tags can be placed in the list. It is undefined 104 + whether a repeated tag appends to the information carried by the 105 + previous tag, or whether it replaces the information in its 106 + entirety; some tags behave as the former, others the latter. 107 + 108 + The boot loader must pass at a minimum the size and location of 109 + the system memory, and root filesystem location. Therefore, the 110 + minimum tagged list should look:: 111 + 112 + +-----------+ 113 + base -> | ATAG_CORE | | 114 + +-----------+ | 115 + | ATAG_MEM | | increasing address 116 + +-----------+ | 117 + | ATAG_NONE | | 118 + +-----------+ v 119 + 120 + The tagged list should be stored in system RAM. 121 + 122 + The tagged list must be placed in a region of memory where neither 123 + the kernel decompressor nor initrd 'bootp' program will overwrite 124 + it. The recommended placement is in the first 16KiB of RAM. 125 + 126 + 4b. Setup the device tree 127 + ------------------------- 128 + 129 + The boot loader must load a device tree image (dtb) into system ram 130 + at a 64bit aligned address and initialize it with the boot data. The 131 + dtb format is documented in Documentation/devicetree/booting-without-of.txt. 132 + The kernel will look for the dtb magic value of 0xd00dfeed at the dtb 133 + physical address to determine if a dtb has been passed instead of a 134 + tagged list. 135 + 136 + The boot loader must pass at a minimum the size and location of the 137 + system memory, and the root filesystem location. The dtb must be 138 + placed in a region of memory where the kernel decompressor will not 139 + overwrite it, while remaining within the region which will be covered 140 + by the kernel's low-memory mapping. 141 + 142 + A safe location is just above the 128MiB boundary from start of RAM. 143 + 144 + 5. Load initramfs. 145 + ------------------ 146 + 147 + Existing boot loaders: 148 + OPTIONAL 149 + New boot loaders: 150 + OPTIONAL 151 + 152 + If an initramfs is in use then, as with the dtb, it must be placed in 153 + a region of memory where the kernel decompressor will not overwrite it 154 + while also with the region which will be covered by the kernel's 155 + low-memory mapping. 156 + 157 + A safe location is just above the device tree blob which itself will 158 + be loaded just above the 128MiB boundary from the start of RAM as 159 + recommended above. 160 + 161 + 6. Calling the kernel image 162 + --------------------------- 163 + 164 + Existing boot loaders: 165 + MANDATORY 166 + New boot loaders: 167 + MANDATORY 168 + 169 + There are two options for calling the kernel zImage. If the zImage 170 + is stored in flash, and is linked correctly to be run from flash, 171 + then it is legal for the boot loader to call the zImage in flash 172 + directly. 173 + 174 + The zImage may also be placed in system RAM and called there. The 175 + kernel should be placed in the first 128MiB of RAM. It is recommended 176 + that it is loaded above 32MiB in order to avoid the need to relocate 177 + prior to decompression, which will make the boot process slightly 178 + faster. 179 + 180 + When booting a raw (non-zImage) kernel the constraints are tighter. 181 + In this case the kernel must be loaded at an offset into system equal 182 + to TEXT_OFFSET - PAGE_OFFSET. 183 + 184 + In any case, the following conditions must be met: 185 + 186 + - Quiesce all DMA capable devices so that memory does not get 187 + corrupted by bogus network packets or disk data. This will save 188 + you many hours of debug. 189 + 190 + - CPU register settings 191 + 192 + - r0 = 0, 193 + - r1 = machine type number discovered in (3) above. 194 + - r2 = physical address of tagged list in system RAM, or 195 + physical address of device tree block (dtb) in system RAM 196 + 197 + - CPU mode 198 + 199 + All forms of interrupts must be disabled (IRQs and FIQs) 200 + 201 + For CPUs which do not include the ARM virtualization extensions, the 202 + CPU must be in SVC mode. (A special exception exists for Angel) 203 + 204 + CPUs which include support for the virtualization extensions can be 205 + entered in HYP mode in order to enable the kernel to make full use of 206 + these extensions. This is the recommended boot method for such CPUs, 207 + unless the virtualisations are already in use by a pre-installed 208 + hypervisor. 209 + 210 + If the kernel is not entered in HYP mode for any reason, it must be 211 + entered in SVC mode. 212 + 213 + - Caches, MMUs 214 + 215 + The MMU must be off. 216 + 217 + Instruction cache may be on or off. 218 + 219 + Data cache must be off. 220 + 221 + If the kernel is entered in HYP mode, the above requirements apply to 222 + the HYP mode configuration in addition to the ordinary PL1 (privileged 223 + kernel modes) configuration. In addition, all traps into the 224 + hypervisor must be disabled, and PL1 access must be granted for all 225 + peripherals and CPU resources for which this is architecturally 226 + possible. Except for entering in HYP mode, the system configuration 227 + should be such that a kernel which does not include support for the 228 + virtualization extensions can boot correctly without extra help. 229 + 230 + - The boot loader is expected to call the kernel image by jumping 231 + directly to the first instruction of the kernel image. 232 + 233 + On CPUs supporting the ARM instruction set, the entry must be 234 + made in ARM state, even for a Thumb-2 kernel. 235 + 236 + On CPUs supporting only the Thumb instruction set such as 237 + Cortex-M class CPUs, the entry must be made in Thumb state.
+533
Documentation/arm/cluster-pm-race-avoidance.rst
··· 1 + ========================================================= 2 + Cluster-wide Power-up/power-down race avoidance algorithm 3 + ========================================================= 4 + 5 + This file documents the algorithm which is used to coordinate CPU and 6 + cluster setup and teardown operations and to manage hardware coherency 7 + controls safely. 8 + 9 + The section "Rationale" explains what the algorithm is for and why it is 10 + needed. "Basic model" explains general concepts using a simplified view 11 + of the system. The other sections explain the actual details of the 12 + algorithm in use. 13 + 14 + 15 + Rationale 16 + --------- 17 + 18 + In a system containing multiple CPUs, it is desirable to have the 19 + ability to turn off individual CPUs when the system is idle, reducing 20 + power consumption and thermal dissipation. 21 + 22 + In a system containing multiple clusters of CPUs, it is also desirable 23 + to have the ability to turn off entire clusters. 24 + 25 + Turning entire clusters off and on is a risky business, because it 26 + involves performing potentially destructive operations affecting a group 27 + of independently running CPUs, while the OS continues to run. This 28 + means that we need some coordination in order to ensure that critical 29 + cluster-level operations are only performed when it is truly safe to do 30 + so. 31 + 32 + Simple locking may not be sufficient to solve this problem, because 33 + mechanisms like Linux spinlocks may rely on coherency mechanisms which 34 + are not immediately enabled when a cluster powers up. Since enabling or 35 + disabling those mechanisms may itself be a non-atomic operation (such as 36 + writing some hardware registers and invalidating large caches), other 37 + methods of coordination are required in order to guarantee safe 38 + power-down and power-up at the cluster level. 39 + 40 + The mechanism presented in this document describes a coherent memory 41 + based protocol for performing the needed coordination. It aims to be as 42 + lightweight as possible, while providing the required safety properties. 43 + 44 + 45 + Basic model 46 + ----------- 47 + 48 + Each cluster and CPU is assigned a state, as follows: 49 + 50 + - DOWN 51 + - COMING_UP 52 + - UP 53 + - GOING_DOWN 54 + 55 + :: 56 + 57 + +---------> UP ----------+ 58 + | v 59 + 60 + COMING_UP GOING_DOWN 61 + 62 + ^ | 63 + +--------- DOWN <--------+ 64 + 65 + 66 + DOWN: 67 + The CPU or cluster is not coherent, and is either powered off or 68 + suspended, or is ready to be powered off or suspended. 69 + 70 + COMING_UP: 71 + The CPU or cluster has committed to moving to the UP state. 72 + It may be part way through the process of initialisation and 73 + enabling coherency. 74 + 75 + UP: 76 + The CPU or cluster is active and coherent at the hardware 77 + level. A CPU in this state is not necessarily being used 78 + actively by the kernel. 79 + 80 + GOING_DOWN: 81 + The CPU or cluster has committed to moving to the DOWN 82 + state. It may be part way through the process of teardown and 83 + coherency exit. 84 + 85 + 86 + Each CPU has one of these states assigned to it at any point in time. 87 + The CPU states are described in the "CPU state" section, below. 88 + 89 + Each cluster is also assigned a state, but it is necessary to split the 90 + state value into two parts (the "cluster" state and "inbound" state) and 91 + to introduce additional states in order to avoid races between different 92 + CPUs in the cluster simultaneously modifying the state. The cluster- 93 + level states are described in the "Cluster state" section. 94 + 95 + To help distinguish the CPU states from cluster states in this 96 + discussion, the state names are given a `CPU_` prefix for the CPU states, 97 + and a `CLUSTER_` or `INBOUND_` prefix for the cluster states. 98 + 99 + 100 + CPU state 101 + --------- 102 + 103 + In this algorithm, each individual core in a multi-core processor is 104 + referred to as a "CPU". CPUs are assumed to be single-threaded: 105 + therefore, a CPU can only be doing one thing at a single point in time. 106 + 107 + This means that CPUs fit the basic model closely. 108 + 109 + The algorithm defines the following states for each CPU in the system: 110 + 111 + - CPU_DOWN 112 + - CPU_COMING_UP 113 + - CPU_UP 114 + - CPU_GOING_DOWN 115 + 116 + :: 117 + 118 + cluster setup and 119 + CPU setup complete policy decision 120 + +-----------> CPU_UP ------------+ 121 + | v 122 + 123 + CPU_COMING_UP CPU_GOING_DOWN 124 + 125 + ^ | 126 + +----------- CPU_DOWN <----------+ 127 + policy decision CPU teardown complete 128 + or hardware event 129 + 130 + 131 + The definitions of the four states correspond closely to the states of 132 + the basic model. 133 + 134 + Transitions between states occur as follows. 135 + 136 + A trigger event (spontaneous) means that the CPU can transition to the 137 + next state as a result of making local progress only, with no 138 + requirement for any external event to happen. 139 + 140 + 141 + CPU_DOWN: 142 + A CPU reaches the CPU_DOWN state when it is ready for 143 + power-down. On reaching this state, the CPU will typically 144 + power itself down or suspend itself, via a WFI instruction or a 145 + firmware call. 146 + 147 + Next state: 148 + CPU_COMING_UP 149 + Conditions: 150 + none 151 + 152 + Trigger events: 153 + a) an explicit hardware power-up operation, resulting 154 + from a policy decision on another CPU; 155 + 156 + b) a hardware event, such as an interrupt. 157 + 158 + 159 + CPU_COMING_UP: 160 + A CPU cannot start participating in hardware coherency until the 161 + cluster is set up and coherent. If the cluster is not ready, 162 + then the CPU will wait in the CPU_COMING_UP state until the 163 + cluster has been set up. 164 + 165 + Next state: 166 + CPU_UP 167 + Conditions: 168 + The CPU's parent cluster must be in CLUSTER_UP. 169 + Trigger events: 170 + Transition of the parent cluster to CLUSTER_UP. 171 + 172 + Refer to the "Cluster state" section for a description of the 173 + CLUSTER_UP state. 174 + 175 + 176 + CPU_UP: 177 + When a CPU reaches the CPU_UP state, it is safe for the CPU to 178 + start participating in local coherency. 179 + 180 + This is done by jumping to the kernel's CPU resume code. 181 + 182 + Note that the definition of this state is slightly different 183 + from the basic model definition: CPU_UP does not mean that the 184 + CPU is coherent yet, but it does mean that it is safe to resume 185 + the kernel. The kernel handles the rest of the resume 186 + procedure, so the remaining steps are not visible as part of the 187 + race avoidance algorithm. 188 + 189 + The CPU remains in this state until an explicit policy decision 190 + is made to shut down or suspend the CPU. 191 + 192 + Next state: 193 + CPU_GOING_DOWN 194 + Conditions: 195 + none 196 + Trigger events: 197 + explicit policy decision 198 + 199 + 200 + CPU_GOING_DOWN: 201 + While in this state, the CPU exits coherency, including any 202 + operations required to achieve this (such as cleaning data 203 + caches). 204 + 205 + Next state: 206 + CPU_DOWN 207 + Conditions: 208 + local CPU teardown complete 209 + Trigger events: 210 + (spontaneous) 211 + 212 + 213 + Cluster state 214 + ------------- 215 + 216 + A cluster is a group of connected CPUs with some common resources. 217 + Because a cluster contains multiple CPUs, it can be doing multiple 218 + things at the same time. This has some implications. In particular, a 219 + CPU can start up while another CPU is tearing the cluster down. 220 + 221 + In this discussion, the "outbound side" is the view of the cluster state 222 + as seen by a CPU tearing the cluster down. The "inbound side" is the 223 + view of the cluster state as seen by a CPU setting the CPU up. 224 + 225 + In order to enable safe coordination in such situations, it is important 226 + that a CPU which is setting up the cluster can advertise its state 227 + independently of the CPU which is tearing down the cluster. For this 228 + reason, the cluster state is split into two parts: 229 + 230 + "cluster" state: The global state of the cluster; or the state 231 + on the outbound side: 232 + 233 + - CLUSTER_DOWN 234 + - CLUSTER_UP 235 + - CLUSTER_GOING_DOWN 236 + 237 + "inbound" state: The state of the cluster on the inbound side. 238 + 239 + - INBOUND_NOT_COMING_UP 240 + - INBOUND_COMING_UP 241 + 242 + 243 + The different pairings of these states results in six possible 244 + states for the cluster as a whole:: 245 + 246 + CLUSTER_UP 247 + +==========> INBOUND_NOT_COMING_UP -------------+ 248 + # | 249 + | 250 + CLUSTER_UP <----+ | 251 + INBOUND_COMING_UP | v 252 + 253 + ^ CLUSTER_GOING_DOWN CLUSTER_GOING_DOWN 254 + # INBOUND_COMING_UP <=== INBOUND_NOT_COMING_UP 255 + 256 + CLUSTER_DOWN | | 257 + INBOUND_COMING_UP <----+ | 258 + | 259 + ^ | 260 + +=========== CLUSTER_DOWN <------------+ 261 + INBOUND_NOT_COMING_UP 262 + 263 + Transitions -----> can only be made by the outbound CPU, and 264 + only involve changes to the "cluster" state. 265 + 266 + Transitions ===##> can only be made by the inbound CPU, and only 267 + involve changes to the "inbound" state, except where there is no 268 + further transition possible on the outbound side (i.e., the 269 + outbound CPU has put the cluster into the CLUSTER_DOWN state). 270 + 271 + The race avoidance algorithm does not provide a way to determine 272 + which exact CPUs within the cluster play these roles. This must 273 + be decided in advance by some other means. Refer to the section 274 + "Last man and first man selection" for more explanation. 275 + 276 + 277 + CLUSTER_DOWN/INBOUND_NOT_COMING_UP is the only state where the 278 + cluster can actually be powered down. 279 + 280 + The parallelism of the inbound and outbound CPUs is observed by 281 + the existence of two different paths from CLUSTER_GOING_DOWN/ 282 + INBOUND_NOT_COMING_UP (corresponding to GOING_DOWN in the basic 283 + model) to CLUSTER_DOWN/INBOUND_COMING_UP (corresponding to 284 + COMING_UP in the basic model). The second path avoids cluster 285 + teardown completely. 286 + 287 + CLUSTER_UP/INBOUND_COMING_UP is equivalent to UP in the basic 288 + model. The final transition to CLUSTER_UP/INBOUND_NOT_COMING_UP 289 + is trivial and merely resets the state machine ready for the 290 + next cycle. 291 + 292 + Details of the allowable transitions follow. 293 + 294 + The next state in each case is notated 295 + 296 + <cluster state>/<inbound state> (<transitioner>) 297 + 298 + where the <transitioner> is the side on which the transition 299 + can occur; either the inbound or the outbound side. 300 + 301 + 302 + CLUSTER_DOWN/INBOUND_NOT_COMING_UP: 303 + Next state: 304 + CLUSTER_DOWN/INBOUND_COMING_UP (inbound) 305 + Conditions: 306 + none 307 + 308 + Trigger events: 309 + a) an explicit hardware power-up operation, resulting 310 + from a policy decision on another CPU; 311 + 312 + b) a hardware event, such as an interrupt. 313 + 314 + 315 + CLUSTER_DOWN/INBOUND_COMING_UP: 316 + 317 + In this state, an inbound CPU sets up the cluster, including 318 + enabling of hardware coherency at the cluster level and any 319 + other operations (such as cache invalidation) which are required 320 + in order to achieve this. 321 + 322 + The purpose of this state is to do sufficient cluster-level 323 + setup to enable other CPUs in the cluster to enter coherency 324 + safely. 325 + 326 + Next state: 327 + CLUSTER_UP/INBOUND_COMING_UP (inbound) 328 + Conditions: 329 + cluster-level setup and hardware coherency complete 330 + Trigger events: 331 + (spontaneous) 332 + 333 + 334 + CLUSTER_UP/INBOUND_COMING_UP: 335 + 336 + Cluster-level setup is complete and hardware coherency is 337 + enabled for the cluster. Other CPUs in the cluster can safely 338 + enter coherency. 339 + 340 + This is a transient state, leading immediately to 341 + CLUSTER_UP/INBOUND_NOT_COMING_UP. All other CPUs on the cluster 342 + should consider treat these two states as equivalent. 343 + 344 + Next state: 345 + CLUSTER_UP/INBOUND_NOT_COMING_UP (inbound) 346 + Conditions: 347 + none 348 + Trigger events: 349 + (spontaneous) 350 + 351 + 352 + CLUSTER_UP/INBOUND_NOT_COMING_UP: 353 + 354 + Cluster-level setup is complete and hardware coherency is 355 + enabled for the cluster. Other CPUs in the cluster can safely 356 + enter coherency. 357 + 358 + The cluster will remain in this state until a policy decision is 359 + made to power the cluster down. 360 + 361 + Next state: 362 + CLUSTER_GOING_DOWN/INBOUND_NOT_COMING_UP (outbound) 363 + Conditions: 364 + none 365 + Trigger events: 366 + policy decision to power down the cluster 367 + 368 + 369 + CLUSTER_GOING_DOWN/INBOUND_NOT_COMING_UP: 370 + 371 + An outbound CPU is tearing the cluster down. The selected CPU 372 + must wait in this state until all CPUs in the cluster are in the 373 + CPU_DOWN state. 374 + 375 + When all CPUs are in the CPU_DOWN state, the cluster can be torn 376 + down, for example by cleaning data caches and exiting 377 + cluster-level coherency. 378 + 379 + To avoid wasteful unnecessary teardown operations, the outbound 380 + should check the inbound cluster state for asynchronous 381 + transitions to INBOUND_COMING_UP. Alternatively, individual 382 + CPUs can be checked for entry into CPU_COMING_UP or CPU_UP. 383 + 384 + 385 + Next states: 386 + 387 + CLUSTER_DOWN/INBOUND_NOT_COMING_UP (outbound) 388 + Conditions: 389 + cluster torn down and ready to power off 390 + Trigger events: 391 + (spontaneous) 392 + 393 + CLUSTER_GOING_DOWN/INBOUND_COMING_UP (inbound) 394 + Conditions: 395 + none 396 + 397 + Trigger events: 398 + a) an explicit hardware power-up operation, 399 + resulting from a policy decision on another 400 + CPU; 401 + 402 + b) a hardware event, such as an interrupt. 403 + 404 + 405 + CLUSTER_GOING_DOWN/INBOUND_COMING_UP: 406 + 407 + The cluster is (or was) being torn down, but another CPU has 408 + come online in the meantime and is trying to set up the cluster 409 + again. 410 + 411 + If the outbound CPU observes this state, it has two choices: 412 + 413 + a) back out of teardown, restoring the cluster to the 414 + CLUSTER_UP state; 415 + 416 + b) finish tearing the cluster down and put the cluster 417 + in the CLUSTER_DOWN state; the inbound CPU will 418 + set up the cluster again from there. 419 + 420 + Choice (a) permits the removal of some latency by avoiding 421 + unnecessary teardown and setup operations in situations where 422 + the cluster is not really going to be powered down. 423 + 424 + 425 + Next states: 426 + 427 + CLUSTER_UP/INBOUND_COMING_UP (outbound) 428 + Conditions: 429 + cluster-level setup and hardware 430 + coherency complete 431 + 432 + Trigger events: 433 + (spontaneous) 434 + 435 + CLUSTER_DOWN/INBOUND_COMING_UP (outbound) 436 + Conditions: 437 + cluster torn down and ready to power off 438 + 439 + Trigger events: 440 + (spontaneous) 441 + 442 + 443 + Last man and First man selection 444 + -------------------------------- 445 + 446 + The CPU which performs cluster tear-down operations on the outbound side 447 + is commonly referred to as the "last man". 448 + 449 + The CPU which performs cluster setup on the inbound side is commonly 450 + referred to as the "first man". 451 + 452 + The race avoidance algorithm documented above does not provide a 453 + mechanism to choose which CPUs should play these roles. 454 + 455 + 456 + Last man: 457 + 458 + When shutting down the cluster, all the CPUs involved are initially 459 + executing Linux and hence coherent. Therefore, ordinary spinlocks can 460 + be used to select a last man safely, before the CPUs become 461 + non-coherent. 462 + 463 + 464 + First man: 465 + 466 + Because CPUs may power up asynchronously in response to external wake-up 467 + events, a dynamic mechanism is needed to make sure that only one CPU 468 + attempts to play the first man role and do the cluster-level 469 + initialisation: any other CPUs must wait for this to complete before 470 + proceeding. 471 + 472 + Cluster-level initialisation may involve actions such as configuring 473 + coherency controls in the bus fabric. 474 + 475 + The current implementation in mcpm_head.S uses a separate mutual exclusion 476 + mechanism to do this arbitration. This mechanism is documented in 477 + detail in vlocks.txt. 478 + 479 + 480 + Features and Limitations 481 + ------------------------ 482 + 483 + Implementation: 484 + 485 + The current ARM-based implementation is split between 486 + arch/arm/common/mcpm_head.S (low-level inbound CPU operations) and 487 + arch/arm/common/mcpm_entry.c (everything else): 488 + 489 + __mcpm_cpu_going_down() signals the transition of a CPU to the 490 + CPU_GOING_DOWN state. 491 + 492 + __mcpm_cpu_down() signals the transition of a CPU to the CPU_DOWN 493 + state. 494 + 495 + A CPU transitions to CPU_COMING_UP and then to CPU_UP via the 496 + low-level power-up code in mcpm_head.S. This could 497 + involve CPU-specific setup code, but in the current 498 + implementation it does not. 499 + 500 + __mcpm_outbound_enter_critical() and __mcpm_outbound_leave_critical() 501 + handle transitions from CLUSTER_UP to CLUSTER_GOING_DOWN 502 + and from there to CLUSTER_DOWN or back to CLUSTER_UP (in 503 + the case of an aborted cluster power-down). 504 + 505 + These functions are more complex than the __mcpm_cpu_*() 506 + functions due to the extra inter-CPU coordination which 507 + is needed for safe transitions at the cluster level. 508 + 509 + A cluster transitions from CLUSTER_DOWN back to CLUSTER_UP via 510 + the low-level power-up code in mcpm_head.S. This 511 + typically involves platform-specific setup code, 512 + provided by the platform-specific power_up_setup 513 + function registered via mcpm_sync_init. 514 + 515 + Deep topologies: 516 + 517 + As currently described and implemented, the algorithm does not 518 + support CPU topologies involving more than two levels (i.e., 519 + clusters of clusters are not supported). The algorithm could be 520 + extended by replicating the cluster-level states for the 521 + additional topological levels, and modifying the transition 522 + rules for the intermediate (non-outermost) cluster levels. 523 + 524 + 525 + Colophon 526 + -------- 527 + 528 + Originally created and documented by Dave Martin for Linaro Limited, in 529 + collaboration with Nicolas Pitre and Achin Gupta. 530 + 531 + Copyright (C) 2012-2013 Linaro Limited 532 + Distributed under the terms of Version 2 of the GNU General Public 533 + License, as defined in linux/COPYING.
-498
Documentation/arm/cluster-pm-race-avoidance.txt
··· 1 - Cluster-wide Power-up/power-down race avoidance algorithm 2 - ========================================================= 3 - 4 - This file documents the algorithm which is used to coordinate CPU and 5 - cluster setup and teardown operations and to manage hardware coherency 6 - controls safely. 7 - 8 - The section "Rationale" explains what the algorithm is for and why it is 9 - needed. "Basic model" explains general concepts using a simplified view 10 - of the system. The other sections explain the actual details of the 11 - algorithm in use. 12 - 13 - 14 - Rationale 15 - --------- 16 - 17 - In a system containing multiple CPUs, it is desirable to have the 18 - ability to turn off individual CPUs when the system is idle, reducing 19 - power consumption and thermal dissipation. 20 - 21 - In a system containing multiple clusters of CPUs, it is also desirable 22 - to have the ability to turn off entire clusters. 23 - 24 - Turning entire clusters off and on is a risky business, because it 25 - involves performing potentially destructive operations affecting a group 26 - of independently running CPUs, while the OS continues to run. This 27 - means that we need some coordination in order to ensure that critical 28 - cluster-level operations are only performed when it is truly safe to do 29 - so. 30 - 31 - Simple locking may not be sufficient to solve this problem, because 32 - mechanisms like Linux spinlocks may rely on coherency mechanisms which 33 - are not immediately enabled when a cluster powers up. Since enabling or 34 - disabling those mechanisms may itself be a non-atomic operation (such as 35 - writing some hardware registers and invalidating large caches), other 36 - methods of coordination are required in order to guarantee safe 37 - power-down and power-up at the cluster level. 38 - 39 - The mechanism presented in this document describes a coherent memory 40 - based protocol for performing the needed coordination. It aims to be as 41 - lightweight as possible, while providing the required safety properties. 42 - 43 - 44 - Basic model 45 - ----------- 46 - 47 - Each cluster and CPU is assigned a state, as follows: 48 - 49 - DOWN 50 - COMING_UP 51 - UP 52 - GOING_DOWN 53 - 54 - +---------> UP ----------+ 55 - | v 56 - 57 - COMING_UP GOING_DOWN 58 - 59 - ^ | 60 - +--------- DOWN <--------+ 61 - 62 - 63 - DOWN: The CPU or cluster is not coherent, and is either powered off or 64 - suspended, or is ready to be powered off or suspended. 65 - 66 - COMING_UP: The CPU or cluster has committed to moving to the UP state. 67 - It may be part way through the process of initialisation and 68 - enabling coherency. 69 - 70 - UP: The CPU or cluster is active and coherent at the hardware 71 - level. A CPU in this state is not necessarily being used 72 - actively by the kernel. 73 - 74 - GOING_DOWN: The CPU or cluster has committed to moving to the DOWN 75 - state. It may be part way through the process of teardown and 76 - coherency exit. 77 - 78 - 79 - Each CPU has one of these states assigned to it at any point in time. 80 - The CPU states are described in the "CPU state" section, below. 81 - 82 - Each cluster is also assigned a state, but it is necessary to split the 83 - state value into two parts (the "cluster" state and "inbound" state) and 84 - to introduce additional states in order to avoid races between different 85 - CPUs in the cluster simultaneously modifying the state. The cluster- 86 - level states are described in the "Cluster state" section. 87 - 88 - To help distinguish the CPU states from cluster states in this 89 - discussion, the state names are given a CPU_ prefix for the CPU states, 90 - and a CLUSTER_ or INBOUND_ prefix for the cluster states. 91 - 92 - 93 - CPU state 94 - --------- 95 - 96 - In this algorithm, each individual core in a multi-core processor is 97 - referred to as a "CPU". CPUs are assumed to be single-threaded: 98 - therefore, a CPU can only be doing one thing at a single point in time. 99 - 100 - This means that CPUs fit the basic model closely. 101 - 102 - The algorithm defines the following states for each CPU in the system: 103 - 104 - CPU_DOWN 105 - CPU_COMING_UP 106 - CPU_UP 107 - CPU_GOING_DOWN 108 - 109 - cluster setup and 110 - CPU setup complete policy decision 111 - +-----------> CPU_UP ------------+ 112 - | v 113 - 114 - CPU_COMING_UP CPU_GOING_DOWN 115 - 116 - ^ | 117 - +----------- CPU_DOWN <----------+ 118 - policy decision CPU teardown complete 119 - or hardware event 120 - 121 - 122 - The definitions of the four states correspond closely to the states of 123 - the basic model. 124 - 125 - Transitions between states occur as follows. 126 - 127 - A trigger event (spontaneous) means that the CPU can transition to the 128 - next state as a result of making local progress only, with no 129 - requirement for any external event to happen. 130 - 131 - 132 - CPU_DOWN: 133 - 134 - A CPU reaches the CPU_DOWN state when it is ready for 135 - power-down. On reaching this state, the CPU will typically 136 - power itself down or suspend itself, via a WFI instruction or a 137 - firmware call. 138 - 139 - Next state: CPU_COMING_UP 140 - Conditions: none 141 - 142 - Trigger events: 143 - 144 - a) an explicit hardware power-up operation, resulting 145 - from a policy decision on another CPU; 146 - 147 - b) a hardware event, such as an interrupt. 148 - 149 - 150 - CPU_COMING_UP: 151 - 152 - A CPU cannot start participating in hardware coherency until the 153 - cluster is set up and coherent. If the cluster is not ready, 154 - then the CPU will wait in the CPU_COMING_UP state until the 155 - cluster has been set up. 156 - 157 - Next state: CPU_UP 158 - Conditions: The CPU's parent cluster must be in CLUSTER_UP. 159 - Trigger events: Transition of the parent cluster to CLUSTER_UP. 160 - 161 - Refer to the "Cluster state" section for a description of the 162 - CLUSTER_UP state. 163 - 164 - 165 - CPU_UP: 166 - When a CPU reaches the CPU_UP state, it is safe for the CPU to 167 - start participating in local coherency. 168 - 169 - This is done by jumping to the kernel's CPU resume code. 170 - 171 - Note that the definition of this state is slightly different 172 - from the basic model definition: CPU_UP does not mean that the 173 - CPU is coherent yet, but it does mean that it is safe to resume 174 - the kernel. The kernel handles the rest of the resume 175 - procedure, so the remaining steps are not visible as part of the 176 - race avoidance algorithm. 177 - 178 - The CPU remains in this state until an explicit policy decision 179 - is made to shut down or suspend the CPU. 180 - 181 - Next state: CPU_GOING_DOWN 182 - Conditions: none 183 - Trigger events: explicit policy decision 184 - 185 - 186 - CPU_GOING_DOWN: 187 - 188 - While in this state, the CPU exits coherency, including any 189 - operations required to achieve this (such as cleaning data 190 - caches). 191 - 192 - Next state: CPU_DOWN 193 - Conditions: local CPU teardown complete 194 - Trigger events: (spontaneous) 195 - 196 - 197 - Cluster state 198 - ------------- 199 - 200 - A cluster is a group of connected CPUs with some common resources. 201 - Because a cluster contains multiple CPUs, it can be doing multiple 202 - things at the same time. This has some implications. In particular, a 203 - CPU can start up while another CPU is tearing the cluster down. 204 - 205 - In this discussion, the "outbound side" is the view of the cluster state 206 - as seen by a CPU tearing the cluster down. The "inbound side" is the 207 - view of the cluster state as seen by a CPU setting the CPU up. 208 - 209 - In order to enable safe coordination in such situations, it is important 210 - that a CPU which is setting up the cluster can advertise its state 211 - independently of the CPU which is tearing down the cluster. For this 212 - reason, the cluster state is split into two parts: 213 - 214 - "cluster" state: The global state of the cluster; or the state 215 - on the outbound side: 216 - 217 - CLUSTER_DOWN 218 - CLUSTER_UP 219 - CLUSTER_GOING_DOWN 220 - 221 - "inbound" state: The state of the cluster on the inbound side. 222 - 223 - INBOUND_NOT_COMING_UP 224 - INBOUND_COMING_UP 225 - 226 - 227 - The different pairings of these states results in six possible 228 - states for the cluster as a whole: 229 - 230 - CLUSTER_UP 231 - +==========> INBOUND_NOT_COMING_UP -------------+ 232 - # | 233 - | 234 - CLUSTER_UP <----+ | 235 - INBOUND_COMING_UP | v 236 - 237 - ^ CLUSTER_GOING_DOWN CLUSTER_GOING_DOWN 238 - # INBOUND_COMING_UP <=== INBOUND_NOT_COMING_UP 239 - 240 - CLUSTER_DOWN | | 241 - INBOUND_COMING_UP <----+ | 242 - | 243 - ^ | 244 - +=========== CLUSTER_DOWN <------------+ 245 - INBOUND_NOT_COMING_UP 246 - 247 - Transitions -----> can only be made by the outbound CPU, and 248 - only involve changes to the "cluster" state. 249 - 250 - Transitions ===##> can only be made by the inbound CPU, and only 251 - involve changes to the "inbound" state, except where there is no 252 - further transition possible on the outbound side (i.e., the 253 - outbound CPU has put the cluster into the CLUSTER_DOWN state). 254 - 255 - The race avoidance algorithm does not provide a way to determine 256 - which exact CPUs within the cluster play these roles. This must 257 - be decided in advance by some other means. Refer to the section 258 - "Last man and first man selection" for more explanation. 259 - 260 - 261 - CLUSTER_DOWN/INBOUND_NOT_COMING_UP is the only state where the 262 - cluster can actually be powered down. 263 - 264 - The parallelism of the inbound and outbound CPUs is observed by 265 - the existence of two different paths from CLUSTER_GOING_DOWN/ 266 - INBOUND_NOT_COMING_UP (corresponding to GOING_DOWN in the basic 267 - model) to CLUSTER_DOWN/INBOUND_COMING_UP (corresponding to 268 - COMING_UP in the basic model). The second path avoids cluster 269 - teardown completely. 270 - 271 - CLUSTER_UP/INBOUND_COMING_UP is equivalent to UP in the basic 272 - model. The final transition to CLUSTER_UP/INBOUND_NOT_COMING_UP 273 - is trivial and merely resets the state machine ready for the 274 - next cycle. 275 - 276 - Details of the allowable transitions follow. 277 - 278 - The next state in each case is notated 279 - 280 - <cluster state>/<inbound state> (<transitioner>) 281 - 282 - where the <transitioner> is the side on which the transition 283 - can occur; either the inbound or the outbound side. 284 - 285 - 286 - CLUSTER_DOWN/INBOUND_NOT_COMING_UP: 287 - 288 - Next state: CLUSTER_DOWN/INBOUND_COMING_UP (inbound) 289 - Conditions: none 290 - Trigger events: 291 - 292 - a) an explicit hardware power-up operation, resulting 293 - from a policy decision on another CPU; 294 - 295 - b) a hardware event, such as an interrupt. 296 - 297 - 298 - CLUSTER_DOWN/INBOUND_COMING_UP: 299 - 300 - In this state, an inbound CPU sets up the cluster, including 301 - enabling of hardware coherency at the cluster level and any 302 - other operations (such as cache invalidation) which are required 303 - in order to achieve this. 304 - 305 - The purpose of this state is to do sufficient cluster-level 306 - setup to enable other CPUs in the cluster to enter coherency 307 - safely. 308 - 309 - Next state: CLUSTER_UP/INBOUND_COMING_UP (inbound) 310 - Conditions: cluster-level setup and hardware coherency complete 311 - Trigger events: (spontaneous) 312 - 313 - 314 - CLUSTER_UP/INBOUND_COMING_UP: 315 - 316 - Cluster-level setup is complete and hardware coherency is 317 - enabled for the cluster. Other CPUs in the cluster can safely 318 - enter coherency. 319 - 320 - This is a transient state, leading immediately to 321 - CLUSTER_UP/INBOUND_NOT_COMING_UP. All other CPUs on the cluster 322 - should consider treat these two states as equivalent. 323 - 324 - Next state: CLUSTER_UP/INBOUND_NOT_COMING_UP (inbound) 325 - Conditions: none 326 - Trigger events: (spontaneous) 327 - 328 - 329 - CLUSTER_UP/INBOUND_NOT_COMING_UP: 330 - 331 - Cluster-level setup is complete and hardware coherency is 332 - enabled for the cluster. Other CPUs in the cluster can safely 333 - enter coherency. 334 - 335 - The cluster will remain in this state until a policy decision is 336 - made to power the cluster down. 337 - 338 - Next state: CLUSTER_GOING_DOWN/INBOUND_NOT_COMING_UP (outbound) 339 - Conditions: none 340 - Trigger events: policy decision to power down the cluster 341 - 342 - 343 - CLUSTER_GOING_DOWN/INBOUND_NOT_COMING_UP: 344 - 345 - An outbound CPU is tearing the cluster down. The selected CPU 346 - must wait in this state until all CPUs in the cluster are in the 347 - CPU_DOWN state. 348 - 349 - When all CPUs are in the CPU_DOWN state, the cluster can be torn 350 - down, for example by cleaning data caches and exiting 351 - cluster-level coherency. 352 - 353 - To avoid wasteful unnecessary teardown operations, the outbound 354 - should check the inbound cluster state for asynchronous 355 - transitions to INBOUND_COMING_UP. Alternatively, individual 356 - CPUs can be checked for entry into CPU_COMING_UP or CPU_UP. 357 - 358 - 359 - Next states: 360 - 361 - CLUSTER_DOWN/INBOUND_NOT_COMING_UP (outbound) 362 - Conditions: cluster torn down and ready to power off 363 - Trigger events: (spontaneous) 364 - 365 - CLUSTER_GOING_DOWN/INBOUND_COMING_UP (inbound) 366 - Conditions: none 367 - Trigger events: 368 - 369 - a) an explicit hardware power-up operation, 370 - resulting from a policy decision on another 371 - CPU; 372 - 373 - b) a hardware event, such as an interrupt. 374 - 375 - 376 - CLUSTER_GOING_DOWN/INBOUND_COMING_UP: 377 - 378 - The cluster is (or was) being torn down, but another CPU has 379 - come online in the meantime and is trying to set up the cluster 380 - again. 381 - 382 - If the outbound CPU observes this state, it has two choices: 383 - 384 - a) back out of teardown, restoring the cluster to the 385 - CLUSTER_UP state; 386 - 387 - b) finish tearing the cluster down and put the cluster 388 - in the CLUSTER_DOWN state; the inbound CPU will 389 - set up the cluster again from there. 390 - 391 - Choice (a) permits the removal of some latency by avoiding 392 - unnecessary teardown and setup operations in situations where 393 - the cluster is not really going to be powered down. 394 - 395 - 396 - Next states: 397 - 398 - CLUSTER_UP/INBOUND_COMING_UP (outbound) 399 - Conditions: cluster-level setup and hardware 400 - coherency complete 401 - Trigger events: (spontaneous) 402 - 403 - CLUSTER_DOWN/INBOUND_COMING_UP (outbound) 404 - Conditions: cluster torn down and ready to power off 405 - Trigger events: (spontaneous) 406 - 407 - 408 - Last man and First man selection 409 - -------------------------------- 410 - 411 - The CPU which performs cluster tear-down operations on the outbound side 412 - is commonly referred to as the "last man". 413 - 414 - The CPU which performs cluster setup on the inbound side is commonly 415 - referred to as the "first man". 416 - 417 - The race avoidance algorithm documented above does not provide a 418 - mechanism to choose which CPUs should play these roles. 419 - 420 - 421 - Last man: 422 - 423 - When shutting down the cluster, all the CPUs involved are initially 424 - executing Linux and hence coherent. Therefore, ordinary spinlocks can 425 - be used to select a last man safely, before the CPUs become 426 - non-coherent. 427 - 428 - 429 - First man: 430 - 431 - Because CPUs may power up asynchronously in response to external wake-up 432 - events, a dynamic mechanism is needed to make sure that only one CPU 433 - attempts to play the first man role and do the cluster-level 434 - initialisation: any other CPUs must wait for this to complete before 435 - proceeding. 436 - 437 - Cluster-level initialisation may involve actions such as configuring 438 - coherency controls in the bus fabric. 439 - 440 - The current implementation in mcpm_head.S uses a separate mutual exclusion 441 - mechanism to do this arbitration. This mechanism is documented in 442 - detail in vlocks.txt. 443 - 444 - 445 - Features and Limitations 446 - ------------------------ 447 - 448 - Implementation: 449 - 450 - The current ARM-based implementation is split between 451 - arch/arm/common/mcpm_head.S (low-level inbound CPU operations) and 452 - arch/arm/common/mcpm_entry.c (everything else): 453 - 454 - __mcpm_cpu_going_down() signals the transition of a CPU to the 455 - CPU_GOING_DOWN state. 456 - 457 - __mcpm_cpu_down() signals the transition of a CPU to the CPU_DOWN 458 - state. 459 - 460 - A CPU transitions to CPU_COMING_UP and then to CPU_UP via the 461 - low-level power-up code in mcpm_head.S. This could 462 - involve CPU-specific setup code, but in the current 463 - implementation it does not. 464 - 465 - __mcpm_outbound_enter_critical() and __mcpm_outbound_leave_critical() 466 - handle transitions from CLUSTER_UP to CLUSTER_GOING_DOWN 467 - and from there to CLUSTER_DOWN or back to CLUSTER_UP (in 468 - the case of an aborted cluster power-down). 469 - 470 - These functions are more complex than the __mcpm_cpu_*() 471 - functions due to the extra inter-CPU coordination which 472 - is needed for safe transitions at the cluster level. 473 - 474 - A cluster transitions from CLUSTER_DOWN back to CLUSTER_UP via 475 - the low-level power-up code in mcpm_head.S. This 476 - typically involves platform-specific setup code, 477 - provided by the platform-specific power_up_setup 478 - function registered via mcpm_sync_init. 479 - 480 - Deep topologies: 481 - 482 - As currently described and implemented, the algorithm does not 483 - support CPU topologies involving more than two levels (i.e., 484 - clusters of clusters are not supported). The algorithm could be 485 - extended by replicating the cluster-level states for the 486 - additional topological levels, and modifying the transition 487 - rules for the intermediate (non-outermost) cluster levels. 488 - 489 - 490 - Colophon 491 - -------- 492 - 493 - Originally created and documented by Dave Martin for Linaro Limited, in 494 - collaboration with Nicolas Pitre and Achin Gupta. 495 - 496 - Copyright (C) 2012-2013 Linaro Limited 497 - Distributed under the terms of Version 2 of the GNU General Public 498 - License, as defined in linux/COPYING.
+72
Documentation/arm/firmware.rst
··· 1 + ========================================================================== 2 + Interface for registering and calling firmware-specific operations for ARM 3 + ========================================================================== 4 + 5 + Written by Tomasz Figa <t.figa@samsung.com> 6 + 7 + Some boards are running with secure firmware running in TrustZone secure 8 + world, which changes the way some things have to be initialized. This makes 9 + a need to provide an interface for such platforms to specify available firmware 10 + operations and call them when needed. 11 + 12 + Firmware operations can be specified by filling in a struct firmware_ops 13 + with appropriate callbacks and then registering it with register_firmware_ops() 14 + function:: 15 + 16 + void register_firmware_ops(const struct firmware_ops *ops) 17 + 18 + The ops pointer must be non-NULL. More information about struct firmware_ops 19 + and its members can be found in arch/arm/include/asm/firmware.h header. 20 + 21 + There is a default, empty set of operations provided, so there is no need to 22 + set anything if platform does not require firmware operations. 23 + 24 + To call a firmware operation, a helper macro is provided:: 25 + 26 + #define call_firmware_op(op, ...) \ 27 + ((firmware_ops->op) ? firmware_ops->op(__VA_ARGS__) : (-ENOSYS)) 28 + 29 + the macro checks if the operation is provided and calls it or otherwise returns 30 + -ENOSYS to signal that given operation is not available (for example, to allow 31 + fallback to legacy operation). 32 + 33 + Example of registering firmware operations:: 34 + 35 + /* board file */ 36 + 37 + static int platformX_do_idle(void) 38 + { 39 + /* tell platformX firmware to enter idle */ 40 + return 0; 41 + } 42 + 43 + static int platformX_cpu_boot(int i) 44 + { 45 + /* tell platformX firmware to boot CPU i */ 46 + return 0; 47 + } 48 + 49 + static const struct firmware_ops platformX_firmware_ops = { 50 + .do_idle = exynos_do_idle, 51 + .cpu_boot = exynos_cpu_boot, 52 + /* other operations not available on platformX */ 53 + }; 54 + 55 + /* init_early callback of machine descriptor */ 56 + static void __init board_init_early(void) 57 + { 58 + register_firmware_ops(&platformX_firmware_ops); 59 + } 60 + 61 + Example of using a firmware operation:: 62 + 63 + /* some platform code, e.g. SMP initialization */ 64 + 65 + __raw_writel(__pa_symbol(exynos4_secondary_startup), 66 + CPU1_BOOT_REG); 67 + 68 + /* Call Exynos specific smc call */ 69 + if (call_firmware_op(cpu_boot, cpu) == -ENOSYS) 70 + cpu_boot_legacy(...); /* Try legacy way */ 71 + 72 + gic_raise_softirq(cpumask_of(cpu), 1);
-70
Documentation/arm/firmware.txt
··· 1 - Interface for registering and calling firmware-specific operations for ARM. 2 - ---- 3 - Written by Tomasz Figa <t.figa@samsung.com> 4 - 5 - Some boards are running with secure firmware running in TrustZone secure 6 - world, which changes the way some things have to be initialized. This makes 7 - a need to provide an interface for such platforms to specify available firmware 8 - operations and call them when needed. 9 - 10 - Firmware operations can be specified by filling in a struct firmware_ops 11 - with appropriate callbacks and then registering it with register_firmware_ops() 12 - function. 13 - 14 - void register_firmware_ops(const struct firmware_ops *ops) 15 - 16 - The ops pointer must be non-NULL. More information about struct firmware_ops 17 - and its members can be found in arch/arm/include/asm/firmware.h header. 18 - 19 - There is a default, empty set of operations provided, so there is no need to 20 - set anything if platform does not require firmware operations. 21 - 22 - To call a firmware operation, a helper macro is provided 23 - 24 - #define call_firmware_op(op, ...) \ 25 - ((firmware_ops->op) ? firmware_ops->op(__VA_ARGS__) : (-ENOSYS)) 26 - 27 - the macro checks if the operation is provided and calls it or otherwise returns 28 - -ENOSYS to signal that given operation is not available (for example, to allow 29 - fallback to legacy operation). 30 - 31 - Example of registering firmware operations: 32 - 33 - /* board file */ 34 - 35 - static int platformX_do_idle(void) 36 - { 37 - /* tell platformX firmware to enter idle */ 38 - return 0; 39 - } 40 - 41 - static int platformX_cpu_boot(int i) 42 - { 43 - /* tell platformX firmware to boot CPU i */ 44 - return 0; 45 - } 46 - 47 - static const struct firmware_ops platformX_firmware_ops = { 48 - .do_idle = exynos_do_idle, 49 - .cpu_boot = exynos_cpu_boot, 50 - /* other operations not available on platformX */ 51 - }; 52 - 53 - /* init_early callback of machine descriptor */ 54 - static void __init board_init_early(void) 55 - { 56 - register_firmware_ops(&platformX_firmware_ops); 57 - } 58 - 59 - Example of using a firmware operation: 60 - 61 - /* some platform code, e.g. SMP initialization */ 62 - 63 - __raw_writel(__pa_symbol(exynos4_secondary_startup), 64 - CPU1_BOOT_REG); 65 - 66 - /* Call Exynos specific smc call */ 67 - if (call_firmware_op(cpu_boot, cpu) == -ENOSYS) 68 - cpu_boot_legacy(...); /* Try legacy way */ 69 - 70 - gic_raise_softirq(cpumask_of(cpu), 1);
+80
Documentation/arm/index.rst
··· 1 + :orphan: 2 + 3 + ================ 4 + ARM Architecture 5 + ================ 6 + 7 + .. toctree:: 8 + :maxdepth: 1 9 + 10 + arm 11 + booting 12 + cluster-pm-race-avoidance 13 + firmware 14 + interrupts 15 + kernel_mode_neon 16 + kernel_user_helpers 17 + memory 18 + mem_alignment 19 + tcm 20 + setup 21 + swp_emulation 22 + uefi 23 + vlocks 24 + porting 25 + 26 + SoC-specific documents 27 + ====================== 28 + 29 + .. toctree:: 30 + :maxdepth: 1 31 + 32 + ixp4xx 33 + 34 + marvel 35 + microchip 36 + 37 + netwinder 38 + nwfpe/index 39 + 40 + keystone/overview 41 + keystone/knav-qmss 42 + 43 + omap/index 44 + 45 + pxa/mfp 46 + 47 + 48 + sa1100/index 49 + 50 + stm32/stm32f746-overview 51 + stm32/overview 52 + stm32/stm32h743-overview 53 + stm32/stm32f769-overview 54 + stm32/stm32f429-overview 55 + stm32/stm32mp157-overview 56 + 57 + sunxi 58 + 59 + samsung/index 60 + samsung-s3c24xx/index 61 + 62 + sunxi/clocks 63 + 64 + spear/overview 65 + 66 + sti/stih416-overview 67 + sti/stih407-overview 68 + sti/stih418-overview 69 + sti/overview 70 + sti/stih415-overview 71 + 72 + vfp/release-notes 73 + 74 + 75 + .. only:: subproject and html 76 + 77 + Indices 78 + ======= 79 + 80 + * :ref:`genindex`
+169
Documentation/arm/interrupts.rst
··· 1 + ========== 2 + Interrupts 3 + ========== 4 + 5 + 2.5.2-rmk5: 6 + This is the first kernel that contains a major shake up of some of the 7 + major architecture-specific subsystems. 8 + 9 + Firstly, it contains some pretty major changes to the way we handle the 10 + MMU TLB. Each MMU TLB variant is now handled completely separately - 11 + we have TLB v3, TLB v4 (without write buffer), TLB v4 (with write buffer), 12 + and finally TLB v4 (with write buffer, with I TLB invalidate entry). 13 + There is more assembly code inside each of these functions, mainly to 14 + allow more flexible TLB handling for the future. 15 + 16 + Secondly, the IRQ subsystem. 17 + 18 + The 2.5 kernels will be having major changes to the way IRQs are handled. 19 + Unfortunately, this means that machine types that touch the irq_desc[] 20 + array (basically all machine types) will break, and this means every 21 + machine type that we currently have. 22 + 23 + Lets take an example. On the Assabet with Neponset, we have:: 24 + 25 + GPIO25 IRR:2 26 + SA1100 ------------> Neponset -----------> SA1111 27 + IIR:1 28 + -----------> USAR 29 + IIR:0 30 + -----------> SMC9196 31 + 32 + The way stuff currently works, all SA1111 interrupts are mutually 33 + exclusive of each other - if you're processing one interrupt from the 34 + SA1111 and another comes in, you have to wait for that interrupt to 35 + finish processing before you can service the new interrupt. Eg, an 36 + IDE PIO-based interrupt on the SA1111 excludes all other SA1111 and 37 + SMC9196 interrupts until it has finished transferring its multi-sector 38 + data, which can be a long time. Note also that since we loop in the 39 + SA1111 IRQ handler, SA1111 IRQs can hold off SMC9196 IRQs indefinitely. 40 + 41 + 42 + The new approach brings several new ideas... 43 + 44 + We introduce the concept of a "parent" and a "child". For example, 45 + to the Neponset handler, the "parent" is GPIO25, and the "children"d 46 + are SA1111, SMC9196 and USAR. 47 + 48 + We also bring the idea of an IRQ "chip" (mainly to reduce the size of 49 + the irqdesc array). This doesn't have to be a real "IC"; indeed the 50 + SA11x0 IRQs are handled by two separate "chip" structures, one for 51 + GPIO0-10, and another for all the rest. It is just a container for 52 + the various operations (maybe this'll change to a better name). 53 + This structure has the following operations:: 54 + 55 + struct irqchip { 56 + /* 57 + * Acknowledge the IRQ. 58 + * If this is a level-based IRQ, then it is expected to mask the IRQ 59 + * as well. 60 + */ 61 + void (*ack)(unsigned int irq); 62 + /* 63 + * Mask the IRQ in hardware. 64 + */ 65 + void (*mask)(unsigned int irq); 66 + /* 67 + * Unmask the IRQ in hardware. 68 + */ 69 + void (*unmask)(unsigned int irq); 70 + /* 71 + * Re-run the IRQ 72 + */ 73 + void (*rerun)(unsigned int irq); 74 + /* 75 + * Set the type of the IRQ. 76 + */ 77 + int (*type)(unsigned int irq, unsigned int, type); 78 + }; 79 + 80 + ack 81 + - required. May be the same function as mask for IRQs 82 + handled by do_level_IRQ. 83 + mask 84 + - required. 85 + unmask 86 + - required. 87 + rerun 88 + - optional. Not required if you're using do_level_IRQ for all 89 + IRQs that use this 'irqchip'. Generally expected to re-trigger 90 + the hardware IRQ if possible. If not, may call the handler 91 + directly. 92 + type 93 + - optional. If you don't support changing the type of an IRQ, 94 + it should be null so people can detect if they are unable to 95 + set the IRQ type. 96 + 97 + For each IRQ, we keep the following information: 98 + 99 + - "disable" depth (number of disable_irq()s without enable_irq()s) 100 + - flags indicating what we can do with this IRQ (valid, probe, 101 + noautounmask) as before 102 + - status of the IRQ (probing, enable, etc) 103 + - chip 104 + - per-IRQ handler 105 + - irqaction structure list 106 + 107 + The handler can be one of the 3 standard handlers - "level", "edge" and 108 + "simple", or your own specific handler if you need to do something special. 109 + 110 + The "level" handler is what we currently have - its pretty simple. 111 + "edge" knows about the brokenness of such IRQ implementations - that you 112 + need to leave the hardware IRQ enabled while processing it, and queueing 113 + further IRQ events should the IRQ happen again while processing. The 114 + "simple" handler is very basic, and does not perform any hardware 115 + manipulation, nor state tracking. This is useful for things like the 116 + SMC9196 and USAR above. 117 + 118 + So, what's changed? 119 + =================== 120 + 121 + 1. Machine implementations must not write to the irqdesc array. 122 + 123 + 2. New functions to manipulate the irqdesc array. The first 4 are expected 124 + to be useful only to machine specific code. The last is recommended to 125 + only be used by machine specific code, but may be used in drivers if 126 + absolutely necessary. 127 + 128 + set_irq_chip(irq,chip) 129 + Set the mask/unmask methods for handling this IRQ 130 + 131 + set_irq_handler(irq,handler) 132 + Set the handler for this IRQ (level, edge, simple) 133 + 134 + set_irq_chained_handler(irq,handler) 135 + Set a "chained" handler for this IRQ - automatically 136 + enables this IRQ (eg, Neponset and SA1111 handlers). 137 + 138 + set_irq_flags(irq,flags) 139 + Set the valid/probe/noautoenable flags. 140 + 141 + set_irq_type(irq,type) 142 + Set active the IRQ edge(s)/level. This replaces the 143 + SA1111 INTPOL manipulation, and the set_GPIO_IRQ_edge() 144 + function. Type should be one of IRQ_TYPE_xxx defined in 145 + <linux/irq.h> 146 + 147 + 3. set_GPIO_IRQ_edge() is obsolete, and should be replaced by set_irq_type. 148 + 149 + 4. Direct access to SA1111 INTPOL is deprecated. Use set_irq_type instead. 150 + 151 + 5. A handler is expected to perform any necessary acknowledgement of the 152 + parent IRQ via the correct chip specific function. For instance, if 153 + the SA1111 is directly connected to a SA1110 GPIO, then you should 154 + acknowledge the SA1110 IRQ each time you re-read the SA1111 IRQ status. 155 + 156 + 6. For any child which doesn't have its own IRQ enable/disable controls 157 + (eg, SMC9196), the handler must mask or acknowledge the parent IRQ 158 + while the child handler is called, and the child handler should be the 159 + "simple" handler (not "edge" nor "level"). After the handler completes, 160 + the parent IRQ should be unmasked, and the status of all children must 161 + be re-checked for pending events. (see the Neponset IRQ handler for 162 + details). 163 + 164 + 7. fixup_irq() is gone, as is `arch/arm/mach-*/include/mach/irq.h` 165 + 166 + Please note that this will not solve all problems - some of them are 167 + hardware based. Mixing level-based and edge-based IRQs on the same 168 + parent signal (eg neponset) is one such area where a software based 169 + solution can't provide the full answer to low IRQ latency.
+173
Documentation/arm/ixp4xx.rst
··· 1 + =========================================================== 2 + Release Notes for Linux on Intel's IXP4xx Network Processor 3 + =========================================================== 4 + 5 + Maintained by Deepak Saxena <dsaxena@plexity.net> 6 + ------------------------------------------------------------------------- 7 + 8 + 1. Overview 9 + 10 + Intel's IXP4xx network processor is a highly integrated SOC that 11 + is targeted for network applications, though it has become popular 12 + in industrial control and other areas due to low cost and power 13 + consumption. The IXP4xx family currently consists of several processors 14 + that support different network offload functions such as encryption, 15 + routing, firewalling, etc. The IXP46x family is an updated version which 16 + supports faster speeds, new memory and flash configurations, and more 17 + integration such as an on-chip I2C controller. 18 + 19 + For more information on the various versions of the CPU, see: 20 + 21 + http://developer.intel.com/design/network/products/npfamily/ixp4xx.htm 22 + 23 + Intel also made the IXCP1100 CPU for sometime which is an IXP4xx 24 + stripped of much of the network intelligence. 25 + 26 + 2. Linux Support 27 + 28 + Linux currently supports the following features on the IXP4xx chips: 29 + 30 + - Dual serial ports 31 + - PCI interface 32 + - Flash access (MTD/JFFS) 33 + - I2C through GPIO on IXP42x 34 + - GPIO for input/output/interrupts 35 + See arch/arm/mach-ixp4xx/include/mach/platform.h for access functions. 36 + - Timers (watchdog, OS) 37 + 38 + The following components of the chips are not supported by Linux and 39 + require the use of Intel's proprietary CSR software: 40 + 41 + - USB device interface 42 + - Network interfaces (HSS, Utopia, NPEs, etc) 43 + - Network offload functionality 44 + 45 + If you need to use any of the above, you need to download Intel's 46 + software from: 47 + 48 + http://developer.intel.com/design/network/products/npfamily/ixp425.htm 49 + 50 + DO NOT POST QUESTIONS TO THE LINUX MAILING LISTS REGARDING THE PROPRIETARY 51 + SOFTWARE. 52 + 53 + There are several websites that provide directions/pointers on using 54 + Intel's software: 55 + 56 + - http://sourceforge.net/projects/ixp4xx-osdg/ 57 + Open Source Developer's Guide for using uClinux and the Intel libraries 58 + 59 + - http://gatewaymaker.sourceforge.net/ 60 + Simple one page summary of building a gateway using an IXP425 and Linux 61 + 62 + - http://ixp425.sourceforge.net/ 63 + ATM device driver for IXP425 that relies on Intel's libraries 64 + 65 + 3. Known Issues/Limitations 66 + 67 + 3a. Limited inbound PCI window 68 + 69 + The IXP4xx family allows for up to 256MB of memory but the PCI interface 70 + can only expose 64MB of that memory to the PCI bus. This means that if 71 + you are running with > 64MB, all PCI buffers outside of the accessible 72 + range will be bounced using the routines in arch/arm/common/dmabounce.c. 73 + 74 + 3b. Limited outbound PCI window 75 + 76 + IXP4xx provides two methods of accessing PCI memory space: 77 + 78 + 1) A direct mapped window from 0x48000000 to 0x4bffffff (64MB). 79 + To access PCI via this space, we simply ioremap() the BAR 80 + into the kernel and we can use the standard read[bwl]/write[bwl] 81 + macros. This is the preffered method due to speed but it 82 + limits the system to just 64MB of PCI memory. This can be 83 + problamatic if using video cards and other memory-heavy devices. 84 + 85 + 2) If > 64MB of memory space is required, the IXP4xx can be 86 + configured to use indirect registers to access PCI This allows 87 + for up to 128MB (0x48000000 to 0x4fffffff) of memory on the bus. 88 + The disadvantage of this is that every PCI access requires 89 + three local register accesses plus a spinlock, but in some 90 + cases the performance hit is acceptable. In addition, you cannot 91 + mmap() PCI devices in this case due to the indirect nature 92 + of the PCI window. 93 + 94 + By default, the direct method is used for performance reasons. If 95 + you need more PCI memory, enable the IXP4XX_INDIRECT_PCI config option. 96 + 97 + 3c. GPIO as Interrupts 98 + 99 + Currently the code only handles level-sensitive GPIO interrupts 100 + 101 + 4. Supported platforms 102 + 103 + ADI Engineering Coyote Gateway Reference Platform 104 + http://www.adiengineering.com/productsCoyote.html 105 + 106 + The ADI Coyote platform is reference design for those building 107 + small residential/office gateways. One NPE is connected to a 10/100 108 + interface, one to 4-port 10/100 switch, and the third to and ADSL 109 + interface. In addition, it also supports to POTs interfaces connected 110 + via SLICs. Note that those are not supported by Linux ATM. Finally, 111 + the platform has two mini-PCI slots used for 802.11[bga] cards. 112 + Finally, there is an IDE port hanging off the expansion bus. 113 + 114 + Gateworks Avila Network Platform 115 + http://www.gateworks.com/support/overview.php 116 + 117 + The Avila platform is basically and IXDP425 with the 4 PCI slots 118 + replaced with mini-PCI slots and a CF IDE interface hanging off 119 + the expansion bus. 120 + 121 + Intel IXDP425 Development Platform 122 + http://www.intel.com/design/network/products/npfamily/ixdpg425.htm 123 + 124 + This is Intel's standard reference platform for the IXDP425 and is 125 + also known as the Richfield board. It contains 4 PCI slots, 16MB 126 + of flash, two 10/100 ports and one ADSL port. 127 + 128 + Intel IXDP465 Development Platform 129 + http://www.intel.com/design/network/products/npfamily/ixdp465.htm 130 + 131 + This is basically an IXDP425 with an IXP465 and 32M of flash instead 132 + of just 16. 133 + 134 + Intel IXDPG425 Development Platform 135 + 136 + This is basically and ADI Coyote board with a NEC EHCI controller 137 + added. One issue with this board is that the mini-PCI slots only 138 + have the 3.3v line connected, so you can't use a PCI to mini-PCI 139 + adapter with an E100 card. So to NFS root you need to use either 140 + the CSR or a WiFi card and a ramdisk that BOOTPs and then does 141 + a pivot_root to NFS. 142 + 143 + Motorola PrPMC1100 Processor Mezanine Card 144 + http://www.fountainsys.com 145 + 146 + The PrPMC1100 is based on the IXCP1100 and is meant to plug into 147 + and IXP2400/2800 system to act as the system controller. It simply 148 + contains a CPU and 16MB of flash on the board and needs to be 149 + plugged into a carrier board to function. Currently Linux only 150 + supports the Motorola PrPMC carrier board for this platform. 151 + 152 + 5. TODO LIST 153 + 154 + - Add support for Coyote IDE 155 + - Add support for edge-based GPIO interrupts 156 + - Add support for CF IDE on expansion bus 157 + 158 + 6. Thanks 159 + 160 + The IXP4xx work has been funded by Intel Corp. and MontaVista Software, Inc. 161 + 162 + The following people have contributed patches/comments/etc: 163 + 164 + - Lennerty Buytenhek 165 + - Lutz Jaenicke 166 + - Justin Mayfield 167 + - Robert E. Ranslam 168 + 169 + [I know I've forgotten others, please email me to be added] 170 + 171 + ------------------------------------------------------------------------- 172 + 173 + Last Update: 01/04/2005
+124
Documentation/arm/kernel_mode_neon.rst
··· 1 + ================ 2 + Kernel mode NEON 3 + ================ 4 + 5 + TL;DR summary 6 + ------------- 7 + * Use only NEON instructions, or VFP instructions that don't rely on support 8 + code 9 + * Isolate your NEON code in a separate compilation unit, and compile it with 10 + '-march=armv7-a -mfpu=neon -mfloat-abi=softfp' 11 + * Put kernel_neon_begin() and kernel_neon_end() calls around the calls into your 12 + NEON code 13 + * Don't sleep in your NEON code, and be aware that it will be executed with 14 + preemption disabled 15 + 16 + 17 + Introduction 18 + ------------ 19 + It is possible to use NEON instructions (and in some cases, VFP instructions) in 20 + code that runs in kernel mode. However, for performance reasons, the NEON/VFP 21 + register file is not preserved and restored at every context switch or taken 22 + exception like the normal register file is, so some manual intervention is 23 + required. Furthermore, special care is required for code that may sleep [i.e., 24 + may call schedule()], as NEON or VFP instructions will be executed in a 25 + non-preemptible section for reasons outlined below. 26 + 27 + 28 + Lazy preserve and restore 29 + ------------------------- 30 + The NEON/VFP register file is managed using lazy preserve (on UP systems) and 31 + lazy restore (on both SMP and UP systems). This means that the register file is 32 + kept 'live', and is only preserved and restored when multiple tasks are 33 + contending for the NEON/VFP unit (or, in the SMP case, when a task migrates to 34 + another core). Lazy restore is implemented by disabling the NEON/VFP unit after 35 + every context switch, resulting in a trap when subsequently a NEON/VFP 36 + instruction is issued, allowing the kernel to step in and perform the restore if 37 + necessary. 38 + 39 + Any use of the NEON/VFP unit in kernel mode should not interfere with this, so 40 + it is required to do an 'eager' preserve of the NEON/VFP register file, and 41 + enable the NEON/VFP unit explicitly so no exceptions are generated on first 42 + subsequent use. This is handled by the function kernel_neon_begin(), which 43 + should be called before any kernel mode NEON or VFP instructions are issued. 44 + Likewise, the NEON/VFP unit should be disabled again after use to make sure user 45 + mode will hit the lazy restore trap upon next use. This is handled by the 46 + function kernel_neon_end(). 47 + 48 + 49 + Interruptions in kernel mode 50 + ---------------------------- 51 + For reasons of performance and simplicity, it was decided that there shall be no 52 + preserve/restore mechanism for the kernel mode NEON/VFP register contents. This 53 + implies that interruptions of a kernel mode NEON section can only be allowed if 54 + they are guaranteed not to touch the NEON/VFP registers. For this reason, the 55 + following rules and restrictions apply in the kernel: 56 + * NEON/VFP code is not allowed in interrupt context; 57 + * NEON/VFP code is not allowed to sleep; 58 + * NEON/VFP code is executed with preemption disabled. 59 + 60 + If latency is a concern, it is possible to put back to back calls to 61 + kernel_neon_end() and kernel_neon_begin() in places in your code where none of 62 + the NEON registers are live. (Additional calls to kernel_neon_begin() should be 63 + reasonably cheap if no context switch occurred in the meantime) 64 + 65 + 66 + VFP and support code 67 + -------------------- 68 + Earlier versions of VFP (prior to version 3) rely on software support for things 69 + like IEEE-754 compliant underflow handling etc. When the VFP unit needs such 70 + software assistance, it signals the kernel by raising an undefined instruction 71 + exception. The kernel responds by inspecting the VFP control registers and the 72 + current instruction and arguments, and emulates the instruction in software. 73 + 74 + Such software assistance is currently not implemented for VFP instructions 75 + executed in kernel mode. If such a condition is encountered, the kernel will 76 + fail and generate an OOPS. 77 + 78 + 79 + Separating NEON code from ordinary code 80 + --------------------------------------- 81 + The compiler is not aware of the special significance of kernel_neon_begin() and 82 + kernel_neon_end(), i.e., that it is only allowed to issue NEON/VFP instructions 83 + between calls to these respective functions. Furthermore, GCC may generate NEON 84 + instructions of its own at -O3 level if -mfpu=neon is selected, and even if the 85 + kernel is currently compiled at -O2, future changes may result in NEON/VFP 86 + instructions appearing in unexpected places if no special care is taken. 87 + 88 + Therefore, the recommended and only supported way of using NEON/VFP in the 89 + kernel is by adhering to the following rules: 90 + 91 + * isolate the NEON code in a separate compilation unit and compile it with 92 + '-march=armv7-a -mfpu=neon -mfloat-abi=softfp'; 93 + * issue the calls to kernel_neon_begin(), kernel_neon_end() as well as the calls 94 + into the unit containing the NEON code from a compilation unit which is *not* 95 + built with the GCC flag '-mfpu=neon' set. 96 + 97 + As the kernel is compiled with '-msoft-float', the above will guarantee that 98 + both NEON and VFP instructions will only ever appear in designated compilation 99 + units at any optimization level. 100 + 101 + 102 + NEON assembler 103 + -------------- 104 + NEON assembler is supported with no additional caveats as long as the rules 105 + above are followed. 106 + 107 + 108 + NEON code generated by GCC 109 + -------------------------- 110 + The GCC option -ftree-vectorize (implied by -O3) tries to exploit implicit 111 + parallelism, and generates NEON code from ordinary C source code. This is fully 112 + supported as long as the rules above are followed. 113 + 114 + 115 + NEON intrinsics 116 + --------------- 117 + NEON intrinsics are also supported. However, as code using NEON intrinsics 118 + relies on the GCC header <arm_neon.h>, (which #includes <stdint.h>), you should 119 + observe the following in addition to the rules above: 120 + 121 + * Compile the unit containing the NEON intrinsics with '-ffreestanding' so GCC 122 + uses its builtin version of <stdint.h> (this is a C99 header which the kernel 123 + does not supply); 124 + * Include <arm_neon.h> last, or at least after <linux/types.h>
-121
Documentation/arm/kernel_mode_neon.txt
··· 1 - Kernel mode NEON 2 - ================ 3 - 4 - TL;DR summary 5 - ------------- 6 - * Use only NEON instructions, or VFP instructions that don't rely on support 7 - code 8 - * Isolate your NEON code in a separate compilation unit, and compile it with 9 - '-march=armv7-a -mfpu=neon -mfloat-abi=softfp' 10 - * Put kernel_neon_begin() and kernel_neon_end() calls around the calls into your 11 - NEON code 12 - * Don't sleep in your NEON code, and be aware that it will be executed with 13 - preemption disabled 14 - 15 - 16 - Introduction 17 - ------------ 18 - It is possible to use NEON instructions (and in some cases, VFP instructions) in 19 - code that runs in kernel mode. However, for performance reasons, the NEON/VFP 20 - register file is not preserved and restored at every context switch or taken 21 - exception like the normal register file is, so some manual intervention is 22 - required. Furthermore, special care is required for code that may sleep [i.e., 23 - may call schedule()], as NEON or VFP instructions will be executed in a 24 - non-preemptible section for reasons outlined below. 25 - 26 - 27 - Lazy preserve and restore 28 - ------------------------- 29 - The NEON/VFP register file is managed using lazy preserve (on UP systems) and 30 - lazy restore (on both SMP and UP systems). This means that the register file is 31 - kept 'live', and is only preserved and restored when multiple tasks are 32 - contending for the NEON/VFP unit (or, in the SMP case, when a task migrates to 33 - another core). Lazy restore is implemented by disabling the NEON/VFP unit after 34 - every context switch, resulting in a trap when subsequently a NEON/VFP 35 - instruction is issued, allowing the kernel to step in and perform the restore if 36 - necessary. 37 - 38 - Any use of the NEON/VFP unit in kernel mode should not interfere with this, so 39 - it is required to do an 'eager' preserve of the NEON/VFP register file, and 40 - enable the NEON/VFP unit explicitly so no exceptions are generated on first 41 - subsequent use. This is handled by the function kernel_neon_begin(), which 42 - should be called before any kernel mode NEON or VFP instructions are issued. 43 - Likewise, the NEON/VFP unit should be disabled again after use to make sure user 44 - mode will hit the lazy restore trap upon next use. This is handled by the 45 - function kernel_neon_end(). 46 - 47 - 48 - Interruptions in kernel mode 49 - ---------------------------- 50 - For reasons of performance and simplicity, it was decided that there shall be no 51 - preserve/restore mechanism for the kernel mode NEON/VFP register contents. This 52 - implies that interruptions of a kernel mode NEON section can only be allowed if 53 - they are guaranteed not to touch the NEON/VFP registers. For this reason, the 54 - following rules and restrictions apply in the kernel: 55 - * NEON/VFP code is not allowed in interrupt context; 56 - * NEON/VFP code is not allowed to sleep; 57 - * NEON/VFP code is executed with preemption disabled. 58 - 59 - If latency is a concern, it is possible to put back to back calls to 60 - kernel_neon_end() and kernel_neon_begin() in places in your code where none of 61 - the NEON registers are live. (Additional calls to kernel_neon_begin() should be 62 - reasonably cheap if no context switch occurred in the meantime) 63 - 64 - 65 - VFP and support code 66 - -------------------- 67 - Earlier versions of VFP (prior to version 3) rely on software support for things 68 - like IEEE-754 compliant underflow handling etc. When the VFP unit needs such 69 - software assistance, it signals the kernel by raising an undefined instruction 70 - exception. The kernel responds by inspecting the VFP control registers and the 71 - current instruction and arguments, and emulates the instruction in software. 72 - 73 - Such software assistance is currently not implemented for VFP instructions 74 - executed in kernel mode. If such a condition is encountered, the kernel will 75 - fail and generate an OOPS. 76 - 77 - 78 - Separating NEON code from ordinary code 79 - --------------------------------------- 80 - The compiler is not aware of the special significance of kernel_neon_begin() and 81 - kernel_neon_end(), i.e., that it is only allowed to issue NEON/VFP instructions 82 - between calls to these respective functions. Furthermore, GCC may generate NEON 83 - instructions of its own at -O3 level if -mfpu=neon is selected, and even if the 84 - kernel is currently compiled at -O2, future changes may result in NEON/VFP 85 - instructions appearing in unexpected places if no special care is taken. 86 - 87 - Therefore, the recommended and only supported way of using NEON/VFP in the 88 - kernel is by adhering to the following rules: 89 - * isolate the NEON code in a separate compilation unit and compile it with 90 - '-march=armv7-a -mfpu=neon -mfloat-abi=softfp'; 91 - * issue the calls to kernel_neon_begin(), kernel_neon_end() as well as the calls 92 - into the unit containing the NEON code from a compilation unit which is *not* 93 - built with the GCC flag '-mfpu=neon' set. 94 - 95 - As the kernel is compiled with '-msoft-float', the above will guarantee that 96 - both NEON and VFP instructions will only ever appear in designated compilation 97 - units at any optimization level. 98 - 99 - 100 - NEON assembler 101 - -------------- 102 - NEON assembler is supported with no additional caveats as long as the rules 103 - above are followed. 104 - 105 - 106 - NEON code generated by GCC 107 - -------------------------- 108 - The GCC option -ftree-vectorize (implied by -O3) tries to exploit implicit 109 - parallelism, and generates NEON code from ordinary C source code. This is fully 110 - supported as long as the rules above are followed. 111 - 112 - 113 - NEON intrinsics 114 - --------------- 115 - NEON intrinsics are also supported. However, as code using NEON intrinsics 116 - relies on the GCC header <arm_neon.h>, (which #includes <stdint.h>), you should 117 - observe the following in addition to the rules above: 118 - * Compile the unit containing the NEON intrinsics with '-ffreestanding' so GCC 119 - uses its builtin version of <stdint.h> (this is a C99 header which the kernel 120 - does not supply); 121 - * Include <arm_neon.h> last, or at least after <linux/types.h>
+268
Documentation/arm/kernel_user_helpers.rst
··· 1 + ============================ 2 + Kernel-provided User Helpers 3 + ============================ 4 + 5 + These are segment of kernel provided user code reachable from user space 6 + at a fixed address in kernel memory. This is used to provide user space 7 + with some operations which require kernel help because of unimplemented 8 + native feature and/or instructions in many ARM CPUs. The idea is for this 9 + code to be executed directly in user mode for best efficiency but which is 10 + too intimate with the kernel counter part to be left to user libraries. 11 + In fact this code might even differ from one CPU to another depending on 12 + the available instruction set, or whether it is a SMP systems. In other 13 + words, the kernel reserves the right to change this code as needed without 14 + warning. Only the entry points and their results as documented here are 15 + guaranteed to be stable. 16 + 17 + This is different from (but doesn't preclude) a full blown VDSO 18 + implementation, however a VDSO would prevent some assembly tricks with 19 + constants that allows for efficient branching to those code segments. And 20 + since those code segments only use a few cycles before returning to user 21 + code, the overhead of a VDSO indirect far call would add a measurable 22 + overhead to such minimalistic operations. 23 + 24 + User space is expected to bypass those helpers and implement those things 25 + inline (either in the code emitted directly by the compiler, or part of 26 + the implementation of a library call) when optimizing for a recent enough 27 + processor that has the necessary native support, but only if resulting 28 + binaries are already to be incompatible with earlier ARM processors due to 29 + usage of similar native instructions for other things. In other words 30 + don't make binaries unable to run on earlier processors just for the sake 31 + of not using these kernel helpers if your compiled code is not going to 32 + use new instructions for other purpose. 33 + 34 + New helpers may be added over time, so an older kernel may be missing some 35 + helpers present in a newer kernel. For this reason, programs must check 36 + the value of __kuser_helper_version (see below) before assuming that it is 37 + safe to call any particular helper. This check should ideally be 38 + performed only once at process startup time, and execution aborted early 39 + if the required helpers are not provided by the kernel version that 40 + process is running on. 41 + 42 + kuser_helper_version 43 + -------------------- 44 + 45 + Location: 0xffff0ffc 46 + 47 + Reference declaration:: 48 + 49 + extern int32_t __kuser_helper_version; 50 + 51 + Definition: 52 + 53 + This field contains the number of helpers being implemented by the 54 + running kernel. User space may read this to determine the availability 55 + of a particular helper. 56 + 57 + Usage example:: 58 + 59 + #define __kuser_helper_version (*(int32_t *)0xffff0ffc) 60 + 61 + void check_kuser_version(void) 62 + { 63 + if (__kuser_helper_version < 2) { 64 + fprintf(stderr, "can't do atomic operations, kernel too old\n"); 65 + abort(); 66 + } 67 + } 68 + 69 + Notes: 70 + 71 + User space may assume that the value of this field never changes 72 + during the lifetime of any single process. This means that this 73 + field can be read once during the initialisation of a library or 74 + startup phase of a program. 75 + 76 + kuser_get_tls 77 + ------------- 78 + 79 + Location: 0xffff0fe0 80 + 81 + Reference prototype:: 82 + 83 + void * __kuser_get_tls(void); 84 + 85 + Input: 86 + 87 + lr = return address 88 + 89 + Output: 90 + 91 + r0 = TLS value 92 + 93 + Clobbered registers: 94 + 95 + none 96 + 97 + Definition: 98 + 99 + Get the TLS value as previously set via the __ARM_NR_set_tls syscall. 100 + 101 + Usage example:: 102 + 103 + typedef void * (__kuser_get_tls_t)(void); 104 + #define __kuser_get_tls (*(__kuser_get_tls_t *)0xffff0fe0) 105 + 106 + void foo() 107 + { 108 + void *tls = __kuser_get_tls(); 109 + printf("TLS = %p\n", tls); 110 + } 111 + 112 + Notes: 113 + 114 + - Valid only if __kuser_helper_version >= 1 (from kernel version 2.6.12). 115 + 116 + kuser_cmpxchg 117 + ------------- 118 + 119 + Location: 0xffff0fc0 120 + 121 + Reference prototype:: 122 + 123 + int __kuser_cmpxchg(int32_t oldval, int32_t newval, volatile int32_t *ptr); 124 + 125 + Input: 126 + 127 + r0 = oldval 128 + r1 = newval 129 + r2 = ptr 130 + lr = return address 131 + 132 + Output: 133 + 134 + r0 = success code (zero or non-zero) 135 + C flag = set if r0 == 0, clear if r0 != 0 136 + 137 + Clobbered registers: 138 + 139 + r3, ip, flags 140 + 141 + Definition: 142 + 143 + Atomically store newval in `*ptr` only if `*ptr` is equal to oldval. 144 + Return zero if `*ptr` was changed or non-zero if no exchange happened. 145 + The C flag is also set if `*ptr` was changed to allow for assembly 146 + optimization in the calling code. 147 + 148 + Usage example:: 149 + 150 + typedef int (__kuser_cmpxchg_t)(int oldval, int newval, volatile int *ptr); 151 + #define __kuser_cmpxchg (*(__kuser_cmpxchg_t *)0xffff0fc0) 152 + 153 + int atomic_add(volatile int *ptr, int val) 154 + { 155 + int old, new; 156 + 157 + do { 158 + old = *ptr; 159 + new = old + val; 160 + } while(__kuser_cmpxchg(old, new, ptr)); 161 + 162 + return new; 163 + } 164 + 165 + Notes: 166 + 167 + - This routine already includes memory barriers as needed. 168 + 169 + - Valid only if __kuser_helper_version >= 2 (from kernel version 2.6.12). 170 + 171 + kuser_memory_barrier 172 + -------------------- 173 + 174 + Location: 0xffff0fa0 175 + 176 + Reference prototype:: 177 + 178 + void __kuser_memory_barrier(void); 179 + 180 + Input: 181 + 182 + lr = return address 183 + 184 + Output: 185 + 186 + none 187 + 188 + Clobbered registers: 189 + 190 + none 191 + 192 + Definition: 193 + 194 + Apply any needed memory barrier to preserve consistency with data modified 195 + manually and __kuser_cmpxchg usage. 196 + 197 + Usage example:: 198 + 199 + typedef void (__kuser_dmb_t)(void); 200 + #define __kuser_dmb (*(__kuser_dmb_t *)0xffff0fa0) 201 + 202 + Notes: 203 + 204 + - Valid only if __kuser_helper_version >= 3 (from kernel version 2.6.15). 205 + 206 + kuser_cmpxchg64 207 + --------------- 208 + 209 + Location: 0xffff0f60 210 + 211 + Reference prototype:: 212 + 213 + int __kuser_cmpxchg64(const int64_t *oldval, 214 + const int64_t *newval, 215 + volatile int64_t *ptr); 216 + 217 + Input: 218 + 219 + r0 = pointer to oldval 220 + r1 = pointer to newval 221 + r2 = pointer to target value 222 + lr = return address 223 + 224 + Output: 225 + 226 + r0 = success code (zero or non-zero) 227 + C flag = set if r0 == 0, clear if r0 != 0 228 + 229 + Clobbered registers: 230 + 231 + r3, lr, flags 232 + 233 + Definition: 234 + 235 + Atomically store the 64-bit value pointed by `*newval` in `*ptr` only if `*ptr` 236 + is equal to the 64-bit value pointed by `*oldval`. Return zero if `*ptr` was 237 + changed or non-zero if no exchange happened. 238 + 239 + The C flag is also set if `*ptr` was changed to allow for assembly 240 + optimization in the calling code. 241 + 242 + Usage example:: 243 + 244 + typedef int (__kuser_cmpxchg64_t)(const int64_t *oldval, 245 + const int64_t *newval, 246 + volatile int64_t *ptr); 247 + #define __kuser_cmpxchg64 (*(__kuser_cmpxchg64_t *)0xffff0f60) 248 + 249 + int64_t atomic_add64(volatile int64_t *ptr, int64_t val) 250 + { 251 + int64_t old, new; 252 + 253 + do { 254 + old = *ptr; 255 + new = old + val; 256 + } while(__kuser_cmpxchg64(&old, &new, ptr)); 257 + 258 + return new; 259 + } 260 + 261 + Notes: 262 + 263 + - This routine already includes memory barriers as needed. 264 + 265 + - Due to the length of this sequence, this spans 2 conventional kuser 266 + "slots", therefore 0xffff0f80 is not used as a valid entry point. 267 + 268 + - Valid only if __kuser_helper_version >= 5 (from kernel version 3.1).
-267
Documentation/arm/kernel_user_helpers.txt
··· 1 - Kernel-provided User Helpers 2 - ============================ 3 - 4 - These are segment of kernel provided user code reachable from user space 5 - at a fixed address in kernel memory. This is used to provide user space 6 - with some operations which require kernel help because of unimplemented 7 - native feature and/or instructions in many ARM CPUs. The idea is for this 8 - code to be executed directly in user mode for best efficiency but which is 9 - too intimate with the kernel counter part to be left to user libraries. 10 - In fact this code might even differ from one CPU to another depending on 11 - the available instruction set, or whether it is a SMP systems. In other 12 - words, the kernel reserves the right to change this code as needed without 13 - warning. Only the entry points and their results as documented here are 14 - guaranteed to be stable. 15 - 16 - This is different from (but doesn't preclude) a full blown VDSO 17 - implementation, however a VDSO would prevent some assembly tricks with 18 - constants that allows for efficient branching to those code segments. And 19 - since those code segments only use a few cycles before returning to user 20 - code, the overhead of a VDSO indirect far call would add a measurable 21 - overhead to such minimalistic operations. 22 - 23 - User space is expected to bypass those helpers and implement those things 24 - inline (either in the code emitted directly by the compiler, or part of 25 - the implementation of a library call) when optimizing for a recent enough 26 - processor that has the necessary native support, but only if resulting 27 - binaries are already to be incompatible with earlier ARM processors due to 28 - usage of similar native instructions for other things. In other words 29 - don't make binaries unable to run on earlier processors just for the sake 30 - of not using these kernel helpers if your compiled code is not going to 31 - use new instructions for other purpose. 32 - 33 - New helpers may be added over time, so an older kernel may be missing some 34 - helpers present in a newer kernel. For this reason, programs must check 35 - the value of __kuser_helper_version (see below) before assuming that it is 36 - safe to call any particular helper. This check should ideally be 37 - performed only once at process startup time, and execution aborted early 38 - if the required helpers are not provided by the kernel version that 39 - process is running on. 40 - 41 - kuser_helper_version 42 - -------------------- 43 - 44 - Location: 0xffff0ffc 45 - 46 - Reference declaration: 47 - 48 - extern int32_t __kuser_helper_version; 49 - 50 - Definition: 51 - 52 - This field contains the number of helpers being implemented by the 53 - running kernel. User space may read this to determine the availability 54 - of a particular helper. 55 - 56 - Usage example: 57 - 58 - #define __kuser_helper_version (*(int32_t *)0xffff0ffc) 59 - 60 - void check_kuser_version(void) 61 - { 62 - if (__kuser_helper_version < 2) { 63 - fprintf(stderr, "can't do atomic operations, kernel too old\n"); 64 - abort(); 65 - } 66 - } 67 - 68 - Notes: 69 - 70 - User space may assume that the value of this field never changes 71 - during the lifetime of any single process. This means that this 72 - field can be read once during the initialisation of a library or 73 - startup phase of a program. 74 - 75 - kuser_get_tls 76 - ------------- 77 - 78 - Location: 0xffff0fe0 79 - 80 - Reference prototype: 81 - 82 - void * __kuser_get_tls(void); 83 - 84 - Input: 85 - 86 - lr = return address 87 - 88 - Output: 89 - 90 - r0 = TLS value 91 - 92 - Clobbered registers: 93 - 94 - none 95 - 96 - Definition: 97 - 98 - Get the TLS value as previously set via the __ARM_NR_set_tls syscall. 99 - 100 - Usage example: 101 - 102 - typedef void * (__kuser_get_tls_t)(void); 103 - #define __kuser_get_tls (*(__kuser_get_tls_t *)0xffff0fe0) 104 - 105 - void foo() 106 - { 107 - void *tls = __kuser_get_tls(); 108 - printf("TLS = %p\n", tls); 109 - } 110 - 111 - Notes: 112 - 113 - - Valid only if __kuser_helper_version >= 1 (from kernel version 2.6.12). 114 - 115 - kuser_cmpxchg 116 - ------------- 117 - 118 - Location: 0xffff0fc0 119 - 120 - Reference prototype: 121 - 122 - int __kuser_cmpxchg(int32_t oldval, int32_t newval, volatile int32_t *ptr); 123 - 124 - Input: 125 - 126 - r0 = oldval 127 - r1 = newval 128 - r2 = ptr 129 - lr = return address 130 - 131 - Output: 132 - 133 - r0 = success code (zero or non-zero) 134 - C flag = set if r0 == 0, clear if r0 != 0 135 - 136 - Clobbered registers: 137 - 138 - r3, ip, flags 139 - 140 - Definition: 141 - 142 - Atomically store newval in *ptr only if *ptr is equal to oldval. 143 - Return zero if *ptr was changed or non-zero if no exchange happened. 144 - The C flag is also set if *ptr was changed to allow for assembly 145 - optimization in the calling code. 146 - 147 - Usage example: 148 - 149 - typedef int (__kuser_cmpxchg_t)(int oldval, int newval, volatile int *ptr); 150 - #define __kuser_cmpxchg (*(__kuser_cmpxchg_t *)0xffff0fc0) 151 - 152 - int atomic_add(volatile int *ptr, int val) 153 - { 154 - int old, new; 155 - 156 - do { 157 - old = *ptr; 158 - new = old + val; 159 - } while(__kuser_cmpxchg(old, new, ptr)); 160 - 161 - return new; 162 - } 163 - 164 - Notes: 165 - 166 - - This routine already includes memory barriers as needed. 167 - 168 - - Valid only if __kuser_helper_version >= 2 (from kernel version 2.6.12). 169 - 170 - kuser_memory_barrier 171 - -------------------- 172 - 173 - Location: 0xffff0fa0 174 - 175 - Reference prototype: 176 - 177 - void __kuser_memory_barrier(void); 178 - 179 - Input: 180 - 181 - lr = return address 182 - 183 - Output: 184 - 185 - none 186 - 187 - Clobbered registers: 188 - 189 - none 190 - 191 - Definition: 192 - 193 - Apply any needed memory barrier to preserve consistency with data modified 194 - manually and __kuser_cmpxchg usage. 195 - 196 - Usage example: 197 - 198 - typedef void (__kuser_dmb_t)(void); 199 - #define __kuser_dmb (*(__kuser_dmb_t *)0xffff0fa0) 200 - 201 - Notes: 202 - 203 - - Valid only if __kuser_helper_version >= 3 (from kernel version 2.6.15). 204 - 205 - kuser_cmpxchg64 206 - --------------- 207 - 208 - Location: 0xffff0f60 209 - 210 - Reference prototype: 211 - 212 - int __kuser_cmpxchg64(const int64_t *oldval, 213 - const int64_t *newval, 214 - volatile int64_t *ptr); 215 - 216 - Input: 217 - 218 - r0 = pointer to oldval 219 - r1 = pointer to newval 220 - r2 = pointer to target value 221 - lr = return address 222 - 223 - Output: 224 - 225 - r0 = success code (zero or non-zero) 226 - C flag = set if r0 == 0, clear if r0 != 0 227 - 228 - Clobbered registers: 229 - 230 - r3, lr, flags 231 - 232 - Definition: 233 - 234 - Atomically store the 64-bit value pointed by *newval in *ptr only if *ptr 235 - is equal to the 64-bit value pointed by *oldval. Return zero if *ptr was 236 - changed or non-zero if no exchange happened. 237 - 238 - The C flag is also set if *ptr was changed to allow for assembly 239 - optimization in the calling code. 240 - 241 - Usage example: 242 - 243 - typedef int (__kuser_cmpxchg64_t)(const int64_t *oldval, 244 - const int64_t *newval, 245 - volatile int64_t *ptr); 246 - #define __kuser_cmpxchg64 (*(__kuser_cmpxchg64_t *)0xffff0f60) 247 - 248 - int64_t atomic_add64(volatile int64_t *ptr, int64_t val) 249 - { 250 - int64_t old, new; 251 - 252 - do { 253 - old = *ptr; 254 - new = old + val; 255 - } while(__kuser_cmpxchg64(&old, &new, ptr)); 256 - 257 - return new; 258 - } 259 - 260 - Notes: 261 - 262 - - This routine already includes memory barriers as needed. 263 - 264 - - Due to the length of this sequence, this spans 2 conventional kuser 265 - "slots", therefore 0xffff0f80 is not used as a valid entry point. 266 - 267 - - Valid only if __kuser_helper_version >= 5 (from kernel version 3.1).
-55
Documentation/arm/keystone/Overview.txt
··· 1 - TI Keystone Linux Overview 2 - -------------------------- 3 - 4 - Introduction 5 - ------------ 6 - Keystone range of SoCs are based on ARM Cortex-A15 MPCore Processors 7 - and c66x DSP cores. This document describes essential information required 8 - for users to run Linux on Keystone based EVMs from Texas Instruments. 9 - 10 - Following SoCs & EVMs are currently supported:- 11 - 12 - ------------ K2HK SoC and EVM -------------------------------------------------- 13 - 14 - a.k.a Keystone 2 Hawking/Kepler SoC 15 - TCI6636K2H & TCI6636K2K: See documentation at 16 - http://www.ti.com/product/tci6638k2k 17 - http://www.ti.com/product/tci6638k2h 18 - 19 - EVM: 20 - http://www.advantech.com/Support/TI-EVM/EVMK2HX_sd.aspx 21 - 22 - ------------ K2E SoC and EVM --------------------------------------------------- 23 - 24 - a.k.a Keystone 2 Edison SoC 25 - K2E - 66AK2E05: See documentation at 26 - http://www.ti.com/product/66AK2E05/technicaldocuments 27 - 28 - EVM: 29 - https://www.einfochips.com/index.php/partnerships/texas-instruments/k2e-evm.html 30 - 31 - ------------ K2L SoC and EVM --------------------------------------------------- 32 - 33 - a.k.a Keystone 2 Lamarr SoC 34 - K2L - TCI6630K2L: See documentation at 35 - http://www.ti.com/product/TCI6630K2L/technicaldocuments 36 - EVM: 37 - https://www.einfochips.com/index.php/partnerships/texas-instruments/k2l-evm.html 38 - 39 - Configuration 40 - ------------- 41 - 42 - All of the K2 SoCs/EVMs share a common defconfig, keystone_defconfig and same 43 - image is used to boot on individual EVMs. The platform configuration is 44 - specified through DTS. Following are the DTS used:- 45 - K2HK EVM : k2hk-evm.dts 46 - K2E EVM : k2e-evm.dts 47 - K2L EVM : k2l-evm.dts 48 - 49 - The device tree documentation for the keystone machines are located at 50 - Documentation/devicetree/bindings/arm/keystone/keystone.txt 51 - 52 - Document Author 53 - --------------- 54 - Murali Karicheri <m-karicheri2@ti.com> 55 - Copyright 2015 Texas Instruments
+60
Documentation/arm/keystone/knav-qmss.rst
··· 1 + ====================================================================== 2 + Texas Instruments Keystone Navigator Queue Management SubSystem driver 3 + ====================================================================== 4 + 5 + Driver source code path 6 + drivers/soc/ti/knav_qmss.c 7 + drivers/soc/ti/knav_qmss_acc.c 8 + 9 + The QMSS (Queue Manager Sub System) found on Keystone SOCs is one of 10 + the main hardware sub system which forms the backbone of the Keystone 11 + multi-core Navigator. QMSS consist of queue managers, packed-data structure 12 + processors(PDSP), linking RAM, descriptor pools and infrastructure 13 + Packet DMA. 14 + The Queue Manager is a hardware module that is responsible for accelerating 15 + management of the packet queues. Packets are queued/de-queued by writing or 16 + reading descriptor address to a particular memory mapped location. The PDSPs 17 + perform QMSS related functions like accumulation, QoS, or event management. 18 + Linking RAM registers are used to link the descriptors which are stored in 19 + descriptor RAM. Descriptor RAM is configurable as internal or external memory. 20 + The QMSS driver manages the PDSP setups, linking RAM regions, 21 + queue pool management (allocation, push, pop and notify) and descriptor 22 + pool management. 23 + 24 + knav qmss driver provides a set of APIs to drivers to open/close qmss queues, 25 + allocate descriptor pools, map the descriptors, push/pop to queues etc. For 26 + details of the available APIs, please refers to include/linux/soc/ti/knav_qmss.h 27 + 28 + DT documentation is available at 29 + Documentation/devicetree/bindings/soc/ti/keystone-navigator-qmss.txt 30 + 31 + Accumulator QMSS queues using PDSP firmware 32 + ============================================ 33 + The QMSS PDSP firmware support accumulator channel that can monitor a single 34 + queue or multiple contiguous queues. drivers/soc/ti/knav_qmss_acc.c is the 35 + driver that interface with the accumulator PDSP. This configures 36 + accumulator channels defined in DTS (example in DT documentation) to monitor 37 + 1 or 32 queues per channel. More description on the firmware is available in 38 + CPPI/QMSS Low Level Driver document (docs/CPPI_QMSS_LLD_SDS.pdf) at 39 + 40 + git://git.ti.com/keystone-rtos/qmss-lld.git 41 + 42 + k2_qmss_pdsp_acc48_k2_le_1_0_0_9.bin firmware supports upto 48 accumulator 43 + channels. This firmware is available under ti-keystone folder of 44 + firmware.git at 45 + 46 + git://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git 47 + 48 + To use copy the firmware image to lib/firmware folder of the initramfs or 49 + ubifs file system and provide a sym link to k2_qmss_pdsp_acc48_k2_le_1_0_0_9.bin 50 + in the file system and boot up the kernel. User would see 51 + 52 + "firmware file ks2_qmss_pdsp_acc48.bin downloaded for PDSP" 53 + 54 + in the boot up log if loading of firmware to PDSP is successful. 55 + 56 + Use of accumulated queues requires the firmware image to be present in the 57 + file system. The driver doesn't acc queues to the supported queue range if 58 + PDSP is not running in the SoC. The API call fails if there is a queue open 59 + request to an acc queue and PDSP is not running. So make sure to copy firmware 60 + to file system before using these queue types.
-56
Documentation/arm/keystone/knav-qmss.txt
··· 1 - * Texas Instruments Keystone Navigator Queue Management SubSystem driver 2 - 3 - Driver source code path 4 - drivers/soc/ti/knav_qmss.c 5 - drivers/soc/ti/knav_qmss_acc.c 6 - 7 - The QMSS (Queue Manager Sub System) found on Keystone SOCs is one of 8 - the main hardware sub system which forms the backbone of the Keystone 9 - multi-core Navigator. QMSS consist of queue managers, packed-data structure 10 - processors(PDSP), linking RAM, descriptor pools and infrastructure 11 - Packet DMA. 12 - The Queue Manager is a hardware module that is responsible for accelerating 13 - management of the packet queues. Packets are queued/de-queued by writing or 14 - reading descriptor address to a particular memory mapped location. The PDSPs 15 - perform QMSS related functions like accumulation, QoS, or event management. 16 - Linking RAM registers are used to link the descriptors which are stored in 17 - descriptor RAM. Descriptor RAM is configurable as internal or external memory. 18 - The QMSS driver manages the PDSP setups, linking RAM regions, 19 - queue pool management (allocation, push, pop and notify) and descriptor 20 - pool management. 21 - 22 - knav qmss driver provides a set of APIs to drivers to open/close qmss queues, 23 - allocate descriptor pools, map the descriptors, push/pop to queues etc. For 24 - details of the available APIs, please refers to include/linux/soc/ti/knav_qmss.h 25 - 26 - DT documentation is available at 27 - Documentation/devicetree/bindings/soc/ti/keystone-navigator-qmss.txt 28 - 29 - Accumulator QMSS queues using PDSP firmware 30 - ============================================ 31 - The QMSS PDSP firmware support accumulator channel that can monitor a single 32 - queue or multiple contiguous queues. drivers/soc/ti/knav_qmss_acc.c is the 33 - driver that interface with the accumulator PDSP. This configures 34 - accumulator channels defined in DTS (example in DT documentation) to monitor 35 - 1 or 32 queues per channel. More description on the firmware is available in 36 - CPPI/QMSS Low Level Driver document (docs/CPPI_QMSS_LLD_SDS.pdf) at 37 - git://git.ti.com/keystone-rtos/qmss-lld.git 38 - 39 - k2_qmss_pdsp_acc48_k2_le_1_0_0_9.bin firmware supports upto 48 accumulator 40 - channels. This firmware is available under ti-keystone folder of 41 - firmware.git at 42 - git://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git 43 - 44 - To use copy the firmware image to lib/firmware folder of the initramfs or 45 - ubifs file system and provide a sym link to k2_qmss_pdsp_acc48_k2_le_1_0_0_9.bin 46 - in the file system and boot up the kernel. User would see 47 - 48 - "firmware file ks2_qmss_pdsp_acc48.bin downloaded for PDSP" 49 - 50 - in the boot up log if loading of firmware to PDSP is successful. 51 - 52 - Use of accumulated queues requires the firmware image to be present in the 53 - file system. The driver doesn't acc queues to the supported queue range if 54 - PDSP is not running in the SoC. The API call fails if there is a queue open 55 - request to an acc queue and PDSP is not running. So make sure to copy firmware 56 - to file system before using these queue types.
+74
Documentation/arm/keystone/overview.rst
··· 1 + ========================== 2 + TI Keystone Linux Overview 3 + ========================== 4 + 5 + Introduction 6 + ------------ 7 + Keystone range of SoCs are based on ARM Cortex-A15 MPCore Processors 8 + and c66x DSP cores. This document describes essential information required 9 + for users to run Linux on Keystone based EVMs from Texas Instruments. 10 + 11 + Following SoCs & EVMs are currently supported:- 12 + 13 + K2HK SoC and EVM 14 + ================= 15 + 16 + a.k.a Keystone 2 Hawking/Kepler SoC 17 + TCI6636K2H & TCI6636K2K: See documentation at 18 + 19 + http://www.ti.com/product/tci6638k2k 20 + http://www.ti.com/product/tci6638k2h 21 + 22 + EVM: 23 + http://www.advantech.com/Support/TI-EVM/EVMK2HX_sd.aspx 24 + 25 + K2E SoC and EVM 26 + =============== 27 + 28 + a.k.a Keystone 2 Edison SoC 29 + 30 + K2E - 66AK2E05: 31 + 32 + See documentation at 33 + 34 + http://www.ti.com/product/66AK2E05/technicaldocuments 35 + 36 + EVM: 37 + https://www.einfochips.com/index.php/partnerships/texas-instruments/k2e-evm.html 38 + 39 + K2L SoC and EVM 40 + =============== 41 + 42 + a.k.a Keystone 2 Lamarr SoC 43 + 44 + K2L - TCI6630K2L: 45 + 46 + See documentation at 47 + http://www.ti.com/product/TCI6630K2L/technicaldocuments 48 + 49 + EVM: 50 + https://www.einfochips.com/index.php/partnerships/texas-instruments/k2l-evm.html 51 + 52 + Configuration 53 + ------------- 54 + 55 + All of the K2 SoCs/EVMs share a common defconfig, keystone_defconfig and same 56 + image is used to boot on individual EVMs. The platform configuration is 57 + specified through DTS. Following are the DTS used: 58 + 59 + K2HK EVM: 60 + k2hk-evm.dts 61 + K2E EVM: 62 + k2e-evm.dts 63 + K2L EVM: 64 + k2l-evm.dts 65 + 66 + The device tree documentation for the keystone machines are located at 67 + 68 + Documentation/devicetree/bindings/arm/keystone/keystone.txt 69 + 70 + Document Author 71 + --------------- 72 + Murali Karicheri <m-karicheri2@ti.com> 73 + 74 + Copyright 2015 Texas Instruments
+488
Documentation/arm/marvel.rst
··· 1 + ================ 2 + ARM Marvell SoCs 3 + ================ 4 + 5 + This document lists all the ARM Marvell SoCs that are currently 6 + supported in mainline by the Linux kernel. As the Marvell families of 7 + SoCs are large and complex, it is hard to understand where the support 8 + for a particular SoC is available in the Linux kernel. This document 9 + tries to help in understanding where those SoCs are supported, and to 10 + match them with their corresponding public datasheet, when available. 11 + 12 + Orion family 13 + ------------ 14 + 15 + Flavors: 16 + - 88F5082 17 + - 88F5181 18 + - 88F5181L 19 + - 88F5182 20 + 21 + - Datasheet: http://www.embeddedarm.com/documentation/third-party/MV88F5182-datasheet.pdf 22 + - Programmer's User Guide: http://www.embeddedarm.com/documentation/third-party/MV88F5182-opensource-manual.pdf 23 + - User Manual: http://www.embeddedarm.com/documentation/third-party/MV88F5182-usermanual.pdf 24 + - 88F5281 25 + 26 + - Datasheet: http://www.ocmodshop.com/images/reviews/networking/qnap_ts409u/marvel_88f5281_data_sheet.pdf 27 + - 88F6183 28 + Core: 29 + Feroceon 88fr331 (88f51xx) or 88fr531-vd (88f52xx) ARMv5 compatible 30 + Linux kernel mach directory: 31 + arch/arm/mach-orion5x 32 + Linux kernel plat directory: 33 + arch/arm/plat-orion 34 + 35 + Kirkwood family 36 + --------------- 37 + 38 + Flavors: 39 + - 88F6282 a.k.a Armada 300 40 + 41 + - Product Brief : http://www.marvell.com/embedded-processors/armada-300/assets/armada_310.pdf 42 + - 88F6283 a.k.a Armada 310 43 + 44 + - Product Brief : http://www.marvell.com/embedded-processors/armada-300/assets/armada_310.pdf 45 + - 88F6190 46 + 47 + - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6190-003_WEB.pdf 48 + - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F619x_OpenSource.pdf 49 + - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 50 + - 88F6192 51 + 52 + - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6192-003_ver1.pdf 53 + - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F619x_OpenSource.pdf 54 + - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 55 + - 88F6182 56 + - 88F6180 57 + 58 + - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6180-003_ver1.pdf 59 + - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F6180_OpenSource.pdf 60 + - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 61 + - 88F6281 62 + 63 + - Product Brief : http://www.marvell.com/embedded-processors/kirkwood/assets/88F6281-004_ver1.pdf 64 + - Hardware Spec : http://www.marvell.com/embedded-processors/kirkwood/assets/HW_88F6281_OpenSource.pdf 65 + - Functional Spec: http://www.marvell.com/embedded-processors/kirkwood/assets/FS_88F6180_9x_6281_OpenSource.pdf 66 + Homepage: 67 + http://www.marvell.com/embedded-processors/kirkwood/ 68 + Core: 69 + Feroceon 88fr131 ARMv5 compatible 70 + Linux kernel mach directory: 71 + arch/arm/mach-mvebu 72 + Linux kernel plat directory: 73 + none 74 + 75 + Discovery family 76 + ---------------- 77 + 78 + Flavors: 79 + - MV78100 80 + 81 + - Product Brief : http://www.marvell.com/embedded-processors/discovery-innovation/assets/MV78100-003_WEB.pdf 82 + - Hardware Spec : http://www.marvell.com/embedded-processors/discovery-innovation/assets/HW_MV78100_OpenSource.pdf 83 + - Functional Spec: http://www.marvell.com/embedded-processors/discovery-innovation/assets/FS_MV76100_78100_78200_OpenSource.pdf 84 + - MV78200 85 + 86 + - Product Brief : http://www.marvell.com/embedded-processors/discovery-innovation/assets/MV78200-002_WEB.pdf 87 + - Hardware Spec : http://www.marvell.com/embedded-processors/discovery-innovation/assets/HW_MV78200_OpenSource.pdf 88 + - Functional Spec: http://www.marvell.com/embedded-processors/discovery-innovation/assets/FS_MV76100_78100_78200_OpenSource.pdf 89 + - MV76100 90 + 91 + Not supported by the Linux kernel. 92 + 93 + Core: 94 + Feroceon 88fr571-vd ARMv5 compatible 95 + 96 + Linux kernel mach directory: 97 + arch/arm/mach-mv78xx0 98 + Linux kernel plat directory: 99 + arch/arm/plat-orion 100 + 101 + EBU Armada family 102 + ----------------- 103 + 104 + Armada 370 Flavors: 105 + - 88F6710 106 + - 88F6707 107 + - 88F6W11 108 + 109 + - Product Brief: http://www.marvell.com/embedded-processors/armada-300/assets/Marvell_ARMADA_370_SoC.pdf 110 + - Hardware Spec: http://www.marvell.com/embedded-processors/armada-300/assets/ARMADA370-datasheet.pdf 111 + - Functional Spec: http://www.marvell.com/embedded-processors/armada-300/assets/ARMADA370-FunctionalSpec-datasheet.pdf 112 + 113 + Core: 114 + Sheeva ARMv7 compatible PJ4B 115 + 116 + Armada 375 Flavors: 117 + - 88F6720 118 + 119 + - Product Brief: http://www.marvell.com/embedded-processors/armada-300/assets/ARMADA_375_SoC-01_product_brief.pdf 120 + 121 + Core: 122 + ARM Cortex-A9 123 + 124 + Armada 38x Flavors: 125 + - 88F6810 Armada 380 126 + - 88F6820 Armada 385 127 + - 88F6828 Armada 388 128 + 129 + - Product infos: http://www.marvell.com/embedded-processors/armada-38x/ 130 + - Functional Spec: https://marvellcorp.wufoo.com/forms/marvell-armada-38x-functional-specifications/ 131 + 132 + Core: 133 + ARM Cortex-A9 134 + 135 + Armada 39x Flavors: 136 + - 88F6920 Armada 390 137 + - 88F6928 Armada 398 138 + 139 + - Product infos: http://www.marvell.com/embedded-processors/armada-39x/ 140 + 141 + Core: 142 + ARM Cortex-A9 143 + 144 + Armada XP Flavors: 145 + - MV78230 146 + - MV78260 147 + - MV78460 148 + 149 + NOTE: 150 + not to be confused with the non-SMP 78xx0 SoCs 151 + 152 + Product Brief: 153 + http://www.marvell.com/embedded-processors/armada-xp/assets/Marvell-ArmadaXP-SoC-product%20brief.pdf 154 + 155 + Functional Spec: 156 + http://www.marvell.com/embedded-processors/armada-xp/assets/ARMADA-XP-Functional-SpecDatasheet.pdf 157 + 158 + - Hardware Specs: 159 + 160 + - http://www.marvell.com/embedded-processors/armada-xp/assets/HW_MV78230_OS.PDF 161 + - http://www.marvell.com/embedded-processors/armada-xp/assets/HW_MV78260_OS.PDF 162 + - http://www.marvell.com/embedded-processors/armada-xp/assets/HW_MV78460_OS.PDF 163 + 164 + Core: 165 + Sheeva ARMv7 compatible Dual-core or Quad-core PJ4B-MP 166 + 167 + Linux kernel mach directory: 168 + arch/arm/mach-mvebu 169 + Linux kernel plat directory: 170 + none 171 + 172 + EBU Armada family ARMv8 173 + ----------------------- 174 + 175 + Armada 3710/3720 Flavors: 176 + - 88F3710 177 + - 88F3720 178 + 179 + Core: 180 + ARM Cortex A53 (ARMv8) 181 + 182 + Homepage: 183 + http://www.marvell.com/embedded-processors/armada-3700/ 184 + 185 + Product Brief: 186 + http://www.marvell.com/embedded-processors/assets/PB-88F3700-FNL.pdf 187 + 188 + Device tree files: 189 + arch/arm64/boot/dts/marvell/armada-37* 190 + 191 + Armada 7K Flavors: 192 + - 88F7020 (AP806 Dual + one CP110) 193 + - 88F7040 (AP806 Quad + one CP110) 194 + 195 + Core: ARM Cortex A72 196 + 197 + Homepage: 198 + http://www.marvell.com/embedded-processors/armada-70xx/ 199 + 200 + Product Brief: 201 + - http://www.marvell.com/embedded-processors/assets/Armada7020PB-Jan2016.pdf 202 + - http://www.marvell.com/embedded-processors/assets/Armada7040PB-Jan2016.pdf 203 + 204 + Device tree files: 205 + arch/arm64/boot/dts/marvell/armada-70* 206 + 207 + Armada 8K Flavors: 208 + - 88F8020 (AP806 Dual + two CP110) 209 + - 88F8040 (AP806 Quad + two CP110) 210 + Core: 211 + ARM Cortex A72 212 + 213 + Homepage: 214 + http://www.marvell.com/embedded-processors/armada-80xx/ 215 + 216 + Product Brief: 217 + - http://www.marvell.com/embedded-processors/assets/Armada8020PB-Jan2016.pdf 218 + - http://www.marvell.com/embedded-processors/assets/Armada8040PB-Jan2016.pdf 219 + 220 + Device tree files: 221 + arch/arm64/boot/dts/marvell/armada-80* 222 + 223 + Avanta family 224 + ------------- 225 + 226 + Flavors: 227 + - 88F6510 228 + - 88F6530P 229 + - 88F6550 230 + - 88F6560 231 + 232 + Homepage: 233 + http://www.marvell.com/broadband/ 234 + 235 + Product Brief: 236 + http://www.marvell.com/broadband/assets/Marvell_Avanta_88F6510_305_060-001_product_brief.pdf 237 + 238 + No public datasheet available. 239 + 240 + Core: 241 + ARMv5 compatible 242 + 243 + Linux kernel mach directory: 244 + no code in mainline yet, planned for the future 245 + Linux kernel plat directory: 246 + no code in mainline yet, planned for the future 247 + 248 + Storage family 249 + -------------- 250 + 251 + Armada SP: 252 + - 88RC1580 253 + 254 + Product infos: 255 + http://www.marvell.com/storage/armada-sp/ 256 + 257 + Core: 258 + Sheeva ARMv7 comatible Quad-core PJ4C 259 + 260 + (not supported in upstream Linux kernel) 261 + 262 + Dove family (application processor) 263 + ----------------------------------- 264 + 265 + Flavors: 266 + - 88AP510 a.k.a Armada 510 267 + 268 + Product Brief: 269 + http://www.marvell.com/application-processors/armada-500/assets/Marvell_Armada510_SoC.pdf 270 + 271 + Hardware Spec: 272 + http://www.marvell.com/application-processors/armada-500/assets/Armada-510-Hardware-Spec.pdf 273 + 274 + Functional Spec: 275 + http://www.marvell.com/application-processors/armada-500/assets/Armada-510-Functional-Spec.pdf 276 + 277 + Homepage: 278 + http://www.marvell.com/application-processors/armada-500/ 279 + 280 + Core: 281 + ARMv7 compatible 282 + 283 + Directory: 284 + - arch/arm/mach-mvebu (DT enabled platforms) 285 + - arch/arm/mach-dove (non-DT enabled platforms) 286 + 287 + PXA 2xx/3xx/93x/95x family 288 + -------------------------- 289 + 290 + Flavors: 291 + - PXA21x, PXA25x, PXA26x 292 + - Application processor only 293 + - Core: ARMv5 XScale1 core 294 + - PXA270, PXA271, PXA272 295 + - Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_pb.pdf 296 + - Design guide : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_design_guide.pdf 297 + - Developers manual : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_dev_man.pdf 298 + - Specification : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_emts.pdf 299 + - Specification update : http://www.marvell.com/application-processors/pxa-family/assets/pxa_27x_spec_update.pdf 300 + - Application processor only 301 + - Core: ARMv5 XScale2 core 302 + - PXA300, PXA310, PXA320 303 + - PXA 300 Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/PXA300_PB_R4.pdf 304 + - PXA 310 Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/PXA310_PB_R4.pdf 305 + - PXA 320 Product Brief : http://www.marvell.com/application-processors/pxa-family/assets/PXA320_PB_R4.pdf 306 + - Design guide : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_Design_Guide.pdf 307 + - Developers manual : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_Developers_Manual.zip 308 + - Specifications : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_EMTS.pdf 309 + - Specification Update : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_Spec_Update.zip 310 + - Reference Manual : http://www.marvell.com/application-processors/pxa-family/assets/PXA3xx_TavorP_BootROM_Ref_Manual.pdf 311 + - Application processor only 312 + - Core: ARMv5 XScale3 core 313 + - PXA930, PXA935 314 + - Application processor with Communication processor 315 + - Core: ARMv5 XScale3 core 316 + - PXA955 317 + - Application processor with Communication processor 318 + - Core: ARMv7 compatible Sheeva PJ4 core 319 + 320 + Comments: 321 + 322 + * This line of SoCs originates from the XScale family developed by 323 + Intel and acquired by Marvell in ~2006. The PXA21x, PXA25x, 324 + PXA26x, PXA27x, PXA3xx and PXA93x were developed by Intel, while 325 + the later PXA95x were developed by Marvell. 326 + 327 + * Due to their XScale origin, these SoCs have virtually nothing in 328 + common with the other (Kirkwood, Dove, etc.) families of Marvell 329 + SoCs, except with the MMP/MMP2 family of SoCs. 330 + 331 + Linux kernel mach directory: 332 + arch/arm/mach-pxa 333 + Linux kernel plat directory: 334 + arch/arm/plat-pxa 335 + 336 + MMP/MMP2/MMP3 family (communication processor) 337 + ---------------------------------------------- 338 + 339 + Flavors: 340 + - PXA168, a.k.a Armada 168 341 + - Homepage : http://www.marvell.com/application-processors/armada-100/armada-168.jsp 342 + - Product brief : http://www.marvell.com/application-processors/armada-100/assets/pxa_168_pb.pdf 343 + - Hardware manual : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_datasheet.pdf 344 + - Software manual : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_software_manual.pdf 345 + - Specification update : http://www.marvell.com/application-processors/armada-100/assets/ARMADA16x_Spec_update.pdf 346 + - Boot ROM manual : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_ref_manual.pdf 347 + - App node package : http://www.marvell.com/application-processors/armada-100/assets/armada_16x_app_note_package.pdf 348 + - Application processor only 349 + - Core: ARMv5 compatible Marvell PJ1 88sv331 (Mohawk) 350 + - PXA910/PXA920 351 + - Homepage : http://www.marvell.com/communication-processors/pxa910/ 352 + - Product Brief : http://www.marvell.com/communication-processors/pxa910/assets/Marvell_PXA910_Platform-001_PB_final.pdf 353 + - Application processor with Communication processor 354 + - Core: ARMv5 compatible Marvell PJ1 88sv331 (Mohawk) 355 + - PXA688, a.k.a. MMP2, a.k.a Armada 610 356 + - Product Brief : http://www.marvell.com/application-processors/armada-600/assets/armada610_pb.pdf 357 + - Application processor only 358 + - Core: ARMv7 compatible Sheeva PJ4 88sv581x core 359 + - PXA2128, a.k.a. MMP3 (OLPC XO4, Linux support not upstream) 360 + - Product Brief : http://www.marvell.com/application-processors/armada/pxa2128/assets/Marvell-ARMADA-PXA2128-SoC-PB.pdf 361 + - Application processor only 362 + - Core: Dual-core ARMv7 compatible Sheeva PJ4C core 363 + - PXA960/PXA968/PXA978 (Linux support not upstream) 364 + - Application processor with Communication Processor 365 + - Core: ARMv7 compatible Sheeva PJ4 core 366 + - PXA986/PXA988 (Linux support not upstream) 367 + - Application processor with Communication Processor 368 + - Core: Dual-core ARMv7 compatible Sheeva PJ4B-MP core 369 + - PXA1088/PXA1920 (Linux support not upstream) 370 + - Application processor with Communication Processor 371 + - Core: quad-core ARMv7 Cortex-A7 372 + - PXA1908/PXA1928/PXA1936 373 + - Application processor with Communication Processor 374 + - Core: multi-core ARMv8 Cortex-A53 375 + 376 + Comments: 377 + 378 + * This line of SoCs originates from the XScale family developed by 379 + Intel and acquired by Marvell in ~2006. All the processors of 380 + this MMP/MMP2 family were developed by Marvell. 381 + 382 + * Due to their XScale origin, these SoCs have virtually nothing in 383 + common with the other (Kirkwood, Dove, etc.) families of Marvell 384 + SoCs, except with the PXA family of SoCs listed above. 385 + 386 + Linux kernel mach directory: 387 + arch/arm/mach-mmp 388 + Linux kernel plat directory: 389 + arch/arm/plat-pxa 390 + 391 + Berlin family (Multimedia Solutions) 392 + ------------------------------------- 393 + 394 + - Flavors: 395 + - 88DE3010, Armada 1000 (no Linux support) 396 + - Core: Marvell PJ1 (ARMv5TE), Dual-core 397 + - Product Brief: http://www.marvell.com.cn/digital-entertainment/assets/armada_1000_pb.pdf 398 + - 88DE3005, Armada 1500 Mini 399 + - Design name: BG2CD 400 + - Core: ARM Cortex-A9, PL310 L2CC 401 + - 88DE3006, Armada 1500 Mini Plus 402 + - Design name: BG2CDP 403 + - Core: Dual Core ARM Cortex-A7 404 + - 88DE3100, Armada 1500 405 + - Design name: BG2 406 + - Core: Marvell PJ4B-MP (ARMv7), Tauros3 L2CC 407 + - 88DE3114, Armada 1500 Pro 408 + - Design name: BG2Q 409 + - Core: Quad Core ARM Cortex-A9, PL310 L2CC 410 + - 88DE3214, Armada 1500 Pro 4K 411 + - Design name: BG3 412 + - Core: ARM Cortex-A15, CA15 integrated L2CC 413 + - 88DE3218, ARMADA 1500 Ultra 414 + - Core: ARM Cortex-A53 415 + 416 + Homepage: https://www.synaptics.com/products/multimedia-solutions 417 + Directory: arch/arm/mach-berlin 418 + 419 + Comments: 420 + 421 + * This line of SoCs is based on Marvell Sheeva or ARM Cortex CPUs 422 + with Synopsys DesignWare (IRQ, GPIO, Timers, ...) and PXA IP (SDHCI, USB, ETH, ...). 423 + 424 + * The Berlin family was acquired by Synaptics from Marvell in 2017. 425 + 426 + CPU Cores 427 + --------- 428 + 429 + The XScale cores were designed by Intel, and shipped by Marvell in the older 430 + PXA processors. Feroceon is a Marvell designed core that developed in-house, 431 + and that evolved into Sheeva. The XScale and Feroceon cores were phased out 432 + over time and replaced with Sheeva cores in later products, which subsequently 433 + got replaced with licensed ARM Cortex-A cores. 434 + 435 + XScale 1 436 + CPUID 0x69052xxx 437 + ARMv5, iWMMXt 438 + XScale 2 439 + CPUID 0x69054xxx 440 + ARMv5, iWMMXt 441 + XScale 3 442 + CPUID 0x69056xxx or 0x69056xxx 443 + ARMv5, iWMMXt 444 + Feroceon-1850 88fr331 "Mohawk" 445 + CPUID 0x5615331x or 0x41xx926x 446 + ARMv5TE, single issue 447 + Feroceon-2850 88fr531-vd "Jolteon" 448 + CPUID 0x5605531x or 0x41xx926x 449 + ARMv5TE, VFP, dual-issue 450 + Feroceon 88fr571-vd "Jolteon" 451 + CPUID 0x5615571x 452 + ARMv5TE, VFP, dual-issue 453 + Feroceon 88fr131 "Mohawk-D" 454 + CPUID 0x5625131x 455 + ARMv5TE, single-issue in-order 456 + Sheeva PJ1 88sv331 "Mohawk" 457 + CPUID 0x561584xx 458 + ARMv5, single-issue iWMMXt v2 459 + Sheeva PJ4 88sv581x "Flareon" 460 + CPUID 0x560f581x 461 + ARMv7, idivt, optional iWMMXt v2 462 + Sheeva PJ4B 88sv581x 463 + CPUID 0x561f581x 464 + ARMv7, idivt, optional iWMMXt v2 465 + Sheeva PJ4B-MP / PJ4C 466 + CPUID 0x562f584x 467 + ARMv7, idivt/idiva, LPAE, optional iWMMXt v2 and/or NEON 468 + 469 + Long-term plans 470 + --------------- 471 + 472 + * Unify the mach-dove/, mach-mv78xx0/, mach-orion5x/ into the 473 + mach-mvebu/ to support all SoCs from the Marvell EBU (Engineering 474 + Business Unit) in a single mach-<foo> directory. The plat-orion/ 475 + would therefore disappear. 476 + 477 + * Unify the mach-mmp/ and mach-pxa/ into the same mach-pxa 478 + directory. The plat-pxa/ would therefore disappear. 479 + 480 + Credits 481 + ------- 482 + 483 + - Maen Suleiman <maen@marvell.com> 484 + - Lior Amsalem <alior@marvell.com> 485 + - Thomas Petazzoni <thomas.petazzoni@free-electrons.com> 486 + - Andrew Lunn <andrew@lunn.ch> 487 + - Nicolas Pitre <nico@fluxnic.net> 488 + - Eric Miao <eric.y.miao@gmail.com>
-58
Documentation/arm/mem_alignment
··· 1 - Too many problems popped up because of unnoticed misaligned memory access in 2 - kernel code lately. Therefore the alignment fixup is now unconditionally 3 - configured in for SA11x0 based targets. According to Alan Cox, this is a 4 - bad idea to configure it out, but Russell King has some good reasons for 5 - doing so on some f***ed up ARM architectures like the EBSA110. However 6 - this is not the case on many design I'm aware of, like all SA11x0 based 7 - ones. 8 - 9 - Of course this is a bad idea to rely on the alignment trap to perform 10 - unaligned memory access in general. If those access are predictable, you 11 - are better to use the macros provided by include/asm/unaligned.h. The 12 - alignment trap can fixup misaligned access for the exception cases, but at 13 - a high performance cost. It better be rare. 14 - 15 - Now for user space applications, it is possible to configure the alignment 16 - trap to SIGBUS any code performing unaligned access (good for debugging bad 17 - code), or even fixup the access by software like for kernel code. The later 18 - mode isn't recommended for performance reasons (just think about the 19 - floating point emulation that works about the same way). Fix your code 20 - instead! 21 - 22 - Please note that randomly changing the behaviour without good thought is 23 - real bad - it changes the behaviour of all unaligned instructions in user 24 - space, and might cause programs to fail unexpectedly. 25 - 26 - To change the alignment trap behavior, simply echo a number into 27 - /proc/cpu/alignment. The number is made up from various bits: 28 - 29 - bit behavior when set 30 - --- ----------------- 31 - 32 - 0 A user process performing an unaligned memory access 33 - will cause the kernel to print a message indicating 34 - process name, pid, pc, instruction, address, and the 35 - fault code. 36 - 37 - 1 The kernel will attempt to fix up the user process 38 - performing the unaligned access. This is of course 39 - slow (think about the floating point emulator) and 40 - not recommended for production use. 41 - 42 - 2 The kernel will send a SIGBUS signal to the user process 43 - performing the unaligned access. 44 - 45 - Note that not all combinations are supported - only values 0 through 5. 46 - (6 and 7 don't make sense). 47 - 48 - For example, the following will turn on the warnings, but without 49 - fixing up or sending SIGBUS signals: 50 - 51 - echo 1 > /proc/cpu/alignment 52 - 53 - You can also read the content of the same file to get statistical 54 - information on unaligned access occurrences plus the current mode of 55 - operation for user space code. 56 - 57 - 58 - Nicolas Pitre, Mar 13, 2001. Modified Russell King, Nov 30, 2001.
+63
Documentation/arm/mem_alignment.rst
··· 1 + ================ 2 + Memory alignment 3 + ================ 4 + 5 + Too many problems popped up because of unnoticed misaligned memory access in 6 + kernel code lately. Therefore the alignment fixup is now unconditionally 7 + configured in for SA11x0 based targets. According to Alan Cox, this is a 8 + bad idea to configure it out, but Russell King has some good reasons for 9 + doing so on some f***ed up ARM architectures like the EBSA110. However 10 + this is not the case on many design I'm aware of, like all SA11x0 based 11 + ones. 12 + 13 + Of course this is a bad idea to rely on the alignment trap to perform 14 + unaligned memory access in general. If those access are predictable, you 15 + are better to use the macros provided by include/asm/unaligned.h. The 16 + alignment trap can fixup misaligned access for the exception cases, but at 17 + a high performance cost. It better be rare. 18 + 19 + Now for user space applications, it is possible to configure the alignment 20 + trap to SIGBUS any code performing unaligned access (good for debugging bad 21 + code), or even fixup the access by software like for kernel code. The later 22 + mode isn't recommended for performance reasons (just think about the 23 + floating point emulation that works about the same way). Fix your code 24 + instead! 25 + 26 + Please note that randomly changing the behaviour without good thought is 27 + real bad - it changes the behaviour of all unaligned instructions in user 28 + space, and might cause programs to fail unexpectedly. 29 + 30 + To change the alignment trap behavior, simply echo a number into 31 + /proc/cpu/alignment. The number is made up from various bits: 32 + 33 + === ======================================================== 34 + bit behavior when set 35 + === ======================================================== 36 + 0 A user process performing an unaligned memory access 37 + will cause the kernel to print a message indicating 38 + process name, pid, pc, instruction, address, and the 39 + fault code. 40 + 41 + 1 The kernel will attempt to fix up the user process 42 + performing the unaligned access. This is of course 43 + slow (think about the floating point emulator) and 44 + not recommended for production use. 45 + 46 + 2 The kernel will send a SIGBUS signal to the user process 47 + performing the unaligned access. 48 + === ======================================================== 49 + 50 + Note that not all combinations are supported - only values 0 through 5. 51 + (6 and 7 don't make sense). 52 + 53 + For example, the following will turn on the warnings, but without 54 + fixing up or sending SIGBUS signals:: 55 + 56 + echo 1 > /proc/cpu/alignment 57 + 58 + You can also read the content of the same file to get statistical 59 + information on unaligned access occurrences plus the current mode of 60 + operation for user space code. 61 + 62 + 63 + Nicolas Pitre, Mar 13, 2001. Modified Russell King, Nov 30, 2001.
+93
Documentation/arm/memory.rst
··· 1 + ================================= 2 + Kernel Memory Layout on ARM Linux 3 + ================================= 4 + 5 + Russell King <rmk@arm.linux.org.uk> 6 + 7 + November 17, 2005 (2.6.15) 8 + 9 + This document describes the virtual memory layout which the Linux 10 + kernel uses for ARM processors. It indicates which regions are 11 + free for platforms to use, and which are used by generic code. 12 + 13 + The ARM CPU is capable of addressing a maximum of 4GB virtual memory 14 + space, and this must be shared between user space processes, the 15 + kernel, and hardware devices. 16 + 17 + As the ARM architecture matures, it becomes necessary to reserve 18 + certain regions of VM space for use for new facilities; therefore 19 + this document may reserve more VM space over time. 20 + 21 + =============== =============== =============================================== 22 + Start End Use 23 + =============== =============== =============================================== 24 + ffff8000 ffffffff copy_user_page / clear_user_page use. 25 + For SA11xx and Xscale, this is used to 26 + setup a minicache mapping. 27 + 28 + ffff4000 ffffffff cache aliasing on ARMv6 and later CPUs. 29 + 30 + ffff1000 ffff7fff Reserved. 31 + Platforms must not use this address range. 32 + 33 + ffff0000 ffff0fff CPU vector page. 34 + The CPU vectors are mapped here if the 35 + CPU supports vector relocation (control 36 + register V bit.) 37 + 38 + fffe0000 fffeffff XScale cache flush area. This is used 39 + in proc-xscale.S to flush the whole data 40 + cache. (XScale does not have TCM.) 41 + 42 + fffe8000 fffeffff DTCM mapping area for platforms with 43 + DTCM mounted inside the CPU. 44 + 45 + fffe0000 fffe7fff ITCM mapping area for platforms with 46 + ITCM mounted inside the CPU. 47 + 48 + ffc00000 ffefffff Fixmap mapping region. Addresses provided 49 + by fix_to_virt() will be located here. 50 + 51 + fee00000 feffffff Mapping of PCI I/O space. This is a static 52 + mapping within the vmalloc space. 53 + 54 + VMALLOC_START VMALLOC_END-1 vmalloc() / ioremap() space. 55 + Memory returned by vmalloc/ioremap will 56 + be dynamically placed in this region. 57 + Machine specific static mappings are also 58 + located here through iotable_init(). 59 + VMALLOC_START is based upon the value 60 + of the high_memory variable, and VMALLOC_END 61 + is equal to 0xff800000. 62 + 63 + PAGE_OFFSET high_memory-1 Kernel direct-mapped RAM region. 64 + This maps the platforms RAM, and typically 65 + maps all platform RAM in a 1:1 relationship. 66 + 67 + PKMAP_BASE PAGE_OFFSET-1 Permanent kernel mappings 68 + One way of mapping HIGHMEM pages into kernel 69 + space. 70 + 71 + MODULES_VADDR MODULES_END-1 Kernel module space 72 + Kernel modules inserted via insmod are 73 + placed here using dynamic mappings. 74 + 75 + 00001000 TASK_SIZE-1 User space mappings 76 + Per-thread mappings are placed here via 77 + the mmap() system call. 78 + 79 + 00000000 00000fff CPU vector page / null pointer trap 80 + CPUs which do not support vector remapping 81 + place their vector page here. NULL pointer 82 + dereferences by both the kernel and user 83 + space are also caught via this mapping. 84 + =============== =============== =============================================== 85 + 86 + Please note that mappings which collide with the above areas may result 87 + in a non-bootable kernel, or may cause the kernel to (eventually) panic 88 + at run time. 89 + 90 + Since future CPUs may impact the kernel mapping layout, user programs 91 + must not access any memory which is not mapped inside their 0x0001000 92 + to TASK_SIZE address range. If they wish to access these areas, they 93 + must set up their own mappings using open() and mmap().
-88
Documentation/arm/memory.txt
··· 1 - Kernel Memory Layout on ARM Linux 2 - 3 - Russell King <rmk@arm.linux.org.uk> 4 - November 17, 2005 (2.6.15) 5 - 6 - This document describes the virtual memory layout which the Linux 7 - kernel uses for ARM processors. It indicates which regions are 8 - free for platforms to use, and which are used by generic code. 9 - 10 - The ARM CPU is capable of addressing a maximum of 4GB virtual memory 11 - space, and this must be shared between user space processes, the 12 - kernel, and hardware devices. 13 - 14 - As the ARM architecture matures, it becomes necessary to reserve 15 - certain regions of VM space for use for new facilities; therefore 16 - this document may reserve more VM space over time. 17 - 18 - Start End Use 19 - -------------------------------------------------------------------------- 20 - ffff8000 ffffffff copy_user_page / clear_user_page use. 21 - For SA11xx and Xscale, this is used to 22 - setup a minicache mapping. 23 - 24 - ffff4000 ffffffff cache aliasing on ARMv6 and later CPUs. 25 - 26 - ffff1000 ffff7fff Reserved. 27 - Platforms must not use this address range. 28 - 29 - ffff0000 ffff0fff CPU vector page. 30 - The CPU vectors are mapped here if the 31 - CPU supports vector relocation (control 32 - register V bit.) 33 - 34 - fffe0000 fffeffff XScale cache flush area. This is used 35 - in proc-xscale.S to flush the whole data 36 - cache. (XScale does not have TCM.) 37 - 38 - fffe8000 fffeffff DTCM mapping area for platforms with 39 - DTCM mounted inside the CPU. 40 - 41 - fffe0000 fffe7fff ITCM mapping area for platforms with 42 - ITCM mounted inside the CPU. 43 - 44 - ffc00000 ffefffff Fixmap mapping region. Addresses provided 45 - by fix_to_virt() will be located here. 46 - 47 - fee00000 feffffff Mapping of PCI I/O space. This is a static 48 - mapping within the vmalloc space. 49 - 50 - VMALLOC_START VMALLOC_END-1 vmalloc() / ioremap() space. 51 - Memory returned by vmalloc/ioremap will 52 - be dynamically placed in this region. 53 - Machine specific static mappings are also 54 - located here through iotable_init(). 55 - VMALLOC_START is based upon the value 56 - of the high_memory variable, and VMALLOC_END 57 - is equal to 0xff800000. 58 - 59 - PAGE_OFFSET high_memory-1 Kernel direct-mapped RAM region. 60 - This maps the platforms RAM, and typically 61 - maps all platform RAM in a 1:1 relationship. 62 - 63 - PKMAP_BASE PAGE_OFFSET-1 Permanent kernel mappings 64 - One way of mapping HIGHMEM pages into kernel 65 - space. 66 - 67 - MODULES_VADDR MODULES_END-1 Kernel module space 68 - Kernel modules inserted via insmod are 69 - placed here using dynamic mappings. 70 - 71 - 00001000 TASK_SIZE-1 User space mappings 72 - Per-thread mappings are placed here via 73 - the mmap() system call. 74 - 75 - 00000000 00000fff CPU vector page / null pointer trap 76 - CPUs which do not support vector remapping 77 - place their vector page here. NULL pointer 78 - dereferences by both the kernel and user 79 - space are also caught via this mapping. 80 - 81 - Please note that mappings which collide with the above areas may result 82 - in a non-bootable kernel, or may cause the kernel to (eventually) panic 83 - at run time. 84 - 85 - Since future CPUs may impact the kernel mapping layout, user programs 86 - must not access any memory which is not mapped inside their 0x0001000 87 - to TASK_SIZE address range. If they wish to access these areas, they 88 - must set up their own mappings using open() and mmap().
+204
Documentation/arm/microchip.rst
··· 1 + ============================= 2 + ARM Microchip SoCs (aka AT91) 3 + ============================= 4 + 5 + 6 + Introduction 7 + ------------ 8 + This document gives useful information about the ARM Microchip SoCs that are 9 + currently supported in Linux Mainline (you know, the one on kernel.org). 10 + 11 + It is important to note that the Microchip (previously Atmel) ARM-based MPU 12 + product line is historically named "AT91" or "at91" throughout the Linux kernel 13 + development process even if this product prefix has completely disappeared from 14 + the official Microchip product name. Anyway, files, directories, git trees, 15 + git branches/tags and email subject always contain this "at91" sub-string. 16 + 17 + 18 + AT91 SoCs 19 + --------- 20 + Documentation and detailed datasheet for each product are available on 21 + the Microchip website: http://www.microchip.com. 22 + 23 + Flavors: 24 + * ARM 920 based SoC 25 + - at91rm9200 26 + 27 + * Datasheet 28 + 29 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-1768-32-bit-ARM920T-Embedded-Microprocessor-AT91RM9200_Datasheet.pdf 30 + 31 + * ARM 926 based SoCs 32 + - at91sam9260 33 + 34 + * Datasheet 35 + 36 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6221-32-bit-ARM926EJ-S-Embedded-Microprocessor-SAM9260_Datasheet.pdf 37 + 38 + - at91sam9xe 39 + 40 + * Datasheet 41 + 42 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6254-32-bit-ARM926EJ-S-Embedded-Microprocessor-SAM9XE_Datasheet.pdf 43 + 44 + - at91sam9261 45 + 46 + * Datasheet 47 + 48 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6062-ARM926EJ-S-Microprocessor-SAM9261_Datasheet.pdf 49 + 50 + - at91sam9263 51 + 52 + * Datasheet 53 + 54 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6249-32-bit-ARM926EJ-S-Embedded-Microprocessor-SAM9263_Datasheet.pdf 55 + 56 + - at91sam9rl 57 + 58 + * Datasheet 59 + 60 + http://ww1.microchip.com/downloads/en/DeviceDoc/doc6289.pdf 61 + 62 + - at91sam9g20 63 + 64 + * Datasheet 65 + 66 + http://ww1.microchip.com/downloads/en/DeviceDoc/DS60001516A.pdf 67 + 68 + - at91sam9g45 family 69 + - at91sam9g45 70 + - at91sam9g46 71 + - at91sam9m10 72 + - at91sam9m11 (device superset) 73 + 74 + * Datasheet 75 + 76 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-6437-32-bit-ARM926-Embedded-Microprocessor-SAM9M11_Datasheet.pdf 77 + 78 + - at91sam9x5 family (aka "The 5 series") 79 + - at91sam9g15 80 + - at91sam9g25 81 + - at91sam9g35 82 + - at91sam9x25 83 + - at91sam9x35 84 + 85 + * Datasheet (can be considered as covering the whole family) 86 + 87 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-11055-32-bit-ARM926EJ-S-Microcontroller-SAM9X35_Datasheet.pdf 88 + 89 + - at91sam9n12 90 + 91 + * Datasheet 92 + 93 + http://ww1.microchip.com/downloads/en/DeviceDoc/DS60001517A.pdf 94 + 95 + * ARM Cortex-A5 based SoCs 96 + - sama5d3 family 97 + 98 + - sama5d31 99 + - sama5d33 100 + - sama5d34 101 + - sama5d35 102 + - sama5d36 (device superset) 103 + 104 + * Datasheet 105 + 106 + http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-11121-32-bit-Cortex-A5-Microcontroller-SAMA5D3_Datasheet.pdf 107 + 108 + * ARM Cortex-A5 + NEON based SoCs 109 + - sama5d4 family 110 + 111 + - sama5d41 112 + - sama5d42 113 + - sama5d43 114 + - sama5d44 (device superset) 115 + 116 + * Datasheet 117 + 118 + http://ww1.microchip.com/downloads/en/DeviceDoc/60001525A.pdf 119 + 120 + - sama5d2 family 121 + 122 + - sama5d21 123 + - sama5d22 124 + - sama5d23 125 + - sama5d24 126 + - sama5d26 127 + - sama5d27 (device superset) 128 + - sama5d28 (device superset + environmental monitors) 129 + 130 + * Datasheet 131 + 132 + http://ww1.microchip.com/downloads/en/DeviceDoc/DS60001476B.pdf 133 + 134 + * ARM Cortex-M7 MCUs 135 + - sams70 family 136 + 137 + - sams70j19 138 + - sams70j20 139 + - sams70j21 140 + - sams70n19 141 + - sams70n20 142 + - sams70n21 143 + - sams70q19 144 + - sams70q20 145 + - sams70q21 146 + 147 + - samv70 family 148 + 149 + - samv70j19 150 + - samv70j20 151 + - samv70n19 152 + - samv70n20 153 + - samv70q19 154 + - samv70q20 155 + 156 + - samv71 family 157 + 158 + - samv71j19 159 + - samv71j20 160 + - samv71j21 161 + - samv71n19 162 + - samv71n20 163 + - samv71n21 164 + - samv71q19 165 + - samv71q20 166 + - samv71q21 167 + 168 + * Datasheet 169 + 170 + http://ww1.microchip.com/downloads/en/DeviceDoc/60001527A.pdf 171 + 172 + 173 + Linux kernel information 174 + ------------------------ 175 + Linux kernel mach directory: arch/arm/mach-at91 176 + MAINTAINERS entry is: "ARM/Microchip (AT91) SoC support" 177 + 178 + 179 + Device Tree for AT91 SoCs and boards 180 + ------------------------------------ 181 + All AT91 SoCs are converted to Device Tree. Since Linux 3.19, these products 182 + must use this method to boot the Linux kernel. 183 + 184 + Work In Progress statement: 185 + Device Tree files and Device Tree bindings that apply to AT91 SoCs and boards are 186 + considered as "Unstable". To be completely clear, any at91 binding can change at 187 + any time. So, be sure to use a Device Tree Binary and a Kernel Image generated from 188 + the same source tree. 189 + Please refer to the Documentation/devicetree/bindings/ABI.txt file for a 190 + definition of a "Stable" binding/ABI. 191 + This statement will be removed by AT91 MAINTAINERS when appropriate. 192 + 193 + Naming conventions and best practice: 194 + 195 + - SoCs Device Tree Source Include files are named after the official name of 196 + the product (at91sam9g20.dtsi or sama5d33.dtsi for instance). 197 + - Device Tree Source Include files (.dtsi) are used to collect common nodes that can be 198 + shared across SoCs or boards (sama5d3.dtsi or at91sam9x5cm.dtsi for instance). 199 + When collecting nodes for a particular peripheral or topic, the identifier have to 200 + be placed at the end of the file name, separated with a "_" (at91sam9x5_can.dtsi 201 + or sama5d3_gmac.dtsi for example). 202 + - board Device Tree Source files (.dts) are prefixed by the string "at91-" so 203 + that they can be identified easily. Note that some files are historical exceptions 204 + to this rule (sama5d3[13456]ek.dts, usb_a9g20.dts or animeo_ip.dts for example).
+85
Documentation/arm/netwinder.rst
··· 1 + ================================ 2 + NetWinder specific documentation 3 + ================================ 4 + 5 + The NetWinder is a small low-power computer, primarily designed 6 + to run Linux. It is based around the StrongARM RISC processor, 7 + DC21285 PCI bridge, with PC-type hardware glued around it. 8 + 9 + Port usage 10 + ========== 11 + 12 + ======= ====== =============================== 13 + Min Max Description 14 + ======= ====== =============================== 15 + 0x0000 0x000f DMA1 16 + 0x0020 0x0021 PIC1 17 + 0x0060 0x006f Keyboard 18 + 0x0070 0x007f RTC 19 + 0x0080 0x0087 DMA1 20 + 0x0088 0x008f DMA2 21 + 0x00a0 0x00a3 PIC2 22 + 0x00c0 0x00df DMA2 23 + 0x0180 0x0187 IRDA 24 + 0x01f0 0x01f6 ide0 25 + 0x0201 Game port 26 + 0x0203 RWA010 configuration read 27 + 0x0220 ? SoundBlaster 28 + 0x0250 ? WaveArtist 29 + 0x0279 RWA010 configuration index 30 + 0x02f8 0x02ff Serial ttyS1 31 + 0x0300 0x031f Ether10 32 + 0x0338 GPIO1 33 + 0x033a GPIO2 34 + 0x0370 0x0371 W83977F configuration registers 35 + 0x0388 ? AdLib 36 + 0x03c0 0x03df VGA 37 + 0x03f6 ide0 38 + 0x03f8 0x03ff Serial ttyS0 39 + 0x0400 0x0408 DC21143 40 + 0x0480 0x0487 DMA1 41 + 0x0488 0x048f DMA2 42 + 0x0a79 RWA010 configuration write 43 + 0xe800 0xe80f ide0/ide1 BM DMA 44 + ======= ====== =============================== 45 + 46 + 47 + Interrupt usage 48 + =============== 49 + 50 + ======= ======= ======================== 51 + IRQ type Description 52 + ======= ======= ======================== 53 + 0 ISA 100Hz timer 54 + 1 ISA Keyboard 55 + 2 ISA cascade 56 + 3 ISA Serial ttyS1 57 + 4 ISA Serial ttyS0 58 + 5 ISA PS/2 mouse 59 + 6 ISA IRDA 60 + 7 ISA Printer 61 + 8 ISA RTC alarm 62 + 9 ISA 63 + 10 ISA GP10 (Orange reset button) 64 + 11 ISA 65 + 12 ISA WaveArtist 66 + 13 ISA 67 + 14 ISA hda1 68 + 15 ISA 69 + ======= ======= ======================== 70 + 71 + DMA usage 72 + ========= 73 + 74 + ======= ======= =========== 75 + DMA type Description 76 + ======= ======= =========== 77 + 0 ISA IRDA 78 + 1 ISA 79 + 2 ISA cascade 80 + 3 ISA WaveArtist 81 + 4 ISA 82 + 5 ISA 83 + 6 ISA 84 + 7 ISA WaveArtist 85 + ======= ======= ===========
-29
Documentation/arm/nwfpe/NOTES
··· 1 - There seems to be a problem with exp(double) and our emulator. I haven't 2 - been able to track it down yet. This does not occur with the emulator 3 - supplied by Russell King. 4 - 5 - I also found one oddity in the emulator. I don't think it is serious but 6 - will point it out. The ARM calling conventions require floating point 7 - registers f4-f7 to be preserved over a function call. The compiler quite 8 - often uses an stfe instruction to save f4 on the stack upon entry to a 9 - function, and an ldfe instruction to restore it before returning. 10 - 11 - I was looking at some code, that calculated a double result, stored it in f4 12 - then made a function call. Upon return from the function call the number in 13 - f4 had been converted to an extended value in the emulator. 14 - 15 - This is a side effect of the stfe instruction. The double in f4 had to be 16 - converted to extended, then stored. If an lfm/sfm combination had been used, 17 - then no conversion would occur. This has performance considerations. The 18 - result from the function call and f4 were used in a multiplication. If the 19 - emulator sees a multiply of a double and extended, it promotes the double to 20 - extended, then does the multiply in extended precision. 21 - 22 - This code will cause this problem: 23 - 24 - double x, y, z; 25 - z = log(x)/log(y); 26 - 27 - The result of log(x) (a double) will be calculated, returned in f0, then 28 - moved to f4 to preserve it over the log(y) call. The division will be done 29 - in extended precision, due to the stfe instruction used to save f4 in log(y).
-70
Documentation/arm/nwfpe/README
··· 1 - This directory contains the version 0.92 test release of the NetWinder 2 - Floating Point Emulator. 3 - 4 - The majority of the code was written by me, Scott Bambrough It is 5 - written in C, with a small number of routines in inline assembler 6 - where required. It was written quickly, with a goal of implementing a 7 - working version of all the floating point instructions the compiler 8 - emits as the first target. I have attempted to be as optimal as 9 - possible, but there remains much room for improvement. 10 - 11 - I have attempted to make the emulator as portable as possible. One of 12 - the problems is with leading underscores on kernel symbols. Elf 13 - kernels have no leading underscores, a.out compiled kernels do. I 14 - have attempted to use the C_SYMBOL_NAME macro wherever this may be 15 - important. 16 - 17 - Another choice I made was in the file structure. I have attempted to 18 - contain all operating system specific code in one module (fpmodule.*). 19 - All the other files contain emulator specific code. This should allow 20 - others to port the emulator to NetBSD for instance relatively easily. 21 - 22 - The floating point operations are based on SoftFloat Release 2, by 23 - John Hauser. SoftFloat is a software implementation of floating-point 24 - that conforms to the IEC/IEEE Standard for Binary Floating-point 25 - Arithmetic. As many as four formats are supported: single precision, 26 - double precision, extended double precision, and quadruple precision. 27 - All operations required by the standard are implemented, except for 28 - conversions to and from decimal. We use only the single precision, 29 - double precision and extended double precision formats. The port of 30 - SoftFloat to the ARM was done by Phil Blundell, based on an earlier 31 - port of SoftFloat version 1 by Neil Carson for NetBSD/arm32. 32 - 33 - The file README.FPE contains a description of what has been implemented 34 - so far in the emulator. The file TODO contains a information on what 35 - remains to be done, and other ideas for the emulator. 36 - 37 - Bug reports, comments, suggestions should be directed to me at 38 - <scottb@netwinder.org>. General reports of "this program doesn't 39 - work correctly when your emulator is installed" are useful for 40 - determining that bugs still exist; but are virtually useless when 41 - attempting to isolate the problem. Please report them, but don't 42 - expect quick action. Bugs still exist. The problem remains in isolating 43 - which instruction contains the bug. Small programs illustrating a specific 44 - problem are a godsend. 45 - 46 - Legal Notices 47 - ------------- 48 - 49 - The NetWinder Floating Point Emulator is free software. Everything Rebel.com 50 - has written is provided under the GNU GPL. See the file COPYING for copying 51 - conditions. Excluded from the above is the SoftFloat code. John Hauser's 52 - legal notice for SoftFloat is included below. 53 - 54 - ------------------------------------------------------------------------------- 55 - SoftFloat Legal Notice 56 - 57 - SoftFloat was written by John R. Hauser. This work was made possible in 58 - part by the International Computer Science Institute, located at Suite 600, 59 - 1947 Center Street, Berkeley, California 94704. Funding was partially 60 - provided by the National Science Foundation under grant MIP-9311980. The 61 - original version of this code was written as part of a project to build 62 - a fixed-point vector processor in collaboration with the University of 63 - California at Berkeley, overseen by Profs. Nelson Morgan and John Wawrzynek. 64 - 65 - THIS SOFTWARE IS DISTRIBUTED AS IS, FOR FREE. Although reasonable effort 66 - has been made to avoid it, THIS SOFTWARE MAY CONTAIN FAULTS THAT WILL AT 67 - TIMES RESULT IN INCORRECT BEHAVIOR. USE OF THIS SOFTWARE IS RESTRICTED TO 68 - PERSONS AND ORGANIZATIONS WHO CAN AND WILL TAKE FULL RESPONSIBILITY FOR ANY 69 - AND ALL LOSSES, COSTS, OR OTHER PROBLEMS ARISING FROM ITS USE. 70 - -------------------------------------------------------------------------------
-156
Documentation/arm/nwfpe/README.FPE
··· 1 - The following describes the current state of the NetWinder's floating point 2 - emulator. 3 - 4 - In the following nomenclature is used to describe the floating point 5 - instructions. It follows the conventions in the ARM manual. 6 - 7 - <S|D|E> = <single|double|extended>, no default 8 - {P|M|Z} = {round to +infinity,round to -infinity,round to zero}, 9 - default = round to nearest 10 - 11 - Note: items enclosed in {} are optional. 12 - 13 - Floating Point Coprocessor Data Transfer Instructions (CPDT) 14 - ------------------------------------------------------------ 15 - 16 - LDF/STF - load and store floating 17 - 18 - <LDF|STF>{cond}<S|D|E> Fd, Rn 19 - <LDF|STF>{cond}<S|D|E> Fd, [Rn, #<expression>]{!} 20 - <LDF|STF>{cond}<S|D|E> Fd, [Rn], #<expression> 21 - 22 - These instructions are fully implemented. 23 - 24 - LFM/SFM - load and store multiple floating 25 - 26 - Form 1 syntax: 27 - <LFM|SFM>{cond}<S|D|E> Fd, <count>, [Rn] 28 - <LFM|SFM>{cond}<S|D|E> Fd, <count>, [Rn, #<expression>]{!} 29 - <LFM|SFM>{cond}<S|D|E> Fd, <count>, [Rn], #<expression> 30 - 31 - Form 2 syntax: 32 - <LFM|SFM>{cond}<FD,EA> Fd, <count>, [Rn]{!} 33 - 34 - These instructions are fully implemented. They store/load three words 35 - for each floating point register into the memory location given in the 36 - instruction. The format in memory is unlikely to be compatible with 37 - other implementations, in particular the actual hardware. Specific 38 - mention of this is made in the ARM manuals. 39 - 40 - Floating Point Coprocessor Register Transfer Instructions (CPRT) 41 - ---------------------------------------------------------------- 42 - 43 - Conversions, read/write status/control register instructions 44 - 45 - FLT{cond}<S,D,E>{P,M,Z} Fn, Rd Convert integer to floating point 46 - FIX{cond}{P,M,Z} Rd, Fn Convert floating point to integer 47 - WFS{cond} Rd Write floating point status register 48 - RFS{cond} Rd Read floating point status register 49 - WFC{cond} Rd Write floating point control register 50 - RFC{cond} Rd Read floating point control register 51 - 52 - FLT/FIX are fully implemented. 53 - 54 - RFS/WFS are fully implemented. 55 - 56 - RFC/WFC are fully implemented. RFC/WFC are supervisor only instructions, and 57 - presently check the CPU mode, and do an invalid instruction trap if not called 58 - from supervisor mode. 59 - 60 - Compare instructions 61 - 62 - CMF{cond} Fn, Fm Compare floating 63 - CMFE{cond} Fn, Fm Compare floating with exception 64 - CNF{cond} Fn, Fm Compare negated floating 65 - CNFE{cond} Fn, Fm Compare negated floating with exception 66 - 67 - These are fully implemented. 68 - 69 - Floating Point Coprocessor Data Instructions (CPDT) 70 - --------------------------------------------------- 71 - 72 - Dyadic operations: 73 - 74 - ADF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - add 75 - SUF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - subtract 76 - RSF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse subtract 77 - MUF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - multiply 78 - DVF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - divide 79 - RDV{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse divide 80 - 81 - These are fully implemented. 82 - 83 - FML{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - fast multiply 84 - FDV{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - fast divide 85 - FRD{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - fast reverse divide 86 - 87 - These are fully implemented as well. They use the same algorithm as the 88 - non-fast versions. Hence, in this implementation their performance is 89 - equivalent to the MUF/DVF/RDV instructions. This is acceptable according 90 - to the ARM manual. The manual notes these are defined only for single 91 - operands, on the actual FPA11 hardware they do not work for double or 92 - extended precision operands. The emulator currently does not check 93 - the requested permissions conditions, and performs the requested operation. 94 - 95 - RMF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - IEEE remainder 96 - 97 - This is fully implemented. 98 - 99 - Monadic operations: 100 - 101 - MVF{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - move 102 - MNF{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - move negated 103 - 104 - These are fully implemented. 105 - 106 - ABS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - absolute value 107 - SQT{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - square root 108 - RND{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - round 109 - 110 - These are fully implemented. 111 - 112 - URD{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - unnormalized round 113 - NRM{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - normalize 114 - 115 - These are implemented. URD is implemented using the same code as the RND 116 - instruction. Since URD cannot return a unnormalized number, NRM becomes 117 - a NOP. 118 - 119 - Library calls: 120 - 121 - POW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - power 122 - RPW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse power 123 - POL{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - polar angle (arctan2) 124 - 125 - LOG{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base 10 126 - LGN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base e 127 - EXP{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - exponent 128 - SIN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - sine 129 - COS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - cosine 130 - TAN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - tangent 131 - ASN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arcsine 132 - ACS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arccosine 133 - ATN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arctangent 134 - 135 - These are not implemented. They are not currently issued by the compiler, 136 - and are handled by routines in libc. These are not implemented by the FPA11 137 - hardware, but are handled by the floating point support code. They should 138 - be implemented in future versions. 139 - 140 - Signalling: 141 - 142 - Signals are implemented. However current ELF kernels produced by Rebel.com 143 - have a bug in them that prevents the module from generating a SIGFPE. This 144 - is caused by a failure to alias fp_current to the kernel variable 145 - current_set[0] correctly. 146 - 147 - The kernel provided with this distribution (vmlinux-nwfpe-0.93) contains 148 - a fix for this problem and also incorporates the current version of the 149 - emulator directly. It is possible to run with no floating point module 150 - loaded with this kernel. It is provided as a demonstration of the 151 - technology and for those who want to do floating point work that depends 152 - on signals. It is not strictly necessary to use the module. 153 - 154 - A module (either the one provided by Russell King, or the one in this 155 - distribution) can be loaded to replace the functionality of the emulator 156 - built into the kernel.
-67
Documentation/arm/nwfpe/TODO
··· 1 - TODO LIST 2 - --------- 3 - 4 - POW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - power 5 - RPW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse power 6 - POL{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - polar angle (arctan2) 7 - 8 - LOG{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base 10 9 - LGN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base e 10 - EXP{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - exponent 11 - SIN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - sine 12 - COS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - cosine 13 - TAN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - tangent 14 - ASN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arcsine 15 - ACS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arccosine 16 - ATN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arctangent 17 - 18 - These are not implemented. They are not currently issued by the compiler, 19 - and are handled by routines in libc. These are not implemented by the FPA11 20 - hardware, but are handled by the floating point support code. They should 21 - be implemented in future versions. 22 - 23 - There are a couple of ways to approach the implementation of these. One 24 - method would be to use accurate table methods for these routines. I have 25 - a couple of papers by S. Gal from IBM's research labs in Haifa, Israel that 26 - seem to promise extreme accuracy (in the order of 99.8%) and reasonable speed. 27 - These methods are used in GLIBC for some of the transcendental functions. 28 - 29 - Another approach, which I know little about is CORDIC. This stands for 30 - Coordinate Rotation Digital Computer, and is a method of computing 31 - transcendental functions using mostly shifts and adds and a few 32 - multiplications and divisions. The ARM excels at shifts and adds, 33 - so such a method could be promising, but requires more research to 34 - determine if it is feasible. 35 - 36 - Rounding Methods 37 - 38 - The IEEE standard defines 4 rounding modes. Round to nearest is the 39 - default, but rounding to + or - infinity or round to zero are also allowed. 40 - Many architectures allow the rounding mode to be specified by modifying bits 41 - in a control register. Not so with the ARM FPA11 architecture. To change 42 - the rounding mode one must specify it with each instruction. 43 - 44 - This has made porting some benchmarks difficult. It is possible to 45 - introduce such a capability into the emulator. The FPCR contains 46 - bits describing the rounding mode. The emulator could be altered to 47 - examine a flag, which if set forced it to ignore the rounding mode in 48 - the instruction, and use the mode specified in the bits in the FPCR. 49 - 50 - This would require a method of getting/setting the flag, and the bits 51 - in the FPCR. This requires a kernel call in ArmLinux, as WFC/RFC are 52 - supervisor only instructions. If anyone has any ideas or comments I 53 - would like to hear them. 54 - 55 - [NOTE: pulled out from some docs on ARM floating point, specifically 56 - for the Acorn FPE, but not limited to it: 57 - 58 - The floating point control register (FPCR) may only be present in some 59 - implementations: it is there to control the hardware in an implementation- 60 - specific manner, for example to disable the floating point system. The user 61 - mode of the ARM is not permitted to use this register (since the right is 62 - reserved to alter it between implementations) and the WFC and RFC 63 - instructions will trap if tried in user mode. 64 - 65 - Hence, the answer is yes, you could do this, but then you will run a high 66 - risk of becoming isolated if and when hardware FP emulation comes out 67 - -- Russell].
+11
Documentation/arm/nwfpe/index.rst
··· 1 + =================================== 2 + NetWinder's floating point emulator 3 + =================================== 4 + 5 + .. toctree:: 6 + :maxdepth: 1 7 + 8 + nwfpe 9 + netwinder-fpe 10 + notes 11 + todo
+162
Documentation/arm/nwfpe/netwinder-fpe.rst
··· 1 + ============= 2 + Current State 3 + ============= 4 + 5 + The following describes the current state of the NetWinder's floating point 6 + emulator. 7 + 8 + In the following nomenclature is used to describe the floating point 9 + instructions. It follows the conventions in the ARM manual. 10 + 11 + :: 12 + 13 + <S|D|E> = <single|double|extended>, no default 14 + {P|M|Z} = {round to +infinity,round to -infinity,round to zero}, 15 + default = round to nearest 16 + 17 + Note: items enclosed in {} are optional. 18 + 19 + Floating Point Coprocessor Data Transfer Instructions (CPDT) 20 + ------------------------------------------------------------ 21 + 22 + LDF/STF - load and store floating 23 + 24 + <LDF|STF>{cond}<S|D|E> Fd, Rn 25 + <LDF|STF>{cond}<S|D|E> Fd, [Rn, #<expression>]{!} 26 + <LDF|STF>{cond}<S|D|E> Fd, [Rn], #<expression> 27 + 28 + These instructions are fully implemented. 29 + 30 + LFM/SFM - load and store multiple floating 31 + 32 + Form 1 syntax: 33 + <LFM|SFM>{cond}<S|D|E> Fd, <count>, [Rn] 34 + <LFM|SFM>{cond}<S|D|E> Fd, <count>, [Rn, #<expression>]{!} 35 + <LFM|SFM>{cond}<S|D|E> Fd, <count>, [Rn], #<expression> 36 + 37 + Form 2 syntax: 38 + <LFM|SFM>{cond}<FD,EA> Fd, <count>, [Rn]{!} 39 + 40 + These instructions are fully implemented. They store/load three words 41 + for each floating point register into the memory location given in the 42 + instruction. The format in memory is unlikely to be compatible with 43 + other implementations, in particular the actual hardware. Specific 44 + mention of this is made in the ARM manuals. 45 + 46 + Floating Point Coprocessor Register Transfer Instructions (CPRT) 47 + ---------------------------------------------------------------- 48 + 49 + Conversions, read/write status/control register instructions 50 + 51 + FLT{cond}<S,D,E>{P,M,Z} Fn, Rd Convert integer to floating point 52 + FIX{cond}{P,M,Z} Rd, Fn Convert floating point to integer 53 + WFS{cond} Rd Write floating point status register 54 + RFS{cond} Rd Read floating point status register 55 + WFC{cond} Rd Write floating point control register 56 + RFC{cond} Rd Read floating point control register 57 + 58 + FLT/FIX are fully implemented. 59 + 60 + RFS/WFS are fully implemented. 61 + 62 + RFC/WFC are fully implemented. RFC/WFC are supervisor only instructions, and 63 + presently check the CPU mode, and do an invalid instruction trap if not called 64 + from supervisor mode. 65 + 66 + Compare instructions 67 + 68 + CMF{cond} Fn, Fm Compare floating 69 + CMFE{cond} Fn, Fm Compare floating with exception 70 + CNF{cond} Fn, Fm Compare negated floating 71 + CNFE{cond} Fn, Fm Compare negated floating with exception 72 + 73 + These are fully implemented. 74 + 75 + Floating Point Coprocessor Data Instructions (CPDT) 76 + --------------------------------------------------- 77 + 78 + Dyadic operations: 79 + 80 + ADF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - add 81 + SUF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - subtract 82 + RSF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse subtract 83 + MUF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - multiply 84 + DVF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - divide 85 + RDV{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse divide 86 + 87 + These are fully implemented. 88 + 89 + FML{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - fast multiply 90 + FDV{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - fast divide 91 + FRD{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - fast reverse divide 92 + 93 + These are fully implemented as well. They use the same algorithm as the 94 + non-fast versions. Hence, in this implementation their performance is 95 + equivalent to the MUF/DVF/RDV instructions. This is acceptable according 96 + to the ARM manual. The manual notes these are defined only for single 97 + operands, on the actual FPA11 hardware they do not work for double or 98 + extended precision operands. The emulator currently does not check 99 + the requested permissions conditions, and performs the requested operation. 100 + 101 + RMF{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - IEEE remainder 102 + 103 + This is fully implemented. 104 + 105 + Monadic operations: 106 + 107 + MVF{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - move 108 + MNF{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - move negated 109 + 110 + These are fully implemented. 111 + 112 + ABS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - absolute value 113 + SQT{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - square root 114 + RND{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - round 115 + 116 + These are fully implemented. 117 + 118 + URD{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - unnormalized round 119 + NRM{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - normalize 120 + 121 + These are implemented. URD is implemented using the same code as the RND 122 + instruction. Since URD cannot return a unnormalized number, NRM becomes 123 + a NOP. 124 + 125 + Library calls: 126 + 127 + POW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - power 128 + RPW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse power 129 + POL{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - polar angle (arctan2) 130 + 131 + LOG{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base 10 132 + LGN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base e 133 + EXP{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - exponent 134 + SIN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - sine 135 + COS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - cosine 136 + TAN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - tangent 137 + ASN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arcsine 138 + ACS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arccosine 139 + ATN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arctangent 140 + 141 + These are not implemented. They are not currently issued by the compiler, 142 + and are handled by routines in libc. These are not implemented by the FPA11 143 + hardware, but are handled by the floating point support code. They should 144 + be implemented in future versions. 145 + 146 + Signalling: 147 + 148 + Signals are implemented. However current ELF kernels produced by Rebel.com 149 + have a bug in them that prevents the module from generating a SIGFPE. This 150 + is caused by a failure to alias fp_current to the kernel variable 151 + current_set[0] correctly. 152 + 153 + The kernel provided with this distribution (vmlinux-nwfpe-0.93) contains 154 + a fix for this problem and also incorporates the current version of the 155 + emulator directly. It is possible to run with no floating point module 156 + loaded with this kernel. It is provided as a demonstration of the 157 + technology and for those who want to do floating point work that depends 158 + on signals. It is not strictly necessary to use the module. 159 + 160 + A module (either the one provided by Russell King, or the one in this 161 + distribution) can be loaded to replace the functionality of the emulator 162 + built into the kernel.
+32
Documentation/arm/nwfpe/notes.rst
··· 1 + Notes 2 + ===== 3 + 4 + There seems to be a problem with exp(double) and our emulator. I haven't 5 + been able to track it down yet. This does not occur with the emulator 6 + supplied by Russell King. 7 + 8 + I also found one oddity in the emulator. I don't think it is serious but 9 + will point it out. The ARM calling conventions require floating point 10 + registers f4-f7 to be preserved over a function call. The compiler quite 11 + often uses an stfe instruction to save f4 on the stack upon entry to a 12 + function, and an ldfe instruction to restore it before returning. 13 + 14 + I was looking at some code, that calculated a double result, stored it in f4 15 + then made a function call. Upon return from the function call the number in 16 + f4 had been converted to an extended value in the emulator. 17 + 18 + This is a side effect of the stfe instruction. The double in f4 had to be 19 + converted to extended, then stored. If an lfm/sfm combination had been used, 20 + then no conversion would occur. This has performance considerations. The 21 + result from the function call and f4 were used in a multiplication. If the 22 + emulator sees a multiply of a double and extended, it promotes the double to 23 + extended, then does the multiply in extended precision. 24 + 25 + This code will cause this problem: 26 + 27 + double x, y, z; 28 + z = log(x)/log(y); 29 + 30 + The result of log(x) (a double) will be calculated, returned in f0, then 31 + moved to f4 to preserve it over the log(y) call. The division will be done 32 + in extended precision, due to the stfe instruction used to save f4 in log(y).
+74
Documentation/arm/nwfpe/nwfpe.rst
··· 1 + Introduction 2 + ============ 3 + 4 + This directory contains the version 0.92 test release of the NetWinder 5 + Floating Point Emulator. 6 + 7 + The majority of the code was written by me, Scott Bambrough It is 8 + written in C, with a small number of routines in inline assembler 9 + where required. It was written quickly, with a goal of implementing a 10 + working version of all the floating point instructions the compiler 11 + emits as the first target. I have attempted to be as optimal as 12 + possible, but there remains much room for improvement. 13 + 14 + I have attempted to make the emulator as portable as possible. One of 15 + the problems is with leading underscores on kernel symbols. Elf 16 + kernels have no leading underscores, a.out compiled kernels do. I 17 + have attempted to use the C_SYMBOL_NAME macro wherever this may be 18 + important. 19 + 20 + Another choice I made was in the file structure. I have attempted to 21 + contain all operating system specific code in one module (fpmodule.*). 22 + All the other files contain emulator specific code. This should allow 23 + others to port the emulator to NetBSD for instance relatively easily. 24 + 25 + The floating point operations are based on SoftFloat Release 2, by 26 + John Hauser. SoftFloat is a software implementation of floating-point 27 + that conforms to the IEC/IEEE Standard for Binary Floating-point 28 + Arithmetic. As many as four formats are supported: single precision, 29 + double precision, extended double precision, and quadruple precision. 30 + All operations required by the standard are implemented, except for 31 + conversions to and from decimal. We use only the single precision, 32 + double precision and extended double precision formats. The port of 33 + SoftFloat to the ARM was done by Phil Blundell, based on an earlier 34 + port of SoftFloat version 1 by Neil Carson for NetBSD/arm32. 35 + 36 + The file README.FPE contains a description of what has been implemented 37 + so far in the emulator. The file TODO contains a information on what 38 + remains to be done, and other ideas for the emulator. 39 + 40 + Bug reports, comments, suggestions should be directed to me at 41 + <scottb@netwinder.org>. General reports of "this program doesn't 42 + work correctly when your emulator is installed" are useful for 43 + determining that bugs still exist; but are virtually useless when 44 + attempting to isolate the problem. Please report them, but don't 45 + expect quick action. Bugs still exist. The problem remains in isolating 46 + which instruction contains the bug. Small programs illustrating a specific 47 + problem are a godsend. 48 + 49 + Legal Notices 50 + ------------- 51 + 52 + The NetWinder Floating Point Emulator is free software. Everything Rebel.com 53 + has written is provided under the GNU GPL. See the file COPYING for copying 54 + conditions. Excluded from the above is the SoftFloat code. John Hauser's 55 + legal notice for SoftFloat is included below. 56 + 57 + ------------------------------------------------------------------------------- 58 + 59 + SoftFloat Legal Notice 60 + 61 + SoftFloat was written by John R. Hauser. This work was made possible in 62 + part by the International Computer Science Institute, located at Suite 600, 63 + 1947 Center Street, Berkeley, California 94704. Funding was partially 64 + provided by the National Science Foundation under grant MIP-9311980. The 65 + original version of this code was written as part of a project to build 66 + a fixed-point vector processor in collaboration with the University of 67 + California at Berkeley, overseen by Profs. Nelson Morgan and John Wawrzynek. 68 + 69 + THIS SOFTWARE IS DISTRIBUTED AS IS, FOR FREE. Although reasonable effort 70 + has been made to avoid it, THIS SOFTWARE MAY CONTAIN FAULTS THAT WILL AT 71 + TIMES RESULT IN INCORRECT BEHAVIOR. USE OF THIS SOFTWARE IS RESTRICTED TO 72 + PERSONS AND ORGANIZATIONS WHO CAN AND WILL TAKE FULL RESPONSIBILITY FOR ANY 73 + AND ALL LOSSES, COSTS, OR OTHER PROBLEMS ARISING FROM ITS USE. 74 + -------------------------------------------------------------------------------
+72
Documentation/arm/nwfpe/todo.rst
··· 1 + TODO LIST 2 + ========= 3 + 4 + :: 5 + 6 + POW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - power 7 + RPW{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - reverse power 8 + POL{cond}<S|D|E>{P,M,Z} Fd, Fn, <Fm,#value> - polar angle (arctan2) 9 + 10 + LOG{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base 10 11 + LGN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - logarithm to base e 12 + EXP{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - exponent 13 + SIN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - sine 14 + COS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - cosine 15 + TAN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - tangent 16 + ASN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arcsine 17 + ACS{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arccosine 18 + ATN{cond}<S|D|E>{P,M,Z} Fd, <Fm,#value> - arctangent 19 + 20 + These are not implemented. They are not currently issued by the compiler, 21 + and are handled by routines in libc. These are not implemented by the FPA11 22 + hardware, but are handled by the floating point support code. They should 23 + be implemented in future versions. 24 + 25 + There are a couple of ways to approach the implementation of these. One 26 + method would be to use accurate table methods for these routines. I have 27 + a couple of papers by S. Gal from IBM's research labs in Haifa, Israel that 28 + seem to promise extreme accuracy (in the order of 99.8%) and reasonable speed. 29 + These methods are used in GLIBC for some of the transcendental functions. 30 + 31 + Another approach, which I know little about is CORDIC. This stands for 32 + Coordinate Rotation Digital Computer, and is a method of computing 33 + transcendental functions using mostly shifts and adds and a few 34 + multiplications and divisions. The ARM excels at shifts and adds, 35 + so such a method could be promising, but requires more research to 36 + determine if it is feasible. 37 + 38 + Rounding Methods 39 + ---------------- 40 + 41 + The IEEE standard defines 4 rounding modes. Round to nearest is the 42 + default, but rounding to + or - infinity or round to zero are also allowed. 43 + Many architectures allow the rounding mode to be specified by modifying bits 44 + in a control register. Not so with the ARM FPA11 architecture. To change 45 + the rounding mode one must specify it with each instruction. 46 + 47 + This has made porting some benchmarks difficult. It is possible to 48 + introduce such a capability into the emulator. The FPCR contains 49 + bits describing the rounding mode. The emulator could be altered to 50 + examine a flag, which if set forced it to ignore the rounding mode in 51 + the instruction, and use the mode specified in the bits in the FPCR. 52 + 53 + This would require a method of getting/setting the flag, and the bits 54 + in the FPCR. This requires a kernel call in ArmLinux, as WFC/RFC are 55 + supervisor only instructions. If anyone has any ideas or comments I 56 + would like to hear them. 57 + 58 + NOTE: 59 + pulled out from some docs on ARM floating point, specifically 60 + for the Acorn FPE, but not limited to it: 61 + 62 + The floating point control register (FPCR) may only be present in some 63 + implementations: it is there to control the hardware in an implementation- 64 + specific manner, for example to disable the floating point system. The user 65 + mode of the ARM is not permitted to use this register (since the right is 66 + reserved to alter it between implementations) and the WFC and RFC 67 + instructions will trap if tried in user mode. 68 + 69 + Hence, the answer is yes, you could do this, but then you will run a high 70 + risk of becoming isolated if and when hardware FP emulation comes out 71 + 72 + -- Russell.
+372
Documentation/arm/omap/dss.rst
··· 1 + ========================= 2 + OMAP2/3 Display Subsystem 3 + ========================= 4 + 5 + This is an almost total rewrite of the OMAP FB driver in drivers/video/omap 6 + (let's call it DSS1). The main differences between DSS1 and DSS2 are DSI, 7 + TV-out and multiple display support, but there are lots of small improvements 8 + also. 9 + 10 + The DSS2 driver (omapdss module) is in arch/arm/plat-omap/dss/, and the FB, 11 + panel and controller drivers are in drivers/video/omap2/. DSS1 and DSS2 live 12 + currently side by side, you can choose which one to use. 13 + 14 + Features 15 + -------- 16 + 17 + Working and tested features include: 18 + 19 + - MIPI DPI (parallel) output 20 + - MIPI DSI output in command mode 21 + - MIPI DBI (RFBI) output 22 + - SDI output 23 + - TV output 24 + - All pieces can be compiled as a module or inside kernel 25 + - Use DISPC to update any of the outputs 26 + - Use CPU to update RFBI or DSI output 27 + - OMAP DISPC planes 28 + - RGB16, RGB24 packed, RGB24 unpacked 29 + - YUV2, UYVY 30 + - Scaling 31 + - Adjusting DSS FCK to find a good pixel clock 32 + - Use DSI DPLL to create DSS FCK 33 + 34 + Tested boards include: 35 + - OMAP3 SDP board 36 + - Beagle board 37 + - N810 38 + 39 + omapdss driver 40 + -------------- 41 + 42 + The DSS driver does not itself have any support for Linux framebuffer, V4L or 43 + such like the current ones, but it has an internal kernel API that upper level 44 + drivers can use. 45 + 46 + The DSS driver models OMAP's overlays, overlay managers and displays in a 47 + flexible way to enable non-common multi-display configuration. In addition to 48 + modelling the hardware overlays, omapdss supports virtual overlays and overlay 49 + managers. These can be used when updating a display with CPU or system DMA. 50 + 51 + omapdss driver support for audio 52 + -------------------------------- 53 + There exist several display technologies and standards that support audio as 54 + well. Hence, it is relevant to update the DSS device driver to provide an audio 55 + interface that may be used by an audio driver or any other driver interested in 56 + the functionality. 57 + 58 + The audio_enable function is intended to prepare the relevant 59 + IP for playback (e.g., enabling an audio FIFO, taking in/out of reset 60 + some IP, enabling companion chips, etc). It is intended to be called before 61 + audio_start. The audio_disable function performs the reverse operation and is 62 + intended to be called after audio_stop. 63 + 64 + While a given DSS device driver may support audio, it is possible that for 65 + certain configurations audio is not supported (e.g., an HDMI display using a 66 + VESA video timing). The audio_supported function is intended to query whether 67 + the current configuration of the display supports audio. 68 + 69 + The audio_config function is intended to configure all the relevant audio 70 + parameters of the display. In order to make the function independent of any 71 + specific DSS device driver, a struct omap_dss_audio is defined. Its purpose 72 + is to contain all the required parameters for audio configuration. At the 73 + moment, such structure contains pointers to IEC-60958 channel status word 74 + and CEA-861 audio infoframe structures. This should be enough to support 75 + HDMI and DisplayPort, as both are based on CEA-861 and IEC-60958. 76 + 77 + The audio_enable/disable, audio_config and audio_supported functions could be 78 + implemented as functions that may sleep. Hence, they should not be called 79 + while holding a spinlock or a readlock. 80 + 81 + The audio_start/audio_stop function is intended to effectively start/stop audio 82 + playback after the configuration has taken place. These functions are designed 83 + to be used in an atomic context. Hence, audio_start should return quickly and be 84 + called only after all the needed resources for audio playback (audio FIFOs, 85 + DMA channels, companion chips, etc) have been enabled to begin data transfers. 86 + audio_stop is designed to only stop the audio transfers. The resources used 87 + for playback are released using audio_disable. 88 + 89 + The enum omap_dss_audio_state may be used to help the implementations of 90 + the interface to keep track of the audio state. The initial state is _DISABLED; 91 + then, the state transitions to _CONFIGURED, and then, when it is ready to 92 + play audio, to _ENABLED. The state _PLAYING is used when the audio is being 93 + rendered. 94 + 95 + 96 + Panel and controller drivers 97 + ---------------------------- 98 + 99 + The drivers implement panel or controller specific functionality and are not 100 + usually visible to users except through omapfb driver. They register 101 + themselves to the DSS driver. 102 + 103 + omapfb driver 104 + ------------- 105 + 106 + The omapfb driver implements arbitrary number of standard linux framebuffers. 107 + These framebuffers can be routed flexibly to any overlays, thus allowing very 108 + dynamic display architecture. 109 + 110 + The driver exports some omapfb specific ioctls, which are compatible with the 111 + ioctls in the old driver. 112 + 113 + The rest of the non standard features are exported via sysfs. Whether the final 114 + implementation will use sysfs, or ioctls, is still open. 115 + 116 + V4L2 drivers 117 + ------------ 118 + 119 + V4L2 is being implemented in TI. 120 + 121 + From omapdss point of view the V4L2 drivers should be similar to framebuffer 122 + driver. 123 + 124 + Architecture 125 + -------------------- 126 + 127 + Some clarification what the different components do: 128 + 129 + - Framebuffer is a memory area inside OMAP's SRAM/SDRAM that contains the 130 + pixel data for the image. Framebuffer has width and height and color 131 + depth. 132 + - Overlay defines where the pixels are read from and where they go on the 133 + screen. The overlay may be smaller than framebuffer, thus displaying only 134 + part of the framebuffer. The position of the overlay may be changed if 135 + the overlay is smaller than the display. 136 + - Overlay manager combines the overlays in to one image and feeds them to 137 + display. 138 + - Display is the actual physical display device. 139 + 140 + A framebuffer can be connected to multiple overlays to show the same pixel data 141 + on all of the overlays. Note that in this case the overlay input sizes must be 142 + the same, but, in case of video overlays, the output size can be different. Any 143 + framebuffer can be connected to any overlay. 144 + 145 + An overlay can be connected to one overlay manager. Also DISPC overlays can be 146 + connected only to DISPC overlay managers, and virtual overlays can be only 147 + connected to virtual overlays. 148 + 149 + An overlay manager can be connected to one display. There are certain 150 + restrictions which kinds of displays an overlay manager can be connected: 151 + 152 + - DISPC TV overlay manager can be only connected to TV display. 153 + - Virtual overlay managers can only be connected to DBI or DSI displays. 154 + - DISPC LCD overlay manager can be connected to all displays, except TV 155 + display. 156 + 157 + Sysfs 158 + ----- 159 + The sysfs interface is mainly used for testing. I don't think sysfs 160 + interface is the best for this in the final version, but I don't quite know 161 + what would be the best interfaces for these things. 162 + 163 + The sysfs interface is divided to two parts: DSS and FB. 164 + 165 + /sys/class/graphics/fb? directory: 166 + mirror 0=off, 1=on 167 + rotate Rotation 0-3 for 0, 90, 180, 270 degrees 168 + rotate_type 0 = DMA rotation, 1 = VRFB rotation 169 + overlays List of overlay numbers to which framebuffer pixels go 170 + phys_addr Physical address of the framebuffer 171 + virt_addr Virtual address of the framebuffer 172 + size Size of the framebuffer 173 + 174 + /sys/devices/platform/omapdss/overlay? directory: 175 + enabled 0=off, 1=on 176 + input_size width,height (ie. the framebuffer size) 177 + manager Destination overlay manager name 178 + name 179 + output_size width,height 180 + position x,y 181 + screen_width width 182 + global_alpha global alpha 0-255 0=transparent 255=opaque 183 + 184 + /sys/devices/platform/omapdss/manager? directory: 185 + display Destination display 186 + name 187 + alpha_blending_enabled 0=off, 1=on 188 + trans_key_enabled 0=off, 1=on 189 + trans_key_type gfx-destination, video-source 190 + trans_key_value transparency color key (RGB24) 191 + default_color default background color (RGB24) 192 + 193 + /sys/devices/platform/omapdss/display? directory: 194 + 195 + =============== ============================================================= 196 + ctrl_name Controller name 197 + mirror 0=off, 1=on 198 + update_mode 0=off, 1=auto, 2=manual 199 + enabled 0=off, 1=on 200 + name 201 + rotate Rotation 0-3 for 0, 90, 180, 270 degrees 202 + timings Display timings (pixclock,xres/hfp/hbp/hsw,yres/vfp/vbp/vsw) 203 + When writing, two special timings are accepted for tv-out: 204 + "pal" and "ntsc" 205 + panel_name 206 + tear_elim Tearing elimination 0=off, 1=on 207 + output_type Output type (video encoder only): "composite" or "svideo" 208 + =============== ============================================================= 209 + 210 + There are also some debugfs files at <debugfs>/omapdss/ which show information 211 + about clocks and registers. 212 + 213 + Examples 214 + -------- 215 + 216 + The following definitions have been made for the examples below:: 217 + 218 + ovl0=/sys/devices/platform/omapdss/overlay0 219 + ovl1=/sys/devices/platform/omapdss/overlay1 220 + ovl2=/sys/devices/platform/omapdss/overlay2 221 + 222 + mgr0=/sys/devices/platform/omapdss/manager0 223 + mgr1=/sys/devices/platform/omapdss/manager1 224 + 225 + lcd=/sys/devices/platform/omapdss/display0 226 + dvi=/sys/devices/platform/omapdss/display1 227 + tv=/sys/devices/platform/omapdss/display2 228 + 229 + fb0=/sys/class/graphics/fb0 230 + fb1=/sys/class/graphics/fb1 231 + fb2=/sys/class/graphics/fb2 232 + 233 + Default setup on OMAP3 SDP 234 + -------------------------- 235 + 236 + Here's the default setup on OMAP3 SDP board. All planes go to LCD. DVI 237 + and TV-out are not in use. The columns from left to right are: 238 + framebuffers, overlays, overlay managers, displays. Framebuffers are 239 + handled by omapfb, and the rest by the DSS:: 240 + 241 + FB0 --- GFX -\ DVI 242 + FB1 --- VID1 --+- LCD ---- LCD 243 + FB2 --- VID2 -/ TV ----- TV 244 + 245 + Example: Switch from LCD to DVI 246 + ------------------------------- 247 + 248 + :: 249 + 250 + w=`cat $dvi/timings | cut -d "," -f 2 | cut -d "/" -f 1` 251 + h=`cat $dvi/timings | cut -d "," -f 3 | cut -d "/" -f 1` 252 + 253 + echo "0" > $lcd/enabled 254 + echo "" > $mgr0/display 255 + fbset -fb /dev/fb0 -xres $w -yres $h -vxres $w -vyres $h 256 + # at this point you have to switch the dvi/lcd dip-switch from the omap board 257 + echo "dvi" > $mgr0/display 258 + echo "1" > $dvi/enabled 259 + 260 + After this the configuration looks like::: 261 + 262 + FB0 --- GFX -\ -- DVI 263 + FB1 --- VID1 --+- LCD -/ LCD 264 + FB2 --- VID2 -/ TV ----- TV 265 + 266 + Example: Clone GFX overlay to LCD and TV 267 + ---------------------------------------- 268 + 269 + :: 270 + 271 + w=`cat $tv/timings | cut -d "," -f 2 | cut -d "/" -f 1` 272 + h=`cat $tv/timings | cut -d "," -f 3 | cut -d "/" -f 1` 273 + 274 + echo "0" > $ovl0/enabled 275 + echo "0" > $ovl1/enabled 276 + 277 + echo "" > $fb1/overlays 278 + echo "0,1" > $fb0/overlays 279 + 280 + echo "$w,$h" > $ovl1/output_size 281 + echo "tv" > $ovl1/manager 282 + 283 + echo "1" > $ovl0/enabled 284 + echo "1" > $ovl1/enabled 285 + 286 + echo "1" > $tv/enabled 287 + 288 + After this the configuration looks like (only relevant parts shown):: 289 + 290 + FB0 +-- GFX ---- LCD ---- LCD 291 + \- VID1 ---- TV ---- TV 292 + 293 + Misc notes 294 + ---------- 295 + 296 + OMAP FB allocates the framebuffer memory using the standard dma allocator. You 297 + can enable Contiguous Memory Allocator (CONFIG_CMA) to improve the dma 298 + allocator, and if CMA is enabled, you use "cma=" kernel parameter to increase 299 + the global memory area for CMA. 300 + 301 + Using DSI DPLL to generate pixel clock it is possible produce the pixel clock 302 + of 86.5MHz (max possible), and with that you get 1280x1024@57 output from DVI. 303 + 304 + Rotation and mirroring currently only supports RGB565 and RGB8888 modes. VRFB 305 + does not support mirroring. 306 + 307 + VRFB rotation requires much more memory than non-rotated framebuffer, so you 308 + probably need to increase your vram setting before using VRFB rotation. Also, 309 + many applications may not work with VRFB if they do not pay attention to all 310 + framebuffer parameters. 311 + 312 + Kernel boot arguments 313 + --------------------- 314 + 315 + omapfb.mode=<display>:<mode>[,...] 316 + - Default video mode for specified displays. For example, 317 + "dvi:800x400MR-24@60". See drivers/video/modedb.c. 318 + There are also two special modes: "pal" and "ntsc" that 319 + can be used to tv out. 320 + 321 + omapfb.vram=<fbnum>:<size>[@<physaddr>][,...] 322 + - VRAM allocated for a framebuffer. Normally omapfb allocates vram 323 + depending on the display size. With this you can manually allocate 324 + more or define the physical address of each framebuffer. For example, 325 + "1:4M" to allocate 4M for fb1. 326 + 327 + omapfb.debug=<y|n> 328 + - Enable debug printing. You have to have OMAPFB debug support enabled 329 + in kernel config. 330 + 331 + omapfb.test=<y|n> 332 + - Draw test pattern to framebuffer whenever framebuffer settings change. 333 + You need to have OMAPFB debug support enabled in kernel config. 334 + 335 + omapfb.vrfb=<y|n> 336 + - Use VRFB rotation for all framebuffers. 337 + 338 + omapfb.rotate=<angle> 339 + - Default rotation applied to all framebuffers. 340 + 0 - 0 degree rotation 341 + 1 - 90 degree rotation 342 + 2 - 180 degree rotation 343 + 3 - 270 degree rotation 344 + 345 + omapfb.mirror=<y|n> 346 + - Default mirror for all framebuffers. Only works with DMA rotation. 347 + 348 + omapdss.def_disp=<display> 349 + - Name of default display, to which all overlays will be connected. 350 + Common examples are "lcd" or "tv". 351 + 352 + omapdss.debug=<y|n> 353 + - Enable debug printing. You have to have DSS debug support enabled in 354 + kernel config. 355 + 356 + TODO 357 + ---- 358 + 359 + DSS locking 360 + 361 + Error checking 362 + 363 + - Lots of checks are missing or implemented just as BUG() 364 + 365 + System DMA update for DSI 366 + 367 + - Can be used for RGB16 and RGB24P modes. Probably not for RGB24U (how 368 + to skip the empty byte?) 369 + 370 + OMAP1 support 371 + 372 + - Not sure if needed
+10
Documentation/arm/omap/index.rst
··· 1 + ======= 2 + TI OMAP 3 + ======= 4 + 5 + .. toctree:: 6 + :maxdepth: 1 7 + 8 + omap 9 + omap_pm 10 + dss
+18
Documentation/arm/omap/omap.rst
··· 1 + ============ 2 + OMAP history 3 + ============ 4 + 5 + This file contains documentation for running mainline 6 + kernel on omaps. 7 + 8 + ====== ====================================================== 9 + KERNEL NEW DEPENDENCIES 10 + ====== ====================================================== 11 + v4.3+ Update is needed for custom .config files to make sure 12 + CONFIG_REGULATOR_PBIAS is enabled for MMC1 to work 13 + properly. 14 + 15 + v4.18+ Update is needed for custom .config files to make sure 16 + CONFIG_MMC_SDHCI_OMAP is enabled for all MMC instances 17 + to work in DRA7 and K2G based boards. 18 + ====== ======================================================
+165
Documentation/arm/omap/omap_pm.rst
··· 1 + ===================== 2 + The OMAP PM interface 3 + ===================== 4 + 5 + This document describes the temporary OMAP PM interface. Driver 6 + authors use these functions to communicate minimum latency or 7 + throughput constraints to the kernel power management code. 8 + Over time, the intention is to merge features from the OMAP PM 9 + interface into the Linux PM QoS code. 10 + 11 + Drivers need to express PM parameters which: 12 + 13 + - support the range of power management parameters present in the TI SRF; 14 + 15 + - separate the drivers from the underlying PM parameter 16 + implementation, whether it is the TI SRF or Linux PM QoS or Linux 17 + latency framework or something else; 18 + 19 + - specify PM parameters in terms of fundamental units, such as 20 + latency and throughput, rather than units which are specific to OMAP 21 + or to particular OMAP variants; 22 + 23 + - allow drivers which are shared with other architectures (e.g., 24 + DaVinci) to add these constraints in a way which won't affect non-OMAP 25 + systems, 26 + 27 + - can be implemented immediately with minimal disruption of other 28 + architectures. 29 + 30 + 31 + This document proposes the OMAP PM interface, including the following 32 + five power management functions for driver code: 33 + 34 + 1. Set the maximum MPU wakeup latency:: 35 + 36 + (*pdata->set_max_mpu_wakeup_lat)(struct device *dev, unsigned long t) 37 + 38 + 2. Set the maximum device wakeup latency:: 39 + 40 + (*pdata->set_max_dev_wakeup_lat)(struct device *dev, unsigned long t) 41 + 42 + 3. Set the maximum system DMA transfer start latency (CORE pwrdm):: 43 + 44 + (*pdata->set_max_sdma_lat)(struct device *dev, long t) 45 + 46 + 4. Set the minimum bus throughput needed by a device:: 47 + 48 + (*pdata->set_min_bus_tput)(struct device *dev, u8 agent_id, unsigned long r) 49 + 50 + 5. Return the number of times the device has lost context:: 51 + 52 + (*pdata->get_dev_context_loss_count)(struct device *dev) 53 + 54 + 55 + Further documentation for all OMAP PM interface functions can be 56 + found in arch/arm/plat-omap/include/mach/omap-pm.h. 57 + 58 + 59 + The OMAP PM layer is intended to be temporary 60 + --------------------------------------------- 61 + 62 + The intention is that eventually the Linux PM QoS layer should support 63 + the range of power management features present in OMAP3. As this 64 + happens, existing drivers using the OMAP PM interface can be modified 65 + to use the Linux PM QoS code; and the OMAP PM interface can disappear. 66 + 67 + 68 + Driver usage of the OMAP PM functions 69 + ------------------------------------- 70 + 71 + As the 'pdata' in the above examples indicates, these functions are 72 + exposed to drivers through function pointers in driver .platform_data 73 + structures. The function pointers are initialized by the `board-*.c` 74 + files to point to the corresponding OMAP PM functions: 75 + 76 + - set_max_dev_wakeup_lat will point to 77 + omap_pm_set_max_dev_wakeup_lat(), etc. Other architectures which do 78 + not support these functions should leave these function pointers set 79 + to NULL. Drivers should use the following idiom:: 80 + 81 + if (pdata->set_max_dev_wakeup_lat) 82 + (*pdata->set_max_dev_wakeup_lat)(dev, t); 83 + 84 + The most common usage of these functions will probably be to specify 85 + the maximum time from when an interrupt occurs, to when the device 86 + becomes accessible. To accomplish this, driver writers should use the 87 + set_max_mpu_wakeup_lat() function to constrain the MPU wakeup 88 + latency, and the set_max_dev_wakeup_lat() function to constrain the 89 + device wakeup latency (from clk_enable() to accessibility). For 90 + example:: 91 + 92 + /* Limit MPU wakeup latency */ 93 + if (pdata->set_max_mpu_wakeup_lat) 94 + (*pdata->set_max_mpu_wakeup_lat)(dev, tc); 95 + 96 + /* Limit device powerdomain wakeup latency */ 97 + if (pdata->set_max_dev_wakeup_lat) 98 + (*pdata->set_max_dev_wakeup_lat)(dev, td); 99 + 100 + /* total wakeup latency in this example: (tc + td) */ 101 + 102 + The PM parameters can be overwritten by calling the function again 103 + with the new value. The settings can be removed by calling the 104 + function with a t argument of -1 (except in the case of 105 + set_max_bus_tput(), which should be called with an r argument of 0). 106 + 107 + The fifth function above, omap_pm_get_dev_context_loss_count(), 108 + is intended as an optimization to allow drivers to determine whether the 109 + device has lost its internal context. If context has been lost, the 110 + driver must restore its internal context before proceeding. 111 + 112 + 113 + Other specialized interface functions 114 + ------------------------------------- 115 + 116 + The five functions listed above are intended to be usable by any 117 + device driver. DSPBridge and CPUFreq have a few special requirements. 118 + DSPBridge expresses target DSP performance levels in terms of OPP IDs. 119 + CPUFreq expresses target MPU performance levels in terms of MPU 120 + frequency. The OMAP PM interface contains functions for these 121 + specialized cases to convert that input information (OPPs/MPU 122 + frequency) into the form that the underlying power management 123 + implementation needs: 124 + 125 + 6. `(*pdata->dsp_get_opp_table)(void)` 126 + 127 + 7. `(*pdata->dsp_set_min_opp)(u8 opp_id)` 128 + 129 + 8. `(*pdata->dsp_get_opp)(void)` 130 + 131 + 9. `(*pdata->cpu_get_freq_table)(void)` 132 + 133 + 10. `(*pdata->cpu_set_freq)(unsigned long f)` 134 + 135 + 11. `(*pdata->cpu_get_freq)(void)` 136 + 137 + Customizing OPP for platform 138 + ============================ 139 + Defining CONFIG_PM should enable OPP layer for the silicon 140 + and the registration of OPP table should take place automatically. 141 + However, in special cases, the default OPP table may need to be 142 + tweaked, for e.g.: 143 + 144 + * enable default OPPs which are disabled by default, but which 145 + could be enabled on a platform 146 + * Disable an unsupported OPP on the platform 147 + * Define and add a custom opp table entry 148 + in these cases, the board file needs to do additional steps as follows: 149 + 150 + arch/arm/mach-omapx/board-xyz.c:: 151 + 152 + #include "pm.h" 153 + .... 154 + static void __init omap_xyz_init_irq(void) 155 + { 156 + .... 157 + /* Initialize the default table */ 158 + omapx_opp_init(); 159 + /* Do customization to the defaults */ 160 + .... 161 + } 162 + 163 + NOTE: 164 + omapx_opp_init will be omap3_opp_init or as required 165 + based on the omap family.
+137
Documentation/arm/porting.rst
··· 1 + ======= 2 + Porting 3 + ======= 4 + 5 + Taken from list archive at http://lists.arm.linux.org.uk/pipermail/linux-arm-kernel/2001-July/004064.html 6 + 7 + Initial definitions 8 + ------------------- 9 + 10 + The following symbol definitions rely on you knowing the translation that 11 + __virt_to_phys() does for your machine. This macro converts the passed 12 + virtual address to a physical address. Normally, it is simply: 13 + 14 + phys = virt - PAGE_OFFSET + PHYS_OFFSET 15 + 16 + 17 + Decompressor Symbols 18 + -------------------- 19 + 20 + ZTEXTADDR 21 + Start address of decompressor. There's no point in talking about 22 + virtual or physical addresses here, since the MMU will be off at 23 + the time when you call the decompressor code. You normally call 24 + the kernel at this address to start it booting. This doesn't have 25 + to be located in RAM, it can be in flash or other read-only or 26 + read-write addressable medium. 27 + 28 + ZBSSADDR 29 + Start address of zero-initialised work area for the decompressor. 30 + This must be pointing at RAM. The decompressor will zero initialise 31 + this for you. Again, the MMU will be off. 32 + 33 + ZRELADDR 34 + This is the address where the decompressed kernel will be written, 35 + and eventually executed. The following constraint must be valid: 36 + 37 + __virt_to_phys(TEXTADDR) == ZRELADDR 38 + 39 + The initial part of the kernel is carefully coded to be position 40 + independent. 41 + 42 + INITRD_PHYS 43 + Physical address to place the initial RAM disk. Only relevant if 44 + you are using the bootpImage stuff (which only works on the old 45 + struct param_struct). 46 + 47 + INITRD_VIRT 48 + Virtual address of the initial RAM disk. The following constraint 49 + must be valid: 50 + 51 + __virt_to_phys(INITRD_VIRT) == INITRD_PHYS 52 + 53 + PARAMS_PHYS 54 + Physical address of the struct param_struct or tag list, giving the 55 + kernel various parameters about its execution environment. 56 + 57 + 58 + Kernel Symbols 59 + -------------- 60 + 61 + PHYS_OFFSET 62 + Physical start address of the first bank of RAM. 63 + 64 + PAGE_OFFSET 65 + Virtual start address of the first bank of RAM. During the kernel 66 + boot phase, virtual address PAGE_OFFSET will be mapped to physical 67 + address PHYS_OFFSET, along with any other mappings you supply. 68 + This should be the same value as TASK_SIZE. 69 + 70 + TASK_SIZE 71 + The maximum size of a user process in bytes. Since user space 72 + always starts at zero, this is the maximum address that a user 73 + process can access+1. The user space stack grows down from this 74 + address. 75 + 76 + Any virtual address below TASK_SIZE is deemed to be user process 77 + area, and therefore managed dynamically on a process by process 78 + basis by the kernel. I'll call this the user segment. 79 + 80 + Anything above TASK_SIZE is common to all processes. I'll call 81 + this the kernel segment. 82 + 83 + (In other words, you can't put IO mappings below TASK_SIZE, and 84 + hence PAGE_OFFSET). 85 + 86 + TEXTADDR 87 + Virtual start address of kernel, normally PAGE_OFFSET + 0x8000. 88 + This is where the kernel image ends up. With the latest kernels, 89 + it must be located at 32768 bytes into a 128MB region. Previous 90 + kernels placed a restriction of 256MB here. 91 + 92 + DATAADDR 93 + Virtual address for the kernel data segment. Must not be defined 94 + when using the decompressor. 95 + 96 + VMALLOC_START / VMALLOC_END 97 + Virtual addresses bounding the vmalloc() area. There must not be 98 + any static mappings in this area; vmalloc will overwrite them. 99 + The addresses must also be in the kernel segment (see above). 100 + Normally, the vmalloc() area starts VMALLOC_OFFSET bytes above the 101 + last virtual RAM address (found using variable high_memory). 102 + 103 + VMALLOC_OFFSET 104 + Offset normally incorporated into VMALLOC_START to provide a hole 105 + between virtual RAM and the vmalloc area. We do this to allow 106 + out of bounds memory accesses (eg, something writing off the end 107 + of the mapped memory map) to be caught. Normally set to 8MB. 108 + 109 + Architecture Specific Macros 110 + ---------------------------- 111 + 112 + BOOT_MEM(pram,pio,vio) 113 + `pram` specifies the physical start address of RAM. Must always 114 + be present, and should be the same as PHYS_OFFSET. 115 + 116 + `pio` is the physical address of an 8MB region containing IO for 117 + use with the debugging macros in arch/arm/kernel/debug-armv.S. 118 + 119 + `vio` is the virtual address of the 8MB debugging region. 120 + 121 + It is expected that the debugging region will be re-initialised 122 + by the architecture specific code later in the code (via the 123 + MAPIO function). 124 + 125 + BOOT_PARAMS 126 + Same as, and see PARAMS_PHYS. 127 + 128 + FIXUP(func) 129 + Machine specific fixups, run before memory subsystems have been 130 + initialised. 131 + 132 + MAPIO(func) 133 + Machine specific function to map IO areas (including the debug 134 + region above). 135 + 136 + INITIRQ(func) 137 + Machine specific function to initialise interrupts.
+288
Documentation/arm/pxa/mfp.rst
··· 1 + ============================================== 2 + MFP Configuration for PXA2xx/PXA3xx Processors 3 + ============================================== 4 + 5 + Eric Miao <eric.miao@marvell.com> 6 + 7 + MFP stands for Multi-Function Pin, which is the pin-mux logic on PXA3xx and 8 + later PXA series processors. This document describes the existing MFP API, 9 + and how board/platform driver authors could make use of it. 10 + 11 + Basic Concept 12 + ============= 13 + 14 + Unlike the GPIO alternate function settings on PXA25x and PXA27x, a new MFP 15 + mechanism is introduced from PXA3xx to completely move the pin-mux functions 16 + out of the GPIO controller. In addition to pin-mux configurations, the MFP 17 + also controls the low power state, driving strength, pull-up/down and event 18 + detection of each pin. Below is a diagram of internal connections between 19 + the MFP logic and the remaining SoC peripherals:: 20 + 21 + +--------+ 22 + | |--(GPIO19)--+ 23 + | GPIO | | 24 + | |--(GPIO...) | 25 + +--------+ | 26 + | +---------+ 27 + +--------+ +------>| | 28 + | PWM2 |--(PWM_OUT)-------->| MFP | 29 + +--------+ +------>| |-------> to external PAD 30 + | +---->| | 31 + +--------+ | | +-->| | 32 + | SSP2 |---(TXD)----+ | | +---------+ 33 + +--------+ | | 34 + | | 35 + +--------+ | | 36 + | Keypad |--(MKOUT4)----+ | 37 + +--------+ | 38 + | 39 + +--------+ | 40 + | UART2 |---(TXD)--------+ 41 + +--------+ 42 + 43 + NOTE: the external pad is named as MFP_PIN_GPIO19, it doesn't necessarily 44 + mean it's dedicated for GPIO19, only as a hint that internally this pin 45 + can be routed from GPIO19 of the GPIO controller. 46 + 47 + To better understand the change from PXA25x/PXA27x GPIO alternate function 48 + to this new MFP mechanism, here are several key points: 49 + 50 + 1. GPIO controller on PXA3xx is now a dedicated controller, same as other 51 + internal controllers like PWM, SSP and UART, with 128 internal signals 52 + which can be routed to external through one or more MFPs (e.g. GPIO<0> 53 + can be routed through either MFP_PIN_GPIO0 as well as MFP_PIN_GPIO0_2, 54 + see arch/arm/mach-pxa/mfp-pxa300.h) 55 + 56 + 2. Alternate function configuration is removed from this GPIO controller, 57 + the remaining functions are pure GPIO-specific, i.e. 58 + 59 + - GPIO signal level control 60 + - GPIO direction control 61 + - GPIO level change detection 62 + 63 + 3. Low power state for each pin is now controlled by MFP, this means the 64 + PGSRx registers on PXA2xx are now useless on PXA3xx 65 + 66 + 4. Wakeup detection is now controlled by MFP, PWER does not control the 67 + wakeup from GPIO(s) any more, depending on the sleeping state, ADxER 68 + (as defined in pxa3xx-regs.h) controls the wakeup from MFP 69 + 70 + NOTE: with such a clear separation of MFP and GPIO, by GPIO<xx> we normally 71 + mean it is a GPIO signal, and by MFP<xxx> or pin xxx, we mean a physical 72 + pad (or ball). 73 + 74 + MFP API Usage 75 + ============= 76 + 77 + For board code writers, here are some guidelines: 78 + 79 + 1. include ONE of the following header files in your <board>.c: 80 + 81 + - #include "mfp-pxa25x.h" 82 + - #include "mfp-pxa27x.h" 83 + - #include "mfp-pxa300.h" 84 + - #include "mfp-pxa320.h" 85 + - #include "mfp-pxa930.h" 86 + 87 + NOTE: only one file in your <board>.c, depending on the processors used, 88 + because pin configuration definitions may conflict in these file (i.e. 89 + same name, different meaning and settings on different processors). E.g. 90 + for zylonite platform, which support both PXA300/PXA310 and PXA320, two 91 + separate files are introduced: zylonite_pxa300.c and zylonite_pxa320.c 92 + (in addition to handle MFP configuration differences, they also handle 93 + the other differences between the two combinations). 94 + 95 + NOTE: PXA300 and PXA310 are almost identical in pin configurations (with 96 + PXA310 supporting some additional ones), thus the difference is actually 97 + covered in a single mfp-pxa300.h. 98 + 99 + 2. prepare an array for the initial pin configurations, e.g.:: 100 + 101 + static unsigned long mainstone_pin_config[] __initdata = { 102 + /* Chip Select */ 103 + GPIO15_nCS_1, 104 + 105 + /* LCD - 16bpp Active TFT */ 106 + GPIOxx_TFT_LCD_16BPP, 107 + GPIO16_PWM0_OUT, /* Backlight */ 108 + 109 + /* MMC */ 110 + GPIO32_MMC_CLK, 111 + GPIO112_MMC_CMD, 112 + GPIO92_MMC_DAT_0, 113 + GPIO109_MMC_DAT_1, 114 + GPIO110_MMC_DAT_2, 115 + GPIO111_MMC_DAT_3, 116 + 117 + ... 118 + 119 + /* GPIO */ 120 + GPIO1_GPIO | WAKEUP_ON_EDGE_BOTH, 121 + }; 122 + 123 + a) once the pin configurations are passed to pxa{2xx,3xx}_mfp_config(), 124 + and written to the actual registers, they are useless and may discard, 125 + adding '__initdata' will help save some additional bytes here. 126 + 127 + b) when there is only one possible pin configurations for a component, 128 + some simplified definitions can be used, e.g. GPIOxx_TFT_LCD_16BPP on 129 + PXA25x and PXA27x processors 130 + 131 + c) if by board design, a pin can be configured to wake up the system 132 + from low power state, it can be 'OR'ed with any of: 133 + 134 + WAKEUP_ON_EDGE_BOTH 135 + WAKEUP_ON_EDGE_RISE 136 + WAKEUP_ON_EDGE_FALL 137 + WAKEUP_ON_LEVEL_HIGH - specifically for enabling of keypad GPIOs, 138 + 139 + to indicate that this pin has the capability of wake-up the system, 140 + and on which edge(s). This, however, doesn't necessarily mean the 141 + pin _will_ wakeup the system, it will only when set_irq_wake() is 142 + invoked with the corresponding GPIO IRQ (GPIO_IRQ(xx) or gpio_to_irq()) 143 + and eventually calls gpio_set_wake() for the actual register setting. 144 + 145 + d) although PXA3xx MFP supports edge detection on each pin, the 146 + internal logic will only wakeup the system when those specific bits 147 + in ADxER registers are set, which can be well mapped to the 148 + corresponding peripheral, thus set_irq_wake() can be called with 149 + the peripheral IRQ to enable the wakeup. 150 + 151 + 152 + MFP on PXA3xx 153 + ============= 154 + 155 + Every external I/O pad on PXA3xx (excluding those for special purpose) has 156 + one MFP logic associated, and is controlled by one MFP register (MFPR). 157 + 158 + The MFPR has the following bit definitions (for PXA300/PXA310/PXA320):: 159 + 160 + 31 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 161 + +-------------------------+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 162 + | RESERVED |PS|PU|PD| DRIVE |SS|SD|SO|EC|EF|ER|--| AF_SEL | 163 + +-------------------------+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 164 + 165 + Bit 3: RESERVED 166 + Bit 4: EDGE_RISE_EN - enable detection of rising edge on this pin 167 + Bit 5: EDGE_FALL_EN - enable detection of falling edge on this pin 168 + Bit 6: EDGE_CLEAR - disable edge detection on this pin 169 + Bit 7: SLEEP_OE_N - enable outputs during low power modes 170 + Bit 8: SLEEP_DATA - output data on the pin during low power modes 171 + Bit 9: SLEEP_SEL - selection control for low power modes signals 172 + Bit 13: PULLDOWN_EN - enable the internal pull-down resistor on this pin 173 + Bit 14: PULLUP_EN - enable the internal pull-up resistor on this pin 174 + Bit 15: PULL_SEL - pull state controlled by selected alternate function 175 + (0) or by PULL{UP,DOWN}_EN bits (1) 176 + 177 + Bit 0 - 2: AF_SEL - alternate function selection, 8 possibilities, from 0-7 178 + Bit 10-12: DRIVE - drive strength and slew rate 179 + 0b000 - fast 1mA 180 + 0b001 - fast 2mA 181 + 0b002 - fast 3mA 182 + 0b003 - fast 4mA 183 + 0b004 - slow 6mA 184 + 0b005 - fast 6mA 185 + 0b006 - slow 10mA 186 + 0b007 - fast 10mA 187 + 188 + MFP Design for PXA2xx/PXA3xx 189 + ============================ 190 + 191 + Due to the difference of pin-mux handling between PXA2xx and PXA3xx, a unified 192 + MFP API is introduced to cover both series of processors. 193 + 194 + The basic idea of this design is to introduce definitions for all possible pin 195 + configurations, these definitions are processor and platform independent, and 196 + the actual API invoked to convert these definitions into register settings and 197 + make them effective there-after. 198 + 199 + Files Involved 200 + -------------- 201 + 202 + - arch/arm/mach-pxa/include/mach/mfp.h 203 + 204 + for 205 + 1. Unified pin definitions - enum constants for all configurable pins 206 + 2. processor-neutral bit definitions for a possible MFP configuration 207 + 208 + - arch/arm/mach-pxa/mfp-pxa3xx.h 209 + 210 + for PXA3xx specific MFPR register bit definitions and PXA3xx common pin 211 + configurations 212 + 213 + - arch/arm/mach-pxa/mfp-pxa2xx.h 214 + 215 + for PXA2xx specific definitions and PXA25x/PXA27x common pin configurations 216 + 217 + - arch/arm/mach-pxa/mfp-pxa25x.h 218 + arch/arm/mach-pxa/mfp-pxa27x.h 219 + arch/arm/mach-pxa/mfp-pxa300.h 220 + arch/arm/mach-pxa/mfp-pxa320.h 221 + arch/arm/mach-pxa/mfp-pxa930.h 222 + 223 + for processor specific definitions 224 + 225 + - arch/arm/mach-pxa/mfp-pxa3xx.c 226 + - arch/arm/mach-pxa/mfp-pxa2xx.c 227 + 228 + for implementation of the pin configuration to take effect for the actual 229 + processor. 230 + 231 + Pin Configuration 232 + ----------------- 233 + 234 + The following comments are copied from mfp.h (see the actual source code 235 + for most updated info):: 236 + 237 + /* 238 + * a possible MFP configuration is represented by a 32-bit integer 239 + * 240 + * bit 0.. 9 - MFP Pin Number (1024 Pins Maximum) 241 + * bit 10..12 - Alternate Function Selection 242 + * bit 13..15 - Drive Strength 243 + * bit 16..18 - Low Power Mode State 244 + * bit 19..20 - Low Power Mode Edge Detection 245 + * bit 21..22 - Run Mode Pull State 246 + * 247 + * to facilitate the definition, the following macros are provided 248 + * 249 + * MFP_CFG_DEFAULT - default MFP configuration value, with 250 + * alternate function = 0, 251 + * drive strength = fast 3mA (MFP_DS03X) 252 + * low power mode = default 253 + * edge detection = none 254 + * 255 + * MFP_CFG - default MFPR value with alternate function 256 + * MFP_CFG_DRV - default MFPR value with alternate function and 257 + * pin drive strength 258 + * MFP_CFG_LPM - default MFPR value with alternate function and 259 + * low power mode 260 + * MFP_CFG_X - default MFPR value with alternate function, 261 + * pin drive strength and low power mode 262 + */ 263 + 264 + Examples of pin configurations are:: 265 + 266 + #define GPIO94_SSP3_RXD MFP_CFG_X(GPIO94, AF1, DS08X, FLOAT) 267 + 268 + which reads GPIO94 can be configured as SSP3_RXD, with alternate function 269 + selection of 1, driving strength of 0b101, and a float state in low power 270 + modes. 271 + 272 + NOTE: this is the default setting of this pin being configured as SSP3_RXD 273 + which can be modified a bit in board code, though it is not recommended to 274 + do so, simply because this default setting is usually carefully encoded, 275 + and is supposed to work in most cases. 276 + 277 + Register Settings 278 + ----------------- 279 + 280 + Register settings on PXA3xx for a pin configuration is actually very 281 + straight-forward, most bits can be converted directly into MFPR value 282 + in a easier way. Two sets of MFPR values are calculated: the run-time 283 + ones and the low power mode ones, to allow different settings. 284 + 285 + The conversion from a generic pin configuration to the actual register 286 + settings on PXA2xx is a bit complicated: many registers are involved, 287 + including GAFRx, GPDRx, PGSRx, PWER, PKWR, PFER and PRER. Please see 288 + mfp-pxa2xx.c for how the conversion is made.
-286
Documentation/arm/pxa/mfp.txt
··· 1 - MFP Configuration for PXA2xx/PXA3xx Processors 2 - 3 - Eric Miao <eric.miao@marvell.com> 4 - 5 - MFP stands for Multi-Function Pin, which is the pin-mux logic on PXA3xx and 6 - later PXA series processors. This document describes the existing MFP API, 7 - and how board/platform driver authors could make use of it. 8 - 9 - Basic Concept 10 - =============== 11 - 12 - Unlike the GPIO alternate function settings on PXA25x and PXA27x, a new MFP 13 - mechanism is introduced from PXA3xx to completely move the pin-mux functions 14 - out of the GPIO controller. In addition to pin-mux configurations, the MFP 15 - also controls the low power state, driving strength, pull-up/down and event 16 - detection of each pin. Below is a diagram of internal connections between 17 - the MFP logic and the remaining SoC peripherals: 18 - 19 - +--------+ 20 - | |--(GPIO19)--+ 21 - | GPIO | | 22 - | |--(GPIO...) | 23 - +--------+ | 24 - | +---------+ 25 - +--------+ +------>| | 26 - | PWM2 |--(PWM_OUT)-------->| MFP | 27 - +--------+ +------>| |-------> to external PAD 28 - | +---->| | 29 - +--------+ | | +-->| | 30 - | SSP2 |---(TXD)----+ | | +---------+ 31 - +--------+ | | 32 - | | 33 - +--------+ | | 34 - | Keypad |--(MKOUT4)----+ | 35 - +--------+ | 36 - | 37 - +--------+ | 38 - | UART2 |---(TXD)--------+ 39 - +--------+ 40 - 41 - NOTE: the external pad is named as MFP_PIN_GPIO19, it doesn't necessarily 42 - mean it's dedicated for GPIO19, only as a hint that internally this pin 43 - can be routed from GPIO19 of the GPIO controller. 44 - 45 - To better understand the change from PXA25x/PXA27x GPIO alternate function 46 - to this new MFP mechanism, here are several key points: 47 - 48 - 1. GPIO controller on PXA3xx is now a dedicated controller, same as other 49 - internal controllers like PWM, SSP and UART, with 128 internal signals 50 - which can be routed to external through one or more MFPs (e.g. GPIO<0> 51 - can be routed through either MFP_PIN_GPIO0 as well as MFP_PIN_GPIO0_2, 52 - see arch/arm/mach-pxa/mfp-pxa300.h) 53 - 54 - 2. Alternate function configuration is removed from this GPIO controller, 55 - the remaining functions are pure GPIO-specific, i.e. 56 - 57 - - GPIO signal level control 58 - - GPIO direction control 59 - - GPIO level change detection 60 - 61 - 3. Low power state for each pin is now controlled by MFP, this means the 62 - PGSRx registers on PXA2xx are now useless on PXA3xx 63 - 64 - 4. Wakeup detection is now controlled by MFP, PWER does not control the 65 - wakeup from GPIO(s) any more, depending on the sleeping state, ADxER 66 - (as defined in pxa3xx-regs.h) controls the wakeup from MFP 67 - 68 - NOTE: with such a clear separation of MFP and GPIO, by GPIO<xx> we normally 69 - mean it is a GPIO signal, and by MFP<xxx> or pin xxx, we mean a physical 70 - pad (or ball). 71 - 72 - MFP API Usage 73 - =============== 74 - 75 - For board code writers, here are some guidelines: 76 - 77 - 1. include ONE of the following header files in your <board>.c: 78 - 79 - - #include "mfp-pxa25x.h" 80 - - #include "mfp-pxa27x.h" 81 - - #include "mfp-pxa300.h" 82 - - #include "mfp-pxa320.h" 83 - - #include "mfp-pxa930.h" 84 - 85 - NOTE: only one file in your <board>.c, depending on the processors used, 86 - because pin configuration definitions may conflict in these file (i.e. 87 - same name, different meaning and settings on different processors). E.g. 88 - for zylonite platform, which support both PXA300/PXA310 and PXA320, two 89 - separate files are introduced: zylonite_pxa300.c and zylonite_pxa320.c 90 - (in addition to handle MFP configuration differences, they also handle 91 - the other differences between the two combinations). 92 - 93 - NOTE: PXA300 and PXA310 are almost identical in pin configurations (with 94 - PXA310 supporting some additional ones), thus the difference is actually 95 - covered in a single mfp-pxa300.h. 96 - 97 - 2. prepare an array for the initial pin configurations, e.g.: 98 - 99 - static unsigned long mainstone_pin_config[] __initdata = { 100 - /* Chip Select */ 101 - GPIO15_nCS_1, 102 - 103 - /* LCD - 16bpp Active TFT */ 104 - GPIOxx_TFT_LCD_16BPP, 105 - GPIO16_PWM0_OUT, /* Backlight */ 106 - 107 - /* MMC */ 108 - GPIO32_MMC_CLK, 109 - GPIO112_MMC_CMD, 110 - GPIO92_MMC_DAT_0, 111 - GPIO109_MMC_DAT_1, 112 - GPIO110_MMC_DAT_2, 113 - GPIO111_MMC_DAT_3, 114 - 115 - ... 116 - 117 - /* GPIO */ 118 - GPIO1_GPIO | WAKEUP_ON_EDGE_BOTH, 119 - }; 120 - 121 - a) once the pin configurations are passed to pxa{2xx,3xx}_mfp_config(), 122 - and written to the actual registers, they are useless and may discard, 123 - adding '__initdata' will help save some additional bytes here. 124 - 125 - b) when there is only one possible pin configurations for a component, 126 - some simplified definitions can be used, e.g. GPIOxx_TFT_LCD_16BPP on 127 - PXA25x and PXA27x processors 128 - 129 - c) if by board design, a pin can be configured to wake up the system 130 - from low power state, it can be 'OR'ed with any of: 131 - 132 - WAKEUP_ON_EDGE_BOTH 133 - WAKEUP_ON_EDGE_RISE 134 - WAKEUP_ON_EDGE_FALL 135 - WAKEUP_ON_LEVEL_HIGH - specifically for enabling of keypad GPIOs, 136 - 137 - to indicate that this pin has the capability of wake-up the system, 138 - and on which edge(s). This, however, doesn't necessarily mean the 139 - pin _will_ wakeup the system, it will only when set_irq_wake() is 140 - invoked with the corresponding GPIO IRQ (GPIO_IRQ(xx) or gpio_to_irq()) 141 - and eventually calls gpio_set_wake() for the actual register setting. 142 - 143 - d) although PXA3xx MFP supports edge detection on each pin, the 144 - internal logic will only wakeup the system when those specific bits 145 - in ADxER registers are set, which can be well mapped to the 146 - corresponding peripheral, thus set_irq_wake() can be called with 147 - the peripheral IRQ to enable the wakeup. 148 - 149 - 150 - MFP on PXA3xx 151 - =============== 152 - 153 - Every external I/O pad on PXA3xx (excluding those for special purpose) has 154 - one MFP logic associated, and is controlled by one MFP register (MFPR). 155 - 156 - The MFPR has the following bit definitions (for PXA300/PXA310/PXA320): 157 - 158 - 31 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 159 - +-------------------------+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 160 - | RESERVED |PS|PU|PD| DRIVE |SS|SD|SO|EC|EF|ER|--| AF_SEL | 161 - +-------------------------+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 162 - 163 - Bit 3: RESERVED 164 - Bit 4: EDGE_RISE_EN - enable detection of rising edge on this pin 165 - Bit 5: EDGE_FALL_EN - enable detection of falling edge on this pin 166 - Bit 6: EDGE_CLEAR - disable edge detection on this pin 167 - Bit 7: SLEEP_OE_N - enable outputs during low power modes 168 - Bit 8: SLEEP_DATA - output data on the pin during low power modes 169 - Bit 9: SLEEP_SEL - selection control for low power modes signals 170 - Bit 13: PULLDOWN_EN - enable the internal pull-down resistor on this pin 171 - Bit 14: PULLUP_EN - enable the internal pull-up resistor on this pin 172 - Bit 15: PULL_SEL - pull state controlled by selected alternate function 173 - (0) or by PULL{UP,DOWN}_EN bits (1) 174 - 175 - Bit 0 - 2: AF_SEL - alternate function selection, 8 possibilities, from 0-7 176 - Bit 10-12: DRIVE - drive strength and slew rate 177 - 0b000 - fast 1mA 178 - 0b001 - fast 2mA 179 - 0b002 - fast 3mA 180 - 0b003 - fast 4mA 181 - 0b004 - slow 6mA 182 - 0b005 - fast 6mA 183 - 0b006 - slow 10mA 184 - 0b007 - fast 10mA 185 - 186 - MFP Design for PXA2xx/PXA3xx 187 - ============================== 188 - 189 - Due to the difference of pin-mux handling between PXA2xx and PXA3xx, a unified 190 - MFP API is introduced to cover both series of processors. 191 - 192 - The basic idea of this design is to introduce definitions for all possible pin 193 - configurations, these definitions are processor and platform independent, and 194 - the actual API invoked to convert these definitions into register settings and 195 - make them effective there-after. 196 - 197 - Files Involved 198 - -------------- 199 - 200 - - arch/arm/mach-pxa/include/mach/mfp.h 201 - 202 - for 203 - 1. Unified pin definitions - enum constants for all configurable pins 204 - 2. processor-neutral bit definitions for a possible MFP configuration 205 - 206 - - arch/arm/mach-pxa/mfp-pxa3xx.h 207 - 208 - for PXA3xx specific MFPR register bit definitions and PXA3xx common pin 209 - configurations 210 - 211 - - arch/arm/mach-pxa/mfp-pxa2xx.h 212 - 213 - for PXA2xx specific definitions and PXA25x/PXA27x common pin configurations 214 - 215 - - arch/arm/mach-pxa/mfp-pxa25x.h 216 - arch/arm/mach-pxa/mfp-pxa27x.h 217 - arch/arm/mach-pxa/mfp-pxa300.h 218 - arch/arm/mach-pxa/mfp-pxa320.h 219 - arch/arm/mach-pxa/mfp-pxa930.h 220 - 221 - for processor specific definitions 222 - 223 - - arch/arm/mach-pxa/mfp-pxa3xx.c 224 - - arch/arm/mach-pxa/mfp-pxa2xx.c 225 - 226 - for implementation of the pin configuration to take effect for the actual 227 - processor. 228 - 229 - Pin Configuration 230 - ----------------- 231 - 232 - The following comments are copied from mfp.h (see the actual source code 233 - for most updated info) 234 - 235 - /* 236 - * a possible MFP configuration is represented by a 32-bit integer 237 - * 238 - * bit 0.. 9 - MFP Pin Number (1024 Pins Maximum) 239 - * bit 10..12 - Alternate Function Selection 240 - * bit 13..15 - Drive Strength 241 - * bit 16..18 - Low Power Mode State 242 - * bit 19..20 - Low Power Mode Edge Detection 243 - * bit 21..22 - Run Mode Pull State 244 - * 245 - * to facilitate the definition, the following macros are provided 246 - * 247 - * MFP_CFG_DEFAULT - default MFP configuration value, with 248 - * alternate function = 0, 249 - * drive strength = fast 3mA (MFP_DS03X) 250 - * low power mode = default 251 - * edge detection = none 252 - * 253 - * MFP_CFG - default MFPR value with alternate function 254 - * MFP_CFG_DRV - default MFPR value with alternate function and 255 - * pin drive strength 256 - * MFP_CFG_LPM - default MFPR value with alternate function and 257 - * low power mode 258 - * MFP_CFG_X - default MFPR value with alternate function, 259 - * pin drive strength and low power mode 260 - */ 261 - 262 - Examples of pin configurations are: 263 - 264 - #define GPIO94_SSP3_RXD MFP_CFG_X(GPIO94, AF1, DS08X, FLOAT) 265 - 266 - which reads GPIO94 can be configured as SSP3_RXD, with alternate function 267 - selection of 1, driving strength of 0b101, and a float state in low power 268 - modes. 269 - 270 - NOTE: this is the default setting of this pin being configured as SSP3_RXD 271 - which can be modified a bit in board code, though it is not recommended to 272 - do so, simply because this default setting is usually carefully encoded, 273 - and is supposed to work in most cases. 274 - 275 - Register Settings 276 - ----------------- 277 - 278 - Register settings on PXA3xx for a pin configuration is actually very 279 - straight-forward, most bits can be converted directly into MFPR value 280 - in a easier way. Two sets of MFPR values are calculated: the run-time 281 - ones and the low power mode ones, to allow different settings. 282 - 283 - The conversion from a generic pin configuration to the actual register 284 - settings on PXA2xx is a bit complicated: many registers are involved, 285 - including GAFRx, GPDRx, PGSRx, PWER, PKWR, PFER and PRER. Please see 286 - mfp-pxa2xx.c for how the conversion is made.
+51
Documentation/arm/sa1100/adsbitsy.rst
··· 1 + =============================== 2 + ADS Bitsy Single Board Computer 3 + =============================== 4 + 5 + (It is different from Bitsy(iPAQ) of Compaq) 6 + 7 + For more details, contact Applied Data Systems or see 8 + http://www.applieddata.net/products.html 9 + 10 + The Linux support for this product has been provided by 11 + Woojung Huh <whuh@applieddata.net> 12 + 13 + Use 'make adsbitsy_config' before any 'make config'. 14 + This will set up defaults for ADS Bitsy support. 15 + 16 + The kernel zImage is linked to be loaded and executed at 0xc0400000. 17 + 18 + Linux can be used with the ADS BootLoader that ships with the 19 + newer rev boards. See their documentation on how to load Linux. 20 + 21 + Supported peripherals 22 + ===================== 23 + 24 + - SA1100 LCD frame buffer (8/16bpp...sort of) 25 + - SA1111 USB Master 26 + - SA1100 serial port 27 + - pcmcia, compact flash 28 + - touchscreen(ucb1200) 29 + - console on LCD screen 30 + - serial ports (ttyS[0-2]) 31 + - ttyS0 is default for serial console 32 + 33 + To do 34 + ===== 35 + 36 + - everything else! :-) 37 + 38 + Notes 39 + ===== 40 + 41 + - The flash on board is divided into 3 partitions. 42 + You should be careful to use flash on board. 43 + Its partition is different from GraphicsClient Plus and GraphicsMaster 44 + 45 + - 16bpp mode requires a different cable than what ships with the board. 46 + Contact ADS or look through the manual to wire your own. Currently, 47 + if you compile with 16bit mode support and switch into a lower bpp 48 + mode, the timing is off so the image is corrupted. This will be 49 + fixed soon. 50 + 51 + Any contribution can be sent to nico@fluxnic.net and will be greatly welcome!
+301
Documentation/arm/sa1100/assabet.rst
··· 1 + ============================================ 2 + The Intel Assabet (SA-1110 evaluation) board 3 + ============================================ 4 + 5 + Please see: 6 + http://developer.intel.com 7 + 8 + Also some notes from John G Dorsey <jd5q@andrew.cmu.edu>: 9 + http://www.cs.cmu.edu/~wearable/software/assabet.html 10 + 11 + 12 + Building the kernel 13 + ------------------- 14 + 15 + To build the kernel with current defaults:: 16 + 17 + make assabet_config 18 + make oldconfig 19 + make zImage 20 + 21 + The resulting kernel image should be available in linux/arch/arm/boot/zImage. 22 + 23 + 24 + Installing a bootloader 25 + ----------------------- 26 + 27 + A couple of bootloaders able to boot Linux on Assabet are available: 28 + 29 + BLOB (http://www.lartmaker.nl/lartware/blob/) 30 + 31 + BLOB is a bootloader used within the LART project. Some contributed 32 + patches were merged into BLOB to add support for Assabet. 33 + 34 + Compaq's Bootldr + John Dorsey's patch for Assabet support 35 + (http://www.handhelds.org/Compaq/bootldr.html) 36 + (http://www.wearablegroup.org/software/bootldr/) 37 + 38 + Bootldr is the bootloader developed by Compaq for the iPAQ Pocket PC. 39 + John Dorsey has produced add-on patches to add support for Assabet and 40 + the JFFS filesystem. 41 + 42 + RedBoot (http://sources.redhat.com/redboot/) 43 + 44 + RedBoot is a bootloader developed by Red Hat based on the eCos RTOS 45 + hardware abstraction layer. It supports Assabet amongst many other 46 + hardware platforms. 47 + 48 + RedBoot is currently the recommended choice since it's the only one to have 49 + networking support, and is the most actively maintained. 50 + 51 + Brief examples on how to boot Linux with RedBoot are shown below. But first 52 + you need to have RedBoot installed in your flash memory. A known to work 53 + precompiled RedBoot binary is available from the following location: 54 + 55 + - ftp://ftp.netwinder.org/users/n/nico/ 56 + - ftp://ftp.arm.linux.org.uk/pub/linux/arm/people/nico/ 57 + - ftp://ftp.handhelds.org/pub/linux/arm/sa-1100-patches/ 58 + 59 + Look for redboot-assabet*.tgz. Some installation infos are provided in 60 + redboot-assabet*.txt. 61 + 62 + 63 + Initial RedBoot configuration 64 + ----------------------------- 65 + 66 + The commands used here are explained in The RedBoot User's Guide available 67 + on-line at http://sources.redhat.com/ecos/docs.html. 68 + Please refer to it for explanations. 69 + 70 + If you have a CF network card (my Assabet kit contained a CF+ LP-E from 71 + Socket Communications Inc.), you should strongly consider using it for TFTP 72 + file transfers. You must insert it before RedBoot runs since it can't detect 73 + it dynamically. 74 + 75 + To initialize the flash directory:: 76 + 77 + fis init -f 78 + 79 + To initialize the non-volatile settings, like whether you want to use BOOTP or 80 + a static IP address, etc, use this command:: 81 + 82 + fconfig -i 83 + 84 + 85 + Writing a kernel image into flash 86 + --------------------------------- 87 + 88 + First, the kernel image must be loaded into RAM. If you have the zImage file 89 + available on a TFTP server:: 90 + 91 + load zImage -r -b 0x100000 92 + 93 + If you rather want to use Y-Modem upload over the serial port:: 94 + 95 + load -m ymodem -r -b 0x100000 96 + 97 + To write it to flash:: 98 + 99 + fis create "Linux kernel" -b 0x100000 -l 0xc0000 100 + 101 + 102 + Booting the kernel 103 + ------------------ 104 + 105 + The kernel still requires a filesystem to boot. A ramdisk image can be loaded 106 + as follows:: 107 + 108 + load ramdisk_image.gz -r -b 0x800000 109 + 110 + Again, Y-Modem upload can be used instead of TFTP by replacing the file name 111 + by '-y ymodem'. 112 + 113 + Now the kernel can be retrieved from flash like this:: 114 + 115 + fis load "Linux kernel" 116 + 117 + or loaded as described previously. To boot the kernel:: 118 + 119 + exec -b 0x100000 -l 0xc0000 120 + 121 + The ramdisk image could be stored into flash as well, but there are better 122 + solutions for on-flash filesystems as mentioned below. 123 + 124 + 125 + Using JFFS2 126 + ----------- 127 + 128 + Using JFFS2 (the Second Journalling Flash File System) is probably the most 129 + convenient way to store a writable filesystem into flash. JFFS2 is used in 130 + conjunction with the MTD layer which is responsible for low-level flash 131 + management. More information on the Linux MTD can be found on-line at: 132 + http://www.linux-mtd.infradead.org/. A JFFS howto with some infos about 133 + creating JFFS/JFFS2 images is available from the same site. 134 + 135 + For instance, a sample JFFS2 image can be retrieved from the same FTP sites 136 + mentioned below for the precompiled RedBoot image. 137 + 138 + To load this file:: 139 + 140 + load sample_img.jffs2 -r -b 0x100000 141 + 142 + The result should look like:: 143 + 144 + RedBoot> load sample_img.jffs2 -r -b 0x100000 145 + Raw file loaded 0x00100000-0x00377424 146 + 147 + Now we must know the size of the unallocated flash:: 148 + 149 + fis free 150 + 151 + Result:: 152 + 153 + RedBoot> fis free 154 + 0x500E0000 .. 0x503C0000 155 + 156 + The values above may be different depending on the size of the filesystem and 157 + the type of flash. See their usage below as an example and take care of 158 + substituting yours appropriately. 159 + 160 + We must determine some values:: 161 + 162 + size of unallocated flash: 0x503c0000 - 0x500e0000 = 0x2e0000 163 + size of the filesystem image: 0x00377424 - 0x00100000 = 0x277424 164 + 165 + We want to fit the filesystem image of course, but we also want to give it all 166 + the remaining flash space as well. To write it:: 167 + 168 + fis unlock -f 0x500E0000 -l 0x2e0000 169 + fis erase -f 0x500E0000 -l 0x2e0000 170 + fis write -b 0x100000 -l 0x277424 -f 0x500E0000 171 + fis create "JFFS2" -n -f 0x500E0000 -l 0x2e0000 172 + 173 + Now the filesystem is associated to a MTD "partition" once Linux has discovered 174 + what they are in the boot process. From Redboot, the 'fis list' command 175 + displays them:: 176 + 177 + RedBoot> fis list 178 + Name FLASH addr Mem addr Length Entry point 179 + RedBoot 0x50000000 0x50000000 0x00020000 0x00000000 180 + RedBoot config 0x503C0000 0x503C0000 0x00020000 0x00000000 181 + FIS directory 0x503E0000 0x503E0000 0x00020000 0x00000000 182 + Linux kernel 0x50020000 0x00100000 0x000C0000 0x00000000 183 + JFFS2 0x500E0000 0x500E0000 0x002E0000 0x00000000 184 + 185 + However Linux should display something like:: 186 + 187 + SA1100 flash: probing 32-bit flash bus 188 + SA1100 flash: Found 2 x16 devices at 0x0 in 32-bit mode 189 + Using RedBoot partition definition 190 + Creating 5 MTD partitions on "SA1100 flash": 191 + 0x00000000-0x00020000 : "RedBoot" 192 + 0x00020000-0x000e0000 : "Linux kernel" 193 + 0x000e0000-0x003c0000 : "JFFS2" 194 + 0x003c0000-0x003e0000 : "RedBoot config" 195 + 0x003e0000-0x00400000 : "FIS directory" 196 + 197 + What's important here is the position of the partition we are interested in, 198 + which is the third one. Within Linux, this correspond to /dev/mtdblock2. 199 + Therefore to boot Linux with the kernel and its root filesystem in flash, we 200 + need this RedBoot command:: 201 + 202 + fis load "Linux kernel" 203 + exec -b 0x100000 -l 0xc0000 -c "root=/dev/mtdblock2" 204 + 205 + Of course other filesystems than JFFS might be used, like cramfs for example. 206 + You might want to boot with a root filesystem over NFS, etc. It is also 207 + possible, and sometimes more convenient, to flash a filesystem directly from 208 + within Linux while booted from a ramdisk or NFS. The Linux MTD repository has 209 + many tools to deal with flash memory as well, to erase it for example. JFFS2 210 + can then be mounted directly on a freshly erased partition and files can be 211 + copied over directly. Etc... 212 + 213 + 214 + RedBoot scripting 215 + ----------------- 216 + 217 + All the commands above aren't so useful if they have to be typed in every 218 + time the Assabet is rebooted. Therefore it's possible to automate the boot 219 + process using RedBoot's scripting capability. 220 + 221 + For example, I use this to boot Linux with both the kernel and the ramdisk 222 + images retrieved from a TFTP server on the network:: 223 + 224 + RedBoot> fconfig 225 + Run script at boot: false true 226 + Boot script: 227 + Enter script, terminate with empty line 228 + >> load zImage -r -b 0x100000 229 + >> load ramdisk_ks.gz -r -b 0x800000 230 + >> exec -b 0x100000 -l 0xc0000 231 + >> 232 + Boot script timeout (1000ms resolution): 3 233 + Use BOOTP for network configuration: true 234 + GDB connection port: 9000 235 + Network debug at boot time: false 236 + Update RedBoot non-volatile configuration - are you sure (y/n)? y 237 + 238 + Then, rebooting the Assabet is just a matter of waiting for the login prompt. 239 + 240 + 241 + 242 + Nicolas Pitre 243 + nico@fluxnic.net 244 + 245 + June 12, 2001 246 + 247 + 248 + Status of peripherals in -rmk tree (updated 14/10/2001) 249 + ------------------------------------------------------- 250 + 251 + Assabet: 252 + Serial ports: 253 + Radio: TX, RX, CTS, DSR, DCD, RI 254 + - PM: Not tested. 255 + - COM: TX, RX, CTS, DSR, DCD, RTS, DTR, PM 256 + - PM: Not tested. 257 + - I2C: Implemented, not fully tested. 258 + - L3: Fully tested, pass. 259 + - PM: Not tested. 260 + 261 + Video: 262 + - LCD: Fully tested. PM 263 + 264 + (LCD doesn't like being blanked with neponset connected) 265 + 266 + - Video out: Not fully 267 + 268 + Audio: 269 + UDA1341: 270 + - Playback: Fully tested, pass. 271 + - Record: Implemented, not tested. 272 + - PM: Not tested. 273 + 274 + UCB1200: 275 + - Audio play: Implemented, not heavily tested. 276 + - Audio rec: Implemented, not heavily tested. 277 + - Telco audio play: Implemented, not heavily tested. 278 + - Telco audio rec: Implemented, not heavily tested. 279 + - POTS control: No 280 + - Touchscreen: Yes 281 + - PM: Not tested. 282 + 283 + Other: 284 + - PCMCIA: 285 + - LPE: Fully tested, pass. 286 + - USB: No 287 + - IRDA: 288 + - SIR: Fully tested, pass. 289 + - FIR: Fully tested, pass. 290 + - PM: Not tested. 291 + 292 + Neponset: 293 + Serial ports: 294 + - COM1,2: TX, RX, CTS, DSR, DCD, RTS, DTR 295 + - PM: Not tested. 296 + - USB: Implemented, not heavily tested. 297 + - PCMCIA: Implemented, not heavily tested. 298 + - CF: Implemented, not heavily tested. 299 + - PM: Not tested. 300 + 301 + More stuff can be found in the -np (Nicolas Pitre's) tree.
+69
Documentation/arm/sa1100/brutus.rst
··· 1 + ====== 2 + Brutus 3 + ====== 4 + 5 + Brutus is an evaluation platform for the SA1100 manufactured by Intel. 6 + For more details, see: 7 + 8 + http://developer.intel.com 9 + 10 + To compile for Brutus, you must issue the following commands:: 11 + 12 + make brutus_config 13 + make config 14 + [accept all the defaults] 15 + make zImage 16 + 17 + The resulting kernel will end up in linux/arch/arm/boot/zImage. This file 18 + must be loaded at 0xc0008000 in Brutus's memory and execution started at 19 + 0xc0008000 as well with the value of registers r0 = 0 and r1 = 16 upon 20 + entry. 21 + 22 + But prior to execute the kernel, a ramdisk image must also be loaded in 23 + memory. Use memory address 0xd8000000 for this. Note that the file 24 + containing the (compressed) ramdisk image must not exceed 4 MB. 25 + 26 + Typically, you'll need angelboot to load the kernel. 27 + The following angelboot.opt file should be used:: 28 + 29 + base 0xc0008000 30 + entry 0xc0008000 31 + r0 0x00000000 32 + r1 0x00000010 33 + device /dev/ttyS0 34 + options "9600 8N1" 35 + baud 115200 36 + otherfile ramdisk_img.gz 37 + otherbase 0xd8000000 38 + 39 + Then load the kernel and ramdisk with:: 40 + 41 + angelboot -f angelboot.opt zImage 42 + 43 + The first Brutus serial port (assumed to be linked to /dev/ttyS0 on your 44 + host PC) is used by angel to load the kernel and ramdisk image. The serial 45 + console is provided through the second Brutus serial port. To access it, 46 + you may use minicom configured with /dev/ttyS1, 9600 baud, 8N1, no flow 47 + control. 48 + 49 + Currently supported 50 + =================== 51 + 52 + - RS232 serial ports 53 + - audio output 54 + - LCD screen 55 + - keyboard 56 + 57 + The actual Brutus support may not be complete without extra patches. 58 + If such patches exist, they should be found from 59 + ftp.netwinder.org/users/n/nico. 60 + 61 + A full PCMCIA support is still missing, although it's possible to hack 62 + some drivers in order to drive already inserted cards at boot time with 63 + little modifications. 64 + 65 + Any contribution is welcome. 66 + 67 + Please send patches to nico@fluxnic.net 68 + 69 + Have Fun !
+35
Documentation/arm/sa1100/cerf.rst
··· 1 + ============== 2 + CerfBoard/Cube 3 + ============== 4 + 5 + *** The StrongARM version of the CerfBoard/Cube has been discontinued *** 6 + 7 + The Intrinsyc CerfBoard is a StrongARM 1110-based computer on a board 8 + that measures approximately 2" square. It includes an Ethernet 9 + controller, an RS232-compatible serial port, a USB function port, and 10 + one CompactFlash+ slot on the back. Pictures can be found at the 11 + Intrinsyc website, http://www.intrinsyc.com. 12 + 13 + This document describes the support in the Linux kernel for the 14 + Intrinsyc CerfBoard. 15 + 16 + Supported in this version 17 + ========================= 18 + 19 + - CompactFlash+ slot (select PCMCIA in General Setup and any options 20 + that may be required) 21 + - Onboard Crystal CS8900 Ethernet controller (Cerf CS8900A support in 22 + Network Devices) 23 + - Serial ports with a serial console (hardcoded to 38400 8N1) 24 + 25 + In order to get this kernel onto your Cerf, you need a server that runs 26 + both BOOTP and TFTP. Detailed instructions should have come with your 27 + evaluation kit on how to use the bootloader. This series of commands 28 + will suffice:: 29 + 30 + make ARCH=arm CROSS_COMPILE=arm-linux- cerfcube_defconfig 31 + make ARCH=arm CROSS_COMPILE=arm-linux- zImage 32 + make ARCH=arm CROSS_COMPILE=arm-linux- modules 33 + cp arch/arm/boot/zImage <TFTP directory> 34 + 35 + support@intrinsyc.com
+25
Documentation/arm/sa1100/freebird.rst
··· 1 + ======== 2 + Freebird 3 + ======== 4 + 5 + Freebird-1.1 is produced by Legend(C), Inc. 6 + `http://web.archive.org/web/*/http://www.legend.com.cn` 7 + and software/linux maintained by Coventive(C), Inc. 8 + (http://www.coventive.com) 9 + 10 + Based on the Nicolas's strongarm kernel tree. 11 + 12 + Maintainer: 13 + 14 + Chester Kuo 15 + - <chester@coventive.com> 16 + - <chester@linux.org.tw> 17 + 18 + Author: 19 + 20 + - Tim wu <timwu@coventive.com> 21 + - CIH <cih@coventive.com> 22 + - Eric Peng <ericpeng@coventive.com> 23 + - Jeff Lee <jeff_lee@coventive.com> 24 + - Allen Cheng 25 + - Tony Liu <tonyliu@coventive.com>
+102
Documentation/arm/sa1100/graphicsclient.rst
··· 1 + ============================================= 2 + ADS GraphicsClient Plus Single Board Computer 3 + ============================================= 4 + 5 + For more details, contact Applied Data Systems or see 6 + http://www.applieddata.net/products.html 7 + 8 + The original Linux support for this product has been provided by 9 + Nicolas Pitre <nico@fluxnic.net>. Continued development work by 10 + Woojung Huh <whuh@applieddata.net> 11 + 12 + It's currently possible to mount a root filesystem via NFS providing a 13 + complete Linux environment. Otherwise a ramdisk image may be used. The 14 + board supports MTD/JFFS, so you could also mount something on there. 15 + 16 + Use 'make graphicsclient_config' before any 'make config'. This will set up 17 + defaults for GraphicsClient Plus support. 18 + 19 + The kernel zImage is linked to be loaded and executed at 0xc0200000. 20 + Also the following registers should have the specified values upon entry:: 21 + 22 + r0 = 0 23 + r1 = 29 (this is the GraphicsClient architecture number) 24 + 25 + Linux can be used with the ADS BootLoader that ships with the 26 + newer rev boards. See their documentation on how to load Linux. 27 + Angel is not available for the GraphicsClient Plus AFAIK. 28 + 29 + There is a board known as just the GraphicsClient that ADS used to 30 + produce but has end of lifed. This code will not work on the older 31 + board with the ADS bootloader, but should still work with Angel, 32 + as outlined below. In any case, if you're planning on deploying 33 + something en masse, you should probably get the newer board. 34 + 35 + If using Angel on the older boards, here is a typical angel.opt option file 36 + if the kernel is loaded through the Angel Debug Monitor:: 37 + 38 + base 0xc0200000 39 + entry 0xc0200000 40 + r0 0x00000000 41 + r1 0x0000001d 42 + device /dev/ttyS1 43 + options "38400 8N1" 44 + baud 115200 45 + #otherfile ramdisk.gz 46 + #otherbase 0xc0800000 47 + exec minicom 48 + 49 + Then the kernel (and ramdisk if otherfile/otherbase lines above are 50 + uncommented) would be loaded with:: 51 + 52 + angelboot -f angelboot.opt zImage 53 + 54 + Here it is assumed that the board is connected to ttyS1 on your PC 55 + and that minicom is preconfigured with /dev/ttyS1, 38400 baud, 8N1, no flow 56 + control by default. 57 + 58 + If any other bootloader is used, ensure it accomplish the same, especially 59 + for r0/r1 register values before jumping into the kernel. 60 + 61 + 62 + Supported peripherals 63 + ===================== 64 + 65 + - SA1100 LCD frame buffer (8/16bpp...sort of) 66 + - on-board SMC 92C96 ethernet NIC 67 + - SA1100 serial port 68 + - flash memory access (MTD/JFFS) 69 + - pcmcia 70 + - touchscreen(ucb1200) 71 + - ps/2 keyboard 72 + - console on LCD screen 73 + - serial ports (ttyS[0-2]) 74 + - ttyS0 is default for serial console 75 + - Smart I/O (ADC, keypad, digital inputs, etc) 76 + See http://www.eurotech-inc.com/linux-sbc.asp for IOCTL documentation 77 + and example user space code. ps/2 keybd is multiplexed through this driver 78 + 79 + To do 80 + ===== 81 + 82 + - UCB1200 audio with new ucb_generic layer 83 + - everything else! :-) 84 + 85 + Notes 86 + ===== 87 + 88 + - The flash on board is divided into 3 partitions. mtd0 is where 89 + the ADS boot ROM and zImage is stored. It's been marked as 90 + read-only to keep you from blasting over the bootloader. :) mtd1 is 91 + for the ramdisk.gz image. mtd2 is user flash space and can be 92 + utilized for either JFFS or if you're feeling crazy, running ext2 93 + on top of it. If you're not using the ADS bootloader, you're 94 + welcome to blast over the mtd1 partition also. 95 + 96 + - 16bpp mode requires a different cable than what ships with the board. 97 + Contact ADS or look through the manual to wire your own. Currently, 98 + if you compile with 16bit mode support and switch into a lower bpp 99 + mode, the timing is off so the image is corrupted. This will be 100 + fixed soon. 101 + 102 + Any contribution can be sent to nico@fluxnic.net and will be greatly welcome!
+60
Documentation/arm/sa1100/graphicsmaster.rst
··· 1 + ======================================== 2 + ADS GraphicsMaster Single Board Computer 3 + ======================================== 4 + 5 + For more details, contact Applied Data Systems or see 6 + http://www.applieddata.net/products.html 7 + 8 + The original Linux support for this product has been provided by 9 + Nicolas Pitre <nico@fluxnic.net>. Continued development work by 10 + Woojung Huh <whuh@applieddata.net> 11 + 12 + Use 'make graphicsmaster_config' before any 'make config'. 13 + This will set up defaults for GraphicsMaster support. 14 + 15 + The kernel zImage is linked to be loaded and executed at 0xc0400000. 16 + 17 + Linux can be used with the ADS BootLoader that ships with the 18 + newer rev boards. See their documentation on how to load Linux. 19 + 20 + Supported peripherals 21 + ===================== 22 + 23 + - SA1100 LCD frame buffer (8/16bpp...sort of) 24 + - SA1111 USB Master 25 + - on-board SMC 92C96 ethernet NIC 26 + - SA1100 serial port 27 + - flash memory access (MTD/JFFS) 28 + - pcmcia, compact flash 29 + - touchscreen(ucb1200) 30 + - ps/2 keyboard 31 + - console on LCD screen 32 + - serial ports (ttyS[0-2]) 33 + - ttyS0 is default for serial console 34 + - Smart I/O (ADC, keypad, digital inputs, etc) 35 + See http://www.eurotech-inc.com/linux-sbc.asp for IOCTL documentation 36 + and example user space code. ps/2 keybd is multiplexed through this driver 37 + 38 + To do 39 + ===== 40 + 41 + - everything else! :-) 42 + 43 + Notes 44 + ===== 45 + 46 + - The flash on board is divided into 3 partitions. mtd0 is where 47 + the zImage is stored. It's been marked as read-only to keep you 48 + from blasting over the bootloader. :) mtd1 is 49 + for the ramdisk.gz image. mtd2 is user flash space and can be 50 + utilized for either JFFS or if you're feeling crazy, running ext2 51 + on top of it. If you're not using the ADS bootloader, you're 52 + welcome to blast over the mtd1 partition also. 53 + 54 + - 16bpp mode requires a different cable than what ships with the board. 55 + Contact ADS or look through the manual to wire your own. Currently, 56 + if you compile with 16bit mode support and switch into a lower bpp 57 + mode, the timing is off so the image is corrupted. This will be 58 + fixed soon. 59 + 60 + Any contribution can be sent to nico@fluxnic.net and will be greatly welcome!
+21
Documentation/arm/sa1100/huw_webpanel.rst
··· 1 + ======================= 2 + Hoeft & Wessel Webpanel 3 + ======================= 4 + 5 + The HUW_WEBPANEL is a product of the german company Hoeft & Wessel AG 6 + 7 + If you want more information, please visit 8 + http://www.hoeft-wessel.de 9 + 10 + To build the kernel:: 11 + 12 + make huw_webpanel_config 13 + make oldconfig 14 + [accept all defaults] 15 + make zImage 16 + 17 + Mostly of the work is done by: 18 + Roman Jordan jor@hoeft-wessel.de 19 + Christoph Schulz schu@hoeft-wessel.de 20 + 21 + 2000/12/18/
+23
Documentation/arm/sa1100/index.rst
··· 1 + ==================== 2 + Intel StrongARM 1100 3 + ==================== 4 + 5 + .. toctree:: 6 + :maxdepth: 1 7 + 8 + adsbitsy 9 + assabet 10 + brutus 11 + cerf 12 + freebird 13 + graphicsclient 14 + graphicsmaster 15 + huw_webpanel 16 + itsy 17 + lart 18 + nanoengine 19 + pangolin 20 + pleb 21 + serial_uart 22 + tifon 23 + yopy
+47
Documentation/arm/sa1100/itsy.rst
··· 1 + ==== 2 + Itsy 3 + ==== 4 + 5 + Itsy is a research project done by the Western Research Lab, and Systems 6 + Research Center in Palo Alto, CA. The Itsy project is one of several 7 + research projects at Compaq that are related to pocket computing. 8 + 9 + For more information, see: 10 + 11 + http://www.hpl.hp.com/downloads/crl/itsy/ 12 + 13 + Notes on initial 2.4 Itsy support (8/27/2000) : 14 + 15 + The port was done on an Itsy version 1.5 machine with a daughtercard with 16 + 64 Meg of DRAM and 32 Meg of Flash. The initial work includes support for 17 + serial console (to see what you're doing). No other devices have been 18 + enabled. 19 + 20 + To build, do a "make menuconfig" (or xmenuconfig) and select Itsy support. 21 + Disable Flash and LCD support. and then do a make zImage. 22 + Finally, you will need to cd to arch/arm/boot/tools and execute a make there 23 + to build the params-itsy program used to boot the kernel. 24 + 25 + In order to install the port of 2.4 to the itsy, You will need to set the 26 + configuration parameters in the monitor as follows:: 27 + 28 + Arg 1:0x08340000, Arg2: 0xC0000000, Arg3:18 (0x12), Arg4:0 29 + 30 + Make sure the start-routine address is set to 0x00060000. 31 + 32 + Next, flash the params-itsy program to 0x00060000 ("p 1 0x00060000" in the 33 + flash menu) Flash the kernel in arch/arm/boot/zImage into 0x08340000 34 + ("p 1 0x00340000"). Finally flash an initial ramdisk into 0xC8000000 35 + ("p 2 0x0") We used ramdisk-2-30.gz from the 0.11 version directory on 36 + handhelds.org. 37 + 38 + The serial connection we established was at: 39 + 40 + 8-bit data, no parity, 1 stop bit(s), 115200.00 b/s. in the monitor, in the 41 + params-itsy program, and in the kernel itself. This can be changed, but 42 + not easily. The monitor parameters are easily changed, the params program 43 + setup is assembly outl's, and the kernel is a configuration item specific to 44 + the itsy. (i.e. grep for CONFIG_SA1100_ITSY and you'll find where it is.) 45 + 46 + 47 + This should get you a properly booting 2.4 kernel on the itsy.
+15
Documentation/arm/sa1100/lart.rst
··· 1 + ==================================== 2 + Linux Advanced Radio Terminal (LART) 3 + ==================================== 4 + 5 + The LART is a small (7.5 x 10cm) SA-1100 board, designed for embedded 6 + applications. It has 32 MB DRAM, 4MB Flash ROM, double RS232 and all 7 + other StrongARM-gadgets. Almost all SA signals are directly accessible 8 + through a number of connectors. The powersupply accepts voltages 9 + between 3.5V and 16V and is overdimensioned to support a range of 10 + daughterboards. A quad Ethernet / IDE / PS2 / sound daughterboard 11 + is under development, with plenty of others in different stages of 12 + planning. 13 + 14 + The hardware designs for this board have been released under an open license; 15 + see the LART page at http://www.lartmaker.nl/ for more information.
+11
Documentation/arm/sa1100/nanoengine.rst
··· 1 + ========== 2 + nanoEngine 3 + ========== 4 + 5 + "nanoEngine" is a SA1110 based single board computer from 6 + Bright Star Engineering Inc. See www.brightstareng.com/arm 7 + for more info. 8 + (Ref: Stuart Adams <sja@brightstareng.com>) 9 + 10 + Also visit Larry Doolittle's "Linux for the nanoEngine" site: 11 + http://www.brightstareng.com/arm/nanoeng.htm
+29
Documentation/arm/sa1100/pangolin.rst
··· 1 + ======== 2 + Pangolin 3 + ======== 4 + 5 + Pangolin is a StrongARM 1110-based evaluation platform produced 6 + by Dialogue Technology (http://www.dialogue.com.tw/). 7 + It has EISA slots for ease of configuration with SDRAM/Flash 8 + memory card, USB/Serial/Audio card, Compact Flash card, 9 + PCMCIA/IDE card and TFT-LCD card. 10 + 11 + To compile for Pangolin, you must issue the following commands:: 12 + 13 + make pangolin_config 14 + make oldconfig 15 + make zImage 16 + 17 + Supported peripherals 18 + ===================== 19 + 20 + - SA1110 serial port (UART1/UART2/UART3) 21 + - flash memory access 22 + - compact flash driver 23 + - UDA1341 sound driver 24 + - SA1100 LCD controller for 800x600 16bpp TFT-LCD 25 + - MQ-200 driver for 800x600 16bpp TFT-LCD 26 + - Penmount(touch panel) driver 27 + - PCMCIA driver 28 + - SMC91C94 LAN driver 29 + - IDE driver (experimental)
+13
Documentation/arm/sa1100/pleb.rst
··· 1 + ==== 2 + PLEB 3 + ==== 4 + 5 + The PLEB project was started as a student initiative at the School of 6 + Computer Science and Engineering, University of New South Wales to make a 7 + pocket computer capable of running the Linux Kernel. 8 + 9 + PLEB support has yet to be fully integrated. 10 + 11 + For more information, see: 12 + 13 + http://www.cse.unsw.edu.au
+51
Documentation/arm/sa1100/serial_uart.rst
··· 1 + ================== 2 + SA1100 serial port 3 + ================== 4 + 5 + The SA1100 serial port had its major/minor numbers officially assigned:: 6 + 7 + > Date: Sun, 24 Sep 2000 21:40:27 -0700 8 + > From: H. Peter Anvin <hpa@transmeta.com> 9 + > To: Nicolas Pitre <nico@CAM.ORG> 10 + > Cc: Device List Maintainer <device@lanana.org> 11 + > Subject: Re: device 12 + > 13 + > Okay. Note that device numbers 204 and 205 are used for "low density 14 + > serial devices", so you will have a range of minors on those majors (the 15 + > tty device layer handles this just fine, so you don't have to worry about 16 + > doing anything special.) 17 + > 18 + > So your assignments are: 19 + > 20 + > 204 char Low-density serial ports 21 + > 5 = /dev/ttySA0 SA1100 builtin serial port 0 22 + > 6 = /dev/ttySA1 SA1100 builtin serial port 1 23 + > 7 = /dev/ttySA2 SA1100 builtin serial port 2 24 + > 25 + > 205 char Low-density serial ports (alternate device) 26 + > 5 = /dev/cusa0 Callout device for ttySA0 27 + > 6 = /dev/cusa1 Callout device for ttySA1 28 + > 7 = /dev/cusa2 Callout device for ttySA2 29 + > 30 + 31 + You must create those inodes in /dev on the root filesystem used 32 + by your SA1100-based device:: 33 + 34 + mknod ttySA0 c 204 5 35 + mknod ttySA1 c 204 6 36 + mknod ttySA2 c 204 7 37 + mknod cusa0 c 205 5 38 + mknod cusa1 c 205 6 39 + mknod cusa2 c 205 7 40 + 41 + In addition to the creation of the appropriate device nodes above, you 42 + must ensure your user space applications make use of the correct device 43 + name. The classic example is the content of the /etc/inittab file where 44 + you might have a getty process started on ttyS0. 45 + 46 + In this case: 47 + 48 + - replace occurrences of ttyS0 with ttySA0, ttyS1 with ttySA1, etc. 49 + 50 + - don't forget to add 'ttySA0', 'console', or the appropriate tty name 51 + in /etc/securetty for root to be allowed to login as well.
+7
Documentation/arm/sa1100/tifon.rst
··· 1 + ===== 2 + Tifon 3 + ===== 4 + 5 + More info has to come... 6 + 7 + Contact: Peter Danielsson <peter.danielsson@era-t.ericsson.se>
+5
Documentation/arm/sa1100/yopy.rst
··· 1 + ==== 2 + Yopy 3 + ==== 4 + 5 + See http://www.yopydeveloper.org for more.
+76
Documentation/arm/samsung-s3c24xx/cpufreq.rst
··· 1 + ======================= 2 + S3C24XX CPUfreq support 3 + ======================= 4 + 5 + Introduction 6 + ------------ 7 + 8 + The S3C24XX series support a number of power saving systems, such as 9 + the ability to change the core, memory and peripheral operating 10 + frequencies. The core control is exported via the CPUFreq driver 11 + which has a number of different manual or automatic controls over the 12 + rate the core is running at. 13 + 14 + There are two forms of the driver depending on the specific CPU and 15 + how the clocks are arranged. The first implementation used as single 16 + PLL to feed the ARM, memory and peripherals via a series of dividers 17 + and muxes and this is the implementation that is documented here. A 18 + newer version where there is a separate PLL and clock divider for the 19 + ARM core is available as a separate driver. 20 + 21 + 22 + Layout 23 + ------ 24 + 25 + The code core manages the CPU specific drivers, any data that they 26 + need to register and the interface to the generic drivers/cpufreq 27 + system. Each CPU registers a driver to control the PLL, clock dividers 28 + and anything else associated with it. Any board that wants to use this 29 + framework needs to supply at least basic details of what is required. 30 + 31 + The core registers with drivers/cpufreq at init time if all the data 32 + necessary has been supplied. 33 + 34 + 35 + CPU support 36 + ----------- 37 + 38 + The support for each CPU depends on the facilities provided by the 39 + SoC and the driver as each device has different PLL and clock chains 40 + associated with it. 41 + 42 + 43 + Slow Mode 44 + --------- 45 + 46 + The SLOW mode where the PLL is turned off altogether and the 47 + system is fed by the external crystal input is currently not 48 + supported. 49 + 50 + 51 + sysfs 52 + ----- 53 + 54 + The core code exports extra information via sysfs in the directory 55 + devices/system/cpu/cpu0/arch-freq. 56 + 57 + 58 + Board Support 59 + ------------- 60 + 61 + Each board that wants to use the cpufreq code must register some basic 62 + information with the core driver to provide information about what the 63 + board requires and any restrictions being placed on it. 64 + 65 + The board needs to supply information about whether it needs the IO bank 66 + timings changing, any maximum frequency limits and information about the 67 + SDRAM refresh rate. 68 + 69 + 70 + 71 + 72 + Document Author 73 + --------------- 74 + 75 + Ben Dooks, Copyright 2009 Simtec Electronics 76 + Licensed under GPLv2
+59
Documentation/arm/samsung-s3c24xx/eb2410itx.rst
··· 1 + =================================== 2 + Simtec Electronics EB2410ITX (BAST) 3 + =================================== 4 + 5 + http://www.simtec.co.uk/products/EB2410ITX/ 6 + 7 + Introduction 8 + ------------ 9 + 10 + The EB2410ITX is a S3C2410 based development board with a variety of 11 + peripherals and expansion connectors. This board is also known by 12 + the shortened name of Bast. 13 + 14 + 15 + Configuration 16 + ------------- 17 + 18 + To set the default configuration, use `make bast_defconfig` which 19 + supports the commonly used features of this board. 20 + 21 + 22 + Support 23 + ------- 24 + 25 + Official support information can be found on the Simtec Electronics 26 + website, at the product page http://www.simtec.co.uk/products/EB2410ITX/ 27 + 28 + Useful links: 29 + 30 + - Resources Page http://www.simtec.co.uk/products/EB2410ITX/resources.html 31 + 32 + - Board FAQ at http://www.simtec.co.uk/products/EB2410ITX/faq.html 33 + 34 + - Bootloader info http://www.simtec.co.uk/products/SWABLE/resources.html 35 + and FAQ http://www.simtec.co.uk/products/SWABLE/faq.html 36 + 37 + 38 + MTD 39 + --- 40 + 41 + The NAND and NOR support has been merged from the linux-mtd project. 42 + Any problems, see http://www.linux-mtd.infradead.org/ for more 43 + information or up-to-date versions of linux-mtd. 44 + 45 + 46 + IDE 47 + --- 48 + 49 + Both onboard IDE ports are supported, however there is no support for 50 + changing speed of devices, PIO Mode 4 capable drives should be used. 51 + 52 + 53 + Maintainers 54 + ----------- 55 + 56 + This board is maintained by Simtec Electronics. 57 + 58 + 59 + Copyright 2004 Ben Dooks, Simtec Electronics
+172
Documentation/arm/samsung-s3c24xx/gpio.rst
··· 1 + ==================== 2 + S3C24XX GPIO Control 3 + ==================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + The s3c2410 kernel provides an interface to configure and 9 + manipulate the state of the GPIO pins, and find out other 10 + information about them. 11 + 12 + There are a number of conditions attached to the configuration 13 + of the s3c2410 GPIO system, please read the Samsung provided 14 + data-sheet/users manual to find out the complete list. 15 + 16 + See Documentation/arm/samsung/gpio.rst for the core implementation. 17 + 18 + 19 + GPIOLIB 20 + ------- 21 + 22 + With the event of the GPIOLIB in drivers/gpio, support for some 23 + of the GPIO functions such as reading and writing a pin will 24 + be removed in favour of this common access method. 25 + 26 + Once all the extant drivers have been converted, the functions 27 + listed below will be removed (they may be marked as __deprecated 28 + in the near future). 29 + 30 + The following functions now either have a `s3c_` specific variant 31 + or are merged into gpiolib. See the definitions in 32 + arch/arm/plat-samsung/include/plat/gpio-cfg.h: 33 + 34 + - s3c2410_gpio_setpin() gpio_set_value() or gpio_direction_output() 35 + - s3c2410_gpio_getpin() gpio_get_value() or gpio_direction_input() 36 + - s3c2410_gpio_getirq() gpio_to_irq() 37 + - s3c2410_gpio_cfgpin() s3c_gpio_cfgpin() 38 + - s3c2410_gpio_getcfg() s3c_gpio_getcfg() 39 + - s3c2410_gpio_pullup() s3c_gpio_setpull() 40 + 41 + 42 + GPIOLIB conversion 43 + ------------------ 44 + 45 + If you need to convert your board or driver to use gpiolib from the phased 46 + out s3c2410 API, then here are some notes on the process. 47 + 48 + 1) If your board is exclusively using an GPIO, say to control peripheral 49 + power, then it will require to claim the gpio with gpio_request() before 50 + it can use it. 51 + 52 + It is recommended to check the return value, with at least WARN_ON() 53 + during initialisation. 54 + 55 + 2) The s3c2410_gpio_cfgpin() can be directly replaced with s3c_gpio_cfgpin() 56 + as they have the same arguments, and can either take the pin specific 57 + values, or the more generic special-function-number arguments. 58 + 59 + 3) s3c2410_gpio_pullup() changes have the problem that while the 60 + s3c2410_gpio_pullup(x, 1) can be easily translated to the 61 + s3c_gpio_setpull(x, S3C_GPIO_PULL_NONE), the s3c2410_gpio_pullup(x, 0) 62 + are not so easy. 63 + 64 + The s3c2410_gpio_pullup(x, 0) case enables the pull-up (or in the case 65 + of some of the devices, a pull-down) and as such the new API distinguishes 66 + between the UP and DOWN case. There is currently no 'just turn on' setting 67 + which may be required if this becomes a problem. 68 + 69 + 4) s3c2410_gpio_setpin() can be replaced by gpio_set_value(), the old call 70 + does not implicitly configure the relevant gpio to output. The gpio 71 + direction should be changed before using gpio_set_value(). 72 + 73 + 5) s3c2410_gpio_getpin() is replaceable by gpio_get_value() if the pin 74 + has been set to input. It is currently unknown what the behaviour is 75 + when using gpio_get_value() on an output pin (s3c2410_gpio_getpin 76 + would return the value the pin is supposed to be outputting). 77 + 78 + 6) s3c2410_gpio_getirq() should be directly replaceable with the 79 + gpio_to_irq() call. 80 + 81 + The s3c2410_gpio and `gpio_` calls have always operated on the same gpio 82 + numberspace, so there is no problem with converting the gpio numbering 83 + between the calls. 84 + 85 + 86 + Headers 87 + ------- 88 + 89 + See arch/arm/mach-s3c24xx/include/mach/regs-gpio.h for the list 90 + of GPIO pins, and the configuration values for them. This 91 + is included by using #include <mach/regs-gpio.h> 92 + 93 + 94 + PIN Numbers 95 + ----------- 96 + 97 + Each pin has an unique number associated with it in regs-gpio.h, 98 + e.g. S3C2410_GPA(0) or S3C2410_GPF(1). These defines are used to tell 99 + the GPIO functions which pin is to be used. 100 + 101 + With the conversion to gpiolib, there is no longer a direct conversion 102 + from gpio pin number to register base address as in earlier kernels. This 103 + is due to the number space required for newer SoCs where the later 104 + GPIOs are not contiguous. 105 + 106 + 107 + Configuring a pin 108 + ----------------- 109 + 110 + The following function allows the configuration of a given pin to 111 + be changed. 112 + 113 + void s3c_gpio_cfgpin(unsigned int pin, unsigned int function); 114 + 115 + e.g.: 116 + 117 + s3c_gpio_cfgpin(S3C2410_GPA(0), S3C_GPIO_SFN(1)); 118 + s3c_gpio_cfgpin(S3C2410_GPE(8), S3C_GPIO_SFN(2)); 119 + 120 + which would turn GPA(0) into the lowest Address line A0, and set 121 + GPE(8) to be connected to the SDIO/MMC controller's SDDAT1 line. 122 + 123 + 124 + Reading the current configuration 125 + --------------------------------- 126 + 127 + The current configuration of a pin can be read by using standard 128 + gpiolib function: 129 + 130 + s3c_gpio_getcfg(unsigned int pin); 131 + 132 + The return value will be from the same set of values which can be 133 + passed to s3c_gpio_cfgpin(). 134 + 135 + 136 + Configuring a pull-up resistor 137 + ------------------------------ 138 + 139 + A large proportion of the GPIO pins on the S3C2410 can have weak 140 + pull-up resistors enabled. This can be configured by the following 141 + function: 142 + 143 + void s3c_gpio_setpull(unsigned int pin, unsigned int to); 144 + 145 + Where the to value is S3C_GPIO_PULL_NONE to set the pull-up off, 146 + and S3C_GPIO_PULL_UP to enable the specified pull-up. Any other 147 + values are currently undefined. 148 + 149 + 150 + Getting and setting the state of a PIN 151 + -------------------------------------- 152 + 153 + These calls are now implemented by the relevant gpiolib calls, convert 154 + your board or driver to use gpiolib. 155 + 156 + 157 + Getting the IRQ number associated with a PIN 158 + -------------------------------------------- 159 + 160 + A standard gpiolib function can map the given pin number to an IRQ 161 + number to pass to the IRQ system. 162 + 163 + int gpio_to_irq(unsigned int pin); 164 + 165 + Note, not all pins have an IRQ. 166 + 167 + 168 + Author 169 + ------- 170 + 171 + Ben Dooks, 03 October 2004 172 + Copyright 2004 Ben Dooks, Simtec Electronics
+41
Documentation/arm/samsung-s3c24xx/h1940.rst
··· 1 + ============= 2 + HP IPAQ H1940 3 + ============= 4 + 5 + http://www.handhelds.org/projects/h1940.html 6 + 7 + Introduction 8 + ------------ 9 + 10 + The HP H1940 is a S3C2410 based handheld device, with 11 + bluetooth connectivity. 12 + 13 + 14 + Support 15 + ------- 16 + 17 + A variety of information is available 18 + 19 + handhelds.org project page: 20 + 21 + http://www.handhelds.org/projects/h1940.html 22 + 23 + handhelds.org wiki page: 24 + 25 + http://handhelds.org/moin/moin.cgi/HpIpaqH1940 26 + 27 + Herbert Pötzl pages: 28 + 29 + http://vserver.13thfloor.at/H1940/ 30 + 31 + 32 + Maintainers 33 + ----------- 34 + 35 + This project is being maintained and developed by a variety 36 + of people, including Ben Dooks, Arnaud Patard, and Herbert Pötzl. 37 + 38 + Thanks to the many others who have also provided support. 39 + 40 + 41 + (c) 2005 Ben Dooks
+18
Documentation/arm/samsung-s3c24xx/index.rst
··· 1 + ========================== 2 + Samsung S3C24XX SoC Family 3 + ========================== 4 + 5 + .. toctree:: 6 + :maxdepth: 1 7 + 8 + h1940 9 + gpio 10 + cpufreq 11 + suspend 12 + usb-host 13 + s3c2412 14 + eb2410itx 15 + nand 16 + smdk2440 17 + s3c2413 18 + overview
+30
Documentation/arm/samsung-s3c24xx/nand.rst
··· 1 + ==================== 2 + S3C24XX NAND Support 3 + ==================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + Small Page NAND 9 + --------------- 10 + 11 + The driver uses a 512 byte (1 page) ECC code for this setup. The 12 + ECC code is not directly compatible with the default kernel ECC 13 + code, so the driver enforces its own OOB layout and ECC parameters 14 + 15 + Large Page NAND 16 + --------------- 17 + 18 + The driver is capable of handling NAND flash with a 2KiB page 19 + size, with support for hardware ECC generation and correction. 20 + 21 + Unlike the 512byte page mode, the driver generates ECC data for 22 + each 256 byte block in an 2KiB page. This means that more than 23 + one error in a page can be rectified. It also means that the 24 + OOB layout remains the default kernel layout for these flashes. 25 + 26 + 27 + Document Author 28 + --------------- 29 + 30 + Ben Dooks, Copyright 2007 Simtec Electronics
+319
Documentation/arm/samsung-s3c24xx/overview.rst
··· 1 + ========================== 2 + S3C24XX ARM Linux Overview 3 + ========================== 4 + 5 + 6 + 7 + Introduction 8 + ------------ 9 + 10 + The Samsung S3C24XX range of ARM9 System-on-Chip CPUs are supported 11 + by the 's3c2410' architecture of ARM Linux. Currently the S3C2410, 12 + S3C2412, S3C2413, S3C2416, S3C2440, S3C2442, S3C2443 and S3C2450 devices 13 + are supported. 14 + 15 + Support for the S3C2400 and S3C24A0 series was never completed and the 16 + corresponding code has been removed after a while. If someone wishes to 17 + revive this effort, partial support can be retrieved from earlier Linux 18 + versions. 19 + 20 + The S3C2416 and S3C2450 devices are very similar and S3C2450 support is 21 + included under the arch/arm/mach-s3c2416 directory. Note, while core 22 + support for these SoCs is in, work on some of the extra peripherals 23 + and extra interrupts is still ongoing. 24 + 25 + 26 + Configuration 27 + ------------- 28 + 29 + A generic S3C2410 configuration is provided, and can be used as the 30 + default by `make s3c2410_defconfig`. This configuration has support 31 + for all the machines, and the commonly used features on them. 32 + 33 + Certain machines may have their own default configurations as well, 34 + please check the machine specific documentation. 35 + 36 + 37 + Layout 38 + ------ 39 + 40 + The core support files are located in the platform code contained in 41 + arch/arm/plat-s3c24xx with headers in include/asm-arm/plat-s3c24xx. 42 + This directory should be kept to items shared between the platform 43 + code (arch/arm/plat-s3c24xx) and the arch/arm/mach-s3c24* code. 44 + 45 + Each cpu has a directory with the support files for it, and the 46 + machines that carry the device. For example S3C2410 is contained 47 + in arch/arm/mach-s3c2410 and S3C2440 in arch/arm/mach-s3c2440 48 + 49 + Register, kernel and platform data definitions are held in the 50 + arch/arm/mach-s3c2410 directory./include/mach 51 + 52 + arch/arm/plat-s3c24xx: 53 + 54 + Files in here are either common to all the s3c24xx family, 55 + or are common to only some of them with names to indicate this 56 + status. The files that are not common to all are generally named 57 + with the initial cpu they support in the series to ensure a short 58 + name without any possibility of confusion with newer devices. 59 + 60 + As an example, initially s3c244x would cover s3c2440 and s3c2442, but 61 + with the s3c2443 which does not share many of the same drivers in 62 + this directory, the name becomes invalid. We stick to s3c2440-<x> 63 + to indicate a driver that is s3c2440 and s3c2442 compatible. 64 + 65 + This does mean that to find the status of any given SoC, a number 66 + of directories may need to be searched. 67 + 68 + 69 + Machines 70 + -------- 71 + 72 + The currently supported machines are as follows: 73 + 74 + Simtec Electronics EB2410ITX (BAST) 75 + 76 + A general purpose development board, see EB2410ITX.txt for further 77 + details 78 + 79 + Simtec Electronics IM2440D20 (Osiris) 80 + 81 + CPU Module from Simtec Electronics, with a S3C2440A CPU, nand flash 82 + and a PCMCIA controller. 83 + 84 + Samsung SMDK2410 85 + 86 + Samsung's own development board, geared for PDA work. 87 + 88 + Samsung/Aiji SMDK2412 89 + 90 + The S3C2412 version of the SMDK2440. 91 + 92 + Samsung/Aiji SMDK2413 93 + 94 + The S3C2412 version of the SMDK2440. 95 + 96 + Samsung/Meritech SMDK2440 97 + 98 + The S3C2440 compatible version of the SMDK2440, which has the 99 + option of an S3C2440 or S3C2442 CPU module. 100 + 101 + Thorcom VR1000 102 + 103 + Custom embedded board 104 + 105 + HP IPAQ 1940 106 + 107 + Handheld (IPAQ), available in several varieties 108 + 109 + HP iPAQ rx3715 110 + 111 + S3C2440 based IPAQ, with a number of variations depending on 112 + features shipped. 113 + 114 + Acer N30 115 + 116 + A S3C2410 based PDA from Acer. There is a Wiki page at 117 + http://handhelds.org/moin/moin.cgi/AcerN30Documentation . 118 + 119 + AML M5900 120 + 121 + American Microsystems' M5900 122 + 123 + Nex Vision Nexcoder 124 + Nex Vision Otom 125 + 126 + Two machines by Nex Vision 127 + 128 + 129 + Adding New Machines 130 + ------------------- 131 + 132 + The architecture has been designed to support as many machines as can 133 + be configured for it in one kernel build, and any future additions 134 + should keep this in mind before altering items outside of their own 135 + machine files. 136 + 137 + Machine definitions should be kept in linux/arch/arm/mach-s3c2410, 138 + and there are a number of examples that can be looked at. 139 + 140 + Read the kernel patch submission policies as well as the 141 + Documentation/arm directory before submitting patches. The 142 + ARM kernel series is managed by Russell King, and has a patch system 143 + located at http://www.arm.linux.org.uk/developer/patches/ 144 + as well as mailing lists that can be found from the same site. 145 + 146 + As a courtesy, please notify <ben-linux@fluff.org> of any new 147 + machines or other modifications. 148 + 149 + Any large scale modifications, or new drivers should be discussed 150 + on the ARM kernel mailing list (linux-arm-kernel) before being 151 + attempted. See http://www.arm.linux.org.uk/mailinglists/ for the 152 + mailing list information. 153 + 154 + 155 + I2C 156 + --- 157 + 158 + The hardware I2C core in the CPU is supported in single master 159 + mode, and can be configured via platform data. 160 + 161 + 162 + RTC 163 + --- 164 + 165 + Support for the onboard RTC unit, including alarm function. 166 + 167 + This has recently been upgraded to use the new RTC core, 168 + and the module has been renamed to rtc-s3c to fit in with 169 + the new rtc naming scheme. 170 + 171 + 172 + Watchdog 173 + -------- 174 + 175 + The onchip watchdog is available via the standard watchdog 176 + interface. 177 + 178 + 179 + NAND 180 + ---- 181 + 182 + The current kernels now have support for the s3c2410 NAND 183 + controller. If there are any problems the latest linux-mtd 184 + code can be found from http://www.linux-mtd.infradead.org/ 185 + 186 + For more information see Documentation/arm/samsung-s3c24xx/nand.rst 187 + 188 + 189 + SD/MMC 190 + ------ 191 + 192 + The SD/MMC hardware pre S3C2443 is supported in the current 193 + kernel, the driver is drivers/mmc/host/s3cmci.c and supports 194 + 1 and 4 bit SD or MMC cards. 195 + 196 + The SDIO behaviour of this driver has not been fully tested. There is no 197 + current support for hardware SDIO interrupts. 198 + 199 + 200 + Serial 201 + ------ 202 + 203 + The s3c2410 serial driver provides support for the internal 204 + serial ports. These devices appear as /dev/ttySAC0 through 3. 205 + 206 + To create device nodes for these, use the following commands 207 + 208 + mknod ttySAC0 c 204 64 209 + mknod ttySAC1 c 204 65 210 + mknod ttySAC2 c 204 66 211 + 212 + 213 + GPIO 214 + ---- 215 + 216 + The core contains support for manipulating the GPIO, see the 217 + documentation in GPIO.txt in the same directory as this file. 218 + 219 + Newer kernels carry GPIOLIB, and support is being moved towards 220 + this with some of the older support in line to be removed. 221 + 222 + As of v2.6.34, the move towards using gpiolib support is almost 223 + complete, and very little of the old calls are left. 224 + 225 + See Documentation/arm/samsung-s3c24xx/gpio.rst for the S3C24XX specific 226 + support and Documentation/arm/samsung/gpio.rst for the core Samsung 227 + implementation. 228 + 229 + 230 + Clock Management 231 + ---------------- 232 + 233 + The core provides the interface defined in the header file 234 + include/asm-arm/hardware/clock.h, to allow control over the 235 + various clock units 236 + 237 + 238 + Suspend to RAM 239 + -------------- 240 + 241 + For boards that provide support for suspend to RAM, the 242 + system can be placed into low power suspend. 243 + 244 + See Suspend.txt for more information. 245 + 246 + 247 + SPI 248 + --- 249 + 250 + SPI drivers are available for both the in-built hardware 251 + (although there is no DMA support yet) and a generic 252 + GPIO based solution. 253 + 254 + 255 + LEDs 256 + ---- 257 + 258 + There is support for GPIO based LEDs via a platform driver 259 + in the LED subsystem. 260 + 261 + 262 + Platform Data 263 + ------------- 264 + 265 + Whenever a device has platform specific data that is specified 266 + on a per-machine basis, care should be taken to ensure the 267 + following: 268 + 269 + 1) that default data is not left in the device to confuse the 270 + driver if a machine does not set it at startup 271 + 272 + 2) the data should (if possible) be marked as __initdata, 273 + to ensure that the data is thrown away if the machine is 274 + not the one currently in use. 275 + 276 + The best way of doing this is to make a function that 277 + kmalloc()s an area of memory, and copies the __initdata 278 + and then sets the relevant device's platform data. Making 279 + the function `__init` takes care of ensuring it is discarded 280 + with the rest of the initialisation code:: 281 + 282 + static __init void s3c24xx_xxx_set_platdata(struct xxx_data *pd) 283 + { 284 + struct s3c2410_xxx_mach_info *npd; 285 + 286 + npd = kmalloc(sizeof(struct s3c2410_xxx_mach_info), GFP_KERNEL); 287 + if (npd) { 288 + memcpy(npd, pd, sizeof(struct s3c2410_xxx_mach_info)); 289 + s3c_device_xxx.dev.platform_data = npd; 290 + } else { 291 + printk(KERN_ERR "no memory for xxx platform data\n"); 292 + } 293 + } 294 + 295 + Note, since the code is marked as __init, it should not be 296 + exported outside arch/arm/mach-s3c2410/, or exported to 297 + modules via EXPORT_SYMBOL() and related functions. 298 + 299 + 300 + Port Contributors 301 + ----------------- 302 + 303 + Ben Dooks (BJD) 304 + Vincent Sanders 305 + Herbert Potzl 306 + Arnaud Patard (RTP) 307 + Roc Wu 308 + Klaus Fetscher 309 + Dimitry Andric 310 + Shannon Holland 311 + Guillaume Gourat (NexVision) 312 + Christer Weinigel (wingel) (Acer N30) 313 + Lucas Correia Villa Real (S3C2400 port) 314 + 315 + 316 + Document Author 317 + --------------- 318 + 319 + Ben Dooks, Copyright 2004-2006 Simtec Electronics
+121
Documentation/arm/samsung-s3c24xx/s3c2412.rst
··· 1 + ========================== 2 + S3C2412 ARM Linux Overview 3 + ========================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + The S3C2412 is part of the S3C24XX range of ARM9 System-on-Chip CPUs 9 + from Samsung. This part has an ARM926-EJS core, capable of running up 10 + to 266MHz (see data-sheet for more information) 11 + 12 + 13 + Clock 14 + ----- 15 + 16 + The core clock code provides a set of clocks to the drivers, and allows 17 + for source selection and a number of other features. 18 + 19 + 20 + Power 21 + ----- 22 + 23 + No support for suspend/resume to RAM in the current system. 24 + 25 + 26 + DMA 27 + --- 28 + 29 + No current support for DMA. 30 + 31 + 32 + GPIO 33 + ---- 34 + 35 + There is support for setting the GPIO to input/output/special function 36 + and reading or writing to them. 37 + 38 + 39 + UART 40 + ---- 41 + 42 + The UART hardware is similar to the S3C2440, and is supported by the 43 + s3c2410 driver in the drivers/serial directory. 44 + 45 + 46 + NAND 47 + ---- 48 + 49 + The NAND hardware is similar to the S3C2440, and is supported by the 50 + s3c2410 driver in the drivers/mtd/nand/raw directory. 51 + 52 + 53 + USB Host 54 + -------- 55 + 56 + The USB hardware is similar to the S3C2410, with extended clock source 57 + control. The OHCI portion is supported by the ohci-s3c2410 driver, and 58 + the clock control selection is supported by the core clock code. 59 + 60 + 61 + USB Device 62 + ---------- 63 + 64 + No current support in the kernel 65 + 66 + 67 + IRQs 68 + ---- 69 + 70 + All the standard, and external interrupt sources are supported. The 71 + extra sub-sources are not yet supported. 72 + 73 + 74 + RTC 75 + --- 76 + 77 + The RTC hardware is similar to the S3C2410, and is supported by the 78 + s3c2410-rtc driver. 79 + 80 + 81 + Watchdog 82 + -------- 83 + 84 + The watchdog hardware is the same as the S3C2410, and is supported by 85 + the s3c2410_wdt driver. 86 + 87 + 88 + MMC/SD/SDIO 89 + ----------- 90 + 91 + No current support for the MMC/SD/SDIO block. 92 + 93 + IIC 94 + --- 95 + 96 + The IIC hardware is the same as the S3C2410, and is supported by the 97 + i2c-s3c24xx driver. 98 + 99 + 100 + IIS 101 + --- 102 + 103 + No current support for the IIS interface. 104 + 105 + 106 + SPI 107 + --- 108 + 109 + No current support for the SPI interfaces. 110 + 111 + 112 + ATA 113 + --- 114 + 115 + No current support for the on-board ATA block. 116 + 117 + 118 + Document Author 119 + --------------- 120 + 121 + Ben Dooks, Copyright 2006 Simtec Electronics
+22
Documentation/arm/samsung-s3c24xx/s3c2413.rst
··· 1 + ========================== 2 + S3C2413 ARM Linux Overview 3 + ========================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + The S3C2413 is an extended version of the S3C2412, with an camera 9 + interface and mobile DDR memory support. See the S3C2412 support 10 + documentation for more information. 11 + 12 + 13 + Camera Interface 14 + ---------------- 15 + 16 + This block is currently not supported. 17 + 18 + 19 + Document Author 20 + --------------- 21 + 22 + Ben Dooks, Copyright 2006 Simtec Electronics
+57
Documentation/arm/samsung-s3c24xx/smdk2440.rst
··· 1 + ========================= 2 + Samsung/Meritech SMDK2440 3 + ========================= 4 + 5 + Introduction 6 + ------------ 7 + 8 + The SMDK2440 is a two part evaluation board for the Samsung S3C2440 9 + processor. It includes support for LCD, SmartMedia, Audio, SD and 10 + 10MBit Ethernet, and expansion headers for various signals, including 11 + the camera and unused GPIO. 12 + 13 + 14 + Configuration 15 + ------------- 16 + 17 + To set the default configuration, use `make smdk2440_defconfig` which 18 + will configure the common features of this board, or use 19 + `make s3c2410_config` to include support for all s3c2410/s3c2440 machines 20 + 21 + 22 + Support 23 + ------- 24 + 25 + Ben Dooks' SMDK2440 site at http://www.fluff.org/ben/smdk2440/ which 26 + includes linux based USB download tools. 27 + 28 + Some of the h1940 patches that can be found from the H1940 project 29 + site at http://www.handhelds.org/projects/h1940.html can also be 30 + applied to this board. 31 + 32 + 33 + Peripherals 34 + ----------- 35 + 36 + There is no current support for any of the extra peripherals on the 37 + base-board itself. 38 + 39 + 40 + MTD 41 + --- 42 + 43 + The NAND flash should be supported by the in kernel MTD NAND support, 44 + NOR flash will be added later. 45 + 46 + 47 + Maintainers 48 + ----------- 49 + 50 + This board is being maintained by Ben Dooks, for more info, see 51 + http://www.fluff.org/ben/smdk2440/ 52 + 53 + Many thanks to Dimitry Andric of TomTom for the loan of the SMDK2440, 54 + and to Simtec Electronics for allowing me time to work on this. 55 + 56 + 57 + (c) 2004 Ben Dooks
+137
Documentation/arm/samsung-s3c24xx/suspend.rst
··· 1 + ======================= 2 + S3C24XX Suspend Support 3 + ======================= 4 + 5 + 6 + Introduction 7 + ------------ 8 + 9 + The S3C24XX supports a low-power suspend mode, where the SDRAM is kept 10 + in Self-Refresh mode, and all but the essential peripheral blocks are 11 + powered down. For more information on how this works, please look 12 + at the relevant CPU datasheet from Samsung. 13 + 14 + 15 + Requirements 16 + ------------ 17 + 18 + 1) A bootloader that can support the necessary resume operation 19 + 20 + 2) Support for at least 1 source for resume 21 + 22 + 3) CONFIG_PM enabled in the kernel 23 + 24 + 4) Any peripherals that are going to be powered down at the same 25 + time require suspend/resume support. 26 + 27 + 28 + Resuming 29 + -------- 30 + 31 + The S3C2410 user manual defines the process of sending the CPU to 32 + sleep and how it resumes. The default behaviour of the Linux code 33 + is to set the GSTATUS3 register to the physical address of the 34 + code to resume Linux operation. 35 + 36 + GSTATUS4 is currently left alone by the sleep code, and is free to 37 + use for any other purposes (for example, the EB2410ITX uses this to 38 + save memory configuration in). 39 + 40 + 41 + Machine Support 42 + --------------- 43 + 44 + The machine specific functions must call the s3c_pm_init() function 45 + to say that its bootloader is capable of resuming. This can be as 46 + simple as adding the following to the machine's definition: 47 + 48 + INITMACHINE(s3c_pm_init) 49 + 50 + A board can do its own setup before calling s3c_pm_init, if it 51 + needs to setup anything else for power management support. 52 + 53 + There is currently no support for over-riding the default method of 54 + saving the resume address, if your board requires it, then contact 55 + the maintainer and discuss what is required. 56 + 57 + Note, the original method of adding an late_initcall() is wrong, 58 + and will end up initialising all compiled machines' pm init! 59 + 60 + The following is an example of code used for testing wakeup from 61 + an falling edge on IRQ_EINT0:: 62 + 63 + 64 + static irqreturn_t button_irq(int irq, void *pw) 65 + { 66 + return IRQ_HANDLED; 67 + } 68 + 69 + statuc void __init machine_init(void) 70 + { 71 + ... 72 + 73 + request_irq(IRQ_EINT0, button_irq, IRQF_TRIGGER_FALLING, 74 + "button-irq-eint0", NULL); 75 + 76 + enable_irq_wake(IRQ_EINT0); 77 + 78 + s3c_pm_init(); 79 + } 80 + 81 + 82 + Debugging 83 + --------- 84 + 85 + There are several important things to remember when using PM suspend: 86 + 87 + 1) The uart drivers will disable the clocks to the UART blocks when 88 + suspending, which means that use of printascii() or similar direct 89 + access to the UARTs will cause the debug to stop. 90 + 91 + 2) While the pm code itself will attempt to re-enable the UART clocks, 92 + care should be taken that any external clock sources that the UARTs 93 + rely on are still enabled at that point. 94 + 95 + 3) If any debugging is placed in the resume path, then it must have the 96 + relevant clocks and peripherals setup before use (ie, bootloader). 97 + 98 + For example, if you transmit a character from the UART, the baud 99 + rate and uart controls must be setup beforehand. 100 + 101 + 102 + Configuration 103 + ------------- 104 + 105 + The S3C2410 specific configuration in `System Type` defines various 106 + aspects of how the S3C2410 suspend and resume support is configured 107 + 108 + `S3C2410 PM Suspend debug` 109 + 110 + This option prints messages to the serial console before and after 111 + the actual suspend, giving detailed information on what is 112 + happening 113 + 114 + 115 + `S3C2410 PM Suspend Memory CRC` 116 + 117 + Allows the entire memory to be checksummed before and after the 118 + suspend to see if there has been any corruption of the contents. 119 + 120 + Note, the time to calculate the CRC is dependent on the CPU speed 121 + and the size of memory. For an 64Mbyte RAM area on an 200MHz 122 + S3C2410, this can take approximately 4 seconds to complete. 123 + 124 + This support requires the CRC32 function to be enabled. 125 + 126 + 127 + `S3C2410 PM Suspend CRC Chunksize (KiB)` 128 + 129 + Defines the size of memory each CRC chunk covers. A smaller value 130 + will mean that the CRC data block will take more memory, but will 131 + identify any faults with better precision 132 + 133 + 134 + Document Author 135 + --------------- 136 + 137 + Ben Dooks, Copyright 2004 Simtec Electronics
+91
Documentation/arm/samsung-s3c24xx/usb-host.rst
··· 1 + ======================== 2 + S3C24XX USB Host support 3 + ======================== 4 + 5 + 6 + 7 + Introduction 8 + ------------ 9 + 10 + This document details the S3C2410/S3C2440 in-built OHCI USB host support. 11 + 12 + Configuration 13 + ------------- 14 + 15 + Enable at least the following kernel options: 16 + 17 + menuconfig:: 18 + 19 + Device Drivers ---> 20 + USB support ---> 21 + <*> Support for Host-side USB 22 + <*> OHCI HCD support 23 + 24 + 25 + .config: 26 + 27 + - CONFIG_USB 28 + - CONFIG_USB_OHCI_HCD 29 + 30 + 31 + Once these options are configured, the standard set of USB device 32 + drivers can be configured and used. 33 + 34 + 35 + Board Support 36 + ------------- 37 + 38 + The driver attaches to a platform device, which will need to be 39 + added by the board specific support file in linux/arch/arm/mach-s3c2410, 40 + such as mach-bast.c or mach-smdk2410.c 41 + 42 + The platform device's platform_data field is only needed if the 43 + board implements extra power control or over-current monitoring. 44 + 45 + The OHCI driver does not ensure the state of the S3C2410's MISCCTRL 46 + register, so if both ports are to be used for the host, then it is 47 + the board support file's responsibility to ensure that the second 48 + port is configured to be connected to the OHCI core. 49 + 50 + 51 + Platform Data 52 + ------------- 53 + 54 + See arch/arm/mach-s3c2410/include/mach/usb-control.h for the 55 + descriptions of the platform device data. An implementation 56 + can be found in linux/arch/arm/mach-s3c2410/usb-simtec.c . 57 + 58 + The `struct s3c2410_hcd_info` contains a pair of functions 59 + that get called to enable over-current detection, and to 60 + control the port power status. 61 + 62 + The ports are numbered 0 and 1. 63 + 64 + power_control: 65 + Called to enable or disable the power on the port. 66 + 67 + enable_oc: 68 + Called to enable or disable the over-current monitoring. 69 + This should claim or release the resources being used to 70 + check the power condition on the port, such as an IRQ. 71 + 72 + report_oc: 73 + The OHCI driver fills this field in for the over-current code 74 + to call when there is a change to the over-current state on 75 + an port. The ports argument is a bitmask of 1 bit per port, 76 + with bit X being 1 for an over-current on port X. 77 + 78 + The function s3c2410_usb_report_oc() has been provided to 79 + ensure this is called correctly. 80 + 81 + port[x]: 82 + This is struct describes each port, 0 or 1. The platform driver 83 + should set the flags field of each port to S3C_HCDFLG_USED if 84 + the port is enabled. 85 + 86 + 87 + 88 + Document Author 89 + --------------- 90 + 91 + Ben Dooks, Copyright 2005 Simtec Electronics
+81
Documentation/arm/samsung/bootloader-interface.rst
··· 1 + ========================================================== 2 + Interface between kernel and boot loaders on Exynos boards 3 + ========================================================== 4 + 5 + Author: Krzysztof Kozlowski 6 + 7 + Date : 6 June 2015 8 + 9 + The document tries to describe currently used interface between Linux kernel 10 + and boot loaders on Samsung Exynos based boards. This is not a definition 11 + of interface but rather a description of existing state, a reference 12 + for information purpose only. 13 + 14 + In the document "boot loader" means any of following: U-boot, proprietary 15 + SBOOT or any other firmware for ARMv7 and ARMv8 initializing the board before 16 + executing kernel. 17 + 18 + 19 + 1. Non-Secure mode 20 + 21 + Address: sysram_ns_base_addr 22 + 23 + ============= ============================================ ================== 24 + Offset Value Purpose 25 + ============= ============================================ ================== 26 + 0x08 exynos_cpu_resume_ns, mcpm_entry_point System suspend 27 + 0x0c 0x00000bad (Magic cookie) System suspend 28 + 0x1c exynos4_secondary_startup Secondary CPU boot 29 + 0x1c + 4*cpu exynos4_secondary_startup (Exynos4412) Secondary CPU boot 30 + 0x20 0xfcba0d10 (Magic cookie) AFTR 31 + 0x24 exynos_cpu_resume_ns AFTR 32 + 0x28 + 4*cpu 0x8 (Magic cookie, Exynos3250) AFTR 33 + 0x28 0x0 or last value during resume (Exynos542x) System suspend 34 + ============= ============================================ ================== 35 + 36 + 37 + 2. Secure mode 38 + 39 + Address: sysram_base_addr 40 + 41 + ============= ============================================ ================== 42 + Offset Value Purpose 43 + ============= ============================================ ================== 44 + 0x00 exynos4_secondary_startup Secondary CPU boot 45 + 0x04 exynos4_secondary_startup (Exynos542x) Secondary CPU boot 46 + 4*cpu exynos4_secondary_startup (Exynos4412) Secondary CPU boot 47 + 0x20 exynos_cpu_resume (Exynos4210 r1.0) AFTR 48 + 0x24 0xfcba0d10 (Magic cookie, Exynos4210 r1.0) AFTR 49 + ============= ============================================ ================== 50 + 51 + Address: pmu_base_addr 52 + 53 + ============= ============================================ ================== 54 + Offset Value Purpose 55 + ============= ============================================ ================== 56 + 0x0800 exynos_cpu_resume AFTR, suspend 57 + 0x0800 mcpm_entry_point (Exynos542x with MCPM) AFTR, suspend 58 + 0x0804 0xfcba0d10 (Magic cookie) AFTR 59 + 0x0804 0x00000bad (Magic cookie) System suspend 60 + 0x0814 exynos4_secondary_startup (Exynos4210 r1.1) Secondary CPU boot 61 + 0x0818 0xfcba0d10 (Magic cookie, Exynos4210 r1.1) AFTR 62 + 0x081C exynos_cpu_resume (Exynos4210 r1.1) AFTR 63 + ============= ============================================ ================== 64 + 65 + 3. Other (regardless of secure/non-secure mode) 66 + 67 + Address: pmu_base_addr 68 + 69 + ============= =============================== =============================== 70 + Offset Value Purpose 71 + ============= =============================== =============================== 72 + 0x0908 Non-zero Secondary CPU boot up indicator 73 + on Exynos3250 and Exynos542x 74 + ============= =============================== =============================== 75 + 76 + 77 + 4. Glossary 78 + 79 + AFTR - ARM Off Top Running, a low power mode, Cortex cores and many other 80 + modules are power gated, except the TOP modules 81 + MCPM - Multi-Cluster Power Management
+41
Documentation/arm/samsung/gpio.rst
··· 1 + =========================== 2 + Samsung GPIO implementation 3 + =========================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + This outlines the Samsung GPIO implementation and the architecture 9 + specific calls provided alongside the drivers/gpio core. 10 + 11 + 12 + S3C24XX (Legacy) 13 + ---------------- 14 + 15 + See Documentation/arm/samsung-s3c24xx/gpio.rst for more information 16 + about these devices. Their implementation has been brought into line 17 + with the core samsung implementation described in this document. 18 + 19 + 20 + GPIOLIB integration 21 + ------------------- 22 + 23 + The gpio implementation uses gpiolib as much as possible, only providing 24 + specific calls for the items that require Samsung specific handling, such 25 + as pin special-function or pull resistor control. 26 + 27 + GPIO numbering is synchronised between the Samsung and gpiolib system. 28 + 29 + 30 + PIN configuration 31 + ----------------- 32 + 33 + Pin configuration is specific to the Samsung architecture, with each SoC 34 + registering the necessary information for the core gpio configuration 35 + implementation to configure pins as necessary. 36 + 37 + The s3c_gpio_cfgpin() and s3c_gpio_setpull() provide the means for a 38 + driver or machine to change gpio configuration. 39 + 40 + See arch/arm/plat-samsung/include/plat/gpio-cfg.h for more information 41 + on these functions.
+10
Documentation/arm/samsung/index.rst
··· 1 + =========== 2 + Samsung SoC 3 + =========== 4 + 5 + .. toctree:: 6 + :maxdepth: 1 7 + 8 + gpio 9 + bootloader-interface 10 + overview
+89
Documentation/arm/samsung/overview.rst
··· 1 + ========================== 2 + Samsung ARM Linux Overview 3 + ========================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + The Samsung range of ARM SoCs spans many similar devices, from the initial 9 + ARM9 through to the newest ARM cores. This document shows an overview of 10 + the current kernel support, how to use it and where to find the code 11 + that supports this. 12 + 13 + The currently supported SoCs are: 14 + 15 + - S3C24XX: See Documentation/arm/samsung-s3c24xx/overview.rst for full list 16 + - S3C64XX: S3C6400 and S3C6410 17 + - S5PC110 / S5PV210 18 + 19 + 20 + S3C24XX Systems 21 + --------------- 22 + 23 + There is still documentation in Documnetation/arm/Samsung-S3C24XX/ which 24 + deals with the architecture and drivers specific to these devices. 25 + 26 + See Documentation/arm/samsung-s3c24xx/overview.rst for more information 27 + on the implementation details and specific support. 28 + 29 + 30 + Configuration 31 + ------------- 32 + 33 + A number of configurations are supplied, as there is no current way of 34 + unifying all the SoCs into one kernel. 35 + 36 + s5pc110_defconfig 37 + - S5PC110 specific default configuration 38 + s5pv210_defconfig 39 + - S5PV210 specific default configuration 40 + 41 + 42 + Layout 43 + ------ 44 + 45 + The directory layout is currently being restructured, and consists of 46 + several platform directories and then the machine specific directories 47 + of the CPUs being built for. 48 + 49 + plat-samsung provides the base for all the implementations, and is the 50 + last in the line of include directories that are processed for the build 51 + specific information. It contains the base clock, GPIO and device definitions 52 + to get the system running. 53 + 54 + plat-s3c24xx is for s3c24xx specific builds, see the S3C24XX docs. 55 + 56 + plat-s5p is for s5p specific builds, and contains common support for the 57 + S5P specific systems. Not all S5Ps use all the features in this directory 58 + due to differences in the hardware. 59 + 60 + 61 + Layout changes 62 + -------------- 63 + 64 + The old plat-s3c and plat-s5pc1xx directories have been removed, with 65 + support moved to either plat-samsung or plat-s5p as necessary. These moves 66 + where to simplify the include and dependency issues involved with having 67 + so many different platform directories. 68 + 69 + 70 + Port Contributors 71 + ----------------- 72 + 73 + Ben Dooks (BJD) 74 + Vincent Sanders 75 + Herbert Potzl 76 + Arnaud Patard (RTP) 77 + Roc Wu 78 + Klaus Fetscher 79 + Dimitry Andric 80 + Shannon Holland 81 + Guillaume Gourat (NexVision) 82 + Christer Weinigel (wingel) (Acer N30) 83 + Lucas Correia Villa Real (S3C2400 port) 84 + 85 + 86 + Document Author 87 + --------------- 88 + 89 + Copyright 2009-2010 Ben Dooks <ben-linux@fluff.org>
+108
Documentation/arm/setup.rst
··· 1 + ============================================= 2 + Kernel initialisation parameters on ARM Linux 3 + ============================================= 4 + 5 + The following document describes the kernel initialisation parameter 6 + structure, otherwise known as 'struct param_struct' which is used 7 + for most ARM Linux architectures. 8 + 9 + This structure is used to pass initialisation parameters from the 10 + kernel loader to the Linux kernel proper, and may be short lived 11 + through the kernel initialisation process. As a general rule, it 12 + should not be referenced outside of arch/arm/kernel/setup.c:setup_arch(). 13 + 14 + There are a lot of parameters listed in there, and they are described 15 + below: 16 + 17 + page_size 18 + This parameter must be set to the page size of the machine, and 19 + will be checked by the kernel. 20 + 21 + nr_pages 22 + This is the total number of pages of memory in the system. If 23 + the memory is banked, then this should contain the total number 24 + of pages in the system. 25 + 26 + If the system contains separate VRAM, this value should not 27 + include this information. 28 + 29 + ramdisk_size 30 + This is now obsolete, and should not be used. 31 + 32 + flags 33 + Various kernel flags, including: 34 + 35 + ===== ======================== 36 + bit 0 1 = mount root read only 37 + bit 1 unused 38 + bit 2 0 = load ramdisk 39 + bit 3 0 = prompt for ramdisk 40 + ===== ======================== 41 + 42 + rootdev 43 + major/minor number pair of device to mount as the root filesystem. 44 + 45 + video_num_cols / video_num_rows 46 + These two together describe the character size of the dummy console, 47 + or VGA console character size. They should not be used for any other 48 + purpose. 49 + 50 + It's generally a good idea to set these to be either standard VGA, or 51 + the equivalent character size of your fbcon display. This then allows 52 + all the bootup messages to be displayed correctly. 53 + 54 + video_x / video_y 55 + This describes the character position of cursor on VGA console, and 56 + is otherwise unused. (should not be used for other console types, and 57 + should not be used for other purposes). 58 + 59 + memc_control_reg 60 + MEMC chip control register for Acorn Archimedes and Acorn A5000 61 + based machines. May be used differently by different architectures. 62 + 63 + sounddefault 64 + Default sound setting on Acorn machines. May be used differently by 65 + different architectures. 66 + 67 + adfsdrives 68 + Number of ADFS/MFM disks. May be used differently by different 69 + architectures. 70 + 71 + bytes_per_char_h / bytes_per_char_v 72 + These are now obsolete, and should not be used. 73 + 74 + pages_in_bank[4] 75 + Number of pages in each bank of the systems memory (used for RiscPC). 76 + This is intended to be used on systems where the physical memory 77 + is non-contiguous from the processors point of view. 78 + 79 + pages_in_vram 80 + Number of pages in VRAM (used on Acorn RiscPC). This value may also 81 + be used by loaders if the size of the video RAM can't be obtained 82 + from the hardware. 83 + 84 + initrd_start / initrd_size 85 + This describes the kernel virtual start address and size of the 86 + initial ramdisk. 87 + 88 + rd_start 89 + Start address in sectors of the ramdisk image on a floppy disk. 90 + 91 + system_rev 92 + system revision number. 93 + 94 + system_serial_low / system_serial_high 95 + system 64-bit serial number 96 + 97 + mem_fclk_21285 98 + The speed of the external oscillator to the 21285 (footbridge), 99 + which control's the speed of the memory bus, timer & serial port. 100 + Depending upon the speed of the cpu its value can be between 101 + 0-66 MHz. If no params are passed or a value of zero is passed, 102 + then a value of 50 Mhz is the default on 21285 architectures. 103 + 104 + paths[8][128] 105 + These are now obsolete, and should not be used. 106 + 107 + commandline 108 + Kernel command line parameters. Details can be found elsewhere.
+65
Documentation/arm/spear/overview.rst
··· 1 + ======================== 2 + SPEAr ARM Linux Overview 3 + ======================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + SPEAr (Structured Processor Enhanced Architecture). 9 + weblink : http://www.st.com/spear 10 + 11 + The ST Microelectronics SPEAr range of ARM9/CortexA9 System-on-Chip CPUs are 12 + supported by the 'spear' platform of ARM Linux. Currently SPEAr1310, 13 + SPEAr1340, SPEAr300, SPEAr310, SPEAr320 and SPEAr600 SOCs are supported. 14 + 15 + Hierarchy in SPEAr is as follows: 16 + 17 + SPEAr (Platform) 18 + - SPEAr3XX (3XX SOC series, based on ARM9) 19 + - SPEAr300 (SOC) 20 + - SPEAr300 Evaluation Board 21 + - SPEAr310 (SOC) 22 + - SPEAr310 Evaluation Board 23 + - SPEAr320 (SOC) 24 + - SPEAr320 Evaluation Board 25 + - SPEAr6XX (6XX SOC series, based on ARM9) 26 + - SPEAr600 (SOC) 27 + - SPEAr600 Evaluation Board 28 + - SPEAr13XX (13XX SOC series, based on ARM CORTEXA9) 29 + - SPEAr1310 (SOC) 30 + - SPEAr1310 Evaluation Board 31 + - SPEAr1340 (SOC) 32 + - SPEAr1340 Evaluation Board 33 + 34 + Configuration 35 + ------------- 36 + 37 + A generic configuration is provided for each machine, and can be used as the 38 + default by:: 39 + 40 + make spear13xx_defconfig 41 + make spear3xx_defconfig 42 + make spear6xx_defconfig 43 + 44 + Layout 45 + ------ 46 + 47 + The common files for multiple machine families (SPEAr3xx, SPEAr6xx and 48 + SPEAr13xx) are located in the platform code contained in arch/arm/plat-spear 49 + with headers in plat/. 50 + 51 + Each machine series have a directory with name arch/arm/mach-spear followed by 52 + series name. Like mach-spear3xx, mach-spear6xx and mach-spear13xx. 53 + 54 + Common file for machines of spear3xx family is mach-spear3xx/spear3xx.c, for 55 + spear6xx is mach-spear6xx/spear6xx.c and for spear13xx family is 56 + mach-spear13xx/spear13xx.c. mach-spear* also contain soc/machine specific 57 + files, like spear1310.c, spear1340.c spear300.c, spear310.c, spear320.c and 58 + spear600.c. mach-spear* doesn't contains board specific files as they fully 59 + support Flattened Device Tree. 60 + 61 + 62 + Document Author 63 + --------------- 64 + 65 + Viresh Kumar <vireshk@kernel.org>, (c) 2010-2012 ST Microelectronics
+36
Documentation/arm/sti/overview.rst
··· 1 + ====================== 2 + STi ARM Linux Overview 3 + ====================== 4 + 5 + Introduction 6 + ------------ 7 + 8 + The ST Microelectronics Multimedia and Application Processors range of 9 + CortexA9 System-on-Chip are supported by the 'STi' platform of 10 + ARM Linux. Currently STiH415, STiH416 SOCs are supported with both 11 + B2000 and B2020 Reference boards. 12 + 13 + 14 + configuration 15 + ------------- 16 + 17 + A generic configuration is provided for both STiH415/416, and can be used as the 18 + default by:: 19 + 20 + make stih41x_defconfig 21 + 22 + Layout 23 + ------ 24 + 25 + All the files for multiple machine families (STiH415, STiH416, and STiG125) 26 + are located in the platform code contained in arch/arm/mach-sti 27 + 28 + There is a generic board board-dt.c in the mach folder which support 29 + Flattened Device Tree, which means, It works with any compatible board with 30 + Device Trees. 31 + 32 + 33 + Document Author 34 + --------------- 35 + 36 + Srinivas Kandagatla <srinivas.kandagatla@st.com>, (c) 2013 ST Microelectronics
-33
Documentation/arm/sti/overview.txt
··· 1 - STi ARM Linux Overview 2 - ========================== 3 - 4 - Introduction 5 - ------------ 6 - 7 - The ST Microelectronics Multimedia and Application Processors range of 8 - CortexA9 System-on-Chip are supported by the 'STi' platform of 9 - ARM Linux. Currently STiH415, STiH416 SOCs are supported with both 10 - B2000 and B2020 Reference boards. 11 - 12 - 13 - configuration 14 - ------------- 15 - 16 - A generic configuration is provided for both STiH415/416, and can be used as the 17 - default by 18 - make stih41x_defconfig 19 - 20 - Layout 21 - ------ 22 - All the files for multiple machine families (STiH415, STiH416, and STiG125) 23 - are located in the platform code contained in arch/arm/mach-sti 24 - 25 - There is a generic board board-dt.c in the mach folder which support 26 - Flattened Device Tree, which means, It works with any compatible board with 27 - Device Trees. 28 - 29 - 30 - Document Author 31 - --------------- 32 - 33 - Srinivas Kandagatla <srinivas.kandagatla@st.com>, (c) 2013 ST Microelectronics
+19
Documentation/arm/sti/stih407-overview.rst
··· 1 + ================ 2 + STiH407 Overview 3 + ================ 4 + 5 + Introduction 6 + ------------ 7 + 8 + The STiH407 is the new generation of SoC for Multi-HD, AVC set-top boxes 9 + and server/connected client application for satellite, cable, terrestrial 10 + and IP-STB markets. 11 + 12 + Features 13 + - ARM Cortex-A9 1.5 GHz dual core CPU (28nm) 14 + - SATA2, USB 3.0, PCIe, Gbit Ethernet 15 + 16 + Document Author 17 + --------------- 18 + 19 + Maxime Coquelin <maxime.coquelin@st.com>, (c) 2014 ST Microelectronics
-18
Documentation/arm/sti/stih407-overview.txt
··· 1 - STiH407 Overview 2 - ================ 3 - 4 - Introduction 5 - ------------ 6 - 7 - The STiH407 is the new generation of SoC for Multi-HD, AVC set-top boxes 8 - and server/connected client application for satellite, cable, terrestrial 9 - and IP-STB markets. 10 - 11 - Features 12 - - ARM Cortex-A9 1.5 GHz dual core CPU (28nm) 13 - - SATA2, USB 3.0, PCIe, Gbit Ethernet 14 - 15 - Document Author 16 - --------------- 17 - 18 - Maxime Coquelin <maxime.coquelin@st.com>, (c) 2014 ST Microelectronics
+14
Documentation/arm/sti/stih415-overview.rst
··· 1 + ================ 2 + STiH415 Overview 3 + ================ 4 + 5 + Introduction 6 + ------------ 7 + 8 + The STiH415 is the next generation of HD, AVC set-top box processors 9 + for satellite, cable, terrestrial and IP-STB markets. 10 + 11 + Features: 12 + 13 + - ARM Cortex-A9 1.0 GHz, dual-core CPU 14 + - SATA2x2,USB 2.0x3, PCIe, Gbit Ethernet MACx2
-12
Documentation/arm/sti/stih415-overview.txt
··· 1 - STiH415 Overview 2 - ================ 3 - 4 - Introduction 5 - ------------ 6 - 7 - The STiH415 is the next generation of HD, AVC set-top box processors 8 - for satellite, cable, terrestrial and IP-STB markets. 9 - 10 - Features 11 - - ARM Cortex-A9 1.0 GHz, dual-core CPU 12 - - SATA2x2,USB 2.0x3, PCIe, Gbit Ethernet MACx2
+13
Documentation/arm/sti/stih416-overview.rst
··· 1 + ================ 2 + STiH416 Overview 3 + ================ 4 + 5 + Introduction 6 + ------------ 7 + 8 + The STiH416 is the next generation of HD, AVC set-top box processors 9 + for satellite, cable, terrestrial and IP-STB markets. 10 + 11 + Features 12 + - ARM Cortex-A9 1.2 GHz dual core CPU 13 + - SATA2x2,USB 2.0x3, PCIe, Gbit Ethernet MACx2
-12
Documentation/arm/sti/stih416-overview.txt
··· 1 - STiH416 Overview 2 - ================ 3 - 4 - Introduction 5 - ------------ 6 - 7 - The STiH416 is the next generation of HD, AVC set-top box processors 8 - for satellite, cable, terrestrial and IP-STB markets. 9 - 10 - Features 11 - - ARM Cortex-A9 1.2 GHz dual core CPU 12 - - SATA2x2,USB 2.0x3, PCIe, Gbit Ethernet MACx2
+21
Documentation/arm/sti/stih418-overview.rst
··· 1 + ================ 2 + STiH418 Overview 3 + ================ 4 + 5 + Introduction 6 + ------------ 7 + 8 + The STiH418 is the new generation of SoC for UHDp60 set-top boxes 9 + and server/connected client application for satellite, cable, terrestrial 10 + and IP-STB markets. 11 + 12 + Features 13 + - ARM Cortex-A9 1.5 GHz quad core CPU (28nm) 14 + - SATA2, USB 3.0, PCIe, Gbit Ethernet 15 + - HEVC L5.1 Main 10 16 + - VP9 17 + 18 + Document Author 19 + --------------- 20 + 21 + Maxime Coquelin <maxime.coquelin@st.com>, (c) 2015 ST Microelectronics
-20
Documentation/arm/sti/stih418-overview.txt
··· 1 - STiH418 Overview 2 - ================ 3 - 4 - Introduction 5 - ------------ 6 - 7 - The STiH418 is the new generation of SoC for UHDp60 set-top boxes 8 - and server/connected client application for satellite, cable, terrestrial 9 - and IP-STB markets. 10 - 11 - Features 12 - - ARM Cortex-A9 1.5 GHz quad core CPU (28nm) 13 - - SATA2, USB 3.0, PCIe, Gbit Ethernet 14 - - HEVC L5.1 Main 10 15 - - VP9 16 - 17 - Document Author 18 - --------------- 19 - 20 - Maxime Coquelin <maxime.coquelin@st.com>, (c) 2015 ST Microelectronics
-2
Documentation/arm/stm32/overview.rst
··· 1 - :orphan: 2 - 3 1 ======================== 4 2 STM32 ARM Linux Overview 5 3 ========================
+2 -5
Documentation/arm/stm32/stm32f429-overview.rst
··· 1 - :orphan: 2 - 1 + ================== 3 2 STM32F429 Overview 4 3 ================== 5 4 ··· 22 23 23 24 .. _STM32F429: http://www.st.com/web/en/catalog/mmc/FM141/SC1169/SS1577/LN1806?ecmp=stm32f429-439_pron_pr-ces2014_nov2013 24 25 25 - :Authors: 26 - 27 - Maxime Coquelin <mcoquelin.stm32@gmail.com> 26 + :Authors: Maxime Coquelin <mcoquelin.stm32@gmail.com>
+2 -5
Documentation/arm/stm32/stm32f746-overview.rst
··· 1 - :orphan: 2 - 1 + ================== 3 2 STM32F746 Overview 4 3 ================== 5 4 ··· 29 30 30 31 .. _STM32F746: http://www.st.com/content/st_com/en/products/microcontrollers/stm32-32-bit-arm-cortex-mcus/stm32f7-series/stm32f7x6/stm32f746ng.html 31 32 32 - :Authors: 33 - 34 - Alexandre Torgue <alexandre.torgue@st.com> 33 + :Authors: Alexandre Torgue <alexandre.torgue@st.com>
+2 -5
Documentation/arm/stm32/stm32f769-overview.rst
··· 1 - :orphan: 2 - 1 + ================== 3 2 STM32F769 Overview 4 3 ================== 5 4 ··· 31 32 32 33 .. _STM32F769: http://www.st.com/content/st_com/en/products/microcontrollers/stm32-32-bit-arm-cortex-mcus/stm32-high-performance-mcus/stm32f7-series/stm32f7x9/stm32f769ni.html 33 34 34 - :Authors: 35 - 36 - Alexandre Torgue <alexandre.torgue@st.com> 35 + :Authors: Alexandre Torgue <alexandre.torgue@st.com>
+2 -5
Documentation/arm/stm32/stm32h743-overview.rst
··· 1 - :orphan: 2 - 1 + ================== 3 2 STM32H743 Overview 4 3 ================== 5 4 ··· 30 31 31 32 .. _STM32H743: http://www.st.com/en/microcontrollers/stm32h7x3.html?querycriteria=productId=LN2033 32 33 33 - :Authors: 34 - 35 - Alexandre Torgue <alexandre.torgue@st.com> 34 + :Authors: Alexandre Torgue <alexandre.torgue@st.com>
+1 -2
Documentation/arm/stm32/stm32mp157-overview.rst
··· 1 - :orphan: 2 - 1 + =================== 3 2 STM32MP157 Overview 4 3 =================== 5 4
+150
Documentation/arm/sunxi.rst
··· 1 + ================== 2 + ARM Allwinner SoCs 3 + ================== 4 + 5 + This document lists all the ARM Allwinner SoCs that are currently 6 + supported in mainline by the Linux kernel. This document will also 7 + provide links to documentation and/or datasheet for these SoCs. 8 + 9 + SunXi family 10 + ------------ 11 + Linux kernel mach directory: arch/arm/mach-sunxi 12 + 13 + Flavors: 14 + 15 + * ARM926 based SoCs 16 + - Allwinner F20 (sun3i) 17 + 18 + * Not Supported 19 + 20 + * ARM Cortex-A8 based SoCs 21 + - Allwinner A10 (sun4i) 22 + 23 + * Datasheet 24 + 25 + http://dl.linux-sunxi.org/A10/A10%20Datasheet%20-%20v1.21%20%282012-04-06%29.pdf 26 + * User Manual 27 + 28 + http://dl.linux-sunxi.org/A10/A10%20User%20Manual%20-%20v1.20%20%282012-04-09%2c%20DECRYPTED%29.pdf 29 + 30 + - Allwinner A10s (sun5i) 31 + 32 + * Datasheet 33 + 34 + http://dl.linux-sunxi.org/A10s/A10s%20Datasheet%20-%20v1.20%20%282012-03-27%29.pdf 35 + 36 + - Allwinner A13 / R8 (sun5i) 37 + 38 + * Datasheet 39 + 40 + http://dl.linux-sunxi.org/A13/A13%20Datasheet%20-%20v1.12%20%282012-03-29%29.pdf 41 + * User Manual 42 + 43 + http://dl.linux-sunxi.org/A13/A13%20User%20Manual%20-%20v1.2%20%282013-01-08%29.pdf 44 + 45 + - Next Thing Co GR8 (sun5i) 46 + 47 + * Single ARM Cortex-A7 based SoCs 48 + - Allwinner V3s (sun8i) 49 + 50 + * Datasheet 51 + 52 + http://linux-sunxi.org/File:Allwinner_V3s_Datasheet_V1.0.pdf 53 + 54 + * Dual ARM Cortex-A7 based SoCs 55 + - Allwinner A20 (sun7i) 56 + 57 + * User Manual 58 + 59 + http://dl.linux-sunxi.org/A20/A20%20User%20Manual%202013-03-22.pdf 60 + 61 + - Allwinner A23 (sun8i) 62 + 63 + * Datasheet 64 + 65 + http://dl.linux-sunxi.org/A23/A23%20Datasheet%20V1.0%2020130830.pdf 66 + 67 + * User Manual 68 + 69 + http://dl.linux-sunxi.org/A23/A23%20User%20Manual%20V1.0%2020130830.pdf 70 + 71 + * Quad ARM Cortex-A7 based SoCs 72 + - Allwinner A31 (sun6i) 73 + 74 + * Datasheet 75 + 76 + http://dl.linux-sunxi.org/A31/A3x_release_document/A31/IC/A31%20datasheet%20V1.3%2020131106.pdf 77 + 78 + * User Manual 79 + 80 + http://dl.linux-sunxi.org/A31/A3x_release_document/A31/IC/A31%20user%20manual%20V1.1%2020130630.pdf 81 + 82 + - Allwinner A31s (sun6i) 83 + 84 + * Datasheet 85 + 86 + http://dl.linux-sunxi.org/A31/A3x_release_document/A31s/IC/A31s%20datasheet%20V1.3%2020131106.pdf 87 + 88 + * User Manual 89 + 90 + http://dl.linux-sunxi.org/A31/A3x_release_document/A31s/IC/A31s%20User%20Manual%20%20V1.0%2020130322.pdf 91 + 92 + - Allwinner A33 (sun8i) 93 + 94 + * Datasheet 95 + 96 + http://dl.linux-sunxi.org/A33/A33%20Datasheet%20release%201.1.pdf 97 + 98 + * User Manual 99 + 100 + http://dl.linux-sunxi.org/A33/A33%20user%20manual%20release%201.1.pdf 101 + 102 + - Allwinner H2+ (sun8i) 103 + 104 + * No document available now, but is known to be working properly with 105 + H3 drivers and memory map. 106 + 107 + - Allwinner H3 (sun8i) 108 + 109 + * Datasheet 110 + 111 + http://dl.linux-sunxi.org/H3/Allwinner_H3_Datasheet_V1.0.pdf 112 + 113 + - Allwinner R40 (sun8i) 114 + 115 + * Datasheet 116 + 117 + https://github.com/tinalinux/docs/raw/r40-v1.y/R40_Datasheet_V1.0.pdf 118 + 119 + * User Manual 120 + 121 + https://github.com/tinalinux/docs/raw/r40-v1.y/Allwinner_R40_User_Manual_V1.0.pdf 122 + 123 + * Quad ARM Cortex-A15, Quad ARM Cortex-A7 based SoCs 124 + - Allwinner A80 125 + 126 + * Datasheet 127 + 128 + http://dl.linux-sunxi.org/A80/A80_Datasheet_Revision_1.0_0404.pdf 129 + 130 + * Octa ARM Cortex-A7 based SoCs 131 + - Allwinner A83T 132 + 133 + * Datasheet 134 + 135 + https://github.com/allwinner-zh/documents/raw/master/A83T/A83T_Datasheet_v1.3_20150510.pdf 136 + 137 + * User Manual 138 + 139 + https://github.com/allwinner-zh/documents/raw/master/A83T/A83T_User_Manual_v1.5.1_20150513.pdf 140 + 141 + * Quad ARM Cortex-A53 based SoCs 142 + - Allwinner A64 143 + 144 + * Datasheet 145 + 146 + http://dl.linux-sunxi.org/A64/A64_Datasheet_V1.1.pdf 147 + 148 + * User Manual 149 + 150 + http://dl.linux-sunxi.org/A64/Allwinner%20A64%20User%20Manual%20v1.0.pdf
-102
Documentation/arm/sunxi/README
··· 1 - ARM Allwinner SoCs 2 - ================== 3 - 4 - This document lists all the ARM Allwinner SoCs that are currently 5 - supported in mainline by the Linux kernel. This document will also 6 - provide links to documentation and/or datasheet for these SoCs. 7 - 8 - SunXi family 9 - ------------ 10 - Linux kernel mach directory: arch/arm/mach-sunxi 11 - 12 - Flavors: 13 - * ARM926 based SoCs 14 - - Allwinner F20 (sun3i) 15 - + Not Supported 16 - 17 - * ARM Cortex-A8 based SoCs 18 - - Allwinner A10 (sun4i) 19 - + Datasheet 20 - http://dl.linux-sunxi.org/A10/A10%20Datasheet%20-%20v1.21%20%282012-04-06%29.pdf 21 - + User Manual 22 - http://dl.linux-sunxi.org/A10/A10%20User%20Manual%20-%20v1.20%20%282012-04-09%2c%20DECRYPTED%29.pdf 23 - 24 - - Allwinner A10s (sun5i) 25 - + Datasheet 26 - http://dl.linux-sunxi.org/A10s/A10s%20Datasheet%20-%20v1.20%20%282012-03-27%29.pdf 27 - 28 - - Allwinner A13 / R8 (sun5i) 29 - + Datasheet 30 - http://dl.linux-sunxi.org/A13/A13%20Datasheet%20-%20v1.12%20%282012-03-29%29.pdf 31 - + User Manual 32 - http://dl.linux-sunxi.org/A13/A13%20User%20Manual%20-%20v1.2%20%282013-01-08%29.pdf 33 - 34 - - Next Thing Co GR8 (sun5i) 35 - 36 - * Single ARM Cortex-A7 based SoCs 37 - - Allwinner V3s (sun8i) 38 - + Datasheet 39 - http://linux-sunxi.org/File:Allwinner_V3s_Datasheet_V1.0.pdf 40 - 41 - * Dual ARM Cortex-A7 based SoCs 42 - - Allwinner A20 (sun7i) 43 - + User Manual 44 - http://dl.linux-sunxi.org/A20/A20%20User%20Manual%202013-03-22.pdf 45 - 46 - - Allwinner A23 (sun8i) 47 - + Datasheet 48 - http://dl.linux-sunxi.org/A23/A23%20Datasheet%20V1.0%2020130830.pdf 49 - + User Manual 50 - http://dl.linux-sunxi.org/A23/A23%20User%20Manual%20V1.0%2020130830.pdf 51 - 52 - * Quad ARM Cortex-A7 based SoCs 53 - - Allwinner A31 (sun6i) 54 - + Datasheet 55 - http://dl.linux-sunxi.org/A31/A3x_release_document/A31/IC/A31%20datasheet%20V1.3%2020131106.pdf 56 - + User Manual 57 - http://dl.linux-sunxi.org/A31/A3x_release_document/A31/IC/A31%20user%20manual%20V1.1%2020130630.pdf 58 - 59 - - Allwinner A31s (sun6i) 60 - + Datasheet 61 - http://dl.linux-sunxi.org/A31/A3x_release_document/A31s/IC/A31s%20datasheet%20V1.3%2020131106.pdf 62 - + User Manual 63 - http://dl.linux-sunxi.org/A31/A3x_release_document/A31s/IC/A31s%20User%20Manual%20%20V1.0%2020130322.pdf 64 - 65 - - Allwinner A33 (sun8i) 66 - + Datasheet 67 - http://dl.linux-sunxi.org/A33/A33%20Datasheet%20release%201.1.pdf 68 - + User Manual 69 - http://dl.linux-sunxi.org/A33/A33%20user%20manual%20release%201.1.pdf 70 - 71 - - Allwinner H2+ (sun8i) 72 - + No document available now, but is known to be working properly with 73 - H3 drivers and memory map. 74 - 75 - - Allwinner H3 (sun8i) 76 - + Datasheet 77 - http://dl.linux-sunxi.org/H3/Allwinner_H3_Datasheet_V1.0.pdf 78 - 79 - - Allwinner R40 (sun8i) 80 - + Datasheet 81 - https://github.com/tinalinux/docs/raw/r40-v1.y/R40_Datasheet_V1.0.pdf 82 - + User Manual 83 - https://github.com/tinalinux/docs/raw/r40-v1.y/Allwinner_R40_User_Manual_V1.0.pdf 84 - 85 - * Quad ARM Cortex-A15, Quad ARM Cortex-A7 based SoCs 86 - - Allwinner A80 87 - + Datasheet 88 - http://dl.linux-sunxi.org/A80/A80_Datasheet_Revision_1.0_0404.pdf 89 - 90 - * Octa ARM Cortex-A7 based SoCs 91 - - Allwinner A83T 92 - + Datasheet 93 - https://github.com/allwinner-zh/documents/raw/master/A83T/A83T_Datasheet_v1.3_20150510.pdf 94 - + User Manual 95 - https://github.com/allwinner-zh/documents/raw/master/A83T/A83T_User_Manual_v1.5.1_20150513.pdf 96 - 97 - * Quad ARM Cortex-A53 based SoCs 98 - - Allwinner A64 99 - + Datasheet 100 - http://dl.linux-sunxi.org/A64/A64_Datasheet_V1.1.pdf 101 - + User Manual 102 - http://dl.linux-sunxi.org/A64/Allwinner%20A64%20User%20Manual%20v1.0.pdf
+57
Documentation/arm/sunxi/clocks.rst
··· 1 + ======================================================= 2 + Frequently asked questions about the sunxi clock system 3 + ======================================================= 4 + 5 + This document contains useful bits of information that people tend to ask 6 + about the sunxi clock system, as well as accompanying ASCII art when adequate. 7 + 8 + Q: Why is the main 24MHz oscillator gatable? Wouldn't that break the 9 + system? 10 + 11 + A: The 24MHz oscillator allows gating to save power. Indeed, if gated 12 + carelessly the system would stop functioning, but with the right 13 + steps, one can gate it and keep the system running. Consider this 14 + simplified suspend example: 15 + 16 + While the system is operational, you would see something like:: 17 + 18 + 24MHz 32kHz 19 + | 20 + PLL1 21 + \ 22 + \_ CPU Mux 23 + | 24 + [CPU] 25 + 26 + When you are about to suspend, you switch the CPU Mux to the 32kHz 27 + oscillator:: 28 + 29 + 24Mhz 32kHz 30 + | | 31 + PLL1 | 32 + / 33 + CPU Mux _/ 34 + | 35 + [CPU] 36 + 37 + Finally you can gate the main oscillator:: 38 + 39 + 32kHz 40 + | 41 + | 42 + / 43 + CPU Mux _/ 44 + | 45 + [CPU] 46 + 47 + Q: Were can I learn more about the sunxi clocks? 48 + 49 + A: The linux-sunxi wiki contains a page documenting the clock registers, 50 + you can find it at 51 + 52 + http://linux-sunxi.org/A10/CCM 53 + 54 + The authoritative source for information at this time is the ccmu driver 55 + released by Allwinner, you can find it at 56 + 57 + https://github.com/linux-sunxi/linux-sunxi/tree/sunxi-3.0/arch/arm/mach-sun4i/clock/ccmu
-56
Documentation/arm/sunxi/clocks.txt
··· 1 - Frequently asked questions about the sunxi clock system 2 - ======================================================= 3 - 4 - This document contains useful bits of information that people tend to ask 5 - about the sunxi clock system, as well as accompanying ASCII art when adequate. 6 - 7 - Q: Why is the main 24MHz oscillator gatable? Wouldn't that break the 8 - system? 9 - 10 - A: The 24MHz oscillator allows gating to save power. Indeed, if gated 11 - carelessly the system would stop functioning, but with the right 12 - steps, one can gate it and keep the system running. Consider this 13 - simplified suspend example: 14 - 15 - While the system is operational, you would see something like 16 - 17 - 24MHz 32kHz 18 - | 19 - PLL1 20 - \ 21 - \_ CPU Mux 22 - | 23 - [CPU] 24 - 25 - When you are about to suspend, you switch the CPU Mux to the 32kHz 26 - oscillator: 27 - 28 - 24Mhz 32kHz 29 - | | 30 - PLL1 | 31 - / 32 - CPU Mux _/ 33 - | 34 - [CPU] 35 - 36 - Finally you can gate the main oscillator 37 - 38 - 32kHz 39 - | 40 - | 41 - / 42 - CPU Mux _/ 43 - | 44 - [CPU] 45 - 46 - Q: Were can I learn more about the sunxi clocks? 47 - 48 - A: The linux-sunxi wiki contains a page documenting the clock registers, 49 - you can find it at 50 - 51 - http://linux-sunxi.org/A10/CCM 52 - 53 - The authoritative source for information at this time is the ccmu driver 54 - released by Allwinner, you can find it at 55 - 56 - https://github.com/linux-sunxi/linux-sunxi/tree/sunxi-3.0/arch/arm/mach-sun4i/clock/ccmu
-27
Documentation/arm/swp_emulation
··· 1 - Software emulation of deprecated SWP instruction (CONFIG_SWP_EMULATE) 2 - --------------------------------------------------------------------- 3 - 4 - ARMv6 architecture deprecates use of the SWP/SWPB instructions, and recommeds 5 - moving to the load-locked/store-conditional instructions LDREX and STREX. 6 - 7 - ARMv7 multiprocessing extensions introduce the ability to disable these 8 - instructions, triggering an undefined instruction exception when executed. 9 - Trapped instructions are emulated using an LDREX/STREX or LDREXB/STREXB 10 - sequence. If a memory access fault (an abort) occurs, a segmentation fault is 11 - signalled to the triggering process. 12 - 13 - /proc/cpu/swp_emulation holds some statistics/information, including the PID of 14 - the last process to trigger the emulation to be invocated. For example: 15 - --- 16 - Emulated SWP: 12 17 - Emulated SWPB: 0 18 - Aborted SWP{B}: 1 19 - Last process: 314 20 - --- 21 - 22 - NOTE: when accessing uncached shared regions, LDREX/STREX rely on an external 23 - transaction monitoring block called a global monitor to maintain update 24 - atomicity. If your system does not implement a global monitor, this option can 25 - cause programs that perform SWP operations to uncached memory to deadlock, as 26 - the STREX operation will always fail. 27 -
+27
Documentation/arm/swp_emulation.rst
··· 1 + Software emulation of deprecated SWP instruction (CONFIG_SWP_EMULATE) 2 + --------------------------------------------------------------------- 3 + 4 + ARMv6 architecture deprecates use of the SWP/SWPB instructions, and recommeds 5 + moving to the load-locked/store-conditional instructions LDREX and STREX. 6 + 7 + ARMv7 multiprocessing extensions introduce the ability to disable these 8 + instructions, triggering an undefined instruction exception when executed. 9 + Trapped instructions are emulated using an LDREX/STREX or LDREXB/STREXB 10 + sequence. If a memory access fault (an abort) occurs, a segmentation fault is 11 + signalled to the triggering process. 12 + 13 + /proc/cpu/swp_emulation holds some statistics/information, including the PID of 14 + the last process to trigger the emulation to be invocated. For example:: 15 + 16 + Emulated SWP: 12 17 + Emulated SWPB: 0 18 + Aborted SWP{B}: 1 19 + Last process: 314 20 + 21 + 22 + NOTE: 23 + when accessing uncached shared regions, LDREX/STREX rely on an external 24 + transaction monitoring block called a global monitor to maintain update 25 + atomicity. If your system does not implement a global monitor, this option can 26 + cause programs that perform SWP operations to uncached memory to deadlock, as 27 + the STREX operation will always fail.
+161
Documentation/arm/tcm.rst
··· 1 + ================================================== 2 + ARM TCM (Tightly-Coupled Memory) handling in Linux 3 + ================================================== 4 + 5 + Written by Linus Walleij <linus.walleij@stericsson.com> 6 + 7 + Some ARM SoC:s have a so-called TCM (Tightly-Coupled Memory). 8 + This is usually just a few (4-64) KiB of RAM inside the ARM 9 + processor. 10 + 11 + Due to being embedded inside the CPU The TCM has a 12 + Harvard-architecture, so there is an ITCM (instruction TCM) 13 + and a DTCM (data TCM). The DTCM can not contain any 14 + instructions, but the ITCM can actually contain data. 15 + The size of DTCM or ITCM is minimum 4KiB so the typical 16 + minimum configuration is 4KiB ITCM and 4KiB DTCM. 17 + 18 + ARM CPU:s have special registers to read out status, physical 19 + location and size of TCM memories. arch/arm/include/asm/cputype.h 20 + defines a CPUID_TCM register that you can read out from the 21 + system control coprocessor. Documentation from ARM can be found 22 + at http://infocenter.arm.com, search for "TCM Status Register" 23 + to see documents for all CPUs. Reading this register you can 24 + determine if ITCM (bits 1-0) and/or DTCM (bit 17-16) is present 25 + in the machine. 26 + 27 + There is further a TCM region register (search for "TCM Region 28 + Registers" at the ARM site) that can report and modify the location 29 + size of TCM memories at runtime. This is used to read out and modify 30 + TCM location and size. Notice that this is not a MMU table: you 31 + actually move the physical location of the TCM around. At the 32 + place you put it, it will mask any underlying RAM from the 33 + CPU so it is usually wise not to overlap any physical RAM with 34 + the TCM. 35 + 36 + The TCM memory can then be remapped to another address again using 37 + the MMU, but notice that the TCM if often used in situations where 38 + the MMU is turned off. To avoid confusion the current Linux 39 + implementation will map the TCM 1 to 1 from physical to virtual 40 + memory in the location specified by the kernel. Currently Linux 41 + will map ITCM to 0xfffe0000 and on, and DTCM to 0xfffe8000 and 42 + on, supporting a maximum of 32KiB of ITCM and 32KiB of DTCM. 43 + 44 + Newer versions of the region registers also support dividing these 45 + TCMs in two separate banks, so for example an 8KiB ITCM is divided 46 + into two 4KiB banks with its own control registers. The idea is to 47 + be able to lock and hide one of the banks for use by the secure 48 + world (TrustZone). 49 + 50 + TCM is used for a few things: 51 + 52 + - FIQ and other interrupt handlers that need deterministic 53 + timing and cannot wait for cache misses. 54 + 55 + - Idle loops where all external RAM is set to self-refresh 56 + retention mode, so only on-chip RAM is accessible by 57 + the CPU and then we hang inside ITCM waiting for an 58 + interrupt. 59 + 60 + - Other operations which implies shutting off or reconfiguring 61 + the external RAM controller. 62 + 63 + There is an interface for using TCM on the ARM architecture 64 + in <asm/tcm.h>. Using this interface it is possible to: 65 + 66 + - Define the physical address and size of ITCM and DTCM. 67 + 68 + - Tag functions to be compiled into ITCM. 69 + 70 + - Tag data and constants to be allocated to DTCM and ITCM. 71 + 72 + - Have the remaining TCM RAM added to a special 73 + allocation pool with gen_pool_create() and gen_pool_add() 74 + and provice tcm_alloc() and tcm_free() for this 75 + memory. Such a heap is great for things like saving 76 + device state when shutting off device power domains. 77 + 78 + A machine that has TCM memory shall select HAVE_TCM from 79 + arch/arm/Kconfig for itself. Code that needs to use TCM shall 80 + #include <asm/tcm.h> 81 + 82 + Functions to go into itcm can be tagged like this: 83 + int __tcmfunc foo(int bar); 84 + 85 + Since these are marked to become long_calls and you may want 86 + to have functions called locally inside the TCM without 87 + wasting space, there is also the __tcmlocalfunc prefix that 88 + will make the call relative. 89 + 90 + Variables to go into dtcm can be tagged like this:: 91 + 92 + int __tcmdata foo; 93 + 94 + Constants can be tagged like this:: 95 + 96 + int __tcmconst foo; 97 + 98 + To put assembler into TCM just use:: 99 + 100 + .section ".tcm.text" or .section ".tcm.data" 101 + 102 + respectively. 103 + 104 + Example code:: 105 + 106 + #include <asm/tcm.h> 107 + 108 + /* Uninitialized data */ 109 + static u32 __tcmdata tcmvar; 110 + /* Initialized data */ 111 + static u32 __tcmdata tcmassigned = 0x2BADBABEU; 112 + /* Constant */ 113 + static const u32 __tcmconst tcmconst = 0xCAFEBABEU; 114 + 115 + static void __tcmlocalfunc tcm_to_tcm(void) 116 + { 117 + int i; 118 + for (i = 0; i < 100; i++) 119 + tcmvar ++; 120 + } 121 + 122 + static void __tcmfunc hello_tcm(void) 123 + { 124 + /* Some abstract code that runs in ITCM */ 125 + int i; 126 + for (i = 0; i < 100; i++) { 127 + tcmvar ++; 128 + } 129 + tcm_to_tcm(); 130 + } 131 + 132 + static void __init test_tcm(void) 133 + { 134 + u32 *tcmem; 135 + int i; 136 + 137 + hello_tcm(); 138 + printk("Hello TCM executed from ITCM RAM\n"); 139 + 140 + printk("TCM variable from testrun: %u @ %p\n", tcmvar, &tcmvar); 141 + tcmvar = 0xDEADBEEFU; 142 + printk("TCM variable: 0x%x @ %p\n", tcmvar, &tcmvar); 143 + 144 + printk("TCM assigned variable: 0x%x @ %p\n", tcmassigned, &tcmassigned); 145 + 146 + printk("TCM constant: 0x%x @ %p\n", tcmconst, &tcmconst); 147 + 148 + /* Allocate some TCM memory from the pool */ 149 + tcmem = tcm_alloc(20); 150 + if (tcmem) { 151 + printk("TCM Allocated 20 bytes of TCM @ %p\n", tcmem); 152 + tcmem[0] = 0xDEADBEEFU; 153 + tcmem[1] = 0x2BADBABEU; 154 + tcmem[2] = 0xCAFEBABEU; 155 + tcmem[3] = 0xDEADBEEFU; 156 + tcmem[4] = 0x2BADBABEU; 157 + for (i = 0; i < 5; i++) 158 + printk("TCM tcmem[%d] = %08x\n", i, tcmem[i]); 159 + tcm_free(tcmem, 20); 160 + } 161 + }
-155
Documentation/arm/tcm.txt
··· 1 - ARM TCM (Tightly-Coupled Memory) handling in Linux 2 - ---- 3 - Written by Linus Walleij <linus.walleij@stericsson.com> 4 - 5 - Some ARM SoC:s have a so-called TCM (Tightly-Coupled Memory). 6 - This is usually just a few (4-64) KiB of RAM inside the ARM 7 - processor. 8 - 9 - Due to being embedded inside the CPU The TCM has a 10 - Harvard-architecture, so there is an ITCM (instruction TCM) 11 - and a DTCM (data TCM). The DTCM can not contain any 12 - instructions, but the ITCM can actually contain data. 13 - The size of DTCM or ITCM is minimum 4KiB so the typical 14 - minimum configuration is 4KiB ITCM and 4KiB DTCM. 15 - 16 - ARM CPU:s have special registers to read out status, physical 17 - location and size of TCM memories. arch/arm/include/asm/cputype.h 18 - defines a CPUID_TCM register that you can read out from the 19 - system control coprocessor. Documentation from ARM can be found 20 - at http://infocenter.arm.com, search for "TCM Status Register" 21 - to see documents for all CPUs. Reading this register you can 22 - determine if ITCM (bits 1-0) and/or DTCM (bit 17-16) is present 23 - in the machine. 24 - 25 - There is further a TCM region register (search for "TCM Region 26 - Registers" at the ARM site) that can report and modify the location 27 - size of TCM memories at runtime. This is used to read out and modify 28 - TCM location and size. Notice that this is not a MMU table: you 29 - actually move the physical location of the TCM around. At the 30 - place you put it, it will mask any underlying RAM from the 31 - CPU so it is usually wise not to overlap any physical RAM with 32 - the TCM. 33 - 34 - The TCM memory can then be remapped to another address again using 35 - the MMU, but notice that the TCM if often used in situations where 36 - the MMU is turned off. To avoid confusion the current Linux 37 - implementation will map the TCM 1 to 1 from physical to virtual 38 - memory in the location specified by the kernel. Currently Linux 39 - will map ITCM to 0xfffe0000 and on, and DTCM to 0xfffe8000 and 40 - on, supporting a maximum of 32KiB of ITCM and 32KiB of DTCM. 41 - 42 - Newer versions of the region registers also support dividing these 43 - TCMs in two separate banks, so for example an 8KiB ITCM is divided 44 - into two 4KiB banks with its own control registers. The idea is to 45 - be able to lock and hide one of the banks for use by the secure 46 - world (TrustZone). 47 - 48 - TCM is used for a few things: 49 - 50 - - FIQ and other interrupt handlers that need deterministic 51 - timing and cannot wait for cache misses. 52 - 53 - - Idle loops where all external RAM is set to self-refresh 54 - retention mode, so only on-chip RAM is accessible by 55 - the CPU and then we hang inside ITCM waiting for an 56 - interrupt. 57 - 58 - - Other operations which implies shutting off or reconfiguring 59 - the external RAM controller. 60 - 61 - There is an interface for using TCM on the ARM architecture 62 - in <asm/tcm.h>. Using this interface it is possible to: 63 - 64 - - Define the physical address and size of ITCM and DTCM. 65 - 66 - - Tag functions to be compiled into ITCM. 67 - 68 - - Tag data and constants to be allocated to DTCM and ITCM. 69 - 70 - - Have the remaining TCM RAM added to a special 71 - allocation pool with gen_pool_create() and gen_pool_add() 72 - and provice tcm_alloc() and tcm_free() for this 73 - memory. Such a heap is great for things like saving 74 - device state when shutting off device power domains. 75 - 76 - A machine that has TCM memory shall select HAVE_TCM from 77 - arch/arm/Kconfig for itself. Code that needs to use TCM shall 78 - #include <asm/tcm.h> 79 - 80 - Functions to go into itcm can be tagged like this: 81 - int __tcmfunc foo(int bar); 82 - 83 - Since these are marked to become long_calls and you may want 84 - to have functions called locally inside the TCM without 85 - wasting space, there is also the __tcmlocalfunc prefix that 86 - will make the call relative. 87 - 88 - Variables to go into dtcm can be tagged like this: 89 - int __tcmdata foo; 90 - 91 - Constants can be tagged like this: 92 - int __tcmconst foo; 93 - 94 - To put assembler into TCM just use 95 - .section ".tcm.text" or .section ".tcm.data" 96 - respectively. 97 - 98 - Example code: 99 - 100 - #include <asm/tcm.h> 101 - 102 - /* Uninitialized data */ 103 - static u32 __tcmdata tcmvar; 104 - /* Initialized data */ 105 - static u32 __tcmdata tcmassigned = 0x2BADBABEU; 106 - /* Constant */ 107 - static const u32 __tcmconst tcmconst = 0xCAFEBABEU; 108 - 109 - static void __tcmlocalfunc tcm_to_tcm(void) 110 - { 111 - int i; 112 - for (i = 0; i < 100; i++) 113 - tcmvar ++; 114 - } 115 - 116 - static void __tcmfunc hello_tcm(void) 117 - { 118 - /* Some abstract code that runs in ITCM */ 119 - int i; 120 - for (i = 0; i < 100; i++) { 121 - tcmvar ++; 122 - } 123 - tcm_to_tcm(); 124 - } 125 - 126 - static void __init test_tcm(void) 127 - { 128 - u32 *tcmem; 129 - int i; 130 - 131 - hello_tcm(); 132 - printk("Hello TCM executed from ITCM RAM\n"); 133 - 134 - printk("TCM variable from testrun: %u @ %p\n", tcmvar, &tcmvar); 135 - tcmvar = 0xDEADBEEFU; 136 - printk("TCM variable: 0x%x @ %p\n", tcmvar, &tcmvar); 137 - 138 - printk("TCM assigned variable: 0x%x @ %p\n", tcmassigned, &tcmassigned); 139 - 140 - printk("TCM constant: 0x%x @ %p\n", tcmconst, &tcmconst); 141 - 142 - /* Allocate some TCM memory from the pool */ 143 - tcmem = tcm_alloc(20); 144 - if (tcmem) { 145 - printk("TCM Allocated 20 bytes of TCM @ %p\n", tcmem); 146 - tcmem[0] = 0xDEADBEEFU; 147 - tcmem[1] = 0x2BADBABEU; 148 - tcmem[2] = 0xCAFEBABEU; 149 - tcmem[3] = 0xDEADBEEFU; 150 - tcmem[4] = 0x2BADBABEU; 151 - for (i = 0; i < 5; i++) 152 - printk("TCM tcmem[%d] = %08x\n", i, tcmem[i]); 153 - tcm_free(tcmem, 20); 154 - } 155 - }
+67
Documentation/arm/uefi.rst
··· 1 + ================================================ 2 + The Unified Extensible Firmware Interface (UEFI) 3 + ================================================ 4 + 5 + UEFI, the Unified Extensible Firmware Interface, is a specification 6 + governing the behaviours of compatible firmware interfaces. It is 7 + maintained by the UEFI Forum - http://www.uefi.org/. 8 + 9 + UEFI is an evolution of its predecessor 'EFI', so the terms EFI and 10 + UEFI are used somewhat interchangeably in this document and associated 11 + source code. As a rule, anything new uses 'UEFI', whereas 'EFI' refers 12 + to legacy code or specifications. 13 + 14 + UEFI support in Linux 15 + ===================== 16 + Booting on a platform with firmware compliant with the UEFI specification 17 + makes it possible for the kernel to support additional features: 18 + 19 + - UEFI Runtime Services 20 + - Retrieving various configuration information through the standardised 21 + interface of UEFI configuration tables. (ACPI, SMBIOS, ...) 22 + 23 + For actually enabling [U]EFI support, enable: 24 + 25 + - CONFIG_EFI=y 26 + - CONFIG_EFI_VARS=y or m 27 + 28 + The implementation depends on receiving information about the UEFI environment 29 + in a Flattened Device Tree (FDT) - so is only available with CONFIG_OF. 30 + 31 + UEFI stub 32 + ========= 33 + The "stub" is a feature that extends the Image/zImage into a valid UEFI 34 + PE/COFF executable, including a loader application that makes it possible to 35 + load the kernel directly from the UEFI shell, boot menu, or one of the 36 + lightweight bootloaders like Gummiboot or rEFInd. 37 + 38 + The kernel image built with stub support remains a valid kernel image for 39 + booting in non-UEFI environments. 40 + 41 + UEFI kernel support on ARM 42 + ========================== 43 + UEFI kernel support on the ARM architectures (arm and arm64) is only available 44 + when boot is performed through the stub. 45 + 46 + When booting in UEFI mode, the stub deletes any memory nodes from a provided DT. 47 + Instead, the kernel reads the UEFI memory map. 48 + 49 + The stub populates the FDT /chosen node with (and the kernel scans for) the 50 + following parameters: 51 + 52 + ========================== ====== =========================================== 53 + Name Size Description 54 + ========================== ====== =========================================== 55 + linux,uefi-system-table 64-bit Physical address of the UEFI System Table. 56 + 57 + linux,uefi-mmap-start 64-bit Physical address of the UEFI memory map, 58 + populated by the UEFI GetMemoryMap() call. 59 + 60 + linux,uefi-mmap-size 32-bit Size in bytes of the UEFI memory map 61 + pointed to in previous entry. 62 + 63 + linux,uefi-mmap-desc-size 32-bit Size in bytes of each entry in the UEFI 64 + memory map. 65 + 66 + linux,uefi-mmap-desc-ver 32-bit Version of the mmap descriptor format. 67 + ========================== ====== ===========================================
-60
Documentation/arm/uefi.txt
··· 1 - UEFI, the Unified Extensible Firmware Interface, is a specification 2 - governing the behaviours of compatible firmware interfaces. It is 3 - maintained by the UEFI Forum - http://www.uefi.org/. 4 - 5 - UEFI is an evolution of its predecessor 'EFI', so the terms EFI and 6 - UEFI are used somewhat interchangeably in this document and associated 7 - source code. As a rule, anything new uses 'UEFI', whereas 'EFI' refers 8 - to legacy code or specifications. 9 - 10 - UEFI support in Linux 11 - ===================== 12 - Booting on a platform with firmware compliant with the UEFI specification 13 - makes it possible for the kernel to support additional features: 14 - - UEFI Runtime Services 15 - - Retrieving various configuration information through the standardised 16 - interface of UEFI configuration tables. (ACPI, SMBIOS, ...) 17 - 18 - For actually enabling [U]EFI support, enable: 19 - - CONFIG_EFI=y 20 - - CONFIG_EFI_VARS=y or m 21 - 22 - The implementation depends on receiving information about the UEFI environment 23 - in a Flattened Device Tree (FDT) - so is only available with CONFIG_OF. 24 - 25 - UEFI stub 26 - ========= 27 - The "stub" is a feature that extends the Image/zImage into a valid UEFI 28 - PE/COFF executable, including a loader application that makes it possible to 29 - load the kernel directly from the UEFI shell, boot menu, or one of the 30 - lightweight bootloaders like Gummiboot or rEFInd. 31 - 32 - The kernel image built with stub support remains a valid kernel image for 33 - booting in non-UEFI environments. 34 - 35 - UEFI kernel support on ARM 36 - ========================== 37 - UEFI kernel support on the ARM architectures (arm and arm64) is only available 38 - when boot is performed through the stub. 39 - 40 - When booting in UEFI mode, the stub deletes any memory nodes from a provided DT. 41 - Instead, the kernel reads the UEFI memory map. 42 - 43 - The stub populates the FDT /chosen node with (and the kernel scans for) the 44 - following parameters: 45 - ________________________________________________________________________________ 46 - Name | Size | Description 47 - ================================================================================ 48 - linux,uefi-system-table | 64-bit | Physical address of the UEFI System Table. 49 - -------------------------------------------------------------------------------- 50 - linux,uefi-mmap-start | 64-bit | Physical address of the UEFI memory map, 51 - | | populated by the UEFI GetMemoryMap() call. 52 - -------------------------------------------------------------------------------- 53 - linux,uefi-mmap-size | 32-bit | Size in bytes of the UEFI memory map 54 - | | pointed to in previous entry. 55 - -------------------------------------------------------------------------------- 56 - linux,uefi-mmap-desc-size | 32-bit | Size in bytes of each entry in the UEFI 57 - | | memory map. 58 - -------------------------------------------------------------------------------- 59 - linux,uefi-mmap-desc-ver | 32-bit | Version of the mmap descriptor format. 60 - --------------------------------------------------------------------------------
+57
Documentation/arm/vfp/release-notes.rst
··· 1 + =============================================== 2 + Release notes for Linux Kernel VFP support code 3 + =============================================== 4 + 5 + Date: 20 May 2004 6 + 7 + Author: Russell King 8 + 9 + This is the first release of the Linux Kernel VFP support code. It 10 + provides support for the exceptions bounced from VFP hardware found 11 + on ARM926EJ-S. 12 + 13 + This release has been validated against the SoftFloat-2b library by 14 + John R. Hauser using the TestFloat-2a test suite. Details of this 15 + library and test suite can be found at: 16 + 17 + http://www.jhauser.us/arithmetic/SoftFloat.html 18 + 19 + The operations which have been tested with this package are: 20 + 21 + - fdiv 22 + - fsub 23 + - fadd 24 + - fmul 25 + - fcmp 26 + - fcmpe 27 + - fcvtd 28 + - fcvts 29 + - fsito 30 + - ftosi 31 + - fsqrt 32 + 33 + All the above pass softfloat tests with the following exceptions: 34 + 35 + - fadd/fsub shows some differences in the handling of +0 / -0 results 36 + when input operands differ in signs. 37 + - the handling of underflow exceptions is slightly different. If a 38 + result underflows before rounding, but becomes a normalised number 39 + after rounding, we do not signal an underflow exception. 40 + 41 + Other operations which have been tested by basic assembly-only tests 42 + are: 43 + 44 + - fcpy 45 + - fabs 46 + - fneg 47 + - ftoui 48 + - ftosiz 49 + - ftouiz 50 + 51 + The combination operations have not been tested: 52 + 53 + - fmac 54 + - fnmac 55 + - fmsc 56 + - fnmsc 57 + - fnmul
+212
Documentation/arm/vlocks.rst
··· 1 + ====================================== 2 + vlocks for Bare-Metal Mutual Exclusion 3 + ====================================== 4 + 5 + Voting Locks, or "vlocks" provide a simple low-level mutual exclusion 6 + mechanism, with reasonable but minimal requirements on the memory 7 + system. 8 + 9 + These are intended to be used to coordinate critical activity among CPUs 10 + which are otherwise non-coherent, in situations where the hardware 11 + provides no other mechanism to support this and ordinary spinlocks 12 + cannot be used. 13 + 14 + 15 + vlocks make use of the atomicity provided by the memory system for 16 + writes to a single memory location. To arbitrate, every CPU "votes for 17 + itself", by storing a unique number to a common memory location. The 18 + final value seen in that memory location when all the votes have been 19 + cast identifies the winner. 20 + 21 + In order to make sure that the election produces an unambiguous result 22 + in finite time, a CPU will only enter the election in the first place if 23 + no winner has been chosen and the election does not appear to have 24 + started yet. 25 + 26 + 27 + Algorithm 28 + --------- 29 + 30 + The easiest way to explain the vlocks algorithm is with some pseudo-code:: 31 + 32 + 33 + int currently_voting[NR_CPUS] = { 0, }; 34 + int last_vote = -1; /* no votes yet */ 35 + 36 + bool vlock_trylock(int this_cpu) 37 + { 38 + /* signal our desire to vote */ 39 + currently_voting[this_cpu] = 1; 40 + if (last_vote != -1) { 41 + /* someone already volunteered himself */ 42 + currently_voting[this_cpu] = 0; 43 + return false; /* not ourself */ 44 + } 45 + 46 + /* let's suggest ourself */ 47 + last_vote = this_cpu; 48 + currently_voting[this_cpu] = 0; 49 + 50 + /* then wait until everyone else is done voting */ 51 + for_each_cpu(i) { 52 + while (currently_voting[i] != 0) 53 + /* wait */; 54 + } 55 + 56 + /* result */ 57 + if (last_vote == this_cpu) 58 + return true; /* we won */ 59 + return false; 60 + } 61 + 62 + bool vlock_unlock(void) 63 + { 64 + last_vote = -1; 65 + } 66 + 67 + 68 + The currently_voting[] array provides a way for the CPUs to determine 69 + whether an election is in progress, and plays a role analogous to the 70 + "entering" array in Lamport's bakery algorithm [1]. 71 + 72 + However, once the election has started, the underlying memory system 73 + atomicity is used to pick the winner. This avoids the need for a static 74 + priority rule to act as a tie-breaker, or any counters which could 75 + overflow. 76 + 77 + As long as the last_vote variable is globally visible to all CPUs, it 78 + will contain only one value that won't change once every CPU has cleared 79 + its currently_voting flag. 80 + 81 + 82 + Features and limitations 83 + ------------------------ 84 + 85 + * vlocks are not intended to be fair. In the contended case, it is the 86 + _last_ CPU which attempts to get the lock which will be most likely 87 + to win. 88 + 89 + vlocks are therefore best suited to situations where it is necessary 90 + to pick a unique winner, but it does not matter which CPU actually 91 + wins. 92 + 93 + * Like other similar mechanisms, vlocks will not scale well to a large 94 + number of CPUs. 95 + 96 + vlocks can be cascaded in a voting hierarchy to permit better scaling 97 + if necessary, as in the following hypothetical example for 4096 CPUs:: 98 + 99 + /* first level: local election */ 100 + my_town = towns[(this_cpu >> 4) & 0xf]; 101 + I_won = vlock_trylock(my_town, this_cpu & 0xf); 102 + if (I_won) { 103 + /* we won the town election, let's go for the state */ 104 + my_state = states[(this_cpu >> 8) & 0xf]; 105 + I_won = vlock_lock(my_state, this_cpu & 0xf)); 106 + if (I_won) { 107 + /* and so on */ 108 + I_won = vlock_lock(the_whole_country, this_cpu & 0xf]; 109 + if (I_won) { 110 + /* ... */ 111 + } 112 + vlock_unlock(the_whole_country); 113 + } 114 + vlock_unlock(my_state); 115 + } 116 + vlock_unlock(my_town); 117 + 118 + 119 + ARM implementation 120 + ------------------ 121 + 122 + The current ARM implementation [2] contains some optimisations beyond 123 + the basic algorithm: 124 + 125 + * By packing the members of the currently_voting array close together, 126 + we can read the whole array in one transaction (providing the number 127 + of CPUs potentially contending the lock is small enough). This 128 + reduces the number of round-trips required to external memory. 129 + 130 + In the ARM implementation, this means that we can use a single load 131 + and comparison:: 132 + 133 + LDR Rt, [Rn] 134 + CMP Rt, #0 135 + 136 + ...in place of code equivalent to:: 137 + 138 + LDRB Rt, [Rn] 139 + CMP Rt, #0 140 + LDRBEQ Rt, [Rn, #1] 141 + CMPEQ Rt, #0 142 + LDRBEQ Rt, [Rn, #2] 143 + CMPEQ Rt, #0 144 + LDRBEQ Rt, [Rn, #3] 145 + CMPEQ Rt, #0 146 + 147 + This cuts down on the fast-path latency, as well as potentially 148 + reducing bus contention in contended cases. 149 + 150 + The optimisation relies on the fact that the ARM memory system 151 + guarantees coherency between overlapping memory accesses of 152 + different sizes, similarly to many other architectures. Note that 153 + we do not care which element of currently_voting appears in which 154 + bits of Rt, so there is no need to worry about endianness in this 155 + optimisation. 156 + 157 + If there are too many CPUs to read the currently_voting array in 158 + one transaction then multiple transations are still required. The 159 + implementation uses a simple loop of word-sized loads for this 160 + case. The number of transactions is still fewer than would be 161 + required if bytes were loaded individually. 162 + 163 + 164 + In principle, we could aggregate further by using LDRD or LDM, but 165 + to keep the code simple this was not attempted in the initial 166 + implementation. 167 + 168 + 169 + * vlocks are currently only used to coordinate between CPUs which are 170 + unable to enable their caches yet. This means that the 171 + implementation removes many of the barriers which would be required 172 + when executing the algorithm in cached memory. 173 + 174 + packing of the currently_voting array does not work with cached 175 + memory unless all CPUs contending the lock are cache-coherent, due 176 + to cache writebacks from one CPU clobbering values written by other 177 + CPUs. (Though if all the CPUs are cache-coherent, you should be 178 + probably be using proper spinlocks instead anyway). 179 + 180 + 181 + * The "no votes yet" value used for the last_vote variable is 0 (not 182 + -1 as in the pseudocode). This allows statically-allocated vlocks 183 + to be implicitly initialised to an unlocked state simply by putting 184 + them in .bss. 185 + 186 + An offset is added to each CPU's ID for the purpose of setting this 187 + variable, so that no CPU uses the value 0 for its ID. 188 + 189 + 190 + Colophon 191 + -------- 192 + 193 + Originally created and documented by Dave Martin for Linaro Limited, for 194 + use in ARM-based big.LITTLE platforms, with review and input gratefully 195 + received from Nicolas Pitre and Achin Gupta. Thanks to Nicolas for 196 + grabbing most of this text out of the relevant mail thread and writing 197 + up the pseudocode. 198 + 199 + Copyright (C) 2012-2013 Linaro Limited 200 + Distributed under the terms of Version 2 of the GNU General Public 201 + License, as defined in linux/COPYING. 202 + 203 + 204 + References 205 + ---------- 206 + 207 + [1] Lamport, L. "A New Solution of Dijkstra's Concurrent Programming 208 + Problem", Communications of the ACM 17, 8 (August 1974), 453-455. 209 + 210 + https://en.wikipedia.org/wiki/Lamport%27s_bakery_algorithm 211 + 212 + [2] linux/arch/arm/common/vlock.S, www.kernel.org.
-211
Documentation/arm/vlocks.txt
··· 1 - vlocks for Bare-Metal Mutual Exclusion 2 - ====================================== 3 - 4 - Voting Locks, or "vlocks" provide a simple low-level mutual exclusion 5 - mechanism, with reasonable but minimal requirements on the memory 6 - system. 7 - 8 - These are intended to be used to coordinate critical activity among CPUs 9 - which are otherwise non-coherent, in situations where the hardware 10 - provides no other mechanism to support this and ordinary spinlocks 11 - cannot be used. 12 - 13 - 14 - vlocks make use of the atomicity provided by the memory system for 15 - writes to a single memory location. To arbitrate, every CPU "votes for 16 - itself", by storing a unique number to a common memory location. The 17 - final value seen in that memory location when all the votes have been 18 - cast identifies the winner. 19 - 20 - In order to make sure that the election produces an unambiguous result 21 - in finite time, a CPU will only enter the election in the first place if 22 - no winner has been chosen and the election does not appear to have 23 - started yet. 24 - 25 - 26 - Algorithm 27 - --------- 28 - 29 - The easiest way to explain the vlocks algorithm is with some pseudo-code: 30 - 31 - 32 - int currently_voting[NR_CPUS] = { 0, }; 33 - int last_vote = -1; /* no votes yet */ 34 - 35 - bool vlock_trylock(int this_cpu) 36 - { 37 - /* signal our desire to vote */ 38 - currently_voting[this_cpu] = 1; 39 - if (last_vote != -1) { 40 - /* someone already volunteered himself */ 41 - currently_voting[this_cpu] = 0; 42 - return false; /* not ourself */ 43 - } 44 - 45 - /* let's suggest ourself */ 46 - last_vote = this_cpu; 47 - currently_voting[this_cpu] = 0; 48 - 49 - /* then wait until everyone else is done voting */ 50 - for_each_cpu(i) { 51 - while (currently_voting[i] != 0) 52 - /* wait */; 53 - } 54 - 55 - /* result */ 56 - if (last_vote == this_cpu) 57 - return true; /* we won */ 58 - return false; 59 - } 60 - 61 - bool vlock_unlock(void) 62 - { 63 - last_vote = -1; 64 - } 65 - 66 - 67 - The currently_voting[] array provides a way for the CPUs to determine 68 - whether an election is in progress, and plays a role analogous to the 69 - "entering" array in Lamport's bakery algorithm [1]. 70 - 71 - However, once the election has started, the underlying memory system 72 - atomicity is used to pick the winner. This avoids the need for a static 73 - priority rule to act as a tie-breaker, or any counters which could 74 - overflow. 75 - 76 - As long as the last_vote variable is globally visible to all CPUs, it 77 - will contain only one value that won't change once every CPU has cleared 78 - its currently_voting flag. 79 - 80 - 81 - Features and limitations 82 - ------------------------ 83 - 84 - * vlocks are not intended to be fair. In the contended case, it is the 85 - _last_ CPU which attempts to get the lock which will be most likely 86 - to win. 87 - 88 - vlocks are therefore best suited to situations where it is necessary 89 - to pick a unique winner, but it does not matter which CPU actually 90 - wins. 91 - 92 - * Like other similar mechanisms, vlocks will not scale well to a large 93 - number of CPUs. 94 - 95 - vlocks can be cascaded in a voting hierarchy to permit better scaling 96 - if necessary, as in the following hypothetical example for 4096 CPUs: 97 - 98 - /* first level: local election */ 99 - my_town = towns[(this_cpu >> 4) & 0xf]; 100 - I_won = vlock_trylock(my_town, this_cpu & 0xf); 101 - if (I_won) { 102 - /* we won the town election, let's go for the state */ 103 - my_state = states[(this_cpu >> 8) & 0xf]; 104 - I_won = vlock_lock(my_state, this_cpu & 0xf)); 105 - if (I_won) { 106 - /* and so on */ 107 - I_won = vlock_lock(the_whole_country, this_cpu & 0xf]; 108 - if (I_won) { 109 - /* ... */ 110 - } 111 - vlock_unlock(the_whole_country); 112 - } 113 - vlock_unlock(my_state); 114 - } 115 - vlock_unlock(my_town); 116 - 117 - 118 - ARM implementation 119 - ------------------ 120 - 121 - The current ARM implementation [2] contains some optimisations beyond 122 - the basic algorithm: 123 - 124 - * By packing the members of the currently_voting array close together, 125 - we can read the whole array in one transaction (providing the number 126 - of CPUs potentially contending the lock is small enough). This 127 - reduces the number of round-trips required to external memory. 128 - 129 - In the ARM implementation, this means that we can use a single load 130 - and comparison: 131 - 132 - LDR Rt, [Rn] 133 - CMP Rt, #0 134 - 135 - ...in place of code equivalent to: 136 - 137 - LDRB Rt, [Rn] 138 - CMP Rt, #0 139 - LDRBEQ Rt, [Rn, #1] 140 - CMPEQ Rt, #0 141 - LDRBEQ Rt, [Rn, #2] 142 - CMPEQ Rt, #0 143 - LDRBEQ Rt, [Rn, #3] 144 - CMPEQ Rt, #0 145 - 146 - This cuts down on the fast-path latency, as well as potentially 147 - reducing bus contention in contended cases. 148 - 149 - The optimisation relies on the fact that the ARM memory system 150 - guarantees coherency between overlapping memory accesses of 151 - different sizes, similarly to many other architectures. Note that 152 - we do not care which element of currently_voting appears in which 153 - bits of Rt, so there is no need to worry about endianness in this 154 - optimisation. 155 - 156 - If there are too many CPUs to read the currently_voting array in 157 - one transaction then multiple transations are still required. The 158 - implementation uses a simple loop of word-sized loads for this 159 - case. The number of transactions is still fewer than would be 160 - required if bytes were loaded individually. 161 - 162 - 163 - In principle, we could aggregate further by using LDRD or LDM, but 164 - to keep the code simple this was not attempted in the initial 165 - implementation. 166 - 167 - 168 - * vlocks are currently only used to coordinate between CPUs which are 169 - unable to enable their caches yet. This means that the 170 - implementation removes many of the barriers which would be required 171 - when executing the algorithm in cached memory. 172 - 173 - packing of the currently_voting array does not work with cached 174 - memory unless all CPUs contending the lock are cache-coherent, due 175 - to cache writebacks from one CPU clobbering values written by other 176 - CPUs. (Though if all the CPUs are cache-coherent, you should be 177 - probably be using proper spinlocks instead anyway). 178 - 179 - 180 - * The "no votes yet" value used for the last_vote variable is 0 (not 181 - -1 as in the pseudocode). This allows statically-allocated vlocks 182 - to be implicitly initialised to an unlocked state simply by putting 183 - them in .bss. 184 - 185 - An offset is added to each CPU's ID for the purpose of setting this 186 - variable, so that no CPU uses the value 0 for its ID. 187 - 188 - 189 - Colophon 190 - -------- 191 - 192 - Originally created and documented by Dave Martin for Linaro Limited, for 193 - use in ARM-based big.LITTLE platforms, with review and input gratefully 194 - received from Nicolas Pitre and Achin Gupta. Thanks to Nicolas for 195 - grabbing most of this text out of the relevant mail thread and writing 196 - up the pseudocode. 197 - 198 - Copyright (C) 2012-2013 Linaro Limited 199 - Distributed under the terms of Version 2 of the GNU General Public 200 - License, as defined in linux/COPYING. 201 - 202 - 203 - References 204 - ---------- 205 - 206 - [1] Lamport, L. "A New Solution of Dijkstra's Concurrent Programming 207 - Problem", Communications of the ACM 17, 8 (August 1974), 453-455. 208 - 209 - https://en.wikipedia.org/wiki/Lamport%27s_bakery_algorithm 210 - 211 - [2] linux/arch/arm/common/vlock.S, www.kernel.org.
+1 -1
Documentation/devicetree/bindings/arm/xen.txt
··· 54 54 }; 55 55 56 56 The format and meaning of the "xen,uefi-*" parameters are similar to those in 57 - Documentation/arm/uefi.txt, which are provided by the regular UEFI stub. However 57 + Documentation/arm/uefi.rst, which are provided by the regular UEFI stub. However 58 58 they differ because they are provided by the Xen hypervisor, together with a set 59 59 of UEFI runtime services implemented via hypercalls, see 60 60 http://xenbits.xen.org/docs/unstable/hypercall/x86_64/include,public,platform.h.html.
+2 -2
Documentation/devicetree/booting-without-of.txt
··· 160 160 of the kernel image. That entry point supports two calling 161 161 conventions. A summary of the interface is described here. A full 162 162 description of the boot requirements is documented in 163 - Documentation/arm/Booting 163 + Documentation/arm/booting.rst 164 164 165 165 a) ATAGS interface. Minimal information is passed from firmware 166 166 to the kernel with a tagged list of predefined parameters. ··· 174 174 b) Entry with a flattened device-tree block. Firmware loads the 175 175 physical address of the flattened device tree block (dtb) into r2, 176 176 r1 is not used, but it is considered good practice to use a valid 177 - machine number as described in Documentation/arm/Booting. 177 + machine number as described in Documentation/arm/booting.rst. 178 178 179 179 r0 : 0 180 180
+1
Documentation/index.rst
··· 1 + 1 2 .. The Linux Kernel documentation master file, created by 2 3 sphinx-quickstart on Fri Feb 12 13:51:46 2016. 3 4 You can adapt this file completely to your liking, but it should at least
+2 -2
Documentation/translations/zh_CN/arm/Booting
··· 1 - Chinese translated version of Documentation/arm/Booting 1 + Chinese translated version of Documentation/arm/booting.rst 2 2 3 3 If you have any comment or update to the content, please contact the 4 4 original document maintainer directly. However, if you have a problem ··· 9 9 Maintainer: Russell King <linux@arm.linux.org.uk> 10 10 Chinese maintainer: Fu Wei <tekkamanninja@gmail.com> 11 11 --------------------------------------------------------------------- 12 - Documentation/arm/Booting 的中文翻译 12 + Documentation/arm/booting.rst 的中文翻译 13 13 14 14 如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文 15 15 交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
+2 -2
Documentation/translations/zh_CN/arm/kernel_user_helpers.txt
··· 1 - Chinese translated version of Documentation/arm/kernel_user_helpers.txt 1 + Chinese translated version of Documentation/arm/kernel_user_helpers.rst 2 2 3 3 If you have any comment or update to the content, please contact the 4 4 original document maintainer directly. However, if you have a problem ··· 10 10 Dave Martin <dave.martin@linaro.org> 11 11 Chinese maintainer: Fu Wei <tekkamanninja@gmail.com> 12 12 --------------------------------------------------------------------- 13 - Documentation/arm/kernel_user_helpers.txt 的中文翻译 13 + Documentation/arm/kernel_user_helpers.rst 的中文翻译 14 14 15 15 如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文 16 16 交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
+2 -2
MAINTAINERS
··· 2218 2218 F: drivers/*/*s5pv210* 2219 2219 F: drivers/memory/samsung/* 2220 2220 F: drivers/soc/samsung/* 2221 - F: Documentation/arm/Samsung/ 2221 + F: Documentation/arm/samsung/ 2222 2222 F: Documentation/devicetree/bindings/arm/samsung/ 2223 2223 F: Documentation/devicetree/bindings/sram/samsung-sram.txt 2224 2224 F: Documentation/devicetree/bindings/power/pd-samsung.txt ··· 11571 11571 L: linux-fbdev@vger.kernel.org 11572 11572 S: Orphan 11573 11573 F: drivers/video/fbdev/omap2/ 11574 - F: Documentation/arm/OMAP/DSS 11574 + F: Documentation/arm/omap/dss.rst 11575 11575 11576 11576 OMAP FRAMEBUFFER SUPPORT 11577 11577 L: linux-fbdev@vger.kernel.org
+1 -1
arch/arm/Kconfig
··· 2142 2142 Say Y to include VFP support code in the kernel. This is needed 2143 2143 if your hardware includes a VFP unit. 2144 2144 2145 - Please see <file:Documentation/arm/VFP/release-notes.txt> for 2145 + Please see <file:Documentation/arm/vfp/release-notes.rst> for 2146 2146 release notes and additional status information. 2147 2147 2148 2148 Say N if your target does not have VFP hardware.
+1 -1
arch/arm/common/mcpm_entry.c
··· 21 21 /* 22 22 * The public API for this code is documented in arch/arm/include/asm/mcpm.h. 23 23 * For a comprehensive description of the main algorithm used here, please 24 - * see Documentation/arm/cluster-pm-race-avoidance.txt. 24 + * see Documentation/arm/cluster-pm-race-avoidance.rst. 25 25 */ 26 26 27 27 struct sync_struct mcpm_sync;
+1 -1
arch/arm/common/mcpm_head.S
··· 5 5 * Created by: Nicolas Pitre, March 2012 6 6 * Copyright: (C) 2012-2013 Linaro Limited 7 7 * 8 - * Refer to Documentation/arm/cluster-pm-race-avoidance.txt 8 + * Refer to Documentation/arm/cluster-pm-race-avoidance.rst 9 9 * for details of the synchronisation algorithms used here. 10 10 */ 11 11
+1 -1
arch/arm/common/vlock.S
··· 6 6 * Copyright: (C) 2012-2013 Linaro Limited 7 7 * 8 8 * This algorithm is described in more detail in 9 - * Documentation/arm/vlocks.txt. 9 + * Documentation/arm/vlocks.rst. 10 10 */ 11 11 12 12 #include <linux/linkage.h>
+1 -1
arch/arm/include/asm/setup.h
··· 5 5 * Copyright (C) 1997-1999 Russell King 6 6 * 7 7 * Structure passed to kernel to tell it about the 8 - * hardware it's running on. See Documentation/arm/Setup 8 + * hardware it's running on. See Documentation/arm/setup.rst 9 9 * for more info. 10 10 */ 11 11 #ifndef __ASMARM_SETUP_H
+1 -1
arch/arm/include/uapi/asm/setup.h
··· 9 9 * published by the Free Software Foundation. 10 10 * 11 11 * Structure passed to kernel to tell it about the 12 - * hardware it's running on. See Documentation/arm/Setup 12 + * hardware it's running on. See Documentation/arm/setup.rst 13 13 * for more info. 14 14 */ 15 15 #ifndef _UAPI__ASMARM_SETUP_H
+1 -1
arch/arm/kernel/entry-armv.S
··· 826 826 * existing ones. This mechanism should be used only for things that are 827 827 * really small and justified, and not be abused freely. 828 828 * 829 - * See Documentation/arm/kernel_user_helpers.txt for formal definitions. 829 + * See Documentation/arm/kernel_user_helpers.rst for formal definitions. 830 830 */ 831 831 THUMB( .arm ) 832 832
+1 -1
arch/arm/mach-exynos/common.h
··· 106 106 #define C2_STATE (1 << 3) 107 107 /* 108 108 * Magic values for bootloader indicating chosen low power mode. 109 - * See also Documentation/arm/Samsung/Bootloader-interface.txt 109 + * See also Documentation/arm/samsung/bootloader-interface.rst 110 110 */ 111 111 #define EXYNOS_SLEEP_MAGIC 0x00000bad 112 112 #define EXYNOS_AFTR_MAGIC 0xfcba0d10
+7 -7
arch/arm/mach-ixp4xx/Kconfig
··· 33 33 help 34 34 Say 'Y' here if you want your kernel to support the Gateworks 35 35 Avila Network Platform. For more information on this platform, 36 - see <file:Documentation/arm/IXP4xx>. 36 + see <file:Documentation/arm/ixp4xx.rst>. 37 37 38 38 config MACH_LOFT 39 39 bool "Loft" ··· 49 49 help 50 50 Say 'Y' here if you want your kernel to support the ADI 51 51 Engineering Coyote Gateway Reference Platform. For more 52 - information on this platform, see <file:Documentation/arm/IXP4xx>. 52 + information on this platform, see <file:Documentation/arm/ixp4xx.rst>. 53 53 54 54 config MACH_GATEWAY7001 55 55 bool "Gateway 7001" ··· 72 72 help 73 73 Say 'Y' here if you want your kernel to support Intel's 74 74 IXDP425 Development Platform (Also known as Richfield). 75 - For more information on this platform, see <file:Documentation/arm/IXP4xx>. 75 + For more information on this platform, see <file:Documentation/arm/ixp4xx.rst>. 76 76 77 77 config MACH_IXDPG425 78 78 bool "IXDPG425" 79 79 help 80 80 Say 'Y' here if you want your kernel to support Intel's 81 81 IXDPG425 Development Platform (Also known as Montajade). 82 - For more information on this platform, see <file:Documentation/arm/IXP4xx>. 82 + For more information on this platform, see <file:Documentation/arm/ixp4xx.rst>. 83 83 84 84 config MACH_IXDP465 85 85 bool "IXDP465" 86 86 help 87 87 Say 'Y' here if you want your kernel to support Intel's 88 88 IXDP465 Development Platform (Also known as BMP). 89 - For more information on this platform, see <file:Documentation/arm/IXP4xx>. 89 + For more information on this platform, see <file:Documentation/arm/ixp4xx.rst>. 90 90 91 91 config MACH_GORAMO_MLR 92 92 bool "GORAMO Multi Link Router" ··· 99 99 help 100 100 Say 'Y' here if you want your kernel to support Intel's 101 101 KIXRP435 Reference Platform. 102 - For more information on this platform, see <file:Documentation/arm/IXP4xx>. 102 + For more information on this platform, see <file:Documentation/arm/ixp4xx.rst>. 103 103 104 104 # 105 105 # IXCDP1100 is the exact same HW as IXDP425, but with a different machine ··· 116 116 help 117 117 Say 'Y' here if you want your kernel to support the Motorola 118 118 PrPCM1100 Processor Mezanine Module. For more information on 119 - this platform, see <file:Documentation/arm/IXP4xx>. 119 + this platform, see <file:Documentation/arm/ixp4xx.rst>. 120 120 121 121 config MACH_NAS100D 122 122 bool
+1 -1
arch/arm/mach-s3c24xx/pm.c
··· 5 5 // 6 6 // S3C24XX Power Manager (Suspend-To-RAM) support 7 7 // 8 - // See Documentation/arm/Samsung-S3C24XX/Suspend.txt for more information 8 + // See Documentation/arm/samsung-s3c24xx/suspend.rst for more information 9 9 // 10 10 // Parts based on arch/arm/mach-pxa/pm.c 11 11 //
+2 -2
arch/arm/mm/Kconfig
··· 709 709 assistance. 710 710 711 711 A compliant bootloader is required in order to make maximum 712 - use of this feature. Refer to Documentation/arm/Booting for 712 + use of this feature. Refer to Documentation/arm/booting.rst for 713 713 details. 714 714 715 715 config SWP_EMULATE ··· 875 875 the CPU type fitted to the system. This permits binaries to be 876 876 run on ARMv4 through to ARMv7 without modification. 877 877 878 - See Documentation/arm/kernel_user_helpers.txt for details. 878 + See Documentation/arm/kernel_user_helpers.rst for details. 879 879 880 880 However, the fixed address nature of these helpers can be used 881 881 by ROP (return orientated programming) authors when creating
+3 -3
arch/arm/plat-samsung/Kconfig
··· 243 243 depends on DEBUG_EXYNOS_UART || DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART 244 244 help 245 245 Say Y here if you want verbose debugging from the PM Suspend and 246 - Resume code. See <file:Documentation/arm/Samsung-S3C24XX/Suspend.txt> 246 + Resume code. See <file:Documentation/arm/samsung-s3c24xx/suspend.rst> 247 247 for more information. 248 248 249 249 config S3C_PM_DEBUG_LED_SMDK ··· 268 268 Note, this can take several seconds depending on memory size 269 269 and CPU speed. 270 270 271 - See <file:Documentation/arm/Samsung-S3C24XX/Suspend.txt> 271 + See <file:Documentation/arm/samsung-s3c24xx/suspend.rst> 272 272 273 273 config SAMSUNG_PM_CHECK_CHUNKSIZE 274 274 int "S3C2410 PM Suspend CRC Chunksize (KiB)" ··· 280 280 the CRC data block will take more memory, but will identify any 281 281 faults with better precision. 282 282 283 - See <file:Documentation/arm/Samsung-S3C24XX/Suspend.txt> 283 + See <file:Documentation/arm/samsung-s3c24xx/suspend.rst> 284 284 285 285 config SAMSUNG_WAKEMASK 286 286 bool
+1 -1
arch/arm/tools/mach-types
··· 7 7 # http://www.arm.linux.org.uk/developer/machines/download.php 8 8 # 9 9 # Please do not send patches to this file; it is automatically generated! 10 - # To add an entry into this database, please see Documentation/arm/README, 10 + # To add an entry into this database, please see Documentation/arm/arm.rst, 11 11 # or visit: 12 12 # 13 13 # http://www.arm.linux.org.uk/developer/machines/?action=new
+1 -1
arch/arm64/Kconfig
··· 1142 1142 the system. This permits binaries to be run on ARMv4 through 1143 1143 to ARMv8 without modification. 1144 1144 1145 - See Documentation/arm/kernel_user_helpers.txt for details. 1145 + See Documentation/arm/kernel_user_helpers.rst for details. 1146 1146 1147 1147 However, the fixed address nature of these helpers can be used 1148 1148 by ROP (return orientated programming) authors when creating
+1 -1
arch/arm64/kernel/kuser32.S
··· 10 10 * aarch32_setup_additional_pages() and are provided for compatibility 11 11 * reasons with 32 bit (aarch32) applications that need them. 12 12 * 13 - * See Documentation/arm/kernel_user_helpers.txt for formal definitions. 13 + * See Documentation/arm/kernel_user_helpers.rst for formal definitions. 14 14 */ 15 15 16 16 #include <asm/unistd.h>
+1 -1
arch/mips/bmips/setup.c
··· 162 162 ioport_resource.start = 0; 163 163 ioport_resource.end = ~0; 164 164 165 - /* intended to somewhat resemble ARM; see Documentation/arm/Booting */ 165 + /* intended to somewhat resemble ARM; see Documentation/arm/booting.rst */ 166 166 if (fw_arg0 == 0 && fw_arg1 == 0xffffffff) 167 167 dtb = phys_to_virt(fw_arg2); 168 168 else if (fw_passed_dtb) /* UHI interface or appended dtb */
+1 -1
drivers/crypto/sunxi-ss/sun4i-ss-cipher.c
··· 8 8 * keysize in CBC and ECB mode. 9 9 * Add support also for DES and 3DES in CBC and ECB mode. 10 10 * 11 - * You could find the datasheet in Documentation/arm/sunxi/README 11 + * You could find the datasheet in Documentation/arm/sunxi.rst 12 12 */ 13 13 #include "sun4i-ss.h" 14 14
+1 -1
drivers/crypto/sunxi-ss/sun4i-ss-core.c
··· 6 6 * 7 7 * Core file which registers crypto algorithms supported by the SS. 8 8 * 9 - * You could find a link for the datasheet in Documentation/arm/sunxi/README 9 + * You could find a link for the datasheet in Documentation/arm/sunxi.rst 10 10 */ 11 11 #include <linux/clk.h> 12 12 #include <linux/crypto.h>
+1 -1
drivers/crypto/sunxi-ss/sun4i-ss-hash.c
··· 6 6 * 7 7 * This file add support for MD5 and SHA1. 8 8 * 9 - * You could find the datasheet in Documentation/arm/sunxi/README 9 + * You could find the datasheet in Documentation/arm/sunxi.rst 10 10 */ 11 11 #include "sun4i-ss.h" 12 12 #include <linux/scatterlist.h>
+1 -1
drivers/crypto/sunxi-ss/sun4i-ss.h
··· 8 8 * Support MD5 and SHA1 hash algorithms. 9 9 * Support DES and 3DES 10 10 * 11 - * You could find the datasheet in Documentation/arm/sunxi/README 11 + * You could find the datasheet in Documentation/arm/sunxi.rst 12 12 */ 13 13 14 14 #include <linux/clk.h>
+1 -1
drivers/input/touchscreen/sun4i-ts.c
··· 22 22 * in the kernel). So this driver offers straight forward, reliable single 23 23 * touch functionality only. 24 24 * 25 - * s.a. A20 User Manual "1.15 TP" (Documentation/arm/sunxi/README) 25 + * s.a. A20 User Manual "1.15 TP" (Documentation/arm/sunxi.rst) 26 26 * (looks like the description in the A20 User Manual v1.3 is better 27 27 * than the one in the A10 User Manual v.1.5) 28 28 */
+1 -1
drivers/tty/serial/Kconfig
··· 500 500 help 501 501 If you have a machine based on a SA1100/SA1110 StrongARM(R) CPU you 502 502 can enable its onboard serial port by enabling this option. 503 - Please read <file:Documentation/arm/SA1100/serial_UART> for further 503 + Please read <file:Documentation/arm/sa1100/serial_uart.rst> for further 504 504 info. 505 505 506 506 config SERIAL_SA1100_CONSOLE