Commit Graph

17485 Commits

Author SHA1 Message Date
Benjamin Herrenschmidt
837c54db21 [POWERPC] Add of_translate_dma_address
This adds a variant of of_translate_address that uses the dma-ranges
property instead of "ranges", it's to be used by PCI code in parsing
the dma-ranges property.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 15:43:35 +11:00
Benjamin Herrenschmidt
f276b5ba0d [POWERPC] Remove useless volatiles in udbg_16550.c
This removes "volatile" from the MMIO pointer udbg_comport
in udbg_16550.c driver, it's useless and makes checkpatch.pl
complain when adding things to this file.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 15:43:35 +11:00
Benjamin Herrenschmidt
6d39635959 [POWERPC] Change 32-bit PCI message about resource allocation
The 32 bits PCI code will display a rather scary error message

   PCI: Cannot allocate resource region N of device XXX

at boot when the existing setup of a device as left by the
firmware doesn't match the kernel needs and the device needs
to be moved.  This is often not an error at all, as the kernel
will generally easily reallocate the device elsewhere.

This changes the message to something less scary and lowers
its level from error to warning.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 15:43:35 +11:00
Benjamin Herrenschmidt
05d3957e11 [POWERPC] Fix powerpc 32-bit resource fixup for 64-bit resources
The 32-bit powerpc resource fixup code uses unsigned longs to do the
offsetting of resources which overflows on platforms such as 4xx where
resources can be 64 bits.

This fixes it by using resource_size_t instead.

However, the IO stuff does rely on some 32 bits arithmetic, so we hack
by cropping the result of the fixups for IO resources with a 32 bits
mask.

This isn't the prettiest but should work for now until we change the
32 bits PCI code to do IO mappings like 64 bits does, within a reserved
are of the kernel address space.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 15:43:35 +11:00
Benjamin Herrenschmidt
13dccb9e65 [POWERPC] Merge pci_process_bridge_OF_ranges()
This merges the 32-bit and 64-bit implementations of
pci_process_bridge_OF_ranges().  The new function is cleaner than both
the old ones, and supports 64 bits ranges on ppc32 which is necessary
for the 4xx port.

It also adds some better (hopefully) output to the kernel log which
should help diagnose problems and makes better use of existing OF
parsing helpers (avoiding a few bugs of both implementations along
the way).

There are still a few unfortunate ifdef's but there is no way around
these for now at least not until some other bits of the PCI code are
made common.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 15:43:35 +11:00
Benjamin Herrenschmidt
25e81f925d [POWERPC] Make isa_mem_base common to 32 and 64 bits
This defines isa_mem_base on both 32 and 64 bits (it used to be 32 bits
only).  This avoids a few ifdef's in later patches and potentially can
allow support for VGA text mode on 64 bits powerpc.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 15:43:34 +11:00
Paul Mackerras
cfad589f56 Merge branch 'linux-2.6' into for-2.6.25 2007-12-11 15:30:27 +11:00
David Gibson
430b01e8f5 [POWERPC] Kill flatdevtree.c
Now that earlier patches have switched the bootwrapper to using libfdt
for device tree manipulation, this patch removes the now unused
flatdevtree.c and related files.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:15 +11:00
David Gibson
2f0dfeaa84 [POWERPC] Use embedded libfdt in the bootwrapper
This incorporates libfdt (from the source embedded in an earlier
commit) into the wrapper.a library used by the bootwrapper.  This
includes adding a libfdt_env.h file, which the libfdt sources need in
order to integrate into the bootwrapper environment, and a
libfdt-wrapper.c which provides glue to connect the bootwrapper's
abstract device tree callbacks to the libfdt functions.

In addition, this changes the various wrapper and platform files to
use libfdt functions instead of the older flatdevtree.c library.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:14 +11:00
David Gibson
1cade99497 [POWERPC] Merge libfdt upstream source
This incorporates a copy of dtc libfdt into the kernel source, in
arch/powerpc/boot/libfdt.  This only imports the upstream sources
verbatim, later patches are needed to actually link it into the kernel
Makefiles.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:13 +11:00
Stephen Rothwell
b76e5e9398 [POWERPC] EEH: Avoid a possible NULL pointer dereference
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:12 +11:00
Stephen Rothwell
1dee20262f [POWERPC] iSeries: Merge vpdinfo.c into pci.c
There was only one global function in vpdinfo.c and it was only called
from pci.c, so merge them and make the function static.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:11 +11:00
Stephen Rothwell
1be9ad6509 [POWERPC] iSeries: Clean up and simplify vdpinfo.c
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:08 +11:00
Stephen Rothwell
cd9afb34ed [POWERPC] iSeries: DeCamelCase vpdinfo.c
This is a purely mechanical transformation.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:07 +11:00
will schmidt
b3b9595f50 [POWERPC] Update xmon slb code
This adds a bit more detail to the xmon SLB output.  When the valid
bit is set, this displays the ESID and VSID values, as well as
decoding the segment size -- 1T or 256M -- and displaying the LLP
bits.  This supresses the output for any slb entries that contain only
zeros.

sample output from power6 (1T segment support):
00 c000000008000000 40004f7ca3000500  1T  ESID=   c00000  VSID=       4f7ca3 LLP:100
01 d000000008000000 4000eb71b0000400  1T  ESID=   d00000  VSID=       eb71b0 LLP:  0
08 0000000018000000 0000c8499f8ccc80 256M ESID=        1  VSID=    c8499f8cc LLP:  0
09 00000000f8000000 0000d2c1a8e46c80 256M ESID=        f  VSID=    d2c1a8e46 LLP:  0
10 0000000048000000 0000ca87eab1dc80 256M ESID=        4  VSID=    ca87eab1d LLP:  0
43 cf00000008000000 400011b260000500  1T  ESID=   cf0000  VSID=       11b260 LLP:100

sample output from power5 (notice the non-valid but non-zero entries)
10 0000000008000000 00004fd0e077ac80 256M ESID=        0  VSID=    4fd0e077a LLP:  0
11 00000000f8000000 00005b085830fc80 256M ESID=        f  VSID=    5b085830f LLP:  0
12 0000000048000000 000052ce99fe6c80 256M ESID=        4  VSID=    52ce99fe6 LLP:  0
13 0000000018000000 000050904ed95c80 256M ESID=        1  VSID=    50904ed95 LLP:  0
14 cf00000008000000 0000d59aca40f500 256M ESID=cf0000000  VSID=    d59aca40f LLP:100
15 c000000078000000 000045cb97751500 256M ESID=c00000007  VSID=    45cb97751 LLP:100

