safe/jmp/linux-2.6
15 years agoMerge branches 'machtypes', 'core', 'ep93xx', 'ks8695', 'netdev' and 'sa1100' into...
Russell King [Thu, 9 Oct 2008 20:31:54 +0000 (21:31 +0100)]
Merge branches 'machtypes', 'core', 'ep93xx', 'ks8695', 'netdev' and 'sa1100' into devel

15 years ago[ARM] 5295/1: make ZONE_DMA optional
Nicolas Pitre [Tue, 7 Oct 2008 19:14:55 +0000 (20:14 +0100)]
[ARM] 5295/1: make ZONE_DMA optional

Most ARM machines don't need a special "DMA" memory zone, and
when configured out, the kernel becomes a bit smaller:

|   text    data     bss     dec     hex filename
|3826182  102384  111700 4040266  3da64a vmlinux
|3823593  101616  111700 4036909  3d992d vmlinux.nodmazone

This is because the system now has only one zone total which effect is
to optimize away many conditionals in page allocation paths.

So let's configure this zone only on machines that need split zones.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5297/1: [KS8695] Fix two compile-time warnings
Andrew Victor [Tue, 7 Oct 2008 19:44:07 +0000 (20:44 +0100)]
[ARM] 5297/1: [KS8695] Fix two compile-time warnings

Fix two warnings when compiling for the KS8695 processor.

arch/arm/include/asm/dma-mapping.h: In function 'dma_to_virt':
arch/arm/include/asm/dma-mapping.h:40: warning: return makes pointer
from integer without a cast

Section mismatch in reference from the function pcibios_fixup_bus() to
the (unknown reference) .devinit.text:(unknown)
The function pcibios_fixup_bus() references
the (unknown reference) __devinit (unknown).
This is often because pcibios_fixup_bus lacks a __devinit
annotation or the annotation of (unknown) is wrong.

Signed-off-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5296/1: [KS8695] Replace macro's with trailing underscores.
Andrew Victor [Tue, 7 Oct 2008 19:20:15 +0000 (20:20 +0100)]
[ARM] 5296/1: [KS8695] Replace macro's with trailing underscores.

Replace Macro names that have trailing underscores.
Also use the IOPD() macro instead of a hard-coded bit-shift (for
better readability).

Signed-off-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5293/1: ep93xx: add defines for external chipselects
Hartley Sweeten [Mon, 6 Oct 2008 21:43:02 +0000 (22:43 +0100)]
[ARM] 5293/1: ep93xx: add defines for external chipselects

This patch adds defines for the external chipselect physical base
addresses available with the EP93xx. These are meant to be used
in the platform init code.

In addition, documentation about the synchronous/asynchronous boot
modes for the EP93xx and a reference to errata about issues with
synchronous booting has been added.

Signed-off-by: <H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5273/2: ep93xx: move ethernet support into core.c
Hartley Sweeten [Sat, 4 Oct 2008 19:01:49 +0000 (20:01 +0100)]
[ARM] 5273/2: ep93xx: move ethernet support into core.c

All EP93xx based systems can support Ethernet. This patch moves
the platform_device setup from the various board support files
into the core support file. The Ethernet driver data still remains
in the individual platform setup files to allow specific platform
configuration.

This also adds Ethernet support to the edb9302, edb9312, and
edb9315 platforms.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5229/3: Replace some ARMv7 opcodes with the instruction name
Catalin Marinas [Fri, 3 Oct 2008 10:09:10 +0000 (11:09 +0100)]
[ARM] 5229/3: Replace some ARMv7 opcodes with the instruction name

These instructions were placed in the code directly as opcodes because
early compilers didn't support them. Toolchains supporting ARMv7
understand these instructions and the patch puts the mnemonics back.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5276/1: ep93xx: allow selecting UART for early kernel messages
Hartley Sweeten [Thu, 2 Oct 2008 16:13:02 +0000 (17:13 +0100)]
[ARM] 5276/1: ep93xx: allow selecting UART for early kernel messages

Currently on the EP93xx platform early kernel messages go to UART1.
Since this UART is the only one that has modem control signals it
might be used for another purpose and it is undesirable for those
messages to appear. This patch allows one of the other UARTs to be
selected in the kernel configuration. It is assumed that the
bootloader has configured and initialized the UART since this was the
previous assumption.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5274/1: simplify request_standard_resources()
Nicolas Pitre [Thu, 2 Oct 2008 02:29:22 +0000 (03:29 +0100)]
[ARM] 5274/1: simplify request_standard_resources()

There is no point converting memory bank addresses from physical to
virtual just to convert them back to physical addresses.  Furthermore
this isn't "right" for highmem even if in this case the end result is
the correct one.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[NET] 5268/1: cs89x0: add support for i.MX31ADS ARM board.
Gilles Chanteperdrix [Fri, 26 Sep 2008 14:44:43 +0000 (15:44 +0100)]
[NET] 5268/1: cs89x0: add support for i.MX31ADS ARM board.

Add support for i.MX31ADS board to the cs89x0 ethernet driver.

Rework Kconfig options for the cs89x0 driver to reduce the #ifdef
clutter.

Signed-off-by: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5250/1: unbalanced enable_irq() for serial_ks8695.c fix
Dick Hollenbeck [Tue, 16 Sep 2008 17:30:27 +0000 (18:30 +0100)]
[ARM] 5250/1: unbalanced enable_irq() for serial_ks8695.c fix

The function ks8695uart_set_termios() would cause an unbalanced
enable_irq() generated message to be printk()ed. This is because
there was no book keeping support to remember if the calls to
enable_irq() and disable_irq() were balanced for the modem
control irq.

