summaryrefslogtreecommitdiffstats
path: root/arch
Commit message (Collapse)AuthorAgeFilesLines
* powerpc: Refuse to build 64-bit with GCC-4.2.0 and CONFIG_MODULESSegher Boessenkool2007-07-161-0/+8
| | | | | | | ...since this won't work (compiler bug, see <http://gcc.gnu.org/PR31490>). Signed-off-by: Segher Boessenkool <segher@kernel.crashing.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* Merge branch 'master' of ↵Linus Torvalds2007-07-1622-456/+5655
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 * 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6: (26 commits) [SPARC64]: Fix UP build. [SPARC64]: dr-cpu unconfigure support. [SERIAL]: Fix console write locking in sparc drivers. [SPARC64]: Give more accurate errors in dr_cpu_configure(). [SPARC64]: Clear cpu_{core,sibling}_map[] in smp_fill_in_sib_core_maps() [SPARC64]: Fix leak when DR added cpu does not bootup. [SPARC64]: Add ->set_affinity IRQ handlers. [SPARC64]: Process dr-cpu events in a kthread instead of workqueue. [SPARC64]: More sensible udelay implementation. [SPARC64]: SMP build fixes. [SPARC64]: mdesc.c needs linux/mm.h [SPARC64]: Fix build regressions added by dr-cpu changes. [SPARC64]: Unconditionally register vio_bus_type. [SPARC64]: Initial LDOM cpu hotplug support. [SPARC64]: Fix setting of variables in LDOM guest. [SPARC64]: Fix MD property lifetime bugs. [SPARC64]: Abstract out mdesc accesses for better MD update handling. [SPARC64]: Use more mearningful names for IRQ registry. [SPARC64]: Initial domain-services driver. [SPARC64]: Export powerd facilities for external entities. ...
| * [SPARC64]: Fix UP build.David S. Miller2007-07-161-1/+1
| | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: dr-cpu unconfigure support.David S. Miller2007-07-164-19/+165
| | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Give more accurate errors in dr_cpu_configure().David S. Miller2007-07-161-3/+13
| | | | | | | | | | | | | | | | | | | | | | | | When cpu_up() fails, we can discern the most likely cause. If cpu_present() is false, this means the cpu did not appear in the MD. If -ENODEV is the error return value, then the processor did not boot properly into the kernel. Pass this information back in the dr-cpu response packet. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Clear cpu_{core,sibling}_map[] in smp_fill_in_sib_core_maps()David S. Miller2007-07-161-0/+2
| | | | | | | | | | | | | | | | When we hot-plug in new cpus, the core_id and proc_id of existing cpus can change. So in order to set the cpu groups correctly we need to clear the maps out completely first. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Fix leak when DR added cpu does not bootup.David S. Miller2007-07-161-6/+6
| | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Add ->set_affinity IRQ handlers.David S. Miller2007-07-161-0/+52
| | | | | | | | | | | | | | | | dr-cpu unconfigure requests will walk throught he enabled IRQs and trigger ->set_affinity so that the going-down cpu no longer has INOs targetted to it. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Process dr-cpu events in a kthread instead of workqueue.David S. Miller2007-07-161-8/+34
| | | | | | | | | | | | | | This will be necessary to handle unconfigure requests properly. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: More sensible udelay implementation.David S. Miller2007-07-167-93/+24
| | | | | | | | | | | | | | | | | | | | Take a page from the powerpc folks and just calculate the delay factor directly. Since frequency scaling chips use a system-tick register, the value is going to be the same system-wide. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: SMP build fixes.David S. Miller2007-07-162-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With the move of ldom_startcpu_cpuid() into smp.c some other things need to follow along: 1) smp.c is not a driver so we can't use "PFX" macro in the printk calls. 2) smp.c now needs asm/io.h and asm/hvtramp.h, ds.c no longer does 3) kimage_addr_to_ra() also needs to move into smp.c While we're here, update copyright info and my email address in smp.c Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: mdesc.c needs linux/mm.hDavid S. Miller2007-07-161-0/+1
| | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Fix build regressions added by dr-cpu changes.David S. Miller2007-07-164-53/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do not select HOTPLUG_CPU from SUN_LDOMS, that causes HOTPLUG_CPU to be selected even on non-SMP which is illegal. Only build hvtramp.o when SMP, just like trampoline.o Protect dr-cpu code in ds.c with HOTPLUG_CPU. Likewise move ldom_startcpu_cpuid() to smp.c and protect it and the call site with SUN_LDOMS && HOTPLUG_CPU. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Unconditionally register vio_bus_type.David S. Miller2007-07-161-7/+7
| | | | | | | | | | | | | | | | The VIO drivers register themselves unconditionally just like those of any other bus type, so to avoid crashes on non-VIO systems we need to always register vio_bus_type. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Initial LDOM cpu hotplug support.David S. Miller2007-07-1610-123/+666
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Only adding cpus is supports at the moment, removal will come next. When new cpus are configured, the machine description is updated. When we get the configure request we pass in a cpu mask of to-be-added cpus to the mdesc CPU node parser so it only fetches information for those cpus. That code also proceeds to update the SMT/multi-core scheduling bitmaps. cpu_up() does all the work and we return the status back over the DS channel. CPUs via dr-cpu need to be booted straight out of the hypervisor, and this requires: 1) A new trampoline mechanism. CPUs are booted straight out of the hypervisor with MMU disabled and running in physical addresses with no mappings installed in the TLB. The new hvtramp.S code sets up the critical cpu state, installs the locked TLB mappings for the kernel, and turns the MMU on. It then proceeds to follow the logic of the existing trampoline.S SMP cpu bringup code. 2) All calls into OBP have to be disallowed when domaining is enabled. Since cpus boot straight into the kernel from the hypervisor, OBP has no state about that cpu and therefore cannot handle being invoked on that cpu. Luckily it's only a handful of interfaces which can be called after the OBP device tree is obtained. For example, rebooting, halting, powering-off, and setting options node variables. CPU removal support will require some infrastructure changes here. Namely we'll have to process the requests via a true kernel thread instead of in a workqueue. workqueues run on a per-cpu thread, but when unconfiguring we might need to force the thread to execute on another cpu if the current cpu is the one being removed. Removal of a cpu also causes the kernel to destroy that cpu's workqueue running thread. Another issue on removal is that we may have interrupts still pointing to the cpu-to-be-removed. So new code will be needed to walk the active INO list and retarget those cpus as-needed. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Fix setting of variables in LDOM guest.David S. Miller2007-07-163-15/+190
| | | | | | | | | | | | | | | | | | There is a special domain services capability for setting variables in the OBP options node. Guests don't have permanent store for the OBP variables like a normal system, so they are instead maintained in the LDOM control node or in the SC. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Fix MD property lifetime bugs.David S. Miller2007-07-161-11/+28
| | | | | | | | | | | | | | | | | | | | Property values cannot be referenced outside of mdesc_grab()/mdesc_release() pairs. The only major offender was the VIO bus layer, easily fixed. Add some commentary to mdesc.h describing these rules. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Abstract out mdesc accesses for better MD update handling.David S. Miller2007-07-165-408/+471
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since we have to be able to handle MD updates, having an in-tree set of data structures representing the MD objects actually makes things more painful. The MD itself is easy to parse, and we can implement the existing interfaces using direct parsing of the MD binary image. The MD is now reference counted, so accesses have to now take the form: handle = mdesc_grab(); ... operations on MD ... mdesc_release(handle); The only remaining issue are cases where code holds on to references to MD property values. mdesc_get_property() returns a direct pointer to the property value, most cases just pull in the information they need and discard the pointer, but there are few that use the pointer directly over a long lifetime. Those will be fixed up in a subsequent changeset. A preliminary handler for MD update events from domain services is there, it is rudimentry but it works and handles all of the reference counting. It does not check the generation number of the MDs, and it does not generate a "add/delete" list for notification to interesting parties about MD changes but that will be forthcoming. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Use more mearningful names for IRQ registry.David S. Miller2007-07-163-5/+15
| | | | | | | | | | | | | | | | | | All of the interrupts say "LDX RX" and "LDX TX" currently which is next to useless. Put a device specific prefix before "RX" and "TX" instead which makes it much more useful. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Initial domain-services driver.David S. Miller2007-07-162-1/+655
| | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Export powerd facilities for external entities.David S. Miller2007-07-161-23/+31
| | | | | | | | | | | | | | | | Besides the existing usage for power-button interrupts, we'll want to make use of this code for domain-services where the LDOM manager can send reboot requests to the guest node. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Add domain-services nodes to VIO device tree.David S. Miller2007-07-161-7/+29
| | | | | | | | | | | | | | They sit under the root of the MD tree unlike the rest of the LDC channel based virtual devices. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Assorted LDC bug cures.David S. Miller2007-07-161-18/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1) LDC_MODE_RELIABLE is deprecated an unused by anything, plus it and LDC_MODE_STREAM were mis-numbered. 2) read_stream() should try to read as much as possible into the per-LDC stream buffer area, so do not trim the read_nonraw() length by the caller's size parameter. 3) Send data ACKs when necessary in read_nonraw(). 4) In read_nonraw() when we get a pure ACK, advance the RX head unconditionally past it. 5) Provide the ACKID field in the ldcdgb() packet dump in read_nonraw(). This helps debugging stream mode LDC channel problems. 6) Decrease verbosity of rx_data_wait() so that it is more useful. A debugging message each loop iteration is too much. 7) In process_data_ack() stop the loop checking when we hit lp->tx_tail not lp->tx_head. 8) Set the seqid field properly in send_data_nack(). Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Do not ACK an INO if it is disabled or inprogress.David S. Miller2007-07-161-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is also a partial workaround for a bug in the LDOM firmware which double-transmits RX inos during high load. Without this, such an event causes the kernel to loop forever in the interrupt call chain ACK'ing but never actually running the IRQ handler (and thus clearing the interrupt condition in the device). There is still a bad potential effect when double INOs occur, not covered by this changeset. Namely, if the INO is already on the per-cpu INO vector list, we still blindly re-insert it and thus we can end up losing interrupts already linked in after it. We could deal with that by traversing the list before insertion, but that's too expensive for this edge case. Signed-off-by: David S. Miller <davem@davemloft.net>
| * [SPARC64]: Add LDOM virtual channel driver and VIO device layer.David S. Miller2007-07-165-0/+3501
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Virtual devices on Sun Logical Domains are built on top of a virtual channel framework. This, with help of hypervisor interfaces, provides a link layer protocol with basic handshaking over which virtual device clients and servers communicate. Built on top of this is a VIO device protocol which has it's own handshaking and message types. At this layer attributes are exchanged (disk size, network device addresses, etc.) descriptor rings are registered, and data transfers are triggers and replied to. Signed-off-by: David S. Miller <davem@davemloft.net>
* | Merge master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6Linus Torvalds2007-07-1697-2358/+4124
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6: (68 commits) sh: sh-rtc support for SH7709. sh: Revert __xdiv64_32 size change. sh: Update r7785rp defconfig. sh: Export div symbols for GCC 4.2 and ST GCC. sh: fix race in parallel out-of-tree build sh: Kill off dead mach.c for hp6xx. sh: hd64461.h cleanup and added comments. sh: Update the alignment when 4K stacks are used. sh: Add a .bss.page_aligned section for 4K stacks. sh: Don't let SH-4A clobber SH-4 CFLAGS. sh: Add parport stub for SuperIO ports. sh: Drop -Wa,-dsp for DSP tuning. sh: Update dreamcast defconfig. fb: pvr2fb: A few more __devinit annotations for PCI. fb: pvr2fb: Fix up section mismatch warnings. sh: Select IPR-IRQ for SH7091. sh: Correct __xdiv64_32/div64_32 return value size. sh: Fix timer-tmu build for SH-3. sh: Add cpu and mach links to CLEAN_FILES. sh: Preliminary support for the SH-X3 CPU. ...
| * | sh: sh-rtc support for SH7709.Kristoffer Ericson2007-07-161-0/+28
| | | | | | | | | | | | | | | Signed-off-by: Kristoffer Ericson <kristoffer.ericson@gmail.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Revert __xdiv64_32 size change.Paul Mundt2007-07-131-2/+2
| | | | | | | | | | | | | | | | | | | | | It's only __div64_32 that needs the fix, __xdiv64_32 behaves as expected with the original size. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Update r7785rp defconfig.Paul Mundt2007-07-131-196/+100
| | | | | | | | | | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Export div symbols for GCC 4.2 and ST GCC.Paul Mundt2007-07-131-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GCC 4.2 can emit integer variants of the FP division routines, so these need to be exported in order to keep the modules happy. 4.1.x versions of the ST compiler have these things backported, and so also generate these symbols (whereas vanilla gcc 4.1.x does not), so handle the __GNUC_STM_RELEASE__ case to accomodate updated versions of the 4.1.x toolchain. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: fix race in parallel out-of-tree buildErik Johansson2007-07-121-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Depending on which of the three dependencies for archprepare (in arch/sh/Makefile) get built first, the directory include/asm-sh may or may not exist when the maketools target is built. If the directory does not exist, awk will fail to generate machtypes.h. This patch fixes this by creating the directory before awk is executed. Signed-off-by: Erik Johansson <erik.johansson@motorola.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Kill off dead mach.c for hp6xx.Kristoffer Ericson2007-07-121-44/+0
| | | | | | | | | | | | | | | Signed-off-by: Kristoffer Ericson <kristoffer.ericson@gmail.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Update the alignment when 4K stacks are used.Robert P. J. Day2007-07-121-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | Use the newly added .bss.page_aligned section for aligning the stacks rather than THREAD_SIZE. Signed-off-by: Robert P. J. Day <rpjday@mindspring.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Add a .bss.page_aligned section for 4K stacks.Paul Mundt2007-07-121-8/+8
| | | | | | | | | | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Don't let SH-4A clobber SH-4 CFLAGS.Paul Mundt2007-07-121-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Older compilers don't support the -m4a{,nofpu} flags, which has the side-effect of allowing FP operations to be emitted. Switch this to incremental tuning, so we at least have -m4-nofpu as a fallback for the gcc3 toolchains. Without this, certain modules emit references to __udivsi3_i4 and __sdivsi3_i4. Reported-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Drop -Wa,-dsp for DSP tuning.Paul Mundt2007-07-071-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | We already hand off the proper ISA variant with the dsp specifier appended, so we don't need to explicitly set -dsp. This causes some confusion with certain toolchains that are restricted to -dsp family opcodes artificially. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Update dreamcast defconfig.Paul Mundt2007-07-071-190/+148
| | | | | | | | | | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Select IPR-IRQ for SH7091.Paul Mundt2007-07-071-0/+1
| | | | | | | | | | | | | | | | | | Fixes a compile failure for the Dreamcast. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Correct __xdiv64_32/div64_32 return value size.Paul Mundt2007-07-062-8/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | These should be returning a uint32_t, whereas they were erroneously returning a u64 before. As the register sizes are 32-bits, this doesn't really make a lot of sense. Reported-by: Katsuya MATSUBARA <matsu@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Add cpu and mach links to CLEAN_FILES.Paul Mundt2007-07-061-1/+3
| | | | | | | | | | | | | | | | | | These weren't being cleaned up, so add them to the CLEAN_FILES. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | Merge branch 'x3'Paul Mundt2007-06-2011-6/+1027
| |\ \
| | * | sh: Preliminary support for the SH-X3 CPU.Paul Mundt2007-06-2010-4/+1020
| | | | | | | | | | | | | | | | | | | | | | | | This adds basic support for UP SH-X3. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | sh: Hook up hard_smp_processor_id() for INTC2 block.Paul Mundt2007-06-201-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We need to know the CPU ID in order to calculate the mask and ack registers effectively. Stub this in for UP. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | | sh: Update se7722 defconfig.Paul Mundt2007-06-201-191/+96
| | | | | | | | | | | | | | | | | | | | | | | | Hook up the multi-node stuff for the SE7722. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | | sh: Fix up cf-enabler dependency for SE boards.Paul Mundt2007-06-201-44/+43
| |/ / | | | | | | | | | | | | | | | | | | | | | This was using CONFIG_SH_SOLUTION_ENGINE, where we really wanted CONFIG_SOLUTION_ENGINE. While we're at it, move the whole CF enabler mess somewhere better suited. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Check oops_may_print() in unhandled fault.Paul Mundt2007-06-181-16/+29
| | | | | | | | | | | | | | | | | | | | | Only print out pgd/pte data in the oops path if oops_may_print() holds true. Follows the i386 implementation. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Update SH-2/SH-2A defconfigs.Paul Mundt2007-06-152-328/+159
| | | | | | | | | | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: rework ipr codeMagnus Damm2007-06-1516-286/+404
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch reworks the ipr code by grouping the offset array together with the ipr_data structure in a new data structure called ipr_desc. This new structure also contains the name of the controller in struct irq_chip. The idea behind putting struct irq_chip in there is that we can use offsetof() to locate the base addresses in the irq_chip callbacks. This strategy has much in common with the recently merged intc2 code. One logic change has been made - the original ipr code enabled the interrupts by default but with this patch they are all disabled by default. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: Only support PMB for SH-X cores.Paul Mundt2007-06-151-1/+1
| | | | | | | | | | | | | | | | | | | | | We don't have a PMB for SH-X2 or later, so only enable it for the few CPUs that support it. Fixes up the boot for SH4AL-DSP. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| * | sh: rework intc2 codeMagnus Damm2007-06-155-65/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The shared intc2 code currently contains cpu-specific #ifdefs. This is a tad unclean and it prevents us from using the shared code to drive board-specific irqs on the se7780 board. This patch reworks the intc2 code by moving the base addresses of the intc2 registers into struct intc2_desc. This new structure also contains the name of the controller in struct irq_chip. The idea behind putting struct irq_chip in there is that we can use offsetof() to locate the base addresses in the irq_chip callbacks. One logic change has been made - the original shared intc2 code enabled the interrupts by default but with this patch they are all disabled by default. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
OpenPOWER on IntegriCloud