Tested on power5 and power6.

Signed-Off-By: Will Schmidt <will_schmidt@vnet.ibm.com>

Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:46:05 +11:00
Michael Neuling
584f8b71a2 [POWERPC] Use SLB size from the device tree
Currently we hardwire the number of SLBs to 64, but PAPR says we
should use the ibm,slb-size property to obtain the number of SLB
entries.  This uses this property instead of assuming 64.  If no
property is found, we assume 64 entries as before.

This soft patches the SLB handler, so it shouldn't change performance
at all.

Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:45:56 +11:00
Stephen Rothwell
44ef339073 [POWERPC] pci_controller->arch_data really is a struct device_node *
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:37 +11:00
Stephen Rothwell
6207e81695 [POWERPC] Don't special case pci_domain_nr() for iSeries
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:36 +11:00
Stephen Rothwell
9ccc4fd260 [POWERPC] Remove some iSeries platform checks from the PCI code
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:35 +11:00
Stephen Rothwell
c96bede657 [POWERPC] iSeries: hose->buid is always zero for iSeries
so remove a firmware feature test.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:34 +11:00
Stephen Rothwell
cb99302909 [POWERPC] iSeries: Call iSeries_pcibios_init from setup_arch
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:32 +11:00
Stephen Rothwell
e60516e3d0 [POWERPC] Inline pci_setup_pci_controller as it has become trivial
and it becomes clear that we should use zalloc_maybe_bootmem.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:31 +11:00
Stephen Rothwell
53761746ec [POWERPC] iSeries: Make pcibios_final_fixup not depend on pci_dn
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:30 +11:00
Stephen Rothwell
3b32c162bb [POWERPC] iSeries: Reduce dependence on pci_dn bussubno
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:28 +11:00
Stephen Rothwell
2cd1008cf5 [POWERPC] iSeries: iseries_ds_addr is only used in pci.c
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:27 +11:00
Stephen Rothwell
72ece3b827 [POWERPC] iSeries: Remove pci_dn dependency from iSeries_Device_Information
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:25 +11:00
Stephen Rothwell
3448938846 [POWERPC] iSeries: Remove one layer of IO routines
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:24 +11:00
Stephen Rothwell
0d416f2a9e [POWERPC] iSeries: Consoldiate PCI IO error check
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:23 +11:00
Stephen Rothwell
3f1786328a [POWERPC] iSeries: Unindent and clean iSeries_pci_final_fixup
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:22 +11:00
Stephen Rothwell
6a90579334 [POWERPC] iSeries: Remove some dead code from pci.c
and an unnecessary cast.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:20 +11:00
Stephen Rothwell
7a73bd7f06 [POWERPC] iSeries: DeCamelCase pci.c
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:19 +11:00
Stephen Rothwell
b9b1812cad [POWERPC] iSeries: Cleanup PCI retry code a little
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:17 +11:00
Stephen Rothwell
9103eb7d3a [POWERPC] iSeries: Move find_Device_Node to avoid a forward declaration
Also remove another unnecessary forward declaration.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:42:16 +11:00
Stephen Rothwell
96188ce57b [POWERPC] pSeries: Remove dependency on pci_dn bussubno
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:41:36 +11:00
Stephen Rothwell
68d315f597 [POWERPC] iommu_free_table doesn't need the device_node
It only needs the iommu_table address.  It also makes use of the node
name to print error messages.  So just pass it the things it needs.
This reduces the places that know about the pci_dn by one.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:41:33 +11:00
Nathan Lynch
0d9dc4b473 [POWERPC] lparcfg: Remove useless buffer allocation
The 'data' member of proc_ppc64_lparcfg is unused, but the lparcfg
module's init routine allocates 4K for it.

Remove the code which allocates and frees this buffer.

Signed-off-by: Nathan Lynch <ntl@pobox.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:41:28 +11:00
Ishizaki Kou
24f1f17579 [POWERPC] Update celleb_defconfig to add support for native CBE
Signed-off-by: Kou Ishizaki <Kou.Ishizaki@toshiba.co.jp>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:41:25 +11:00
Ishizaki Kou
9858ee8ac5 [POWERPC] celleb: Add support for native CBE
This adds support for native CBE on Celleb, that is, without the BEAT
hypervisor.  Many codes in platforms/cell/ are used in native CBE
environment.

Signed-off-by: Kou Ishizaki <Kou.Ishizaki@toshiba.co.jp>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:34:40 +11:00
Ishizaki Kou
c7a3f93d00 [POWERPC] cell: Fix undefined reference to mmio_nvram_init
This fixes the following link error with CONFIG_PPC_CELL_NATIVE=y and
CONFIG_PPC_CELL_BLADE=n:

arch/powerpc/platforms/built-in.o: In function `.cell_setup_arch':
setup.c:(.init.text+0xe80): undefined reference to `.mmio_nvram_init'

Signed-off-by: Kou Ishizaki <Kou.Ishizaki@toshiba.co.jp>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:34:39 +11:00
Stephen Rothwell
94b146ceee [POWERPC] kernel_execve is identical in 32 and 64 bit
so consolidate it into misc.S.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:34:39 +11:00
Stephen Rothwell
18cce5d321 [POWERPC] Use of_register_driver to implement of_register_platform_driver
Also use of_unregister_driver to implement of_unregister_platform_driver.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-11 13:34:39 +11:00
Linus Torvalds
437105f2a7 Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6:
  [IA64] Fix iosapic interrupt delivery mode for CPE
  [IA64] kprobe: make kreturn probe handler stack unwind correct
  [IA64] operator priority fix in acpi_map_lsapic()
  [IA64] Add missing "space" to concatenated strings
  [IA64] make full use of macro efi_md_size
  [IA64] rename _bss to __bss_start
  [IA64] SGI Altix : fix bug in sn_io_late_init()
  [IA64] iosapic cleanup
  [IA64] signal : fix missing error checkings
  [IA64] export copy_page() to modules
  [IA64] don't assume that unwcheck.py is executable
  [IA64] increase .data.patch offset
2007-12-10 14:40:46 -08:00
Benjamin Herrenschmidt
6d98bda79b powerpc: Fix IDE legacy vs. native fixups
PowerMac and CHRP/BriQ platforms have quirks to switch some IDE
controllers from legacy mode to fully native mode. Those quirks
however will not work properly anymore due to a change to the
generic code to better handle legacy IDE resources.

