]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/log
linux-2.6-omap-h63xx.git
15 years agoBlackfin arch: include linux/mm.h since we use PAGE_ALIGN and such
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: include linux/mm.h since we use PAGE_ALIGN and such

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: enable DEBUG_KERNEL for ADI boards
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: enable DEBUG_KERNEL for ADI boards

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: rewrite dma_memcpy() and dma in/out functions
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: rewrite dma_memcpy() and dma in/out functions

- unify all dma in/out functions (takes ~35 lines of code now)
- unify dma_memcpy with dma in/out functions (1 place that touches MDMA0
  registers)
- add support for 32bit transfers
- cleanup dma_memcpy code to be much more readable
- irqs are disabled only while programming MDMA registers rather than
  the entire transaction

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: check pointers in safe_dma_memcpy
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: check pointers in safe_dma_memcpy

Check pointers in safe_dma_memcpy as this is the entry point for user-space code

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: push bf561 PERIPHERAL_MAP oddity into bf561-specific code
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: push bf561 PERIPHERAL_MAP oddity into bf561-specific code

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: ADP5588 QWERTY I2C Keyboard Input device driver
Michael Hennerich [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch:  ADP5588 QWERTY I2C Keyboard Input device driver

Add BF537-STAMP platform Support

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: cleanup - use scm for changelog, not file headers
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: cleanup - use scm for changelog, not file headers

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Add basic irq stack checking for Blackfin
Robin Getz [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: Add basic irq stack checking for Blackfin

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Set TWI/I2C Clock to 100kHz
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: Set TWI/I2C Clock to 100kHz

All slaves I'm aware of should support at least 100kHz

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: dma_memcpy() - do not return NULL when transferring a multiple of 65k
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: dma_memcpy() - do not return NULL when transferring a multiple of 65k

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Add BF537-STAMP platform support for ENC28J60 SPI Ethernet MAC
Michael Hennerich [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: Add BF537-STAMP platform support for ENC28J60 SPI Ethernet MAC

This device shouldn't be considered as an alternative to a Memory Mapped
or built-in Ethernet MAC. Throughput is slow (~460kByte/s) while generating
a very high system load (~60%).

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: remove #if check on L2_LENGTH
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: remove #if check on L2_LENGTH

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Retire old spi_mmc driver
Yi Li [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: Retire old spi_mmc driver

Turn to use the mmc_spi driver in mainline kernel.

Signed-off-by: Yi Li <yi.li@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: add mmc_spi support to BF537-STAMP
Yi Li [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: add mmc_spi support to BF537-STAMP

Signed-off-by: Yi Li <yi.li@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: rename MAX_BLACKFIN_DMA_CHANNEL to MAX_DMA_CHANNELS to match everyone...
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: rename MAX_BLACKFIN_DMA_CHANNEL to MAX_DMA_CHANNELS to match everyone else

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: fix bug - kernel build fails with undefined reference to pm_overflow_h...
Michael Hennerich [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: fix bug - kernel build fails with undefined reference to pm_overflow_handler

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Use reads/writes instead of ins/outs directly
Sonic Zhang [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: Use reads/writes instead of ins/outs directly

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: add const to some function prototype and struct dma_channel
Michael McTernan [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: add const to some function prototype and struct dma_channel

Signed-off-by: Michael McTernan <mmcternan@airvana.com>
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: implement support for /proc/dma
Graf Yang [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: implement support for /proc/dma

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: smp patch cleanup from LKML review
Graf Yang [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: smp patch cleanup from LKML review

1. Use inline get_l1_... functions instead of macro
2. Fix compile issue about smp barrier functions

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: get oprofile work for user space
Graf Yang [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: get oprofile work for user space

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: fix bugs in linker script when using upstream binutils
Bernd Schmidt [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: fix bugs in linker script when using upstream binutils

Fix a few problems I discovered when building a kernel with upstream CVS
binutils.

We have to add the NOTES macro to our linker script, since a kernel
built with --build-id is otherwise unable to boot.  Last time NOTES was
added, it broke things, but the definition of the macro has changed not
to rely on parts of the linker script that aren't present on Blackfin.

I also noticed that _l2_lma_start does not point into the kernel image,
but rather somewhere in L1/L2 space, which seems unintended.  Also, when
the L2 section was added to the linker script, the part following it which
computes then length of the init section was not updated.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Add document about bfin-gpio
Graf Yang [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: Add document about bfin-gpio

Add document about bfin-gpio when requesting a pin
both as gpio and gpio interrupt.

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Remove all traces of the relocation stack
Bernd Schmidt [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: Remove all traces of the relocation stack

Remove all traces of the relocation stack.  It's been removed from
binutils for years now.

Add a sanity overflow check to pcrel24 relocations to catch modules that
were built without -mlong-calls.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: tweak the BUG_ON() check to allow for equal values
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: tweak the BUG_ON() check to allow for equal values

Tweak the BUG_ON() check to allow for equal values since the way pos is
handled ... it is always indexed and post incremented

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: gpio.h split into machine subfolders like already done for BF54x
Michael Hennerich [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: gpio.h split into machine subfolders like already done for BF54x

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: cleanup the header file comments
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: cleanup the header file comments

use scm changelog rather than comment blocks in files

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: rewrite cplbinfo to use seq files
Mike Frysinger [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: rewrite cplbinfo to use seq files

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: fix bugs and unify BFIN_KERNEL_CLOCK option
Michael Hennerich [Wed, 7 Jan 2009 15:14:39 +0000 (23:14 +0800)]
Blackfin arch: fix bugs and unify BFIN_KERNEL_CLOCK option

 - remove duplicated code and headers
 - add option allowing arbitrary SDRAM/DDR Timing parameters.
 - mark automatically calculated timings as EXPERIMENTAL
 - fix comment header block

Related to BUGs:
 - kernel boot up fails with CONFIG_BFIN_KERNEL_CLOCK item on.
 - kernel does not boot if re-program clocks

[ Mike Frysinger <vapier.adi@gmail.com>
 - fix comment header
 - mark do_sync static
 - document the DMA shutdown
 - simplify SIC_IWR handling
 - fix ANOMALY_05000265 handling to work as intended ]

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: add simple-gpio resources to all adi/tinyboards
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: add simple-gpio resources to all adi/tinyboards

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: Allow a gpio pin be requested both as gpio and irq.
Graf Yang [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: Allow a gpio pin be requested both as gpio and irq.

[Mike Frysinger <vapier.adi@gmail.com>:
 - use KERN_NOTICE when using gpios as both irq and non
   rather than KERN_ERR
 - embedded newlines in printk() does not fly]

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: do not allow L2 to be cached on BF561 SMP
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: do not allow L2 to be cached on BF561 SMP

Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoBlackfin arch: delete now unused "cclk" member of blackfin_cpudata
Mike Frysinger [Wed, 7 Jan 2009 15:14:38 +0000 (23:14 +0800)]
Blackfin arch: delete now unused "cclk" member of blackfin_cpudata

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
15 years agoi2c: Use snprintf to set adapter names
Jean Delvare [Wed, 7 Jan 2009 13:29:18 +0000 (14:29 +0100)]
i2c: Use snprintf to set adapter names

Use snprintf instead of sprintf to set adapter names, it's safer.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
15 years agoInput: apanel - convert to new i2c binding
Jean Delvare [Wed, 7 Jan 2009 13:29:17 +0000 (14:29 +0100)]
Input: apanel - convert to new i2c binding

Convert the apanel driver to the new i2c device driver binding model,
as the legacy model is going away soon. In the new model, the apanel
driver is no longer scanning all the i2c adapters, instead the
relevant bus driver (i2c-i801) is instantiating the device as needed.

One side benefit is that the apanel driver will now load automatically
on all systems where it is needed.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Stephen Hemminger <shemminger@linux-foundation.org>
15 years agoi2c: Drop I2C_CLASS_CAM_DIGITAL
Jean Delvare [Wed, 7 Jan 2009 13:29:17 +0000 (14:29 +0100)]
i2c: Drop I2C_CLASS_CAM_DIGITAL

There are a number of drivers which set their i2c bus class to
I2C_CLASS_CAM_DIGITAL, however no chip driver actually checks for this
flag, so we might as well drop it now.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
15 years agoi2c: Drop I2C_CLASS_CAM_ANALOG and I2C_CLASS_SOUND
Jean Delvare [Wed, 7 Jan 2009 13:29:17 +0000 (14:29 +0100)]
i2c: Drop I2C_CLASS_CAM_ANALOG and I2C_CLASS_SOUND

There are no users left of these two i2c probe class flags so we can
drop the now.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
15 years agoi2c: Drop I2C_CLASS_ALL
Jean Delvare [Wed, 7 Jan 2009 13:29:16 +0000 (14:29 +0100)]
i2c: Drop I2C_CLASS_ALL

I2C_CLASS_ALL is almost never what bus driver authors really want.
These i2c classes are really only about which devices must be probed,
not what devices can be present. As device drivers get converted to the
new i2c device driver model, only a few device types will keep relying
on probing.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Sonic Zhang <sonic.zhang@analog.com>
15 years agoi2c: Get rid of remaining bus_id access
Jean Delvare [Wed, 7 Jan 2009 13:29:16 +0000 (14:29 +0100)]
i2c: Get rid of remaining bus_id access

Use dev_name(dev) instead of accessing dev.bus_id directly, as the
latter is going away soon.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Kay Sievers <kay.sievers@vrfy.org>
15 years agoi2c: Replace bus_id with dev_name(), dev_set_name()
Kay Sievers [Wed, 7 Jan 2009 13:29:16 +0000 (14:29 +0100)]
i2c: Replace bus_id with dev_name(), dev_set_name()

This patch is part of a larger patch series which will remove
the "char bus_id[20]" name string from struct device. The device
name is managed in the kobject anyway, and without any size
limitation, and just needlessly copied into "struct device".

To set and read the device name dev_name(dev) and dev_set_name(dev)
must be used. If your code uses static kobjects, which it shouldn't
do, "const char *init_name" can be used to statically provide the
name the registered device should have. At registration time, the
init_name field is cleared, to enforce the use of dev_name(dev) to
access the device name at a later time.

We need to get rid of all occurrences of bus_id in the entire tree
to be able to enable the new interface. Please apply this patch,
and possibly convert any remaining remaining occurrences of bus_id.

We want to submit a patch to -next, which will remove bus_id from
"struct device", to find the remaining pieces to convert, and finally
switch over to the new api, which will remove the 20 bytes array
and does no longer have a size limitation.

Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
15 years agoavr32: Move syscalls.h under arch/avr32/include/asm/
Haavard Skinnemoen [Wed, 7 Jan 2009 10:26:03 +0000 (11:26 +0100)]
avr32: Move syscalls.h under arch/avr32/include/asm/

This file was added to the old include/asm-avr32/ directory by mistake.

Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
15 years agoMerge branches 'fixes', 'cleanups' and 'boards'
Haavard Skinnemoen [Wed, 7 Jan 2009 10:05:42 +0000 (11:05 +0100)]
Merge branches 'fixes', 'cleanups' and 'boards'

15 years agoavr32: Define DIE_OOPS
Haavard Skinnemoen [Wed, 7 Jan 2009 09:36:15 +0000 (10:36 +0100)]
avr32: Define DIE_OOPS

Whatever the hell that is. Needed to make kernel/trace/trace.c compile
again.

Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
15 years agoGFS2: Fix typo in gfs_page_mkwrite()
Benjamin Marzinski [Tue, 6 Jan 2009 16:47:50 +0000 (10:47 -0600)]
GFS2: Fix typo in gfs_page_mkwrite()

There is a typo in gfs2_page_mkwrite()

gfs2_write_alloc_required() expects pos to be the offset in bytes. However,
instead of the page index being shifted by by PAGE_CACHE_SHIFT, it was shifted
by (PAGE_CACHE_SIZE - inode->i_blkbits).  This patch simply shifts the page
index by the proper amount.

Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
15 years agoGFS2: LSF and LBD are now one and the same
Steven Whitehouse [Tue, 6 Jan 2009 14:56:26 +0000 (14:56 +0000)]
GFS2: LSF and LBD are now one and the same

As a result of this recent patch:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=b3a6ffe16b5cc48abe7db8d04882dc45280eb693
We only need to depend on LBD.

Reported-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
15 years agoGFS2: Set GFP_NOFS when allocating page on write
Steven Whitehouse [Tue, 6 Jan 2009 10:08:33 +0000 (10:08 +0000)]
GFS2: Set GFP_NOFS when allocating page on write

We need to ensure that we always set GFP_NOFS in this one
particular case when allocating pages for write.

Reported-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
15 years agoFix up 64-bit byte swaps for most 32-bit architectures
Linus Torvalds [Wed, 7 Jan 2009 05:17:57 +0000 (21:17 -0800)]
Fix up 64-bit byte swaps for most 32-bit architectures

The __SWAB_64_THRU_32__ case of a 64-bit byte swap was depending on the
no-longer-existant ___swab32() method (three underscores).  We got rid
of some of the worst indirection and complexity, and now it should just
use the 32-bit swab function that was defined right above it.

Reported-and-tested-by: Nicolas Pitre <nico@cam.org>
Reported-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agobyteorder: remove the now unused byteorder.h
Harvey Harrison [Tue, 6 Jan 2009 21:30:58 +0000 (13:30 -0800)]
byteorder: remove the now unused byteorder.h

This implementation caused problems in userspace which can, and does
define _both_ __LITTLE_ENDIAN and __BIG_ENDIAN.

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agomn10300: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:34 +0000 (14:56 -0800)]
mn10300: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agofrv: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:33 +0000 (14:56 -0800)]
frv: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agom32r: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:33 +0000 (14:56 -0800)]
m32r: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agom68knommu: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:32 +0000 (14:56 -0800)]
m68knommu: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoh8300: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:31 +0000 (14:56 -0800)]
h8300: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoia64: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:31 +0000 (14:56 -0800)]
ia64: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoblackfin: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:30 +0000 (14:56 -0800)]
blackfin: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoarm: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:30 +0000 (14:56 -0800)]
arm: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoalpha: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:29 +0000 (14:56 -0800)]
alpha: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agom68k: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:28 +0000 (14:56 -0800)]
m68k: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agox86: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:28 +0000 (14:56 -0800)]
x86: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agosparc: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:27 +0000 (14:56 -0800)]
sparc: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agosh: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:25 +0000 (14:56 -0800)]
sh: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agos390: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:24 +0000 (14:56 -0800)]
s390: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agopowerpc: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:23 +0000 (14:56 -0800)]
powerpc: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agomips: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:23 +0000 (14:56 -0800)]
mips: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoavr32: introduce asm/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:22 +0000 (14:56 -0800)]
avr32: introduce asm/swab.h

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agobyteorder: only use linux/swab.h
Harvey Harrison [Tue, 6 Jan 2009 22:56:21 +0000 (14:56 -0800)]
byteorder: only use linux/swab.h