Signed-off-by: Dick Hollenbeck <dick@softplc.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5270/1: Fix Formatting in mach-sa1100/ machine files
Kristoffer Ericson [Mon, 29 Sep 2008 16:09:10 +0000 (17:09 +0100)]
[ARM] 5270/1: Fix Formatting in mach-sa1100/ machine files

This patch fixes formatting issues in mach-sa1100/
machine files. More specificly badge4.c,generic.c and
pleb.c.

Signed-off-by: Kristoffer Ericson <Kristoffer.Ericson@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5256/1: Update jornada default config
Kristoffer Ericson [Thu, 18 Sep 2008 11:36:36 +0000 (12:36 +0100)]
[ARM] 5256/1: Update jornada default config

This patch updates the jornada default
config (which was made for 2.6.12). Plenty
of development has happend since then, most
importantly the SSP driver and kbd/touchscr.

This config has been tested to compile
and bootup properly.

Signed-off-by: Kristoffer Ericson <Kristoffer.Ericson@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: allow LH7A40x to use sparsemem
Russell King [Wed, 1 Oct 2008 20:38:23 +0000 (21:38 +0100)]
[ARM] mm: allow LH7A40x to use sparsemem

Enable Sparsemem support for LH7A40x SoCs, while still allowing the
existing discontig support for the time being.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: deprecate discontigmem on ARM
Russell King [Wed, 1 Oct 2008 20:39:58 +0000 (21:39 +0100)]
[ARM] mm: deprecate discontigmem on ARM

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: switch SA1100 to use sparsemem
Russell King [Wed, 1 Oct 2008 20:03:21 +0000 (21:03 +0100)]
[ARM] mm: switch SA1100 to use sparsemem

Tested on Assabet, and Assabet with Neponset's SDRAM at 3328M phys.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: enable sparsemem on clps7500 and RiscPC
Russell King [Wed, 1 Oct 2008 16:11:06 +0000 (17:11 +0100)]
[ARM] mm: enable sparsemem on clps7500 and RiscPC

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: finish ARM sparsemem support
Russell King [Wed, 1 Oct 2008 15:58:32 +0000 (16:58 +0100)]
[ARM] mm: finish ARM sparsemem support

... including some comments about the ordering required to bring
sparsemem up.  You have to repeatedly guess, test, reguess, try
again and again to work out what the right ordering is.  Many
hours later...

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: provide helpers for accessing membanks
Russell King [Wed, 1 Oct 2008 15:56:15 +0000 (16:56 +0100)]
[ARM] mm: provide helpers for accessing membanks

Provide helpers for getting physical addresses or pfns from the
meminfo array, and use them.  Move for_each_nodebank() to
asm/setup.h alongside the meminfo structure definition.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: move vmalloc= parsing to arch/arm/mm/mmu.c
Russell King [Tue, 30 Sep 2008 18:31:44 +0000 (19:31 +0100)]
[ARM] mm: move vmalloc= parsing to arch/arm/mm/mmu.c

There's no point scattering this around the tree, the parsing
of the parameter might as well live beside the code which uses
it.  That also means we can make vmalloc_reserve a static
variable.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] mm: move validation of membanks to one place
Russell King [Tue, 30 Sep 2008 18:29:25 +0000 (19:29 +0100)]
[ARM] mm: move validation of membanks to one place

The newly introduced sanity_check_meminfo() function should be
used to collect all validation of the meminfo array, which we
have in bootmem_init().  Move it there.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5272/1: remove conditional compilation in show_pte()
Nicolas Pitre [Tue, 30 Sep 2008 15:10:11 +0000 (16:10 +0100)]
[ARM] 5272/1: remove conditional compilation in show_pte()

The PTRS_PER_PMD != 1 condition can be evaluated with C code and
optimized at compile time.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5271/1: get rid of pages_to_mb()
Nicolas Pitre [Tue, 30 Sep 2008 15:05:09 +0000 (16:05 +0100)]
[ARM] 5271/1: get rid of pages_to_mb()

There is no use of this in the whole tree.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5269/1: ARMv7: Use -march=armv7-a as compiler flag
Catalin Marinas [Mon, 29 Sep 2008 10:06:09 +0000 (11:06 +0100)]
[ARM] 5269/1: ARMv7: Use -march=armv7-a as compiler flag

The current -march=armv7a is not supported by mainline gcc.

Cc: Paul Brook <paul@codesourcery.com>
Cc: Wei Zhong <weizhong@broadcom.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: fix some comments in dma-mapping.h
Russell King [Tue, 30 Sep 2008 10:30:24 +0000 (11:30 +0100)]
[ARM] dma: fix some comments in dma-mapping.h

... to prevent people being mislead.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: don't touch cache on dma_*_for_cpu()
Russell King [Mon, 29 Sep 2008 18:50:59 +0000 (19:50 +0100)]
[ARM] dma: don't touch cache on dma_*_for_cpu()

As per the dma_unmap_* calls, we don't touch the cache when a DMA
buffer transitions from device to CPU ownership.  Presently, no
problems have been identified with speculative cache prefetching
which in itself is a new feature in later architectures.  We may
have to revisit the DMA API later for these architectures anyway.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: add validation of DMA params
Russell King [Mon, 29 Sep 2008 12:48:17 +0000 (13:48 +0100)]
[ARM] dma: add validation of DMA params