This fixes it by moving those quirk to "early" quirks (so they
run before resources are probed for the devices) and clearing
all BARs after the conversion to force a reallocation of sane
values.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-10 07:39:54 -08:00
Paul Mackerras
b242a60206 Merge branch 'linux-2.6' 2007-12-10 15:41:22 +11:00
Kenji Kaneshige
aa0ebec9cf [IA64] Fix iosapic interrupt delivery mode for CPE
If "CPEI Processor Override" bit is not set in "Platform Interrupt
Source Flags" in "Platform Interrupt Sources Structure" in ACPI MADT,
the target processor of CPEI is restricted to a specific CPU. Because
of this, the delivery mode for CPEI should be IOSAPIC_FIXED.

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:13:03 -08:00
Shaohua Li
3661999a17 [IA64] kprobe: make kreturn probe handler stack unwind correct
Restore regs->ccr_iip before kreturn probe handler runs. In this way, if
probe handler does unwind, unwind can correctly get the stack trace.

Fixes: http://sourceware.org/bugzilla/show_bug.cgi?id=5051

Signed-off-by: Shaohua Li <shaohua.li@intel.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:12:50 -08:00
Roel Kluin
965d747264 [IA64] operator priority fix in acpi_map_lsapic()
'!' has a higher priority than '&', so as was
this won't test the first bit, but rather evaluates to false for any non-zero
lsapic->lapic_flags.

Signed-off-by: Roel Kluin <12o3l@tiscali.nl>
Acked-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:12:30 -08:00
Joe Perches
c2eeb321a8 [IA64] Add missing "space" to concatenated strings
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:12:17 -08:00
Li Zefan
685c7f5d36 [IA64] make full use of macro efi_md_size
Macro efi_md_size is defined in efi.c, and here we apply it throughout
efi.c.

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Acked-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:12:00 -08:00
Bernhard Walle
b898a424ed [IA64] rename _bss to __bss_start
Rename _bss to __bss_start as on other architectures.  That makes it
possible to use the <linux/sections.h> instead of own declarations.  Also
add __bss_stop because that symbol exists on other architectures.

Signed-off-by: Bernhard Walle <bwalle@suse.de>
Cc: "Luck, Tony" <tony.luck@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:11:49 -08:00
Mike Habeck
afc2cf35b4 [IA64] SGI Altix : fix bug in sn_io_late_init()
When initializing pci_controller->node to point to the closest node we need
to take into consideration that a PIC PCI Bridge ASIC can be connected to a
headless/memless node just like the TIOCP and TIOCE Bridge ASICs

Signed-off-by: Mike Habeck <habeck@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:11:37 -08:00
Simon Horman
9e004ebd2d [IA64] iosapic cleanup
Make some IOSAPIC functions static and remove one that is unused.

Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:11:12 -08:00
Shi Weihua
b9ab117c2f [IA64] signal : fix missing error checkings
Not all the return value of __copy_from_user and
__put_user is checked.This patch fixed it.

Signed-off-by: Shi Weihua <shiwh@cn.fujitsu.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:10:59 -08:00
Andrew Morton
bdc2619ab9 [IA64] export copy_page() to modules
With the unionfs patch applied I get

ERROR: "copy_page" [fs/unionfs/unionfs.ko] undefined!

the other architectures (some, at least) export copy_page() so I guess ia64
should also do so.

To do this we need to move the copy_page() functions out of lib.a and into
built-in.o and add the EXPORT_SYMBOL().

Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 16:10:19 -08:00
Andrew Morton
ff08e657f3 [IA64] don't assume that unwcheck.py is executable
Don't assume that this file has execute permissions.  For example, patch(1)
loses that information.

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 14:42:08 -08:00
Andrew Morton
1f0abae878 [IA64] increase .data.patch offset
/opt/crosstool/gcc-3.4.5-glibc-2.3.6/ia64-unknown-linux-gnu/lib/gcc/ia64-unknown-linux-gnu/3.4.5/../../../../ia64-unknown-linux-gnu/bin/ld: section .data.patch [a000000000000500 -> a000000000000507] overlaps section .dynamic [a0000000000003c8 -> a000000000000507]

This only appears to be a problem with strangely configured
cross-compilation ... native compilers don't have this issue.
But in the interests of helping others at least compile for
ia64, this can go in. -Tony

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2007-12-07 14:28:02 -08:00
Benjamin Herrenschmidt
bff713b562 ibm_newemac: Cleanup/fix support for STACR register variants
There are a few variants of the STACR register that affect more than
just the "AXON" version of EMAC. Replace the current test of various
chip models with tests for generic properties in the device-tree.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-12-07 15:09:06 -05:00
Benjamin Herrenschmidt
1f57877a39 ibm_newemac: Cleanup/Fix RGMII MDIO support detection
More than just "AXON" version of EMAC RGMII supports MDIO, so replace
the current test with a generic property in the device-tree that
indicates such support.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Stefan Roese <sr@denx.de>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-12-07 15:09:06 -05:00
Linus Torvalds
e17587b5b9 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/hskinnemoen/avr32-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/hskinnemoen/avr32-2.6:
  [AVR32] Fix wrong pt_regs in critical exception handler
  [AVR32] Fix copy_to_user_page() breakage
  [AVR32] Follow the rules when dealing with the OCD system
  [AVR32] Clean up OCD register usage
  [AVR32] Implement irqflags trace and lockdep support
  [AVR32] Implement stacktrace support
  [AVR32] Kconfig: Use def_bool instead of bool + default
  [AVR32] Fix invalid status register bit definitions in asm/ptrace.h
  [AVR32] Add TIF_RESTORE_SIGMASK to the work masks
2007-12-07 11:00:31 -08:00
Linus Torvalds
f3656b9a27 Merge branch 'master' of 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:
  [SPARC64]: Fix memory controller register access when non-SMP.
2007-12-07 10:59:33 -08:00
Haavard Skinnemoen
5998a3cf32 [AVR32] Fix wrong pt_regs in critical exception handler
It's not like it really matters at this point since the system is
dying anyway, but handle_critical pushes too few registers on the
stack so the register dump, which makes the register dump look a bit
strange. This patch fixes it.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:54:48 +01:00
Haavard Skinnemoen
68ca3e537f [AVR32] Fix copy_to_user_page() breakage
The current implementation of copy_to_user_page() gives "vaddr" to the
cache instruction when trying to sync the icache with the dcache. If
vaddr does not exist in the TLB, the CPU will silently abort the
operation, which may result in the caches staying out of sync.