The first step to make swab.h a regular header that will
include an asm/swab.h with arch overrides.

Avoid the gratuitous differences introduced in the new
linux/swab.h by naming the ___constant_swabXX bits and
__fswabXX bits exactly as found in the old implementation
in byteorder/swab[b].h

Use this new swab.h in byteorder/[big|little]_endian.h and
remove the two old swab headers.

Although the inclusion of asm/byteorder.h looks strange in
linux/swab.h, this will allow each arch to move the actual
arch overrides for the swab bits in an asm file and then
the includes can be cleaned up without requiring a flag day
for all arches at once.

Keep providing __fswabXX in case some userspace was using them
directly, but the revised __swabXX should be used instead in
any new code and will always do constant folding not dependent
on the optimization level, which means the __constant versions
can be phased out in-kernel.

Arches that use the old-style arch macros will lose their
optimized versions until they move to the new style, but at
least they will still compile.  Many arches have already moved
and the patches to move the remaining arches are trivial.

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoMerge branch 'drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied...
Linus Torvalds [Wed, 7 Jan 2009 02:06:44 +0000 (18:06 -0800)]
Merge branch 'drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6

* 'drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
  drm: fix ordering of driver unload vs agp unload.
  drm/i915: Respect the other stolen memory sizes we know of.
  drm/i915: Non-mobile parts don't have integrated TV-out.
  drm/i915: Add support for integrated HDMI on G4X hardware.
  drm/i915: Pin cursor bo and unpin old bo when setting cursor.
  drm/i915: Don't allow objects to get bound while VT switched.