Validate the direction argument like x86 does.  In addition,
validate the dma_unmap_* parameters against those passed to
dma_map_* when using the DMA bounce code.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: coding style cleanups
Russell King [Thu, 25 Sep 2008 21:23:31 +0000 (22:23 +0100)]
[ARM] dma: coding style cleanups

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: fix dmabounce dma_sync_xxx() implementations
Russell King [Thu, 25 Sep 2008 21:16:22 +0000 (22:16 +0100)]
[ARM] dma: fix dmabounce dma_sync_xxx() implementations

The dmabounce dma_sync_xxx() implementation have been broken for
quite some time; they all copy data between the DMA buffer and
the CPU visible buffer no irrespective of the change of ownership.
(IOW, a DMA_FROM_DEVICE mapping copies data from the DMA buffer
to the CPU buffer during a call to dma_sync_single_for_device().)

Fix it by getting rid of sync_single(), moving the contents into
the recently created dmabounce_sync_for_xxx() functions and adjusting
appropriately.

This also makes it possible to properly support the DMA range sync
functions.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: use new dmabounce_sync_for_xxx() for dma_sync_single_xxx()
Russell King [Thu, 25 Sep 2008 20:52:49 +0000 (21:52 +0100)]
[ARM] dma: use new dmabounce_sync_for_xxx() for dma_sync_single_xxx()

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: Reduce to one dma_sync_sg_* implementation
Russell King [Thu, 25 Sep 2008 20:38:41 +0000 (21:38 +0100)]
[ARM] dma: Reduce to one dma_sync_sg_* implementation

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: Reduce to one dma_map_sg()/dma_unmap_sg() implementation
Russell King [Thu, 25 Sep 2008 20:05:02 +0000 (21:05 +0100)]
[ARM] dma: Reduce to one dma_map_sg()/dma_unmap_sg() implementation

No point having two of these; dma_map_page() can do all the work
for us.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: provide a better dma_map_page() implementation
Russell King [Thu, 25 Sep 2008 19:59:12 +0000 (20:59 +0100)]
[ARM] dma: provide a better dma_map_page() implementation

We can translate a struct page directly to a DMA address using
page_to_dma().  No need to use page_address() followed by
virt_to_dma().

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Update dma_map_sg()/dma_unmap_sg() API
Russell King [Thu, 25 Sep 2008 15:30:57 +0000 (16:30 +0100)]
[ARM] Update dma_map_sg()/dma_unmap_sg() API

Update the ARM DMA scatter gather APIs for the scatterlist changes.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] dma: rename consistent.c to dma-mapping.c
Russell King [Thu, 25 Sep 2008 14:59:19 +0000 (15:59 +0100)]
[ARM] dma: rename consistent.c to dma-mapping.c

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Print details relevant to how we handle the cache
Russell King [Thu, 25 Sep 2008 14:39:20 +0000 (15:39 +0100)]
[ARM] Print details relevant to how we handle the cache

This replaces the original cache type decoding printks.  We now
indicate how we're treating the cache which we found, rather
than what we found.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Introduce new bitmask based cache type macros
Russell King [Thu, 25 Sep 2008 14:35:28 +0000 (15:35 +0100)]
[ARM] Introduce new bitmask based cache type macros

Rather than trying to (inaccurately) decode the cache type from the
registers each time we need to decide what type of cache we have,
use a bitmask initialized early during boot.

Since the setup is a one-off initialization, we can be a little more
clever and take account of the CPU architecture as well.

Note that we continue to achieve the compactness on optimised kernels
by forcing tests to always-false or always-true as appropriate, thereby
allowing the compiler to do build-time code elimination.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Remove cache type printks
Russell King [Thu, 25 Sep 2008 13:45:02 +0000 (14:45 +0100)]
[ARM] Remove cache type printks

The cache type register found in ARMv5 and later CPUs changes format
and meaning depending on the CPU architecture version.  Currently,
this code:
a) doesn't work for everything - Xscale's are identified as
   'unknown 5'.
b) is not able to tell whether the caches are VIVT or VIPT from the
   cache type.
c) prints rubbish on some ARMv6 and ARMv7+ CPUs.

The two solutions to this are:
1. Add yet more code to decode and print the various different register
   formats.
2. Remove the code altogther.

The code only exists to decode and print the cache parameters.
Increasing the complexity of it just for the sake of a few prinks
isn't worth it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Update mach-types
Russell King [Thu, 25 Sep 2008 09:12:25 +0000 (10:12 +0100)]
[ARM] Update mach-types

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Fix IOP13xx build warnings
Russell King [Wed, 17 Sep 2008 19:36:49 +0000 (20:36 +0100)]
[ARM] Fix IOP13xx build warnings

http://armlinux.simtec.co.uk/kautobuild/2.6.27-rc5/iop13xx_defconfig/zimage.log

Occurrences  Warning text
339  arch/arm/include/asm/dma-mapping.h:40: warning: return makes pointer from integer without a cast
203  arch/arm/include/asm/dma-mapping.h:45: warning: return makes integer from pointer without a cast

Acked-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Add -march=all to assembly file build in arch/arm/boot/compressed
Russell King [Tue, 9 Sep 2008 12:56:45 +0000 (13:56 +0100)]
[ARM] Add -march=all to assembly file build in arch/arm/boot/compressed

This allows assembly files to be crafted to cover all ARM CPU types
rather than erroring out on instructions only in later CPUs.  We
are careful in these files to only execute CPU specific code when
the CPU ID says we can.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5243/1: ep93xx: bugfix, GPIO ports C and F are swapped
Hartley Sweeten [Fri, 5 Sep 2008 16:24:40 +0000 (17:24 +0100)]
[ARM] 5243/1: ep93xx: bugfix, GPIO ports C and F are swapped