To fix this, pass the "dst" parameter to flush_icache_range() instead
-- we know this is valid because we just wrote to it.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:54:47 +01:00
Haavard Skinnemoen
2507bc1338 [AVR32] Follow the rules when dealing with the OCD system
The current debug trap handling code does a number of things that are
illegal according to the AVR32 Architecture manual. Most importantly,
it may try to schedule from Debug Mode, thus clearing the D bit, which
can lead to "undefined behaviour".

It seems like this works in most cases, but several people have
observed somewhat unstable behaviour when debugging programs,
including soft lockups. So there's definitely something which is not
right with the existing code.

The new code will never schedule from Debug mode, it will always exit
Debug mode with a "retd" instruction, and if something not running in
Debug mode needs to do something debug-related (like doing a single
step), it will enter debug mode through a "breakpoint" instruction.
The monitor code will then return directly to user space, bypassing
its own saved registers if necessary (since we don't actually care
about the trapped context, only the one that came before.)

This adds three instructions to the common exception handling code,
including one branch. It does not touch super-hot paths like the TLB
miss handler.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:54:46 +01:00
Haavard Skinnemoen
8dfe8f29cd [AVR32] Clean up OCD register usage
Generate a new set of OCD register definitions in asm/ocd.h and rename
__mfdr() and __mtdr() to ocd_read() and ocd_write() respectively.

The bitfield definitions are a lot more complete now, and they are
entirely based on bit numbers, not masks. This is because OCD
registers are frequently accessed from assembly code, where bit
numbers are a lot more useful (can be fed directly to sbr, bfins,
etc.)

Bitfields that consist of more than one bit have two definitions:
_START, which indicates the number of the first bit, and _SIZE, which
indicates the number of bits. These directly correspond to the
parameters taken by the bfextu, bfexts and bfins instructions.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:54:40 +01:00
Haavard Skinnemoen
320516b78b [AVR32] Implement irqflags trace and lockdep support
Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:52:37 +01:00
Haavard Skinnemoen
2f0260371f [AVR32] Implement stacktrace support
Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:52:36 +01:00
Haavard Skinnemoen
58bd2bfebd [AVR32] Kconfig: Use def_bool instead of bool + default
Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:52:35 +01:00
Haavard Skinnemoen
df679771ce [AVR32] Fix invalid status register bit definitions in asm/ptrace.h
The 'H' bit is bit 29, while the 'R' bit doesn't exist. Luckily, we
don't actually use any of the bits in question.

Also update show_regs() to show the Debug Mask and Debug state bits.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-12-07 14:52:33 +01:00
David S. Miller
b332b8bc9c [SPARC64]: Fix memory controller register access when non-SMP.
get_cpu() always returns zero on non-SMP builds, but we
really want the physical cpu number in this code in order
to do the right thing.

Based upon a non-SMP kernel boot failure report from Bernd Zeimetz.

Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-07 01:10:14 -08:00
Linus Torvalds
5fa2e15913 Merge branch 'merge' of master.kernel.org:/pub/scm/linux/kernel/git/paulus/powerpc
* 'merge' of master.kernel.org:/pub/scm/linux/kernel/git/paulus/powerpc:
  [POWERPC] virtex bug fix: Use canonical value for AC97 interrupt xparams
  [POWERPC] Update defconfigs
  [POWERPC] PS3: Update ps3_defconfig
  [POWERPC] Update iseries_defconfig
  [POWERPC] Fix hardware IRQ time accounting problem.
2007-12-06 17:50:07 -08:00
Grant Likely
7cc955c8fd [POWERPC] virtex bug fix: Use canonical value for AC97 interrupt xparams
The ml300 and ml403 xparameters.h files use different macros for the
AC97 interrupt pin assignments.  This normalizes them to a canonical
value similar to what EDK generates for most other devices.  This is
needed to get ml300 support to compile in arch/ppc.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-07 11:43:55 +11:00
Linus Torvalds
f194d132e4 Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
  ACPI: suspend: old debugging hacks sneaked back
  Freezer: Fix JFFS2 garbage collector freezing issue (rev. 2)
  HWMON: coretemp, suspend fix
  Freezer: Fix APM emulation breakage
  Freezer: Fix s2disk resume from initrd
2007-12-06 14:14:16 -08:00
Len Brown
f7a5274d7d Pull suspend-2.6.24 into release branch 2007-12-06 16:26:52 -05:00
Pavel Machek
74d0f3338f ACPI: suspend: old debugging hacks sneaked back
Old debugging hack sneaked back during x86 merge, this removes it.

Signed-off-by: Pavel Machek <pavel@suse.cz>
Acked-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Len Brown <len.brown@intel.com>
2007-12-06 16:03:06 -05:00
Linus Torvalds
09f3eca2b7 Merge branch 'for-2.6.24' of git://git.kernel.org/pub/scm/linux/kernel/git/galak/powerpc
* 'for-2.6.24' of git://git.kernel.org/pub/scm/linux/kernel/git/galak/powerpc:
  [POWERPC] Fix swapper_pg_dir size when CONFIG_PTE_64BIT=y on FSL_BOOKE
2007-12-06 12:27:09 -08:00
Linus Torvalds
e1b7361f32 Merge git://git.kernel.org/pub/scm/linux/kernel/git/kyle/parisc-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/kyle/parisc-2.6:
  [PARISC] lba_pci: pci_claim_resources disabled expansion roms
  [PARISC] print more than one character at a time for pdc console
  [PARISC] Update parisc-linux MAINTAINERS entries
  [PARISC] timer interrupt should not be IRQ_DISABLED
  Revert "[PARISC] import necessary bits of libgcc.a"
2007-12-06 12:26:17 -08:00
Kumar Gala
bee86f14d5 [POWERPC] Fix swapper_pg_dir size when CONFIG_PTE_64BIT=y on FSL_BOOKE
The size of swapper_pg_dir is 8k instead of 4k when using 64-bit PTEs
(CONFIG_PTE_64BIT).

