summaryrefslogtreecommitdiffstats
path: root/arch/microblaze
Commit message (Collapse)AuthorAgeFilesLines
* microblaze: resource/PCI: align functions now return start of resourceMichal Simek2010-05-061-7/+6
| | | | | | | | | | | | | | This change should be part of b26b2d494b659f988b4d75eb394dfa0ddac415c9 Origin description: resource/PCI: align functions now return start of resource As suggested by Linus, align functions should return the start of a resource, not void. An update of "res->start" is no longer necessary. Signed-off-by: Michal Simek <monstr@monstr.eu>
* microblaze: PCI: add pci_bus_for_each_resource(), remove direct ↵Michal Simek2010-05-061-2/+2
| | | | | | | | | | | | | | | | | | | bus->resource[] refs This change should be part of 89a74ecccd1f78e51faf6287e5c0e93a92ac096e Origin description: PCI: add pci_bus_for_each_resource(), remove direct bus->resource[] refs No functional change; this converts loops that iterate from 0 to PCI_BUS_NUM_RESOURCES through pci_bus resource[] table to use the pci_bus_for_each_resource() iterator instead. This doesn't change the way resources are stored; it merely removes dependencies on the fact that they're in a table. Signed-off-by: Michal Simek <monstr@monstr.eu>
* microblaze: Remove unused variable from ptraceMichal Simek2010-04-071-1/+0
| | | | | | Patch b3c1e01a09d6af2dd7811a066ffcfc5171be2bed should do it. Signed-off-by: Michal Simek <monstr@monstr.eu>
* microblaze: io.h: Add io big-endian functionJohn Linn2010-04-071-0/+5
| | | | | | | | Add new io big-endian function. They will be used for uartlite and spi driver. Signed-off-by: John Linn <john.linn@xilinx.com> Signed-off-by: Michal Simek <monstr@monstr.eu>
* microblaze: Fix futex codeMichal Simek2010-04-071-1/+1
| | | | | | Use logical and NOT for ANDN. It was likely type fault. Signed-off-by: Michal Simek <monstr@monstr.eu>
* microblaze: Fix ftrace_update_ftrace_func panicSteven J. Magnani2010-04-071-9/+3
| | | | | | | | | | | | | | | | | | The Microblaze dynamic ftrace code assumes a call ordering that is not met in all scenarios. Specifically, executing a command similar to: echo 105 > /sys/kernel/debug/tracing/set_ftrace_pid before any other tracing-related commands results in a kernel panic: BUG: failure at arch/microblaze/kernel/ftrace.c:198/ftrace_update_ftrace_func()! Recoding ftrace_update_ftrace_func() to use &ftrace_caller directly eliminates the need to capture its address elsewhere (and thus rely on a particular call sequence). Signed-off-by: Steven J. Magnani <steve@digidescorp.com> Signed-off-by: Michal Simek <monstr@monstr.eu>
* Merge branch 'master' into export-slabhTejun Heo2010-04-0524-446/+407
|\
| * microblaze: Support word copying in copy_tofrom_userMichal Simek2010-04-011-14/+25
| | | | | | | | | | | | | | | | Word copying is used only for aligned addresses. Here is space for improving to use any better copying technique. Look at memcpy implementation. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Print early printk information to log bufferMichal Simek2010-04-011-9/+15
| | | | | | | | | | | | | | If early printk console is not enabled then all messages are written to log buffer. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: head.S typo fixMichal Simek2010-04-011-2/+2
| | | | | | | | | | | | I forget to change register name in comments. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Use MICROBLAZE_TLB_SIZE in asm codeMichal Simek2010-04-012-3/+3
| | | | | | | | | | | | | | TLB size was hardcoded in asm code. This patch brings ability to change TLB size only in one place. (mmu.h). Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Kconfig Fix - pciMichal Simek2010-04-011-3/+0
| | | | | | | | | | | | I forget to remove pci Kconfig option. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Adding likely macrosMichal Simek2010-04-016-26/+28
| | | | | | | | | | | | | | On the base on GCOV analytics is helpful to add likely/unlikely macros. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Add .type and .size to ASM functionsMichal Simek2010-04-013-1/+22
| | | | | | | | | | | | Cachegrind analysis need this fix to be able to log asm functions. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Fix TLB macrosMichal Simek2010-04-011-1/+2
| | | | | | | | | | | | To be able to do trace TLB operations. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Use instruction with delay slotMichal Simek2010-04-011-8/+5
| | | | | | | | | | | | Sync labels. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Remove additional resr and rear loadingMichal Simek2010-04-011-15/+3
| | | | | | | | | | | | RESR and REAR uses the same regs in whole file. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Change register usage for ESR and EARMichal Simek2010-04-011-35/+35
| | | | | | | | | | | | | | | | This change synchronize register usage in code. ESR = R4 EAR = R3 Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Prepare work for optimization in exception codeMichal Simek2010-04-011-6/+3
| | | | | | | | | | | | Any sync branch must follow mts instructions not mfs. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Add DEBUG optionMichal Simek2010-04-011-0/+2
| | | | | | | | | | | | Disable debug option in asm code. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Support systems without lmb bramMichal Simek2010-04-011-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the system has no lmb bram, main memory should be start from zero because of microblaze vectors. DTS fragment could look like: DDR2_SDRAM: memory@0 { device_type = "memory"; reg = < 0x0 0x10000000 >; } ; Then you have to setup CONFIG_KERNEL_BASE_ADDR=0 which caused that kernel physical start address will be zero. On reset vector place will be jump to 0x100 and on 0x100 starts kernel text. You have to solve how to load the kernel before cpu starts. Tested with XMD. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: Sync strlen, strnlen, copy_to/from_userMichal Simek2010-04-011-56/+32
| | | | | | | | | | | | Last sync. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: Unify __copy_tofrom_userMichal Simek2010-04-012-39/+22
| | | | | | | | | | | | Move to generic location. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: Move functions to generic locationMichal Simek2010-04-013-200/+61
| | | | | | | | | | | | noMMU and MMU use them. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: Fix put_user for noMMUMichal Simek2010-04-011-22/+56
| | | | | | | | | | | | | | | | Here is small regression on dhrystone tests and I think that on all benchmarking tests. It is due to better checking mechanism in put_user macro Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: Fix get_user macro for noMMUMichal Simek2010-04-011-23/+66
| | | | | | | | | | | | Use unified version. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: fix clear_user for noMMU kernelMichal Simek2010-04-011-45/+36
| | | | | | | | | | | | | | Previous patches fixed only MMU version and this is the first patch for noMMU kernel Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: Fix strncpy_from_user functionMichal Simek2010-04-011-3/+11
| | | | | | | | | | | | Generic implementation for noMMU and MMU version Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: fix copy_from_user macroMichal Simek2010-04-011-9/+14
| | | | | | | | | | | | copy_from_user macro also use copy_tofrom_user function Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: copy_to_user unificationMichal Simek2010-04-011-9/+16
| | | | | | | | | | | | | | noMMU and MMU kernel will use copy copy_tofrom_user asm implementation. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: sync put/get/clear_user macrosMichal Simek2010-04-011-37/+69
| | | | | | | | | | | | Add macro description and resort. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: fix put_user and get_user macrosMichal Simek2010-04-011-51/+49
| | | | | | | | | | | | Use FIXUP macros and resort them. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: fix __get_user_asm macroMichal Simek2010-04-011-16/+17
| | | | | | | | | | | | It is used __FIXUP_SECTION and __EX_TABLE_SECTION macros. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: uaccess: fix clean user macroMichal Simek2010-04-011-34/+55
| | | | | | | | | | | | | | | | This is the first patch which does uaccess unification. I choosed to do several patches to be able to use bisect in future if any fault happens. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: move noMMU __range_ok function to uaccess.hMichal Simek2010-04-012-9/+6
| | | | | | | | | | | | | | The same noMMU and MMU functions should be placed in one file. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Move exception_table_entry upwardMichal Simek2010-04-011-16/+15
| | | | | | | | | | | | Just sort to be able remove whole block. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Remove segment.hMichal Simek2010-04-015-52/+34
| | | | | | | | | | | | | | I would like to use asm-generic uaccess.h where are segment macros defined. This is just first step. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Remove memset in free_init_pagesMichal Simek2010-04-011-1/+0
| | | | | | | | | | | | We don't need to do it. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Makefile cleanupsArun Bhanu2010-04-011-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | If CONFIG_INITRAMFS_SOURCE is set, "scripts/gen_initramfs_list.sh" checks if the cpio image exists. Remove the duplicate check from the Makefile. Remove the "clean-kernel" variable which is unused in the Makefile and is not used by the Kbuild. Signed-off-by: Arun Bhanu <arun@bhanu.net> Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Fix Makefile to delete build generated filesArun Bhanu2010-04-012-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'make clean' does not to delete the following build generated file: arch/microblaze/boot/linux.bin.ub 'make mrproper' does not to delete the following build generated files: arch/microblaze/boot/simpleImage.* Fix the Makefile to delete these build generated files. See [1] for a discussion on why simpleImage.* files are deleted with 'make mrproper' and not with 'make clean'. [1] http://lkml.org/lkml/2010/3/12/96 Signed-off-by: Arun Bhanu <arun@bhanu.net> Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Add a missing single quote to make 'make help' happyArun Bhanu2010-04-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | 'make ARCH=microblaze help' fails with the following error due to a missing single quote. /bin/sh: -c: line 0: unexpected EOF while looking for matching `'' /bin/sh: -c: line 1: syntax error: unexpected end of file make: *** [help] Error 2 Signed-off-by: Arun Bhanu <arun@bhanu.net> Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Fix "kstack=" parsingSteven J. Magnani2010-04-011-4/+2
| | | | | | | | | | | | | | | | The "kstack=" command line parameter is not parsed correctly. All proper values are interpreted as zero. Signed-off-by: Steven J. Magnani <steve@digidescorp.com> Signed-off-by: Michal Simek <monstr@monstr.eu>
* | include cleanup: Update gfp.h and slab.h includes to prepare for breaking ↵Tejun Heo2010-03-309-3/+6
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | implicit slab.h inclusion from percpu.h percpu.h is included by sched.h and module.h and thus ends up being included when building most .c files. percpu.h includes slab.h which in turn includes gfp.h making everything defined by the two files universally available and complicating inclusion dependencies. percpu.h -> slab.h dependency is about to be removed. Prepare for this change by updating users of gfp and slab facilities include those headers directly instead of assuming availability. As this conversion needs to touch large number of source files, the following script is used as the basis of conversion. http://userweb.kernel.org/~tj/misc/slabh-sweep.py The script does the followings. * Scan files for gfp and slab usages and update includes such that only the necessary includes are there. ie. if only gfp is used, gfp.h, if slab is used, slab.h. * When the script inserts a new include, it looks at the include blocks and try to put the new include such that its order conforms to its surrounding. It's put in the include block which contains core kernel includes, in the same order that the rest are ordered - alphabetical, Christmas tree, rev-Xmas-tree or at the end if there doesn't seem to be any matching order. * If the script can't find a place to put a new include (mostly because the file doesn't have fitting include block), it prints out an error message indicating which .h file needs to be added to the file. The conversion was done in the following steps. 1. The initial automatic conversion of all .c files updated slightly over 4000 files, deleting around 700 includes and adding ~480 gfp.h and ~3000 slab.h inclusions. The script emitted errors for ~400 files. 2. Each error was manually checked. Some didn't need the inclusion, some needed manual addition while adding it to implementation .h or embedding .c file was more appropriate for others. This step added inclusions to around 150 files. 3. The script was run again and the output was compared to the edits from #2 to make sure no file was left behind. 4. Several build tests were done and a couple of problems were fixed. e.g. lib/decompress_*.c used malloc/free() wrappers around slab APIs requiring slab.h to be added manually. 5. The script was run on all .h files but without automatically editing them as sprinkling gfp.h and slab.h inclusions around .h files could easily lead to inclusion dependency hell. Most gfp.h inclusion directives were ignored as stuff from gfp.h was usually wildly available and often used in preprocessor macros. Each slab.h inclusion directive was examined and added manually as necessary. 6. percpu.h was updated not to include slab.h. 7. Build test were done on the following configurations and failures were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my distributed build env didn't work with gcov compiles) and a few more options had to be turned off depending on archs to make things build (like ipr on powerpc/64 which failed due to missing writeq). * x86 and x86_64 UP and SMP allmodconfig and a custom test config. * powerpc and powerpc64 SMP allmodconfig * sparc and sparc64 SMP allmodconfig * ia64 SMP allmodconfig * s390 SMP allmodconfig * alpha SMP allmodconfig * um on x86_64 SMP allmodconfig 8. percpu.h modifications were reverted so that it could be applied as a separate patch and serve as bisection point. Given the fact that I had only a couple of failures from tests on step 6, I'm fairly confident about the coverage of this conversion patch. If there is a breakage, it's likely to be something in one of the arch headers which should be easily discoverable easily on most builds of the specific arch. Signed-off-by: Tejun Heo <tj@kernel.org> Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
* Merge branch 'for-linus' of git://git.monstr.eu/linux-2.6-microblazeLinus Torvalds2010-03-1832-195/+3839
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'for-linus' of git://git.monstr.eu/linux-2.6-microblaze: (27 commits) microblaze: entry.S use delay slot for return handlers microblaze: Save current task directly microblaze: Simplify entry.S - save/restore r3/r4 - ret_from_trap microblaze: PCI early support for noMMU system microblaze: Fix dma alloc and free coherent dma functions microblaze: Add consistent code microblaze: pgtable.h: move consistent functions microblaze: Remove ancient Kconfig option for consistent mapping microblaze: Remove VMALLOC_VMADDR microblaze: Add define for ASM_LOOP microblaze: Preliminary support for dma drivers microblaze: remove trailing space in messages microblaze: Use generic show_mem() microblaze: Change temp register for cmdline microblaze: Preliminary support for dma drivers microblaze: Move cache function to cache.c microblaze: Add support from PREEMPT microblaze: Add support for Xilinx PCI host bridge microblaze: Enable PCI, missing files microblaze: Add core PCI files ...
| * microblaze: entry.S use delay slot for return handlersMichal Simek2010-03-111-6/+3
| | | | | | | | Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Save current task directlyMichal Simek2010-03-111-8/+4
| | | | | | | | Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Simplify entry.S - save/restore r3/r4 - ret_from_trapMichal Simek2010-03-111-48/+30
| | | | | | | | | | | | | | There is possible to save r3/r4 at the beggining of user part before calling handlers and at the end restore it. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: PCI early support for noMMU systemMichal Simek2010-03-114-6/+18
| | | | | | | | Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Fix dma alloc and free coherent dma functionsMichal Simek2010-03-111-4/+13
| | | | | | | | | | | | | | | | | | | | We have to use consistent code to be able to do coherent dma function. In consistent code is used cache inhibit page mapping. Xilinx reported that there is bug in Microblaze for WB and d-cache_always use option. Microblaze 7.30.a should be first version where is this bug removed. Signed-off-by: Michal Simek <monstr@monstr.eu>
| * microblaze: Add consistent codeMichal Simek2010-03-113-1/+256
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove ancient Kconfig option for consistent code. MMU uses cache inhibit pages. noMMU uses UNCACHE SHADOW feature where is used double ram size. For example: Physical ram is 256MB and cache are setup to cover the same size. But if you setup in HW that size is 512MB and cache covers 256MB than you can use adresses from 256-512MB without caches and correspond with 0-256MB with cache. That's why I am using dcache base/high addresses to find out uncache area. Signed-off-by: Michal Simek <monstr@monstr.eu>
OpenPOWER on IntegriCloud