In the GPIOLIB support for EP93xx ports C anf F are swapped. This
patch correct it.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5242/1: ep93xx: bugfix, GPIO port F enable register offset
Hartley Sweeten [Fri, 5 Sep 2008 16:14:35 +0000 (17:14 +0100)]
[ARM] 5242/1: ep93xx: bugfix, GPIO port F enable register offset

The GPIO port F enable register offset points to the wrong register,
0x5c is the IntStsF register. The correct offset is 0x58. This patch
corrects it.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[NET] smc91x: provide configurable leds
Russell King [Thu, 4 Sep 2008 20:13:37 +0000 (21:13 +0100)]
[NET] smc91x: provide configurable leds

This patch provides a mechanism for platforms to be able to supply the
LED configuration via platform data, rather than having to hard code
it in smc91x.h.

Acked-by: Eric Miao <eric.y.miao@gmail.com>
Acked-by: Nicolas Pitre <nico@cam.org>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Convert asm/bitops.h to linux/bitops.h
Russell King [Sat, 6 Sep 2008 11:13:59 +0000 (12:13 +0100)]
[ARM] Convert asm/bitops.h to linux/bitops.h

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Convert asm/delay.h to linux/delay.h
Russell King [Sat, 6 Sep 2008 11:11:37 +0000 (12:11 +0100)]
[ARM] Convert asm/delay.h to linux/delay.h

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Convert asm/io.h to linux/io.h
Russell King [Sat, 6 Sep 2008 11:10:45 +0000 (12:10 +0100)]
[ARM] Convert asm/io.h to linux/io.h

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Convert asm/uaccess.h to linux/uaccess.h
Russell King [Sat, 6 Sep 2008 10:35:55 +0000 (11:35 +0100)]
[ARM] Convert asm/uaccess.h to linux/uaccess.h

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] clean up a load of old declarations
Russell King [Sat, 6 Sep 2008 10:23:30 +0000 (11:23 +0100)]
[ARM] clean up a load of old declarations

