diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-08-03 17:31:24 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-08-03 17:31:24 -0400 |
commit | be82ae0238b0453afcf4a76f0512b7dde34ba500 (patch) | |
tree | aaa3f5f11fd51fd73365ee1a2164aad9a03de060 /Documentation | |
parent | 4b4fd27c0b5ec638a1f06ced9226fd95229dbbf0 (diff) | |
parent | 7b70c4275f28702b76b273c8534c38f8313812e9 (diff) |
Merge branch 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm: (291 commits)
ARM: AMBA: Add pclk support to AMBA bus infrastructure
ARM: 6278/2: fix regression in RealView after the introduction of pclk
ARM: 6277/1: mach-shmobile: Allow users to select HZ, default to 128
ARM: 6276/1: mach-shmobile: remove duplicate NR_IRQS_LEGACY
ARM: 6246/1: mmci: support larger MMCIDATALENGTH register
ARM: 6245/1: mmci: enable hardware flow control on Ux500 variants
ARM: 6244/1: mmci: add variant data and default MCICLOCK support
ARM: 6243/1: mmci: pass power_mode to the translate_vdd callback
ARM: 6274/1: add global control registers definition header file for nuc900
mx2_camera: fix type of dma buffer virtual address pointer
mx2_camera: Add soc_camera support for i.MX25/i.MX27
arm/imx/gpio: add spinlock protection
ARM: Add support for the LPC32XX arch
ARM: LPC32XX: Arch config menu supoport and makefiles
ARM: LPC32XX: Phytec 3250 platform support
ARM: LPC32XX: Misc support functions
ARM: LPC32XX: Serial support code
ARM: LPC32XX: System suspend support
ARM: LPC32XX: GPIO, timer, and IRQ drivers
ARM: LPC32XX: Clock driver
...
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/arm/memory.txt | 8 | ||||
-rw-r--r-- | Documentation/arm/tcm.txt | 30 |
2 files changed, 26 insertions, 12 deletions
diff --git a/Documentation/arm/memory.txt b/Documentation/arm/memory.txt index eb0fae18ffb1..771d48d3b335 100644 --- a/Documentation/arm/memory.txt +++ b/Documentation/arm/memory.txt | |||
@@ -33,7 +33,13 @@ ffff0000 ffff0fff CPU vector page. | |||
33 | 33 | ||
34 | fffe0000 fffeffff XScale cache flush area. This is used | 34 | fffe0000 fffeffff XScale cache flush area. This is used |
35 | in proc-xscale.S to flush the whole data | 35 | in proc-xscale.S to flush the whole data |
36 | cache. Free for other usage on non-XScale. | 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. | ||
37 | 43 | ||
38 | fff00000 fffdffff Fixmap mapping region. Addresses provided | 44 | fff00000 fffdffff Fixmap mapping region. Addresses provided |
39 | by fix_to_virt() will be located here. | 45 | by fix_to_virt() will be located here. |
diff --git a/Documentation/arm/tcm.txt b/Documentation/arm/tcm.txt index 77fd9376e6d7..7c15871c1885 100644 --- a/Documentation/arm/tcm.txt +++ b/Documentation/arm/tcm.txt | |||
@@ -19,8 +19,8 @@ defines a CPUID_TCM register that you can read out from the | |||
19 | system control coprocessor. Documentation from ARM can be found | 19 | system control coprocessor. Documentation from ARM can be found |
20 | at http://infocenter.arm.com, search for "TCM Status Register" | 20 | at http://infocenter.arm.com, search for "TCM Status Register" |
21 | to see documents for all CPUs. Reading this register you can | 21 | to see documents for all CPUs. Reading this register you can |
22 | determine if ITCM (bit 0) and/or DTCM (bit 16) is present in the | 22 | determine if ITCM (bits 1-0) and/or DTCM (bit 17-16) is present |
23 | machine. | 23 | in the machine. |
24 | 24 | ||
25 | There is further a TCM region register (search for "TCM Region | 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 | 26 | Registers" at the ARM site) that can report and modify the location |
@@ -35,7 +35,15 @@ 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 | 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 | 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 | 37 | implementation will map the TCM 1 to 1 from physical to virtual |
38 | memory in the location specified by the machine. | 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). | ||
39 | 47 | ||
40 | TCM is used for a few things: | 48 | TCM is used for a few things: |
41 | 49 | ||
@@ -65,18 +73,18 @@ in <asm/tcm.h>. Using this interface it is possible to: | |||
65 | memory. Such a heap is great for things like saving | 73 | memory. Such a heap is great for things like saving |
66 | device state when shutting off device power domains. | 74 | device state when shutting off device power domains. |
67 | 75 | ||
68 | A machine that has TCM memory shall select HAVE_TCM in | 76 | A machine that has TCM memory shall select HAVE_TCM from |
69 | arch/arm/Kconfig for itself, and then the | 77 | arch/arm/Kconfig for itself. Code that needs to use TCM shall |
70 | rest of the functionality will depend on the physical | 78 | #include <asm/tcm.h> |
71 | location and size of ITCM and DTCM to be defined in | ||
72 | mach/memory.h for the machine. Code that needs to use | ||
73 | TCM shall #include <asm/tcm.h> If the TCM is not located | ||
74 | at the place given in memory.h it will be moved using | ||
75 | the TCM Region registers. | ||
76 | 79 | ||
77 | Functions to go into itcm can be tagged like this: | 80 | Functions to go into itcm can be tagged like this: |
78 | int __tcmfunc foo(int bar); | 81 | int __tcmfunc foo(int bar); |
79 | 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 | |||
80 | Variables to go into dtcm can be tagged like this: | 88 | Variables to go into dtcm can be tagged like this: |
81 | int __tcmdata foo; | 89 | int __tcmdata foo; |
82 | 90 | ||