This was reported by Cedric Hombourger <chombourger@gmail.com>

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-12-06 13:11:04 -06:00
Linus Torvalds
ceaeee6ad6 Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
  [MIPS] Oprofile: Fix computation of number of counters.
  [MIPS] Alchemy: fix IRQ bases
  [MIPS] Alchemy: replace ffs() with __ffs()
  [MIPS] BCM1480: Fix interrupt routing, take 2.
2007-12-06 09:43:26 -08:00
Linus Torvalds
3743d33edf Tiny clean-up of OPROFILE/KPROBES configuration
Make the Kconfig.instrumentation file a bit easier on the eyes, and use
the new ARCH_SUPPORTS_OPROFILE for x86[-64].

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-06 09:41:12 -08:00
Ralf Baechle
00a5825332 Fix oprofile configuration breakage
The cleanup 09cadedbdc broke the oprofile
configuration for MIPS by allowing oprofile support to be built for
kernel models where oprofile doesn't have a chance in hell to work.

Just a dependecy list on a number of architectures is - surprise - broken
and should as per past discussions probably in most considered to be
broken in most cases.  So I introduce a dependency for the oprofile
configuration on ARCH_SUPPORTS_OPROFILE.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-06 09:37:03 -08:00
Kyle McMartin
721fdf3416 [PARISC] print more than one character at a time for pdc console
There's really no reason not to print more than one character at a
time to the PDC console... Booting is measurably speedier, and now I don't
have to watch individual characters get drawn.

Signed-off-by: Kyle McMartin <kyle@mcmartin.ca>
2007-12-06 09:32:15 -08:00
Kyle McMartin
2421ba5b57 [PARISC] timer interrupt should not be IRQ_DISABLED
The timer interrupt had accidentally been marked IRQ_DISABLED since
IRQ_PER_CPU had been OR-ed in, instead of set. This had been working
by accident for quite a while.

Commit c642b8391c changed the behaviour of
IRQ_PER_CPU interrupts, which previously weren't checked for IRQ_DISABLED.

Signed-off-by: Kyle McMartin <kyle@mcmartin.ca>
2007-12-06 09:16:45 -08:00
Kyle McMartin
9d29213fd4 Revert "[PARISC] import necessary bits of libgcc.a"
This reverts commit efb80e7e09, it turned
out to cause sporadic problems with the timer interrupt on 32-bit kernels.
Needs more investigation.

Signed-off-by: Kyle McMartin <kyle@mcmartin.ca>
2007-12-06 09:16:29 -08:00
Ralf Baechle
5e2862eb5a [MIPS] Oprofile: Fix computation of number of counters.
VSMP kernels will split the available performance counters between the two
processors / cores.  But don't do this when we're not on a VSMP system ...

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-12-06 17:15:58 +00:00
Sergei Shtylyov
0e8120e094 [MIPS] Alchemy: fix IRQ bases
Do what the commits commits f3e8d1da38 and
9d360ab4a7 failed to achieve -- actually
convert the Alchemy code to irq_cpu.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-12-06 17:15:58 +00:00
Sergei Shtylyov
4b36673284 [MIPS] Alchemy: replace ffs() with __ffs()
Fix havoc wrought by commit 56f621c7f6 --
au_ffs() and ffs() are equivalent, that patch should have just replaced one
with another.  Now replace ffs() with __ffs() which returns an unbiased bit
number.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-12-06 17:15:58 +00:00
Ralf Baechle
f435a91e66 [MIPS] BCM1480: Fix interrupt routing, take 2.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-12-06 17:15:57 +00:00
Paul Mackerras
43af66e135 [POWERPC] Update defconfigs
This updates all the defconfigs in arch/powerpc/configs except iseries
and ps3, which were updated by the preceding commits.

This mostly takes the defaults, except that I turned on tickless idle
and high-resolution timers for everything, and turned off instrumentation
support and "Fair group CPU scheduler" for the smaller/embedded platforms.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 16:54:02 +11:00
Geoff Levand
b3330def90 [POWERPC] PS3: Update ps3_defconfig
Update ps3_defconfig.

Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 16:09:00 +11:00
Stephen Rothwell
d4a76d2bdf [POWERPC] Update iseries_defconfig
The notable changes here are the enabling of NO_HZ and HIGH_RES_TIMERS.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 16:09:00 +11:00
Tony Breeds
81a3843f97 [POWERPC] Fix hardware IRQ time accounting problem.
The commit fa13a5a1f2 (sched: restore
deterministic CPU accounting on powerpc), unconditionally calls
update_process_tick() in system context.  In the deterministic
accounting case this is the correct thing to do.  However, in the
non-deterministic accounting case we need to not do this, since doing
this results in the time accounted as hardware irq time being
artificially elevated.

Also this collapses 2 consecutive '#ifdef CONFIG_VIRT_CPU_ACCOUNTING'
checks in time.h into one for neatness.

Signed-off-by: Tony Breeds <tony@bakeyournoodle.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 16:08:59 +11:00
David Woodhouse
773f76b160 [POWERPC] Implement 'make bootwrapper_install'
This adds a 'bootwrapper_install' make target for the powerpc
architecture, which installs the wrapper script, intermediate object
files and device-tree sources for later use.

This will then allow bootable zImages to be created other than in the
context of a kernel build.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 14:44:30 +11:00
David Woodhouse
5c539ee382 [POWERPC] Allow for bootwrapper utilities being in different directory to objects
It's possible that the executables which are built as helpers for the
bootwrapper stuff might end up in a different place to the intermediate
object files. Handle that.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 14:44:30 +11:00
David Woodhouse
701172d1b8 [POWERPC] Find device-tree source file in default directory
If a .dts file is given to the bootwrapper script without a full path
name, look in a sensible place for it.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 14:44:30 +11:00
David Woodhouse
928b969559 [POWERPC] Create otheros.bld next to specified output file, not in $object directory
The bootwrapper script currently generates an 'otheros.bld' file in
addition to the file specified by the -o option, when asked to build a
wrapper for PS3.

It should do that in the same directory as the output, not the directory
where the wrapper objects are kept (which might potentially not be
writable when the script runs).