... some of which are now in linux/*.h headers.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] move initrd code from kernel/setup.c to mm/init.c
Russell King [Sat, 6 Sep 2008 09:57:03 +0000 (10:57 +0100)]
[ARM] move initrd code from kernel/setup.c to mm/init.c

This quietens some sparse warnings about phys_initrd_start and
phys_initrd_size.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] sparse: quieten arch/arm/kernel/irq.c
Russell King [Sat, 6 Sep 2008 09:56:27 +0000 (10:56 +0100)]
[ARM] sparse: quieten arch/arm/kernel/irq.c

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] remove pc_pointer()
Russell King [Sat, 6 Sep 2008 09:14:24 +0000 (10:14 +0100)]
[ARM] remove pc_pointer()

pc_pointer() was a function to mask the PC for 26-bit ARMs, which
we no longer support.  Remove it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] sparse: fix several warnings
Russell King [Fri, 5 Sep 2008 13:08:44 +0000 (14:08 +0100)]
[ARM] sparse: fix several warnings

arch/arm/kernel/process.c:270:6: warning: symbol 'show_fpregs' was not declared. Should it be static?

This function isn't used, so can be removed.

arch/arm/kernel/setup.c:532:9: warning: symbol 'len' shadows an earlier one
arch/arm/kernel/setup.c:524:6: originally declared here

A function containing two 'len's.

arch/arm/mm/fault-armv.c:188:13: warning: symbol 'check_writebuffer_bugs' was not declared. Should it be static?
arch/arm/mm/mmap.c:122:5: warning: symbol 'valid_phys_addr_range' was not declared. Should it be static?
arch/arm/mm/mmap.c:137:5: warning: symbol 'valid_mmap_phys_addr_range' was not declared. Should it be static?

Missing includes.

arch/arm/kernel/traps.c:71:77: warning: Using plain integer as NULL pointer
arch/arm/mm/ioremap.c:355:46: error: incompatible types in comparison expression (different address spaces)

Sillies.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5231/1: Do not save the frame pointer in the csum_partial_copy_* functions
Catalin Marinas [Fri, 29 Aug 2008 17:31:27 +0000 (18:31 +0100)]
[ARM] 5231/1: Do not save the frame pointer in the csum_partial_copy_* functions

Since the other assembly functions do not seem to save the frame
pointer onto the stack, this patch changes the csum_partial_copy_*
functions to behave in the same way.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5230/1: Replace post-indexed LDRT/STRT in uaccess.h
Catalin Marinas [Fri, 29 Aug 2008 17:31:15 +0000 (18:31 +0100)]
[ARM] 5230/1: Replace post-indexed LDRT/STRT in uaccess.h

The post-index immediate value is optional if it is 0 and this patch
removes it. The reason is to allow such instructions to compile to
Thumb-2 where only pre-indexed LDRT/STRT instructions are allowed.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5232/1: Do not post-index STRT instruction in clear_user.S
Catalin Marinas [Fri, 29 Aug 2008 17:31:21 +0000 (18:31 +0100)]
[ARM] 5232/1: Do not post-index STRT instruction in clear_user.S

The last strnebt instruction has a post-index of 1 but the address
register is set to 0 in the next instruction, so no need for
post-indexing.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5227/1: Add the ENDPROC declarations to the .S files
Catalin Marinas [Thu, 28 Aug 2008 10:22:32 +0000 (11:22 +0100)]
[ARM] 5227/1: Add the ENDPROC declarations to the .S files

This declaration specifies the "function" type and size for various
assembly functions, mainly needed for generating the correct branch
instructions in Thumb-2.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5222/1: Allow configuring user:kernel split via Kconfig
Lennert Buytenhek [Mon, 25 Aug 2008 20:03:32 +0000 (21:03 +0100)]
[ARM] 5222/1: Allow configuring user:kernel split via Kconfig

This patch adds a config option (CONFIG_VMSPLIT_*) to allow choosing
between 3:1, 2:2 and 1:3 user:kernel memory splits.

Tested-by: Riku Voipio <riku.voipio@iki.fi>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5221/1: fix ldm/stm emulation for kprobes
Nicolas Pitre [Thu, 21 Aug 2008 22:22:49 +0000 (23:22 +0100)]
[ARM] 5221/1: fix ldm/stm emulation for kprobes

Logic for the p bit was reversed.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5211/2: fix a couple warnings from BUG() usage
Nicolas Pitre [Thu, 21 Aug 2008 22:09:48 +0000 (23:09 +0100)]
[ARM] 5211/2: fix a couple warnings from BUG() usage

When CONFIG_DEBUG_BUGVERBOSE is not set, we get warnings such as:

arch/arm/mm/ioremap.c: In function â€˜remap_area_pte’:
arch/arm/mm/ioremap.c:67: warning: control reaches end of non-void function
mm/bootmem.c: In function â€˜mark_bootmem’:
mm/bootmem.c:321: warning: control reaches end of non-void function
fs/dcache.c: In function â€˜d_materialise_unique’:
fs/dcache.c:1875: warning: control reaches end of non-void function
fs/nfs/client.c: In function â€˜nfs_sockaddr_match_ipaddr’:
fs/nfs/client.c:251: warning: control reaches end of non-void function
block/cfq-iosched.c: In function â€˜cfq_async_queue_prio’:
block/cfq-iosched.c:1501: warning: control reaches end of non-void function

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5218/1: arm: improved futex support
Mikael Pettersson [Wed, 20 Aug 2008 08:36:07 +0000 (09:36 +0100)]
[ARM] 5218/1: arm: improved futex support

Linux/ARM currently doesn't support robust or PI futexes.
The problem is that the kernel wants to perform certain ops
(cmpxchg, set, add, or, andn, xor) atomically on user-space
addresses, and ARM's futex.h doesn't support that.

This patch adds that support, but only for uniprocessor machines.
For UP it's enough to disable preemption to ensure mutual exclusion
with other software agents (futexes don't need to care about other
hardware agents, fortunately).

This patch is based on one posted by Khem Raj on 2007-08-01
<http://marc.info/?l=linux-arm-kernel&m=118599407413016&w=2>.
(That patch is included in the -RT kernel patches.)
My changes since that version include:
* corrected implementation of FUTEX_OP_ANDN (must complement oparg)
* added missing memory clobber to futex_atomic_cmpxchg_inatomic()
* removed spinlock because it's unnecessary for UP and insufficient
  for SMP, instead the code is restricted to UP and relies on the
  fact that pagefault_disable() also disables preemption
* coding style cleanups

Tested on ARMv5 XScales with the glibc-2.6 nptl test suite.

Tested-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Mikael Pettersson <mikpe@it.uu.se>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5206/1: remove kprobe_trap_handler() hack
Nicolas Pitre [Tue, 19 Aug 2008 03:15:23 +0000 (04:15 +0100)]
[ARM] 5206/1: remove kprobe_trap_handler() hack

As mentioned in commit 796969104cab0d454dbc792ad0d12a4f365a8564,
and because of commit b03a5b7559563dafdbe52f8b5d8e453a914db941,
the direct calling of kprobe_trap_handler() can be removed.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] Update arch/arm/Kconfig for drivers/Kconfig changes, add cpuidle
Russell King [Mon, 18 Aug 2008 16:26:00 +0000 (17:26 +0100)]
[ARM] Update arch/arm/Kconfig for drivers/Kconfig changes, add cpuidle

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5195/1: ARMv7 Oprofile support
Jean PIHET [Tue, 12 Aug 2008 18:07:39 +0000 (19:07 +0100)]
[ARM] 5195/1: ARMv7 Oprofile support

Add Oprofile kernel support for ARMv7.
Tested on OMAP3430 and OMAP3530 chipsets (Cortex-A8).

Signed-off-by: Jean Pihet <jpihet@mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] cachetype: move definitions to separate header
Russell King [Sun, 10 Aug 2008 17:10:19 +0000 (18:10 +0100)]
[ARM] cachetype: move definitions to separate header

Rather than pollute asm/cacheflush.h with the cache type definitions,
move them to asm/cachetype.h, and include this new header where
necessary.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] cputype: separate definitions, use them
Russell King [Sun, 10 Aug 2008 17:08:10 +0000 (18:08 +0100)]
[ARM] cputype: separate definitions, use them

Add asm/cputype.h, moving functions and definitions from asm/system.h
there.  Convert all users of 'processor_id' to the more efficient
read_cpuid_id() function.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Tue, 26 Aug 2008 00:48:07 +0000 (17:48 -0700)]
Merge git://git./linux/kernel/git/davem/net-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
  bnx2x: Version update
  bnx2x: Multi Queue
  bnx2x: NAPI and interrupts enable/disable
  bnx2x: NIC load failure cleanup
  bnx2x: Initialization structure
  bnx2x: HW lock timeout
  bnx2x: Minimize lock time
  bnx2x: Fan failure mechanism on additional design
  bnx2x: Rx work check
  ipv6: sysctl fixes
  ipv4: sysctl fixes
  sctp: add verification checks to SCTP_AUTH_KEY option

15 years agoALSA: fix for CA0106 on MSI K8N Diamond PLUS Motherboard
Stephen Rothwell [Tue, 26 Aug 2008 00:33:32 +0000 (10:33 +1000)]
ALSA: fix for CA0106 on MSI K8N Diamond PLUS Motherboard

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agobnx2x: Version update
Eilon Greenstein [Mon, 25 Aug 2008 22:30:39 +0000 (15:30 -0700)]
bnx2x: Version update

Version update

Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: Multi Queue
Yitchak Gertner [Mon, 25 Aug 2008 22:27:06 +0000 (15:27 -0700)]
bnx2x: Multi Queue

The multi queue support is still disabled by default for the bnx2x
(needs some more testing and validation), but there are 2 obvious bug in
it which are fixed in this patch

Signed-off-by: Yitchak Gertner <gertner@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: NAPI and interrupts enable/disable
Yitchak Gertner [Mon, 25 Aug 2008 22:26:24 +0000 (15:26 -0700)]
bnx2x: NAPI and interrupts enable/disable

Fixing the order of enabling and disabling NAPI and the interrupts

Signed-off-by: Yitchak Gertner <gertner@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: NIC load failure cleanup
Yitchak Gertner [Mon, 25 Aug 2008 22:25:45 +0000 (15:25 -0700)]
bnx2x: NIC load failure cleanup

Load failures were not handled correctly

Signed-off-by: Yitchak Gertner <gertner@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: Initialization structure
Yitchak Gertner [Mon, 25 Aug 2008 22:24:21 +0000 (15:24 -0700)]
bnx2x: Initialization structure

The TPA initialization is part of the FW internal memory initialization
and so it is moved to the appropriate function

Signed-off-by: Yitchak Gertner <gertner@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: HW lock timeout
Eilon Greenstein [Mon, 25 Aug 2008 22:23:30 +0000 (15:23 -0700)]
bnx2x: HW lock timeout

Increasing the lock timeout to 5 seconds instead of 1 second to minimize
the chance of failures due to timeout

Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: Minimize lock time
Eilon Greenstein [Mon, 25 Aug 2008 22:22:46 +0000 (15:22 -0700)]
bnx2x: Minimize lock time

After iSCSI boot, the HW lock should only protect the flag so only the
first function will reset the chip and not then entire chip reset
process

Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: Fan failure mechanism on additional design
Eilon Greenstein [Mon, 25 Aug 2008 22:20:48 +0000 (15:20 -0700)]
bnx2x: Fan failure mechanism on additional design

The A1021G board is also using the fan failure mechanism in the same way
the A1022G board does

Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agobnx2x: Rx work check
Eilon Greenstein [Mon, 25 Aug 2008 22:19:17 +0000 (15:19 -0700)]
bnx2x: Rx work check

The has Rx work check was wrong: when the FW was at the end of the page,
the driver was already at the beginning of the next page. Since the
check only validated that both driver and FW are pointing to the same
place, it concluded that there is still work to be done. This caused
some serious issues including long latency results on ping-pong test and
lockups while unloading the driver in that condition.

Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipv6: sysctl fixes
Al Viro [Mon, 25 Aug 2008 22:18:15 +0000 (15:18 -0700)]
ipv6: sysctl fixes

Braino: net.ipv6 in ipv6 skeleton has no business in rotable
class

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipv4: sysctl fixes
Al Viro [Mon, 25 Aug 2008 22:17:44 +0000 (15:17 -0700)]
ipv4: sysctl fixes

net.ipv4.neigh should be a part of skeleton to avoid ordering problems

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosctp: add verification checks to SCTP_AUTH_KEY option
Vlad Yasevich [Mon, 25 Aug 2008 22:16:19 +0000 (15:16 -0700)]
sctp: add verification checks to SCTP_AUTH_KEY option

The structure used for SCTP_AUTH_KEY option contains a
length that needs to be verfied to prevent buffer overflow
conditions.  Spoted by Eugene Teo <eteo@redhat.com>.

Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years ago[x86] Clean up MAXSMP Kconfig, and limit NR_CPUS to 512
Linus Torvalds [Mon, 25 Aug 2008 21:15:38 +0000 (14:15 -0700)]
[x86] Clean up MAXSMP Kconfig, and limit NR_CPUS to 512

This fixes a regression that was indirectly caused by commit
1184dc2ffe2c8fb9afb766d870850f2c3165ef25 ("x86: modify Kconfig to allow
up to 4096 cpus").

Allowing 4k CPU's is not practical at this time, because we still have a
number of places that have several 'cpumask_t's on the stack, and a
4k-bit cpumask is 512 bytes of stack-space for each such variable.  This
literally caused functions like 'smp_call_function_mask' to have a 2.5kB
stack frame, and several functions to have 2kB stackframes.

With an 8kB stack total, smashing the stack was simply much too likely.
At least bugzilla entry

http://bugzilla.kernel.org/show_bug.cgi?id=11342

was due to this.

The earlier commit to not inline load_module() into sys_init_module()
fixed the particular symptoms of this that Alan Brunelle saw in that
bugzilla entry, but the huge stack waste by cpumask_t's was the more
direct cause.

Some day we'll have allocation helpers that allocate large CPU masks
dynamically, but in the meantime we simply cannot allow cpumasks this
large.

Cc: Alan D. Brunelle <Alan.Brunelle@hp.com>
Cc: Mike Travis <travis@sgi.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoMerge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Mon, 25 Aug 2008 18:26:56 +0000 (11:26 -0700)]
Merge branch 'timers-fixes-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  rtc: fix deadlock

15 years agoMerge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Mon, 25 Aug 2008 18:26:33 +0000 (11:26 -0700)]
Merge branch 'x86-fixes-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86: add X86_FEATURE_XMM4_2 definitions
  x86: fix cpufreq + sched_clock() regression
  x86: fix HPET regression in 2.6.26 versus 2.6.25, check hpet against BAR, v3
  x86: do not enable TSC notifier if we don't need it
  x86 MCE: Fix CPU hotplug problem with multiple multicore AMD CPUs
  x86: fix: make PCI ECS for AMD CPUs hotplug capable
  x86: fix: do not run code in amd_bus.c on non-AMD CPUs

15 years agoMerge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Mon, 25 Aug 2008 18:26:02 +0000 (11:26 -0700)]
Merge branch 'sched-fixes-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  sched_clock: fix cpu_clock()

15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes...
Linus Torvalds [Mon, 25 Aug 2008 18:25:10 +0000 (11:25 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jbarnes/pci-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6:
  PCI: fix reference leak in pci_get_dev_by_id()
  PCI: shpchp: Rename duplicate slot name N as N-1, N-2, N-M...
  PCI: pciehp: Rename duplicate slot name N as N-1, N-2, N-M...

15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
Linus Torvalds [Mon, 25 Aug 2008 18:24:51 +0000 (11:24 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: ASoC: Fix double free and memory leak in many codec drivers
  ALSA: CA0106 on MSI K8N Diamond PLUS Motherboard

15 years agoMerge branch 'kvm-updates-2.6.27' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Mon, 25 Aug 2008 18:19:53 +0000 (11:19 -0700)]
Merge branch 'kvm-updates-2.6.27' of git://git./linux/kernel/git/avi/kvm

* 'kvm-updates-2.6.27' of git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm:
  KVM: fix userspace ABI breakage
  KVM: MMU: Fix torn shadow pte
  KVM: Use .fixup instead of .text.fixup on __kvm_handle_fault_on_reboot

15 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus
Linus Torvalds [Mon, 25 Aug 2008 18:18:49 +0000 (11:18 -0700)]
Merge git://git./linux/kernel/git/rusty/linux-2.6-for-linus

* git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus:
  lguest: update commentry
  stop_machine: Remove deprecated stop_machine_run
  stop_machine: wean Xen off stop_machine_run
  virtio_balloon: fix towards_target when deflating balloon

15 years ago[module] Don't let gcc inline load_module()
Linus Torvalds [Mon, 25 Aug 2008 18:10:26 +0000 (11:10 -0700)]
[module] Don't let gcc inline load_module()

'load_module()' is a complex function that contains all the ELF section
logic, and inlining it is utterly insane.  But gcc will do it, simply
because there is only one call-site.  As a result, all the stack space
that is allocated for all the work to load the module will still be
active when we actually call the module init sequence, and the deep call
chain makes stack overflows happen.

And stack overflows are really hard to debug, because they not only
corrupt random pages below the stack, but also corrupt the thread_info
structure that is allocated under the stack.

In this case, Alan Brunelle reported some crazy oopses at bootup, after
loading the processor module that ends up doing complex ACPI stuff and
has quite a deep callchain.  This should fix it, and is the sane thing
to do regardless.

Cc: Alan D. Brunelle <Alan.Brunelle@hp.com>
Cc: Arjan van de Ven <arjan@linux.intel.com>
Cc: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agosched_clock: fix cpu_clock()
Peter Zijlstra [Mon, 25 Aug 2008 15:15:34 +0000 (17:15 +0200)]
sched_clock: fix cpu_clock()

This patch fixes 3 issues:

a) it removes the dependency on jiffies, because jiffies are incremented
   by a single CPU, and the tick is not synchronized between CPUs. Therefore
   relying on it to calculate a window to clip whacky TSC values doesn't work
   as it can drift around.

   So instead use [GTOD, GTOD+TICK_NSEC) as the window.

b) __update_sched_clock() did (roughly speaking):

   delta = sched_clock() - scd->tick_raw;
   clock += delta;

   Which gives exponential growth, instead of linear.

c) allows the sched_clock_cpu() value to warp the u64 without breaking.

the results are more reliable sched_clock() deltas:

           before       after   sched_clock

cpu_clock: 15750        51312   51488
cpu_clock: 59719        51052   50947
cpu_clock: 15879        51249   51061
cpu_clock: 1            50933   51198
cpu_clock: 1            50931   51039
cpu_clock: 1            51093   50981
cpu_clock: 1            51043   51040
cpu_clock: 1            50959   50938
cpu_clock: 1            50981   51011
cpu_clock: 1            51364   51212
cpu_clock: 1            51219   51273
cpu_clock: 1            51389   51048
cpu_clock: 1            51285   51611
cpu_clock: 1            50964   51137
cpu_clock: 1            50973   50968
cpu_clock: 1            50967   50972
cpu_clock: 1            58910   58485
cpu_clock: 1            51082   51025
cpu_clock: 1            50957   50958
cpu_clock: 1            50958   50957
cpu_clock: 1006128      51128   50971
cpu_clock: 1            51107   51155
cpu_clock: 1            51371   51081
cpu_clock: 1            51104   51365
cpu_clock: 1            51363   51309
cpu_clock: 1            51107   51160
cpu_clock: 1            51139   51100
cpu_clock: 1            51216   51136
cpu_clock: 1            51207   51215
cpu_clock: 1            51087   51263
cpu_clock: 1            51249   51177
cpu_clock: 1            51519   51412
cpu_clock: 1            51416   51255
cpu_clock: 1            51591   51594
cpu_clock: 1            50966   51374
cpu_clock: 1            50966   50966
cpu_clock: 1            51291   50948
cpu_clock: 1            50973   50867
cpu_clock: 1            50970   50970
cpu_clock: 998306       50970   50971
cpu_clock: 1            50971   50970
cpu_clock: 1            50970   50970
cpu_clock: 1            50971   50971
cpu_clock: 1            50970   50970
cpu_clock: 1            51351   50970
cpu_clock: 1            50970   51352
cpu_clock: 1            50971   50970
cpu_clock: 1            50970   50970
cpu_clock: 1            51321   50971
cpu_clock: 1            50974   51324

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86: add X86_FEATURE_XMM4_2 definitions
Austin Zhang [Mon, 25 Aug 2008 15:14:51 +0000 (11:14 -0400)]
x86: add X86_FEATURE_XMM4_2 definitions

Added Intel processor SSE4.2 feature flag.

No in-tree user at the moment, but makes the tree-merging life easier
for the crypto tree.

Signed-off-by: Austin Zhang <austin.zhang@intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agoKVM: fix userspace ABI breakage
Adrian Bunk [Tue, 5 Aug 2008 22:36:09 +0000 (01:36 +0300)]
KVM: fix userspace ABI breakage

The following part of commit 9ef621d3be56e1188300476a8102ff54f7b6793f
(KVM: Support mixed endian machines) changed on the size of a struct
that is exported to userspace:

include/linux/kvm.h:

@@ -318,14 +318,14 @@ struct kvm_trace_rec {
  __u32 vcpu_id;
  union {
  struct {
- __u32 cycle_lo, cycle_hi;
+ __u64 cycle_u64;
  __u32 extra_u32[KVM_TRC_EXTRA_MAX];
  } cycle;
  struct {
  __u32 extra_u32[KVM_TRC_EXTRA_MAX];
  } nocycle;
  } u;
-};
+} __attribute__((packed));

Packing a struct was the correct idea, but it packed the wrong struct.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Avi Kivity <avi@qumranet.com>
15 years agoKVM: MMU: Fix torn shadow pte
Avi Kivity [Fri, 22 Aug 2008 16:19:38 +0000 (19:19 +0300)]
KVM: MMU: Fix torn shadow pte

The shadow code assigns a pte directly in one place, which is nonatomic on
i386 can can cause random memory references.  Fix by using an atomic setter.

Signed-off-by: Avi Kivity <avi@qumranet.com>
15 years agoKVM: Use .fixup instead of .text.fixup on __kvm_handle_fault_on_reboot
Eduardo Habkost [Tue, 19 Aug 2008 23:00:08 +0000 (20:00 -0300)]
KVM: Use .fixup instead of .text.fixup on __kvm_handle_fault_on_reboot

vmlinux.lds expects the fixup code to be on a section named .fixup. The
.text.fixup section is not mentioned on vmlinux.lds, and is included on
the resulting vmlinux (just after .text) only because of ld heuristics on
placing orphan sections.

However, placing .text.fixup outside .text breaks the definition of
_etext, making it exclude the .text.fixup contents. That makes .text.fixup
be ignored by the kernel initialization code that needs to know about
section locations, such as the code setting page protection bits.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
15 years agolguest: update commentry
Rusty Russell [Tue, 26 Aug 2008 05:19:27 +0000 (00:19 -0500)]
lguest: update commentry

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
15 years agostop_machine: Remove deprecated stop_machine_run
Rusty Russell [Tue, 26 Aug 2008 05:19:27 +0000 (00:19 -0500)]
stop_machine: Remove deprecated stop_machine_run

Everyone should be using stop_machine() now.  The staged API
transition helped life in linux-next.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
15 years agostop_machine: wean Xen off stop_machine_run
Rusty Russell [Tue, 26 Aug 2008 05:19:26 +0000 (00:19 -0500)]
stop_machine: wean Xen off stop_machine_run

This is the last use of (the deprecated) stop_machine_run in the tree.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Acked-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
15 years agovirtio_balloon: fix towards_target when deflating balloon
Anthony Liguori [Mon, 18 Aug 2008 22:15:31 +0000 (17:15 -0500)]
virtio_balloon: fix towards_target when deflating balloon

Both v and vb->num_pages are u32 and unsigned int respectively.  If v is less
than vb->num_pages (and it is, when deflating the balloon), the result is a
very large 32-bit number.  Since we're returning a s64, instead of getting the
same negative number we desire, we get a very large positive number.

This handles the case where v < vb->num_pages and ensures we get a small,
negative, s64 as the result.

Rusty: please push this for 2.6.27-rc4.  It's probably appropriate for the
stable tree too as it will cause an unexpected OOM when ballooning.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (simplified)
15 years agox86: fix cpufreq + sched_clock() regression
Peter Zijlstra [Mon, 25 Aug 2008 11:35:06 +0000 (13:35 +0200)]
x86: fix cpufreq + sched_clock() regression

I noticed that my sched_clock() was slow on a number of machine, so I
started looking at cpufreq.

The below seems to fix the problem for me.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agoMerge branch 'linus' into x86/urgent
Ingo Molnar [Mon, 25 Aug 2008 12:39:12 +0000 (14:39 +0200)]
Merge branch 'linus' into x86/urgent