summaryrefslogtreecommitdiff
path: root/arch
Commit message (Collapse)AuthorAgeFilesLines
* Merge tag 'for-linus-20121212' of ↵Linus Torvalds2012-12-1210-136/+234
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-mn10300 Pull MN10300 changes from David Howells: "miscellaneous MN10300 arch patches. I've based it on top of Al Viro's signal tree - so these patches should be pulled after that." * tag 'for-linus-20121212' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-mn10300: MN10300: Use asm-generic/pci_iomap.h MN10300: Get rid of unused variable from ASB2305 PCI code MN10300: ASB2305 PCI code needs linux/irq.h mn10300/mm/fault.c: Port OOM changes to do_page_fault MN10300: Handle cacheable PCI regions in pci_iomap() MN10300: fix debug polling in ttySM driver MN10300: ttySM: clean up unnecessary casting MN10300: fix SMP synchronization between txdma and serial driver MN10300: fix serial port vdma irq setup for SMP MN10300: cleanup IRQ affinity setting MN10300: ttySM: Use memory barriers correctly in circular buffer logic
| * MN10300: Use asm-generic/pci_iomap.hDavid Howells2012-12-121-0/+1
| | | | | | | | | | | | | | | | The declarations from MN10300's pci_iomap() was removed by commit 34f1bdee1910f7efe3c32e1a891dba4fd21cb3b6 but asm-generic/pci_iomap.h wasn't then #included from asm/io.h. Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: Get rid of unused variable from ASB2305 PCI codeDavid Howells2012-12-121-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | Get rid of an unused variable in pcibios_fixup_device_resources() which leads to the following warning: arch/mn10300/unit-asb2305/pci.c: In function 'pcibios_fixup_device_resources': arch/mn10300/unit-asb2305/pci.c:324:24: warning: unused variable 'region' [-Wunused-variable] Whilst we're at it, merge the two integer variable declarations into one line. Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: ASB2305 PCI code needs linux/irq.hDavid Howells2012-12-121-0/+1
| | | | | | | | | | | | | | ASB2305 PCI code needs to #include linux/irq.h for XIRQ1 so that it can set the CPU interrupt priority level on the PCI interrupt. Signed-off-by: David Howells <dhowells@redhat.com>
| * mn10300/mm/fault.c: Port OOM changes to do_page_faultKautuk Consul2012-12-121-8/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit d065bd810b6deb67d4897a14bfe21f8eb526ba99 (mm: retry page fault when blocking on disk transfer) and commit 37b23e0525d393d48a7d59f870b3bc061a30ccdb (x86,mm: make pagefault killable) The above commits introduced changes into the x86 pagefault handler for making the page fault handler retryable as well as killable. These changes reduce the mmap_sem hold time, which is crucial during OOM killer invocation. Port these changes to mn10300. Signed-off-by: Kautuk Consul <consul.kautuk@gmail.com> Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: Handle cacheable PCI regions in pci_iomap()David Howells2012-12-122-1/+36
| | | | | | | | | | | | | | Handle cacheable PCI regions in pci_iomap(). If IORESOURCE_CACHEABLE is set then we AND away the 0x20000000 "flag". Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: fix debug polling in ttySM driverMark Salter2012-12-121-12/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The debug polling interface for the SoC serial ports did not work in the case where the serial ports were not also used as a console. In that case, the uart driver startup function will not be called so tx and rx would not be enabled in the hardware control register. Also, vdma interrupts would not be enabled which the poll_get_char function relied on. This patch makes sure that the rx and tx enables are set as a consequence of the uart set_termios call which is the only initialization done for the debug polling interface. Also, the poll_get_char now handles the case where vdma interrupts are not enabled. Signed-off-by: Mark Salter <msalter@redhat.com> Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: ttySM: clean up unnecessary castingMark Salter2012-12-122-6/+6
| | | | | | | | | | | | | | | | The ttySM uart data register pointers are declared as void* pointers. Change them to u8* pointers so we don't need to use casts in the code. Signed-off-by: Mark Salter <msalter@redhat.com> Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: fix SMP synchronization between txdma and serial driverMark Salter2012-12-124-48/+90
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The SoC serial port driver uses a high priority interrupt to handle tx of characters in the tx ring buffer. The driver needs to disable/enable this IRQ from outside of irq context. The original code to do this is not foolproof on SMP machines because the IRQ running on one core could still access the serial port for a short time after the driver running on another core disables the interrupt. This patch adds a flag to tell the IRQ handler that the driver wants to disable the interrupt. After seeing the flag, the IRQ handler will immediately disable the interrupt and exit. After setting the flag, the driver will wait for interrupt to be disabled by the IRQ handler. Signed-off-by: Mark Salter <msalter@redhat.com> Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: fix serial port vdma irq setup for SMPMark Salter2012-12-121-4/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The builtin SoC serial ports have no FIFOs and use a virtual DMA mechanism based on high priority IRQs to avoid overruns. These high priority interrupts are pinned to cpu#0 on SMP systems. This patch fixes a problem with SMP where the set_intr_level() interface is used to set the priority for these IRQs. The set_intr_level() function sets priority on the local cpu but on SMP systems, this code may be run on some other cpu than the one handling the interrupts. Instead of setting interrupt level explicitly, this patch uses a special irq_chip for these interrupts so that the mask/unmask methods can set the interrupt level implicitly. Signed-off-by: Mark Salter <msalter@redhat.com> Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: cleanup IRQ affinity settingMark Salter2012-12-123-52/+17
| | | | | | | | | | | | | | | | | | | | | | | | The irq_set_affinity handler for the mn10300 cpu pic had some hard-coded IRQs which were not to be migrated from one cpu to another. This patch cleans those up by using a combination of IRQF_NOBALANCING and specialized irq chips with no irq_set_affinity handler. This maintains the previous behavior by using generic IRQ interfaces rather than hard coding IRQ numbers in the default irq_set_affinity handler. Signed-off-by: Mark Salter <msalter@redhat.com> Signed-off-by: David Howells <dhowells@redhat.com>
| * MN10300: ttySM: Use memory barriers correctly in circular buffer logicDavid Howells2012-12-121-6/+8
| | | | | | | | | | | | | | | | Use memory barriers correctly in the circular buffer logic used in the driver, as documented in Documentation/circular-buffers.txt. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Mark Salter <msalter@redhat.com>
* | Merge branch 'for-linus' of ↵Linus Torvalds2012-12-12246-3912/+1226
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal Pull big execve/kernel_thread/fork unification series from Al Viro: "All architectures are converted to new model. Quite a bit of that stuff is actually shared with architecture trees; in such cases it's literally shared branch pulled by both, not a cherry-pick. A lot of ugliness and black magic is gone (-3KLoC total in this one): - kernel_thread()/kernel_execve()/sys_execve() redesign. We don't do syscalls from kernel anymore for either kernel_thread() or kernel_execve(): kernel_thread() is essentially clone(2) with callback run before we return to userland, the callbacks either never return or do successful do_execve() before returning. kernel_execve() is a wrapper for do_execve() - it doesn't need to do transition to user mode anymore. As a result kernel_thread() and kernel_execve() are arch-independent now - they live in kernel/fork.c and fs/exec.c resp. sys_execve() is also in fs/exec.c and it's completely architecture-independent. - daemonize() is gone, along with its parts in fs/*.c - struct pt_regs * is no longer passed to do_fork/copy_process/ copy_thread/do_execve/search_binary_handler/->load_binary/do_coredump. - sys_fork()/sys_vfork()/sys_clone() unified; some architectures still need wrappers (ones with callee-saved registers not saved in pt_regs on syscall entry), but the main part of those suckers is in kernel/fork.c now." * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal: (113 commits) do_coredump(): get rid of pt_regs argument print_fatal_signal(): get rid of pt_regs argument ptrace_signal(): get rid of unused arguments get rid of ptrace_signal_deliver() arguments new helper: signal_pt_regs() unify default ptrace_signal_deliver flagday: kill pt_regs argument of do_fork() death to idle_regs() don't pass regs to copy_process() flagday: don't pass regs to copy_thread() bfin: switch to generic vfork, get rid of pointless wrappers xtensa: switch to generic clone() openrisc: switch to use of generic fork and clone unicore32: switch to generic clone(2) score: switch to generic fork/vfork/clone c6x: sanitize copy_thread(), get rid of clone(2) wrapper, switch to generic clone() take sys_fork/sys_vfork/sys_clone prototypes to linux/syscalls.h mn10300: switch to generic fork/vfork/clone h8300: switch to generic fork/vfork/clone tile: switch to generic clone() ... Conflicts: arch/microblaze/include/asm/Kbuild
| * get rid of ptrace_signal_deliver() argumentsAl Viro2012-11-292-3/+3
| | | | | | | | | | | | | | the first one is equal to signal_pt_regs(), the second is never used (and always NULL, while we are at it). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * new helper: signal_pt_regs()Al Viro2012-11-292-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Always equal to task_pt_regs(current); defined only when we are in signal delivery. It may be different from current_pt_regs() - e.g. architectures like m68k may have pt_regs location on exception different from that on a syscall and signals (just as ptrace handling) may happen on exceptions as well as on syscalls. When they are equal, it's often better to have signal_pt_regs defined (in asm/ptrace.h) as current_pt_regs - that tends to be optimized better than default would be. However, optimisation is the only reason why we might want an arch-specific definition; if current_pt_regs() and task_pt_regs(current) have different values, the latter one is right. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * unify default ptrace_signal_deliverAl Viro2012-11-2916-40/+2
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * flagday: kill pt_regs argument of do_fork()Al Viro2012-11-297-17/+13
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * death to idle_regs()Al Viro2012-11-283-16/+0
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * flagday: don't pass regs to copy_thread()Al Viro2012-11-2832-58/+43
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * bfin: switch to generic vfork, get rid of pointless wrappersAl Viro2012-11-285-54/+7
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * xtensa: switch to generic clone()Al Viro2012-11-285-11/+3
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * openrisc: switch to use of generic fork and cloneAl Viro2012-11-286-66/+19
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * unicore32: switch to generic clone(2)Al Viro2012-11-284-25/+7
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * score: switch to generic fork/vfork/cloneAl Viro2012-11-286-58/+8
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * c6x: sanitize copy_thread(), get rid of clone(2) wrapper, switch to generic ↵Al Viro2012-11-284-36/+6
| | | | | | | | | | | | clone() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * take sys_fork/sys_vfork/sys_clone prototypes to linux/syscalls.hAl Viro2012-11-2810-51/+1
| | | | | | | | | | | | now it can be done... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * mn10300: switch to generic fork/vfork/cloneAl Viro2012-11-282-28/+8
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * h8300: switch to generic fork/vfork/cloneAl Viro2012-11-283-44/+6
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * tile: switch to generic clone()Al Viro2012-11-282-8/+1
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * m68k: sanitize copy_thread(), fork/vfork/clone wrappers, switch to generic ↵Al Viro2012-11-284-71/+46
| | | | | | | | | | | | fork/vfork Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * alpha: switch to generic fork/vfork/cloneAl Viro2012-11-284-59/+17
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * s390: switch to generic fork/vfork/cloneAl Viro2012-11-283-42/+14
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * microblaze: switch to generic fork/vfork/cloneAl Viro2012-11-287-56/+12
| | | | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
| * hexagon: switch to generic clone()Al Viro2012-11-284-52/+6
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * sh: switch to generic fork/vfork/cloneAl Viro2012-11-285-110/+11
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * parisc: switch to generic fork/vfork/cloneAl Viro2012-11-284-69/+22
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * m32r: switch to generic fork/vfork/cloneAl Viro2012-11-282-42/+7
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * cris: switch to generic fork/vfork/cloneAl Viro2012-11-284-60/+13
| | | | | | | | | | | | | | same braindamage as on s390 - the first two arguments of clone(2) in the wrong order. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * avr32: sanitize copy_thread(), switch to generic fork/vfork/clone, kill wrappersAl Viro2012-11-284-47/+11
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * arm64: sanitize copy_thread(), switch to generic fork/vfork/cloneAl Viro2012-11-287-28/+12
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * frv: switch to generic fork/vfork/cloneAl Viro2012-11-282-40/+8
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * powerpc: switch to generic fork/clone/vforkAl Viro2012-11-284-32/+4
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * arm: switch to generic fork/vfork/cloneAl Viro2012-11-286-55/+13
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * x86, um: switch to generic fork/vfork/cloneAl Viro2012-11-2816-117/+52
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * get rid of pt_regs argument of ->load_binary()Al Viro2012-11-282-3/+4
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * get rid of pt_regs argument of search_binary_handler()Al Viro2012-11-281-1/+1
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * kill stray kernel_thread() garbageAl Viro2012-11-284-6/+0
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * consolidate sys_execve() prototypeAl Viro2012-11-284-11/+0
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| *-----------------. Merge branches 'no-rebases', 'arch-avr32', 'arch-blackfin', 'arch-cris', ↵Al Viro2012-11-28164-2779/+982
| |\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'arch-h8300', 'arch-m32r', 'arch-mn10300', 'arch-score', 'arch-sh' and 'arch-powerpc' into for-next
| | | | | | | | | | | * powerpc: make fork_idle() take the common "kernel thread" path in copy_thread()Al Viro2012-10-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>