Arguably, the 'otheros.bld' ought to be created with the filename
specified as the -o argument. But that's a more intrusive change.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Acked-by: Geoff Levand <geoffrey.levand@am.sony.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 14:44:30 +11:00
Cyrill Gorcunov
3a1c81f4fa [POWERPC] CELLEB: Fix possible NULL pointer dereference
This adds checking for NULL returned value from of_get_property to
prevent possible NULL pointer dereference in the case when expected
properties are not present.

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 14:44:30 +11:00
Jon Loeliger
eb8f276341 [POWERPC] Clean out asm/of_{platform, device}.h from sysdev/
Convert #include of asm/of_{platform, device}.h into
linux/of_{platform,device}.h for remaining arch/powerpc files.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 14:44:30 +11:00
Jon Loeliger
5f867dc798 [POWERPC] Clean out asm/of_{platform, device}.h
Convert #include of asm/of_{platform, device}.h into
linux/of_{platform,device}.h for a few scattered platforms.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06 14:44:30 +11:00
Linus Torvalds
2cfae2739b Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [SPARC64]: Update defconfig.
  [SPARC]: Add missing of_node_put
  [SPARC64]: check for possible NULL pointer dereference
  [SPARC]: Add missing "space"
  [SPARC64]: Add missing "space"
  [SPARC64]: Add missing pci_dev_put
  [SYSCTL_CHECK]: Fix typo in KERN_SPARC_SCONS_PWROFF entry string.
  [SPARC64]: Missing mdesc_release() in ldc_init().
2007-12-05 09:25:53 -08:00
Al Viro
79901a9738 no need to mess with KBUILD_CFLAGS on uml-i386 anymore
Now that X86_32 is provided on Kconfig level for uml-i386, there's no
need to play with it explicitly on Makefile level anymore.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-05 09:25:20 -08:00
David S. Miller
9cb1200a28 [SPARC64]: Update defconfig.
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-05 05:38:01 -08:00
Julia Lawall
b127aa8baf [SPARC]: Add missing of_node_put
There should be an of_node_put when breaking out of a loop that iterates
using for_each_node_by_type.

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-05 05:38:00 -08:00
Cyrill Gorcunov
75c6d1410c [SPARC64]: check for possible NULL pointer dereference
This patch adds checking for possible NULL pointer dereference
if of_find_property() failed.

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-05 05:37:59 -08:00
Joe Perches
794b26e060 [SPARC]: Add missing "space"
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-05 05:37:58 -08:00
Joe Perches
519c4d2deb [SPARC64]: Add missing "space"
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-05 05:37:58 -08:00
Julia Lawall
55c45a3ad8 [SPARC64]: Add missing pci_dev_put
There should be a pci_dev_put when breaking out of a loop that iterates
over calls to pci_get_device and similar functions.

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-05 05:37:57 -08:00
David S. Miller
6fab2600f9 [SPARC64]: Missing mdesc_release() in ldc_init().
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-05 05:37:55 -08:00
Paul Mackerras
cc1bf182bb Merge branch 'for-2.6.25' of git://git.kernel.org/pub/scm/linux/kernel/git/olof/pasemi into for-2.6.25 2007-12-05 16:13:25 +11:00
Linus Torvalds
2254c2e018 Merge branch 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6
* 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6:
  [S390] Make sure the restore psw masks are initialized.
  [S390] Fix compile error on 31bit without preemption
  [S390] dcssblk: prevent early access without own make_request function
  [S390] cio: add missing reprobe loop end statement
  [S390] cio: Issue SenseID per path.
2007-12-04 09:37:39 -08:00
Andrew Morton
da54becc71 x86: arch_register_cpu() section fix
fix this on i386 allnoconfig:

 WARNING: vmlinux.o(.text+0x6f2e): Section mismatch: reference to .init.text:register_cpu (between 'arch_register_cpu' and 'text_poke')

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2007-12-04 17:19:07 +01:00
Adrian Bunk
f22d9bc1e8 x86: free_cache_attributes() section fix
free_cache_attributes() must be __cpuinit since it calls the
__cpuinit cache_remove_shared_cpu_map().

This patch fixes the following section mismatch reported by
Chris Clayton:

 ...
 WARNING: vmlinux.o(.text+0x90b6): Section mismatch: reference to .init.text:cache_remove_shared_cpu_map (between 'free_cache_attributes' and 'show_level')
 ...

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2007-12-04 17:19:07 +01:00
Don Zickus
75bc122c2d x86: add the word 'WARNING' in check_nmi_watchdog() output
Our automated test suite looks for keywords like error, fail, warning in
the boot log.  In the case when the nmi watchdog is determined to be
stuck in check_nmi_watchdog(), none of those keywords are displayed.

This patch adds a keyword, "WARNING:", so it makes it easier to notice
when the nmi watchdog isn't working correctly. Also add a proper
KERN_WARNING mark to this printout.

Signed-off-by: Don Zickus <dzickus@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2007-12-04 17:19:07 +01:00
Adrian Bunk
ee0011a798 x86: revert CONFIG_X86_HT semantics change
The recent Kconfig changes in x86 resulted in CONFIG_X86_HT no longer
being set if (X86_32 && MK8).

After grep'ing through the tree I think the problem is that different
places have different assumptions about the semantics of CONFIG_X86_HT,
either:

- hyperthreading or
- multicore

This should be sorted out properly, but until then we should keep the
2.6.23 status quo.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2007-12-04 17:19:07 +01:00
Heiko Carstens
7af0d6f753 [S390] Make sure the restore psw masks are initialized.
In case of TRACE_IRQFLAGS the restore psw masks will not be
initialized if noexec is turned on. This will lead to an
immediate system crash.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-12-04 16:09:58 +01:00
Christian Borntraeger
ab1809b4ed [S390] Fix compile error on 31bit without preemption
Commit b8e7a54cd0 introduced a compile
error if CONFIG_PREEMPT is not set:

arch/s390/kernel/built-in.o: In function `cleanup_io_leave_insn':
/space/kvm/arch/s390/kernel/entry.S:(.text+0xbfce): undefined reference to `preempt_schedule_irq'

This patch hides preempt_schedule_irq if CONFIG_PREEMPT is not set.

Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-12-04 16:09:58 +01:00
Olof Johansson
5619965fec [POWERPC] pasemi: Fix module information for gpio-mdio
Fix up the module information for gpio-mdio, it wouldn't load
because of lacking license, and wouldn't auto-load because of missing
MODULE_DEVICE_TABLE.

Signed-off-by: Olof Johansson <olof@lixom.net>
2007-12-03 18:02:34 -06:00
Linus Torvalds
c5ef91eee5 Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6.24
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6.24:
  sh: Support PCI IO access of SH7780 base boards.
  sh: Fix PCI IO space base address of SH7780.
