01 Oct, 2006
40 commits
-
Convert various spin_lock_irqsave() callers to correctly use `unsigned long'.
Signed-off-by: Alexey Dobriyan
Cc: Miles Bader
Cc: "Luck, Tony"
Acked-by: Kyle McMartin
Cc: Jean Delvare
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
VFS: Use SEEK_{SET,CUR,END} instead of hardcoded values
Signed-off-by: Josef 'Jeff' Sipek
Acked-by: Trond Myklebust
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
EICON ISDN: Removed unused definitions for OS_SEEK_*
Signed-off-by: Josef 'Jeff' Sipek
Cc: Karsten Keil
Acked-by: Armin Schindler
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
MBCS: Use SEEK_{SET,CUR,END} instead of hardcoded values
Signed-off-by: Josef 'Jeff' Sipek
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
If we can clean up these remainders we can finally delete pci_find_*
Signed-off-by: Alan Cox
Cc: Greg KH
Acked-by: Benjamin Herrenschmidt
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Mirrors the drivers/ata version, hold a reference to the host bridge while we
are doing setup.Signed-off-by: Alan Cox
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
As we don't support hotplug we end up leaking an isa_dev reference which if
unload was ever added we would drop at the end of unloading. This is fine
because we do genuinely need the isa_dev pointer until unload.Signed-off-by: Alan Cox
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Simple conversion
Signed-off-by: Alan Cox
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fairly trivial change in this case
Signed-off-by: Alan Cox
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
pci_find_device is not refcounting and should be getting killed off.
Signed-off-by: Alan Cox
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The driver for /proc/config.gz consumes rather a lot of memory and it is in
fact possible to build it as a module.In some ways this is a bit risky, because the .config which is used for
compiling kernel/configs.c isn't necessarily the same as the .config which was
used to build vmlinux.But OTOH the potential memory savings are decent, and it'd be fairly dumb to
build your configs.o with a different .config.Signed-off-by: Andrew Morton
Cc: "Randy.Dunlap"
Cc: Sam Ravnborg
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix up kernel/sys.c to be consistent with CodingStyle and the rest of the
file.Signed-off-by: Cal Peake
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Stop some other people peering into the baud bits on their own and make
them use the tty_get_baud_rate() helper as a preperation for the move to
the new termios. Corrected dependancy previous one had on new termios
structsSigned-off-by: Alan Cox
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add support for logical volumes >2TB. All SAS/SATA controllers support
large volumes.Signed-off-by: Mike Miller
Cc: Jens Axboe
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
* fs/open.c is getting bit crowdy
* preparation to lutimes(2)Signed-off-by: Alexey Dobriyan
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
One of idiomatic ways to duplicate a region of memory is
dst = kmalloc(len, GFP_KERNEL);
if (!dst)
return -ENOMEM;
memcpy(dst, src, len);which is neat code except a programmer needs to write size twice. Which
sometimes leads to mistakes. If len passed to kmalloc is smaller that len
passed to memcpy, it's straight overwrite-beyond-end. If len passed to
memcpy is smaller than len passed to kmalloc, it's either a) legit
behaviour ;-), or b) cloned buffer will contain garbage in second half.Slight trolling of commit lists shows several duplications bugs
done exactly because of diverged lenghts:Linux:
[CRYPTO]: Fix memcpy/memset args.
[PATCH] memcpy/memset fixes
OpenBSD:
kerberosV/src/lib/asn1: der_copy.c:1.4If programmer is given only one place to play with lengths, I believe, such
mistakes could be avoided.With kmemdup, the snippet above will be rewritten as:
dst = kmemdup(src, len, GFP_KERNEL);
if (!dst)
return -ENOMEM;This also leads to smaller code (kzalloc effect). Quick grep shows
200+ places where kmemdup() can be used.Signed-off-by: Alexey Dobriyan
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add maximum latency tracking to the ALSA subsystem for PCM playback. In
ALSA, the playback application controls the buffer size and thus indirectly
the period of latency that it can deal with. This patch uses 75% of the
total available latency as threshold to announce to the latency subsystem;
While 75% is a crude heuristic it's a quite reasonable one; the remaining
25% can be used for all driver processing for the next samples which is
also proportional to the size of the buffer.With ogg123 a latency setting of about 4msec was seen (at 44Khz), while
with the "play" command a much longer maximum tolerable latency was seen.
Other, more multimedia oriented players as well as games, will have a lot
smaller buffers to allow better synchronization and those will actually get
into the latency domains where there is impact on the power management
rules.Signed-off-by: Takashi Iwai
Signed-off-by: Arjan van de Ven
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add infrastructure to track "maximum allowable latency" for power saving
policies.The reason for adding this infrastructure is that power management in the
idle loop needs to make a tradeoff between latency and power savings
(deeper power save modes have a longer latency to running code again). The
code that today makes this tradeoff just does a rather simple algorithm;
however this is not good enough: There are devices and use cases where a
lower latency is required than that the higher power saving states provide.
An example would be audio playback, but another example is the ipw2100
wireless driver that right now has a very direct and ugly acpi hook to
disable some higher power states randomly when it gets certain types of
error.The proposed solution is to have an interface where drivers can
* announce the maximum latency (in microseconds) that they can deal with
* modify this latency
* give up their constraintand a function where the code that decides on power saving strategy can
query the current global desired maximum.This patch has a user of each side: on the consumer side, ACPI is patched
to use this, on the producer side the ipw2100 driver is patched.A generic maximum latency is also registered of 2 timer ticks (more and you
lose accurate time tracking after all).While the existing users of the patch are x86 specific, the infrastructure
is not. I'd like to ask the arch maintainers of other architectures if the
infrastructure is generic enough for their use (assuming the architecture
has such a tradeoff as concept at all), and the sound/multimedia driver
owners to look at the driver facing API to see if this is something they
can use.[akpm@osdl.org: cleanups]
Signed-off-by: Arjan van de Ven
Signed-off-by: Ingo Molnar
Acked-by: Jesse Barnes
Cc: "Brown, Len"
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Conversion of booleans to: generic-boolean.patch (2006-08-23)
Signed-off-by: Richard Knutsson
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Conversion of booleans to: generic-boolean.patch (2006-08-23)
Signed-off-by: Richard Knutsson
Cc: Dave Kleikamp
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Conversion of booleans to: generic-boolean.patch (2006-08-23)
Signed-off-by: Richard Knutsson
Signed-off-by: Anton Altaparmakov
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This patch defines:
* a generic boolean-type, named 'bool'
* aliases to 0 and 1, named 'false' and 'true'Removing colliding definitions of 'bool', 'false' and 'true'.
Signed-off-by: Richard Knutsson
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
- Add soothing comment
- uninline thrice-called function
Cc: OGAWA Hirofumi
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The api for hot-add memory already has a construct for finding nodes based on
an address, memory_add_physaddr_to_nid. This patch allows the fucntion to do
something besides return 0. It uses the nodes_add infomation to lookup to
node info for a hot add event.Signed-off-by: Keith Mannthey
Cc: KAMEZAWA Hiroyuki
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Migate CONFIG_MEMORY_HOTPLUG to CONFIG_MEMORY_HOTPLUG_SPARSE where needed.
Signed-off-by: Keith Mannthey
Cc: KAMEZAWA Hiroyuki
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
In cases where the acpi memory-add event does not containe the pxm (node)
infomation allow the driver to look up node info based on the address. The
acpi_get_node call returns -1 if it can't decode the pxm info, this causes
add_memory to panic. acpi_get_node would have to decode the resource from the
handle (a lenghty proposition). This seems to be the cleanist point to
interject the hook.[kamezawa.hiroyu@jp.fujitsu.com: build fixes]
[y-goto@jp.fujitsu.com: build fixes]
Signed-off-by: Keith Mannthey
Cc: KAMEZAWA Hiroyuki
Cc: Andi Kleen
Signed-off-by: KAMEZAWA Hiroyuki
Signed-off-by: Yasunori Goto
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The api for hot-add memory already has a construct for finding nodes based on
an address, memory_add_physaddr_to_nid. This patch allows the fucntion to do
something besides return 0. It uses the nodes_add infomation to lookup to
node info for a hot add event.Signed-off-by: Keith Mannthey
Cc: KAMEZAWA Hiroyuki
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Enable x86_64 srat.c to share code between both reserve and sparsemem based
add memory paths. Both paths need the hot-add area node locality infomration
(nodes_add). This code refactors the code path to allow this.Signed-off-by: Keith Mannthey
Cc: KAMEZAWA Hiroyuki
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Create Kconfig namespace for MEMORY_HOTPLUG_RESERVE and MEMORY_HOTPLUG_SPARSE.
This is needed to create a disticiton between the 2 paths. Selecting the
high level opiton of MEMORY_HOTPLUG will get you MEMORY_HOTPLUG_SPARSE if you
have sparsemem enabled or MEMORY_HOTPLUG_RESERVE if you are x86_64 with
discontig and ACPI numa support.Signed-off-by: Keith Mannthey
Cc: KAMEZAWA Hiroyuki
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix up externs in memory_hotplug.c. Cleanup.
Signed-off-by: Keith Mannthey
Cc: KAMEZAWA Hiroyuki
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This fixes two things
Firstly someone mistakenly used "errata" for the singular. This causes
Dave Woodhouse to emit diagnostics whenever the string is read, and so
should be fixed.Secondly the AMD AGP tunnel has an erratum which causes hangs if you try
and do direct PCI to AGP transfers in some cases. We have a flag for
PCI/PCI failures but we need a different flag for this really as in this
case we don't want to stop PCI/PCI transfers using things like IOAT and the
new RAID offload work.I'll post some updates to make proper use of the PCIAGP flag in the
media/video drivers to Mauro.Signed-off-by: Alan Cox
Cc: David Woodhouse
Signed-off-by: Greg Kroah-Hartman
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Don't try and give NULL to fput() in the error handling in do_mmap_pgoff()
as it'll cause an oops.Signed-off-by: David Howells
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
These two BUG_ON()s are redundant and undesired: we're checking for this
condition further on in the function, only better.Cc: Dave Jones
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The ->flags in struct request was split into two variables, in a recent
changeset. The merge of this change forgot to update SCSI's libsas,
probably because libsas was a very recent merge.Signed-off-by: Jeff Garzik
Signed-off-by: Linus Torvalds -
device_reprobe() should return an error code. When it does so,
scsi_device_reprobe() should propagate it back.Acked-by: Jeff Garzik
Signed-off-by: Andrew Morton
Signed-off-by: James Bottomley
Signed-off-by: Linus Torvalds -
* 'block' of git://brick.kernel.dk/data/git/linux-2.6-block:
[PATCH] Only enable CONFIG_BLOCK option for embedded -
It's too easy for people to shoot themselves in the foot, and it
only makes sense for embedded folks anyway.Signed-off-by: Jens Axboe
-
* 'block' of git://brick.kernel.dk/data/git/linux-2.6-block: (67 commits)
[PATCH] blk_queue_start_tag() shared map race fix
[PATCH] Update axboe@suse.de email address
[PATCH] fix creating zero sized bio mempools in low memory system
[PATCH] CONFIG_BLOCK: blk_congestion_wait() fix
[PATCH] CONFIG_BLOCK internal.h cleanups
[PATCH] BLOCK: Make USB storage depend on SCSI rather than selecting it [try #6]
[PATCH] BLOCK: Make it possible to disable the block layer [try #6]
[PATCH] BLOCK: Remove no-longer necessary linux/buffer_head.h inclusions [try #6]
[PATCH] BLOCK: Remove no-longer necessary linux/mpage.h inclusions [try #6]
[PATCH] BLOCK: Move the msdos device ioctl compat stuff to the msdos driver [try #6]
[PATCH] BLOCK: Move the Ext3 device ioctl compat stuff to the Ext3 driver [try #6]
[PATCH] BLOCK: Move the Ext2 device ioctl compat stuff to the Ext2 driver [try #6]
[PATCH] BLOCK: Move the ReiserFS device ioctl compat stuff to the ReiserFS driver [try #6]
[PATCH] BLOCK: Move common FS-specific ioctls to linux/fs.h [try #6]
[PATCH] BLOCK: Move the loop device ioctl compat stuff to the loop driver [try #6]
[PATCH] BLOCK: Move __invalidate_device() to block_dev.c [try #6]
[PATCH] BLOCK: Dissociate generic_writepages() from mpage stuff [try #6]
[PATCH] BLOCK: Remove dependence on existence of blockdev_superblock [try #6]
[PATCH] BLOCK: Move extern declarations out of fs/*.c into header files [try #6]
[PATCH] BLOCK: Don't call block_sync_page() from AFS [try #6]
... -
If we share the tag map between two or more queues, then we cannot
use __set_bit() to set the bit. In fact we need to make sure we
atomically acquire this tag, so loop using test_and_set_bit() to
protect from that.Noticed by Mike Christie
Signed-off-by: Jens Axboe