15 years agodrm: fix ordering of driver unload vs agp unload.
Dave Airlie [Wed, 7 Jan 2009 01:54:57 +0000 (11:54 +1000)]
drm: fix ordering of driver unload vs agp unload.

For KMS drivers, we really need to cleanup the driver before disabling
the AGP subsystem.

Signed-off-by: Dave Airlie <airlied@redhat.com>
15 years agodrm/i915: Respect the other stolen memory sizes we know of.
Eric Anholt [Sat, 3 Jan 2009 02:05:51 +0000 (18:05 -0800)]
drm/i915: Respect the other stolen memory sizes we know of.

fd.o bug #19336.

Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
15 years agodrm/i915: Non-mobile parts don't have integrated TV-out.
Eric Anholt [Fri, 2 Jan 2009 23:57:35 +0000 (15:57 -0800)]
drm/i915: Non-mobile parts don't have integrated TV-out.

Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
15 years agodrm/i915: Add support for integrated HDMI on G4X hardware.
Eric Anholt [Fri, 2 Jan 2009 21:33:00 +0000 (13:33 -0800)]
drm/i915: Add support for integrated HDMI on G4X hardware.

This is ported directly from the userland 2D driver code.  The HDMI audio bits
aren't hooked up yet.

Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
15 years agodrm/i915: Pin cursor bo and unpin old bo when setting cursor.
Kristian Høgsberg [Thu, 18 Dec 2008 03:14:59 +0000 (22:14 -0500)]
drm/i915: Pin cursor bo and unpin old bo when setting cursor.