2007-12-03 15:46:37 -08:00
Ralf Baechle
a6733f2e14 [MIPS] BCM1480: Fix interrupt routing.
The old code did did only work as long as CFE and the kernel were using
the same interrupt numbering ...

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-12-03 19:40:26 +00:00
Linus Torvalds
1a2edea9af Merge git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-x86
* git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-x86:
  x86: fix x86-32 early fixmap initialization.
  x86: disable hpet legacy replacement for kdump
  x86: disable hpet on shutdown
2007-12-03 08:45:15 -08:00
Linus Torvalds
f589b86d4b Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc:
  [POWERPC] Remove xmon from ml300 and ml403 defconfig in arch/ppc
  Revert "[POWERPC] Fix RTAS os-term usage on kernel panic"
2007-12-03 08:23:58 -08:00
Eric W. Biederman
17d57a9206 x86: fix x86-32 early fixmap initialization.
pageexec@freemail.hu writes:

> i've just noticed that the chunk in i386/kernel/head.S ended up in a
> weird place, namely, it's not going to be executed as it's just after
> a 'jmp 3f' and before startup_32_smp, probably not what you intended.
> on a sidenote, the whole thing can be done in a single insn, like:
>
> movl $(swapper_pg_pmd - __PAGE_OFFSET + 0x067), (swapper_pg_dir -
> __PAGE_OFFSET+ 4092)

Thanks for the reminder I thought we had fixed this problem a while ago.

Needed to get fixed virtual address for USB debug and earlycon with mmio.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2007-12-03 17:17:10 +01:00
OGAWA Hirofumi
0c1b272406 x86: disable hpet legacy replacement for kdump
we should also add hpet_disable() for kdump.

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2007-12-03 17:17:10 +01:00
OGAWA Hirofumi
c86c7fbc82 x86: disable hpet on shutdown
If HPET was enabled by pci quirks, we use i8253 as initial clockevent
because pci quirks doesn't run until pci is initialized.

The above means the kernel (or something) is assuming HPET legacy
replacement is disabled and can use i8253 at boot.

If we used kexec, it isn't true. So, this patch disables HPET legacy
replacement for kexec in machine_shutdown().

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Acked-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2007-12-03 17:17:10 +01:00
Jeff Dike
ce3b642d42 uml: work around host tcsetattr bug
Under the conditions that UML uses it, tcgetattr is guaranteed to return
-EINTR when the console is attached to /dev/ptmx, making generic_console_write
hang because it loops, calling tcgetattr until it succeeds.  This is a host
bug - see http://marc.info/?l=linux-kernel&m=119618990807182&w=2 for the
details.

This patch works around it by blocking SIGIO while the terminal attributes are
being fiddled.

Signed-off-by: Jeff Dike <jdike@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-03 08:13:17 -08:00
Jeff Dike
0a765329ed uml: after_sleep_interval should return something
I forgot to have an int-returning function actually return something.

Signed-off-by: Jeff Dike <jdike@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-03 08:13:17 -08:00
Jeff Dike
54d67ee22c uml: keep UML Kconfig in sync with x86
Fix a UML build breakage introduced by commit
1032c0ba9d - it introduces X86_32, with many
things which UML needs depending on it.

This patch adds definitions of X86_32 and RWSEM_XCHGADD_ALGORITHM to
the UML/i386 Kconfig.

Signed-off-by: Jeff Dike <jdike@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-03 08:13:17 -08:00
joe@perches.com
44032af0e7 [POWERPC] Add missing spaces in printk formats in arch/ppc
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:27 +11:00
joe@perches.com
df3c9019ed [POWERPC] Add missing spaces in printk formats
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:27 +11:00
Stephen Rothwell
215a5575b5 [POWERPC] Remove redundant declaration of hose_list
It is already declared in ppc-pci.h which is included.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:27 +11:00
Stephen Rothwell
5db9abd936 [POWERPC] iSeries: Fix sparse warnings in setup.c
arch/powerpc/platforms/iseries/setup.c:111:27: warning: constant 0x100000000 is so big it is long
arch/powerpc/platforms/iseries/setup.c:113:23: warning: constant 0x100000000 is so big it is long
arch/powerpc/platforms/iseries/setup.c:117:27: warning: constant 0x000fffffffffffff is so big it is long
arch/powerpc/platforms/iseries/setup.c:127:28: warning: constant 0x100000000 is so big it is long
arch/powerpc/platforms/iseries/setup.c:129:24: warning: constant 0x100000000 is so big it is long
arch/powerpc/platforms/iseries/setup.c:233:5: warning: constant 0x000fffffffffffff is so big it is long
arch/powerpc/platforms/iseries/setup.c:235:5: warning: constant 0x000fffffffffffff is so big it is long
arch/powerpc/platforms/iseries/setup.c:319:6: warning: symbol 'mschunks_alloc' was not declared. Should it be static?
arch/powerpc/platforms/iseries/setup.c:661:6: warning: symbol 'iSeries_early_setup' was not declared. Should it be static?

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:27 +11:00
Stephen Rothwell
26b6d5b170 [POWERPC] iSeries: Declare iSeries_pci_final_fixup in pci.h
Fixes sparse warning:
arch/powerpc/platforms/iseries/pci.c:169:13: warning: symbol 'iSeries_pci_final_fixup' was not declared. Should it be static?

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:27 +11:00
Stephen Rothwell
1e10590475 [POWERPC] iSeries: Mark two functions __init
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:27 +11:00
Stephen Rothwell
ebfc00f78c [POWERPC] Make global_phb_number static
since it's not used outside of arch/powerpc/kernel/pci-common.c.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:26 +11:00
Benjamin Herrenschmidt
5a8a1a28bb [POWERPC] Add xmon function to dump 44x TLB
This adds a function to xmon to dump the content of the 44x processor
TLB with a little bit of decoding (but not much).

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:26 +11:00
Linas Vepstas
5f1a7c811b [POWERPC] EEH: Report errors as soon as possible
Do not wait for the pci slot status before reporting an error
to the device driver. Some systems may take many seconds to
report the slot status, and this can confuse unsuspecting
device drivers.

Signed-off-by: Linas Vepstas <linas@austin.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:26 +11:00
Linas Vepstas
c9b65a7da6 [POWERPC] EEH: Be careful when identifying "empty" slots.
If an "empty" slot is failing, make sure its a permanent failure;
else process the error normally.

