Alan Cox
9d793b0bcb
i2o: Fix 32/64bit DMA locking
...
The I2O ioctls assume 32bits. In itself that is fine as they are old
cards and nobody uses 64bit. However on LKML it was noted this
assumption is also made for allocated memory and is unsafe on 64bit
systems.
Fixing this is a mess. It turns out there is tons of crap buried in a
header file that does racy 32/64bit filtering on the masks.
So we:
- Verify all callers of the racy code can sleep (i2o_dma_[re]alloc)
- Move the code into a new i2o/memory.c file
- Remove the gfp_mask argument so nobody can try and misuse the function
- Wrap a mutex around the problem area (a single mutex is easy to do and
none of this is performance relevant)
- Switch the remaining problem kmalloc holdout to use i2o_dma_alloc
Cc: Markus Lidel <Markus.Lidel@shadowconnect.com>
Cc: Vasily Averin <vvs@sw.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-10-16 11:21:38 -07:00
..
accessibility
acpi
rtc-cmos: move wake setup from ACPI glue into RTC driver
2008-10-14 16:08:21 -07:00
amba
ata
Merge commit 'origin'
2008-10-15 11:31:54 +11:00
atm
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
2008-10-11 12:39:35 -07:00
auxdisplay
base
Fix typo in the FIRMWARE_IN_KERNEL help
2008-10-16 11:21:32 -07:00
block
Merge commit 'origin'
2008-10-15 11:31:54 +11:00
bluetooth
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
2008-10-13 14:12:40 -07:00
cdrom
gdrom: change to use __blk_end_request()
2008-10-09 08:56:21 +02:00
char
Remove Andrew Morton's old email accounts
2008-10-16 11:21:32 -07:00
clocksource
connector
cpufreq
[CPUFREQ] Fix BUG: using smp_processor_id() in preemptible code
2008-10-09 13:52:44 -04:00
cpuidle
crypto
dca
dio
dma
edac
eisa
firewire
firmware
gpio
spi: core and gpio expanders use subsys_init
2008-10-16 11:21:38 -07:00
gpu
misc: replace __FUNCTION__ with __func__
2008-10-16 11:21:30 -07:00
hid
HID: build drivers for all quirky devices by default
2008-10-14 23:51:05 +02:00
hwmon
Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc
2008-10-15 08:07:35 -07:00
i2c
Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc
2008-10-15 08:07:35 -07:00
ide
Kconfig: eliminate "def_bool n" constructs
2008-10-16 11:21:31 -07:00
ieee1394
infiniband
vfs: Use const for kernel parser table
2008-10-13 10:10:37 -07:00
input
misc: replace __FUNCTION__ with __func__
2008-10-16 11:21:30 -07:00
isdn
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
2008-10-14 10:28:49 -07:00
leds
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
2008-10-11 12:39:35 -07:00
lguest
macintosh
mca
md
raid, fastboot: hide RAID autodetect option if MD is compiled as a module
2008-10-12 08:25:14 -07:00
media
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
2008-10-13 14:03:59 -07:00
memstick
memstick: change to use __blk_end_request()
2008-10-09 08:56:20 +02:00
message
i2o: Fix 32/64bit DMA locking
2008-10-16 11:21:38 -07:00
mfd
mfd: Fix warning in WM8350
2008-10-13 21:51:57 +01:00
misc
AT91: atmel_pwm only available for certain AT91 processors
2008-10-16 11:21:32 -07:00
mmc
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
2008-10-13 17:13:56 +01:00
mtd
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
2008-10-13 14:12:40 -07:00
net
Remove Andrew Morton's old email accounts
2008-10-16 11:21:32 -07:00
nubus
nubus: fix mis-indented statement
2008-10-16 11:21:30 -07:00
of
Merge commit 'gcl/gcl-next'
2008-10-14 10:11:27 +11:00
oprofile
Merge branch 'linus' into oprofile-v2
2008-10-13 11:05:51 +02:00
parisc
parport
Remove Andrew Morton's old email accounts
2008-10-16 11:21:32 -07:00
pci
Merge commit 'origin'
2008-10-15 11:31:54 +11:00
pcmcia
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
2008-10-13 14:12:40 -07:00
pnp
Merge commit 'origin'
2008-10-15 11:31:54 +11:00
power
olpc: olpc_battery.c sparse endian annotations
2008-10-16 11:21:30 -07:00
ps3
rapidio
regulator
da903x: add regulator support for DA9030/DA9034
2008-10-13 21:51:57 +01:00
rtc
RTC: M48T35: new RTC driver
2008-10-15 12:46:51 +01:00
s390
misc: replace __FUNCTION__ with __func__
2008-10-16 11:21:30 -07:00
sbus
scsi
m68k: Atari SCSI needs NVRAM
2008-10-14 10:23:27 -07:00
serial
Merge commit 'origin'
2008-10-15 11:31:54 +11:00
sh
sn
spi
spi: core and gpio expanders use subsys_init
2008-10-16 11:21:38 -07:00
ssb
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
2008-10-13 14:12:40 -07:00
tc
telephony
thermal
uio
usb
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
2008-10-13 14:12:40 -07:00
video
metronomefb: Fix warning when building 64bit
2008-10-15 10:19:51 -07:00
virtio
w1
watchdog
Merge git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog
2008-10-12 11:51:32 -07:00
xen
zorro
Kconfig
Makefile