We also didn't track the cursor bo before and would leak a reference
when the cursor image was change.

Signed-off-by: Kristian Høgsberg <krh@redhat.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
15 years agodrm/i915: Don't allow objects to get bound while VT switched.
Eric Anholt [Wed, 24 Dec 2008 02:42:32 +0000 (18:42 -0800)]
drm/i915: Don't allow objects to get bound while VT switched.

This avoids a BUG_ON in the enter_vt path due to objects being in the GTT
when we shouldn't have ever let them be (as we're not supposed to touch the
device during that time).

This was triggered by a change in the 2D driver to use the GTT mapping of
objects after pinning them to improve software fallback performance.

Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Linus Torvalds [Wed, 7 Jan 2009 01:14:01 +0000 (17:14 -0800)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (29 commits)
  Input: i8042 - add Dell Vostro 1510 to nomux list
  Input: gtco - use USB endpoint API
  Input: add support for Maple controller as a joystick
  Input: atkbd - broaden the Dell DMI signatures
  Input: HIL drivers - add MODULE_ALIAS()
  Input: map_to_7segment.h - convert to __inline__ for userspace
  Input: add support for enhanced rotary controller on pxa930 and pxa935
  Input: add support for trackball on pxa930 and pxa935
  Input: add da9034 touchscreen support
  Input: ads7846 - strict_strtoul takes unsigned long
  Input: make some variables and functions static
  Input: add tsc2007 based touchscreen driver
  Input: psmouse - add module parameters to control OLPC touchpad delays
  Input: i8042 - add Gigabyte M912 netbook to noloop exception table
  Input: atkbd - Samsung NC10 key repeat fix
  Input: atkbd - add keyboard quirk for HP Pavilion ZV6100 laptop
  Input: libps2 - handle 0xfc responses from devices
  Input: add support for Wacom W8001 penabled serial touchscreen
  Input: synaptics - report multi-taps only if supported by the device
  Input: add joystick driver for Walkera WK-0701 RC transmitter
  ...

15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris...
Linus Torvalds [Wed, 7 Jan 2009 01:11:39 +0000 (17:11 -0800)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6:
  CRED: Fix regression in cap_capable() as shown up by sys_faccessat() [ver #3]
  Revert "CRED: Fix regression in cap_capable() as shown up by sys_faccessat() [ver #2]"
  SELinux: shrink sizeof av_inhert selinux_class_perm and context
  CRED: Fix regression in cap_capable() as shown up by sys_faccessat() [ver #2]
  keys: fix sparse warning by adding __user annotation to cast
  smack: Add support for unlabeled network hosts and networks
  selinux: Deprecate and schedule the removal of the the compat_net functionality
  netlabel: Update kernel configuration API

15 years agoMerge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 7 Jan 2009 01:10:53 +0000 (17:10 -0800)]
Merge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/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:
  hrtimer: splitout peek ahead functionality, fix
  hrtimer: fixup comments
  hrtimer: fix recursion deadlock by re-introducing the softirq
  hrtimer: simplify hotplug migration
  hrtimer: fix HOTPLUG_CPU=n compile warning
  hrtimer: splitout peek ahead functionality

15 years agoMerge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 7 Jan 2009 01:10:33 +0000 (17:10 -0800)]
Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/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: fix section mismatch
  sched: fix double kfree in failure path
  sched: clean up arch_reinit_sched_domains()
  sched: mark sched_create_sysfs_power_savings_entries() as __init
  getrusage: RUSAGE_THREAD should return ru_utime and ru_stime
  sched: fix sched_slice()
  sched_clock: prevent scd->clock from moving backwards, take #2
  sched: sched.c declare variables before they get used

15 years agoMerge branch 'irq-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Wed, 7 Jan 2009 01:10:19 +0000 (17:10 -0800)]
Merge branch 'irq-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'irq-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  genirq: provide irq_to_desc() to non-genirq architectures too

15 years agoMerge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 7 Jan 2009 01:10:04 +0000 (17:10 -0800)]
Merge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  rcu: fix rcutorture bug
  rcu: eliminate synchronize_rcu_xxx macro
  rcu: make treercu safe for suspend and resume
  rcu: fix rcutree grace-period-latency bug on small systems
  futex: catch certain assymetric (get|put)_futex_key calls
  futex: make futex_(get|put)_key() calls symmetric
  locking, percpu counters: introduce separate lock classes
  swiotlb: clean up EXPORT_SYMBOL usage
  swiotlb: remove unnecessary declaration
  swiotlb: replace architecture-specific swiotlb.h with linux/swiotlb.h
  swiotlb: add support for systems with highmem
  swiotlb: store phys address in io_tlb_orig_addr array
  swiotlb: add hwdev to swiotlb_phys_to_bus() / swiotlb_sg_to_bus()

15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
Linus Torvalds [Wed, 7 Jan 2009 01:09:51 +0000 (17:09 -0800)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ASoC: Fix SND_SOC_ALL_CODECS handling of dual SPI and I2C control buses
  ASoC: Use snd_soc_dapm_nc_pin() in at91sam9g20ek
  ASoC: TWL4030: Convert the bitfield enums to VALUE_ENUM type
  ASoC: New enum type: value_enum
  pxa2xx-ac97: switch AC unit to correct state before probing
  ASoC: Clocking fixes for davinci-evm.c
  ASoC: Mark non-connected TWL4030 pins for pandora
  ASoC: OMAP: Select OMAP pin multiplexing when using Nokia N810 ASoC drivers

15 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6
Linus Torvalds [Wed, 7 Jan 2009 01:04:29 +0000 (17:04 -0800)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6: (237 commits)
  Staging: android: binder: fix build errors
  Staging: android: add lowmemorykiller driver
  Staging: android: remove dummy android.c driver
  Staging: android: timed_gpio: Rename android_timed_gpio to timed_gpio
  Staging: android: add timed_gpio driver
  Staging: android: add ram_console driver
  Staging: android: add logging driver
  staging: android: binder: Fix use of euid
  Staging: android: binder: Fix gcc warnings about improper format specifiers for size_t in printk
  Staging: android: add binder driver
  Staging: add android framework
  Staging: epl: fix netdev->priv b0rkage
  Staging: epl: hr timers all run in hard irq context now
  Staging: epl: run Lindent on *.c files
  Staging: epl: run Lindent on *.h files
  Staging: epl: run Lindent on all user/*.h files
  Staging: epl: run Lindent on all kernel/*.h files
  Staging: add epl stack
  Staging: frontier: fix compiler warnings
  Staging: frontier: remove unused alphatrack_sysfs.c file
  ...

15 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6
Linus Torvalds [Wed, 7 Jan 2009 01:02:07 +0000 (17:02 -0800)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6: (60 commits)
  uio: make uio_info's name and version const
  UIO: Documentation for UIO ioport info handling
  UIO: Pass information about ioports to userspace (V2)
  UIO: uio_pdrv_genirq: allow custom irq_flags
  UIO: use pci_ioremap_bar() in drivers/uio
  arm: struct device - replace bus_id with dev_name(), dev_set_name()
  libata: struct device - replace bus_id with dev_name(), dev_set_name()
  avr: struct device - replace bus_id with dev_name(), dev_set_name()
  block: struct device - replace bus_id with dev_name(), dev_set_name()
  chris: struct device - replace bus_id with dev_name(), dev_set_name()
  dmi: struct device - replace bus_id with dev_name(), dev_set_name()
  gadget: struct device - replace bus_id with dev_name(), dev_set_name()
  gpio: struct device - replace bus_id with dev_name(), dev_set_name()
  gpu: struct device - replace bus_id with dev_name(), dev_set_name()
  hwmon: struct device - replace bus_id with dev_name(), dev_set_name()
  i2o: struct device - replace bus_id with dev_name(), dev_set_name()
  IA64: struct device - replace bus_id with dev_name(), dev_set_name()
  i7300_idle: struct device - replace bus_id with dev_name(), dev_set_name()
  infiniband: struct device - replace bus_id with dev_name(), dev_set_name()
  ISDN: struct device - replace bus_id with dev_name(), dev_set_name()
  ...

15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi...
Linus Torvalds [Wed, 7 Jan 2009 01:01:20 +0000 (17:01 -0800)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse:
  fuse: clean up annotations of fc->lock
  fuse: fix sparse warning in ioctl
  fuse: update interface version
  fuse: add fuse_conn->release()
  fuse: separate out fuse_conn_init() from new_conn()
  fuse: add fuse_ prefix to several functions
  fuse: implement poll support
  fuse: implement unsolicited notification
  fuse: add file kernel handle
  fuse: implement ioctl support
  fuse: don't let fuse_req->end() put the base reference
  fuse: move FUSE_MINOR to miscdevice.h
  fuse: style fixes

15 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6
Linus Torvalds [Wed, 7 Jan 2009 01:00:50 +0000 (17:00 -0800)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6: (41 commits)
  scc_pata: make use of scc_dma_sff_read_status()
  ide-dma-sff: factor out ide_dma_sff_write_status()
  ide: move read_sff_dma_status() method to 'struct ide_dma_ops'
  ide: don't set hwif->dma_ops in init_dma() method
  Resurrect IT8172 IDE controller driver
  piix: sync ich_laptop[] with ata_piix.c
  ide: update warm-plug HOWTO
  ide: fix ide_port_scan() to do ACPI setup after initializing request queues
  ide: remove now redundant ->cur_dev checks
  ide: remove unused ide_hwif_t.sg_mapped field
  ide: struct ide_atapi_pc - remove unused fields and update documentation
  ide: remove superfluous hwif variable assignment from ide_timer_expiry()
  ide: use ide_pci_is_in_compatibility_mode() helper in setup-pci.c
  ide: make "paranoia" ->handler check in ide_intr() more strict
  ide-cd: convert to ide-atapi facilities
  ide-cd: start DMA before sending the actual packet command
  ide-cd: wait for DRQ to get set per default
  ide: Fix drive's DWORD-IO handling
  ide: add port and host iterators
  ide: dynamic allocation of device structures
  ...

15 years agoparport: ieee1284: use del_timer_sync() in parport_wait_event()
Michael Buesch [Tue, 6 Jan 2009 22:43:14 +0000 (14:43 -0800)]
parport: ieee1284: use del_timer_sync() in parport_wait_event()

Use del_timer_sync() instead of del_timer() to make sure the timer won't
be running when we return from parport_wait_event(), because this would
crash due to destruction of timer_list.

This is untested and just based on a code review.  Just think about the
following sequence of events:

- add_timer()

- down_interruptible() is interrupted by a signal.

- we enter the timer callback handler on another CPU.

- del_timer(), but the timer callback is still running.

- eturn from parport_wait_even, which destroys the automatic variable
  "timer" while the callback is running on another CPU.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agobfs: check that filesystem fits on the blockdevice
Eric Sesterhenn [Tue, 6 Jan 2009 22:43:13 +0000 (14:43 -0800)]
bfs: check that filesystem fits on the blockdevice

Since all sanity checks rely on the validity of s_start which gets only
checked to be smaller than s_end, we should also check if s_end is sane.
Now we also try to retrieve the last block of the filesystem, which is
computed by s_end.  If this fails, something is bogus.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Acked-by: Tigran Aivazian <tigran@aivazian.fsnet.co.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agobfs: add some basic sanity checks
Eric Sesterhenn [Tue, 6 Jan 2009 22:43:12 +0000 (14:43 -0800)]
bfs: add some basic sanity checks

bfs_fill_super() already touches all inodes, so we can easily add some
cheap sanity checks and check if the inode start and end blocks are
smaller than the maximum number of blocks, the inode start block lies
behind the end block or the file end offset is behind the end of the
filesystem.  Also check if the start of data offset in the super block
fits the filesystem.

The added sanity checks catch softlockup issues early when we try to
sb_bread() lots of blocks in a loop in bfs_readdir() and bfs_find_entry().
 In addition an oom issue in bfs_fill_super() is prevented by this when
s_start is corrupted, which influences imap_len and we try to allocate a
huge info->si_imap.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Acked-by: Tigran Aivazian <tigran@aivazian.fsnet.co.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agodma-coherent: catch oversized requests to dma_alloc_from_coherent()
Johannes Weiner [Tue, 6 Jan 2009 22:43:10 +0000 (14:43 -0800)]
dma-coherent: catch oversized requests to dma_alloc_from_coherent()

Prevent passing an order to bitmap_find_free_region() that is larger than
the actual bitmap can represent.

These requests can come from device drivers that have no idea how big the
dma region is and need to rely on dma_alloc_from_coherent() to sort it out
for them.

Reported-by: Guennadi Liakhovetski <lg@denx.de>
Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Cc: Pekka Enberg <penberg@cs.helsinki.fi>
Cc: Dmitry Baryshkov <dbaryshkov@gmail.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agodma_alloc_coherent: clean it up
Andrew Morton [Tue, 6 Jan 2009 22:43:09 +0000 (14:43 -0800)]
dma_alloc_coherent: clean it up

This thing was rather stupidly coded.  Rework it all prior to making
changes.

Also, rename local variable `page': kernel readers expect something called
`page' to have type `struct page *'.

Cc: Guennadi Liakhovetski <lg@denx.de>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Pekka Enberg <penberg@cs.helsinki.fi>
Cc: Dmitry Baryshkov <dbaryshkov@gmail.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agodma_alloc_from_coherent(): fix fallback to generic memory
Andrew Morton [Tue, 6 Jan 2009 22:43:08 +0000 (14:43 -0800)]
dma_alloc_from_coherent(): fix fallback to generic memory

If bitmap_find_free_region() fails and DMA_MEMORY_EXCLUSIVE is not set,
the function will fail to write anything to *ret and will return 1.             This will cause dma_alloc_coherent() to return an uninitialised value,
crashing the kernel, perhaps via DMA to a random address.

Fix that by changing it to return zero in this case, so the caller will
proceed to allocate the memory from the generic memory allocator.

Cc: Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>
Cc: Dmitry Baryshkov <dbaryshkov@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoedac: driver for i5400 MCH (update)
Mauro Carvalho Chehab [Tue, 6 Jan 2009 22:43:00 +0000 (14:43 -0800)]
edac: driver for i5400 MCH (update)

Signed-off-by: Ben Woodard <woodard@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Cc: Doug Thompson <norsk5@yahoo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoedac: driver for i5400 MCH (Seaburg)
Mauro Carvalho Chehab [Tue, 6 Jan 2009 22:43:00 +0000 (14:43 -0800)]
edac: driver for i5400 MCH (Seaburg)

EDAC driver for i5400 MCH (Seaburg)

This driver adds support for i5400 MCH chipset.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Ben Woodard <woodard@redhat.com>
Cc: Doug Thompson <norsk5@yahoo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoedac: fix mpc85xx and add mpc8536 mpc8560
Kumar Gala [Tue, 6 Jan 2009 22:42:59 +0000 (14:42 -0800)]
edac: fix mpc85xx and add mpc8536 mpc8560

All other compatibles that are uniquely identifying the processor use a
prefix of the form fsl,mpc85...'.  We add support for it so we can
deprecate the older 'fsl,85...' that was improperly used here.

Additionally added mpc8536 & mpc8560 to the compatible lists.

This patch is based on Nate's 8572 patch.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Signed-off-by: Doug Thompson <dougthompson@xmission.com>
Acked-by: Dave Jiang <djiang@mvista.com>
Cc: Nate Case <ncase@xes-inc.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoedac: struct device: replace bus_id with dev_name(), dev_set_name()
Kay Sievers [Tue, 6 Jan 2009 22:42:57 +0000 (14:42 -0800)]
edac: struct device: replace bus_id with dev_name(), dev_set_name()

This patch is part of a larger patch series which will remove the "char
bus_id[20]" name string from struct device.  The device name is managed in
the kobject anyway, and without any size limitation, and just needlessly
copied into "struct device".

[akpm@linux-foundation.org: coding-style fixes]
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Acked-by: Doug Thompson <dougthompson@xmission.com>
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agopci: use pci_ioremap_bar() in drivers/edac
Arjan van de Ven [Tue, 6 Jan 2009 22:42:56 +0000 (14:42 -0800)]
pci: use pci_ioremap_bar() in drivers/edac

Use the newly introduced pci_ioremap_bar() function in drivers/edac.
pci_ioremap_bar() just takes a pci device and a bar number, with the goal
of making it really hard to get wrong, while also having a central place
to stick sanity checks.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Acked-by: Doug Thompson <dougthompson@xmission.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agorandom: don't try to look at entropy_count outside the lock
Matt Mackall [Tue, 6 Jan 2009 22:42:55 +0000 (14:42 -0800)]
random: don't try to look at entropy_count outside the lock

As a non-atomic value, it's only safe to look at entropy_count when the
pool lock is held, so we move the BUG_ON inside the lock for correctness.

Also remove the spurious comment.  It's ok for entropy_count to
temporarily exceed POOLBITS so long as it's left in a consistent state
when the lock is released.

This is a more correct, simple, and idiomatic fix for the bug in
8b76f46a2db.  I've left the reorderings introduced by that patch in place
as they're harmless, even though they don't properly deal with potential
atomicity issues.

Signed-off-by: Matt Mackall <mpm@selenic.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoconsolemap: indentation & braces disagree - reindent
Ilpo Järvinen [Tue, 6 Jan 2009 22:42:54 +0000 (14:42 -0800)]
consolemap: indentation & braces disagree - reindent

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agomake firmware/dsp56k/bootstrap.asm buildable on a56
Robert Millan [Tue, 6 Jan 2009 22:42:52 +0000 (14:42 -0800)]
make firmware/dsp56k/bootstrap.asm buildable on a56

Make firmware/dsp56k/bootstrap.asm buildable on a56, the free Motorola
DSP56001 assembler (http://www.zdomain.com/a56.html).

Summary of changes:

  - Remove '<' and '>' candy (they specify explicit addressing modes,
    which a56 don't grok, but uses implicitly anyway).

  - Replace 'move' with 'movem' when accessing program memory.

  - Rename a few labels to avoid duplicates (which a56 can't handle).

Signed-off-by: Robert Millan <rmh@aybabtu.com>
Cc: Jaswinder Singh <jaswinder@infradead.org>
Cc: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoipc/ipc_sysctl.c: move the definition of ipc_auto_callback()
akpm@linux-foundation.org [Tue, 6 Jan 2009 22:42:51 +0000 (14:42 -0800)]
ipc/ipc_sysctl.c: move the definition of ipc_auto_callback()

proc_ipcauto_dointvec_minmax() is the only user of ipc_auto_callback(),
since the former function is protected by CONFIG_PROC_FS, so should be the
latter one.

Just move its definition down.

Signed-off-by: WANG Cong <wangcong@zeuux.org>
Cc: Eric Biederman <ebiederm@xmision.com>
Cc: Nadia Derbey <Nadia.Derbey@bull.net>
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoipc: do not goto to the next line
Denis V. Lunev [Tue, 6 Jan 2009 22:42:50 +0000 (14:42 -0800)]
ipc: do not goto to the next line

Signed-off-by: Denis V. Lunev <den@openvz.org>
Reviewed-by: WANG Cong <wangcong@zeuux.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>