Signed-off-by: Linas Vepstas <linas@austin.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:26 +11:00
Linas Vepstas
307d46e832 [POWERPC] EEH: Work with device endpoint, always
Perform all error checking at the "partitonable endpoint"
of the device.

Signed-off-by: Linas Vepstas <linas@austin.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:26 +11:00
Johannes Berg
6215762064 [POWERPC] powermac: Fix warning in time.c
arch/powerpc/platforms/powermac/time.c:88: warning: 'to_rtc_time' defined but not used

This fixes the warning by making the relevant code depend on the
users.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:25 +11:00
Nathan Lynch
d65dded426 [POWERPC] Remove prod_processor()
prod_processor() is unused, and that's a good thing, since it does not
supply the required proc id parameter to H_PROD.

Signed-off-by: Nathan Lynch <ntl@pobox.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:25 +11:00
Benjamin Herrenschmidt
8d089085a4 [POWERPC] Cleanup SMT thread handling
This cleans up the SMT thread handling, removing some hard coded
assumptions and providing a set of helpers to convert between linux
cpu numbers, thread numbers and cores.

This implementation requires the number of threads per core to be a
power of 2 and identical on all cores in the system, but it's an
implementation detail, not an API requirement and so this limitation
can be lifted in the future if anybody ever needs it.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 13:56:25 +11:00
Grant Likely
b80fa3cce7 [POWERPC] Remove xmon from ml300 and ml403 defconfig in arch/ppc
xmon is broken under arch/ppc so remove it from the defconfig.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 10:08:53 +11:00
Paul Mackerras
8f51506164 Revert "[POWERPC] Fix RTAS os-term usage on kernel panic"
This reverts commit a2b51812a4.

It turns out that this change caused some machines to fail to come
back up when being rebooted, and generated an error in the hypervisor
error log on some machines.  The platform architecture (PAPR) is a
little unclear on exactly when the RTAS ibm,os-term function should be
called.  Until that is clarified I'm reverting this commit.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-03 09:39:45 +11:00
Olof Johansson
32e2b55eec [POWERPC] pasemi: Move cpus to hold loop before restart
Use smp_send_stop() to move all cpus besides the one executing reboot
into a hold loop, to keep them from being in powersavings mode at the
time of reboot.

Signed-off-by: Olof Johansson <olof@lixom.net>
2007-12-01 13:04:39 -06:00
Olof Johansson
8b32bc0325 [POWERPC] pasemi: Don't enter powersaving states from elevated astates
When the PWRficient cpus are entered into powersavings states, the
astate is automatically dropped down to 0. While we still restore it
when we come out of idle, it can still cause some weird effects with
respect to performance (especially since it takes a while to ramp up to
higher astates).

So, to avoid this, don't enter power savings when the cpufreq driver
(or user) has set higher astates than 0.

The restore is still required, since there's a chance the astate has
been raised from the other cpu while the idling one was asleep.

Signed-off-by: Olof Johansson <olof@lixom.net>
2007-12-01 13:03:40 -06:00
Linus Torvalds
1811534a80 Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
  [MIPS] Fix build.
  [MIPS] Fix use of smp_processor_id() in preemptible code.
2007-11-30 17:07:38 -08:00
Ralf Baechle
e6a1bb725e [MIPS] Fix build.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-12-01 00:39:37 +00:00
Linus Torvalds
b62c855938 Merge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm:
  [ARM] 4680/1: parentheses around NR_IRQS definition
  [ARM] 4679/1: AT91: Change maintainer email address
  [ARM] 4675/1: pxa: fix mfp address definition error for pxa320
  [ARM] 4674/1: pxa: increase LCD PCLK drive strength to fast 2mA for PXA300/PXA310
  [ARM] 4673/1: pxa: add missing IRQ_SSP4 definitions for PXA3xx
  [ARM] 4672/1: pxa: fix DRCMR(n) to support PXA27x and later processors
  [ARM] 4665/1: fix __und_usr wrt accessing the undefined insn in user space
  [ARM] 4659/1: remove possibilities for spurious false negative with __kuser_cmpxchg
  [ARM] 4661/1: fix do_undefinstr wrt the enabling of IRQs
  [ARM] uengine: fix memset size error
  [ARM] 4648/1: i.MX/MX1 ensure more complete AITC initialization
  [ARM] 4611/2: AT91: Fix GPIO buttons pins on SAM9261-EK.
  [ARM] 4650/1: AT91: New-style init of I2C, support for i2c-gpio
  [ARM] 4604/2: AT91: Master clock divistor on SAM9
  [ARM] 4662/1: Fix PXA serial driver compilation if SERIAL_PXA_CONSOLE is disabled
  [ARM] PXA ssp: unlock when ssp tries to close an invalid port
  [ARM] 4654/1: pxa: update default MFP register value
  [ARM] 4653/1: pxa: fix a gpio typo in mfp-pxa320.h
  [ARM] 4652/1: pxa: fix a typo of pxa27x usb host clk definition
  [ARM] 4651/1: pxa: add PXA3xx specific IRQ definitions
2007-11-30 08:11:18 -08:00
Olof Johansson
0d08a84770 [POWERPC] pasemi: Broaden specific references to 1682M
There will be more product numbers in the future than just PA6T-1682M,
but they will share much of the features. Remove some of the explicit
references and compatibility checks with 1682M, and replace most of them
with the more generic term "PWRficient".

Signed-off-by: Olof Johansson <olof@lixom.net>
Acked-by: Michael Buesch <mb@bu3sch.de>
Acked-by: Doug Thompson <dougthompson@xmission.com>
2007-11-29 22:30:47 -06:00
Olof Johansson
2dd3c00160 [POWERPC] pasemi: clean up mdio_gpio a bit
Misc cleanups of mdio_gpio:
* Better error handling/unrolling in case of init/alloc failures
* Go through child nodes and get their interrupts instead of using
  hardcoded values
* Remap the GPIO registers at module load/driver init instead of during probe
* Coding style and other misc cleanups

Signed-off-by: Olof Johansson <olof@lixom.net>
2007-11-29 22:30:44 -06:00
Nobuhiro Iwamatsu
b0d98dc504 sh: Support PCI IO access of SH7780 base boards.
The IO access of PCI is not supported in R7780RP and the MS7780SE
board now. The support of the IO access mode of e100 and a lot of IDE
chips becomes possible by fixing the code.

Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2007-11-30 12:36:13 +09:00