Al Viro [Wed, 19 Mar 2008 16:27:48 +0000 (16:27 +0000)]
drivers/char/rocket portability fixes
unsigned long != __le32, TYVM, and unsigned char[4] is not guaranteed
to be aligned for u32.
While we are at it, sanitize sOutDW() a bit - have it take Byte_t * and
handle dereferencing internally.
NB: sWriteTxPrioByte() is almost certainly buggered on big-endian and is
missing cpu_to_le16() on assignments to *WordPtr; I've left it alone for now.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: "Theodore Ts'o" <tytso@mit.edu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Thu, 20 Mar 2008 02:10:56 +0000 (19:10 -0700)]
Merge branch 'merge' of git://git./linux/kernel/git/paulus/powerpc
* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc:
[POWERPC] Update some defconfigs
[POWERPC] Hide resources on Axon PCIE root complex nodes
[POWERPC] Fix cell IOMMU code to cope with empty dma-ranges and non-PCI devices
[POWERPC] Fix build failure for tqm8540 and sbc85xx defconfigs
[POWERPC] Fix PMU + soft interrupt disable bug
[POWERPC] user_regset PTRACE_SETREGS regression fix
Jaya Kumar [Thu, 20 Mar 2008 00:01:10 +0000 (17:01 -0700)]
fbdev: defio and Metronomefb
Implement support for the E-Ink Metronome controller. It provides an mmapable
interface to the controller using defio support. It was tested with a gumstix
pxa255 with Vizplex media using Xfbdev and various X clients such as xeyes,
xpdf, xloadimage.
This patch also fixes the following bug: Defio would cause a hang on write
access to the framebuffer as the page fault would be called ad-infinitum. It
fixes fb_defio by setting the mapping to be used by page_mkclean.
Signed-off-by: Jaya Kumar <jayakumar.lkml@gmail.com>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
David Brownell [Thu, 20 Mar 2008 00:01:09 +0000 (17:01 -0700)]
rtc-at91sam9 fixes
Updates to the at91sam9 rtt-as-rtc driver:
- Bugfix: IRQ enable bits need shifting before masking with status
- Platform code to initialize wakeup bits didn't get merged; cope
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Justin Waters <justin.waters@timesys.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Andrew Morton [Thu, 20 Mar 2008 00:01:08 +0000 (17:01 -0700)]
revert "clocksource: make clocksource watchdog cycle through online CPUs"
Revert commit
1ada5cba6a0318f90e45b38557e7b5206a9cba38 ("clocksource:
make clocksource watchdog cycle through online CPUs") due to the
regression reported by Gabriel C at
http://lkml.org/lkml/2008/2/24/281
(short vesion: it makes TSC be marked as always unstable on his
machine).
Cc: Andi Kleen <ak@suse.de>
Acked-by: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Robert Hancock <hancockr@shaw.ca>
Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Gabriel C <nix.or.die@googlemail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Alex Dubov [Thu, 20 Mar 2008 00:01:08 +0000 (17:01 -0700)]
memstick: optimize setup of JMicron host parameters
Set correct clock management values to improve over-all performance.
Signed-off-by: Alex Dubov <oakad@yahoo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Alex Dubov [Thu, 20 Mar 2008 00:01:07 +0000 (17:01 -0700)]
memstick: add support for 8-bit parallel mode
Newer MemoryStick (HG) cards and hosts support 8-bit parallel mode of
operation in addition to original 4-bit and 1-bit modes.
Signed-off-by: Alex Dubov <oakad@yahoo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Alex Dubov [Thu, 20 Mar 2008 00:01:06 +0000 (17:01 -0700)]
memstick: automatically retrieve "INT" value from command response
MemoryStick storage cards, when in parallel mode, send several meaningful bits
of their "INT" register as part of command response. This data is stored by
host and can be used to spare invocation of "GET_INT" TPC on each data page
transferred between host and card.
Signed-off-by: Alex Dubov <oakad@yahoo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Andrew Morton [Thu, 20 Mar 2008 00:01:05 +0000 (17:01 -0700)]
fs/ufs/balloc.c: fix sparc64 printk warning
fs/ufs/balloc.c: In function `ufs_change_blocknr':
fs/ufs/balloc.c:317: warning: long long unsigned int format, long unsigned int arg (arg 2)
fs/ufs/balloc.c:317: warning: long long unsigned int format, long unsigned int arg (arg 3)
sector_t is u64 and we don't know what type the architecture uses to implement
u64.
Cc: Evgeniy Dushistov <dushistov@mail.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Andrew Morton [Thu, 20 Mar 2008 00:01:05 +0000 (17:01 -0700)]
drivers/md/raid5.c: fix printk warnings
gcc-3.4.5 on sparc64:
drivers/md/raid5.c: In function `raid5_end_read_request':
drivers/md/raid5.c:1147: warning: long long unsigned int format, long unsigned int arg (arg 4)
drivers/md/raid5.c:1164: warning: long long unsigned int format, long unsigned int arg (arg 3)
drivers/md/raid5.c:1170: warning: long long unsigned int format, long unsigned int arg (arg 3)
sector_t is u64, and we don't know what type the architecture uses to
implement u64 (on some it is unsigned long).
Cc: Neil Brown <neilb@suse.de>
Cc: "J. Bruce Fields" <bfields@fieldses.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Andrew Morton [Thu, 20 Mar 2008 00:01:04 +0000 (17:01 -0700)]
memstick: drivers/memstick/host/jmb38x_ms.c: suppress uninitialized var warning
drivers/memstick/host/jmb38x_ms.c: In function 'jmb38x_ms_transfer_data':
drivers/memstick/host/jmb38x_ms.c:294: warning: 'p_off' may be used uninitialized in this function
Cc: Alex Dubov <oakad@yahoo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Andrew Morton [Thu, 20 Mar 2008 00:01:03 +0000 (17:01 -0700)]
memstick: drivers/memstick/host/jmb38x_ms.c needs dma-mapping.h
sparc32:
drivers/memstick/host/jmb38x_ms.c: In function 'jmb38x_ms_probe':
drivers/memstick/host/jmb38x_ms.c:818: error: 'DMA_32BIT_MASK' undeclared (first use in this function)
drivers/memstick/host/jmb38x_ms.c:818: error: (Each undeclared identifier is reported only once
drivers/memstick/host/jmb38x_ms.c:818: error: for each function it appears in.)
Cc: Alex Dubov <oakad@yahoo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:01:02 +0000 (17:01 -0700)]
mm/readahead: fix kernel-doc notation
Fix kernel-doc notation in mm/readahead.c.
Change ":" to ";" so that it doesn't get treated as a doc section heading.
Move the comment block ending "*/" to a line by itself so that the text on
that last line is not lost (dropped).
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Dave Young [Thu, 20 Mar 2008 00:01:01 +0000 (17:01 -0700)]
zisofs: fix readpage() outside i_size
A read request outside i_size will be handled in do_generic_file_read(). So
we just return 0 to avoid getting -EIO as normal reading, let
do_generic_file_read do the rest.
At the same time we need unlock the page to avoid system stuck.
Fixes http://bugzilla.kernel.org/show_bug.cgi?id=10227
Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
Acked-by: Jan Kara <jack@suse.cz>
Report-by: Christian Perle <chris@linuxinfotag.de>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:01:00 +0000 (17:01 -0700)]
fs: fix kernel-doc notation warnings
Fix kernel-doc notation warnings in fs/.
Warning(mmotm-2008-0314-1449//fs/super.c:560): missing initial short description on line:
* mark_files_ro
Warning(mmotm-2008-0314-1449//fs/locks.c:1277): missing initial short description on line:
* lease_get_mtime
Warning(mmotm-2008-0314-1449//fs/locks.c:1277): missing initial short description on line:
* lease_get_mtime
Warning(mmotm-2008-0314-1449//fs/namei.c:1368): missing initial short description on line:
* lookup_one_len: filesystem helper to lookup single pathname component
Warning(mmotm-2008-0314-1449//fs/buffer.c:3221): missing initial short description on line:
* bh_uptodate_or_lock: Test whether the buffer is uptodate
Warning(mmotm-2008-0314-1449//fs/buffer.c:3240): missing initial short description on line:
* bh_submit_read: Submit a locked buffer for reading
Warning(mmotm-2008-0314-1449//fs/fs-writeback.c:30): missing initial short description on line:
* writeback_acquire: attempt to get exclusive writeback access to a device
Warning(mmotm-2008-0314-1449//fs/fs-writeback.c:47): missing initial short description on line:
* writeback_in_progress: determine whether there is writeback in progress
Warning(mmotm-2008-0314-1449//fs/fs-writeback.c:58): missing initial short description on line:
* writeback_release: relinquish exclusive writeback access against a device.
Warning(mmotm-2008-0314-1449//include/linux/jbd.h:351): contents before sections
Warning(mmotm-2008-0314-1449//include/linux/jbd.h:561): contents before sections
Warning(mmotm-2008-0314-1449//fs/jbd/transaction.c:1935): missing initial short description on line:
* void journal_invalidatepage()
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Michael Halcrow [Thu, 20 Mar 2008 00:00:58 +0000 (17:00 -0700)]
eCryptfs: Swap dput() and mntput()
ecryptfs_d_release() is doing a mntput before doing the dput. This patch
moves the dput before the mntput.
Thanks to Rajouri Jammu for reporting this.
Signed-off-by: Michael Halcrow <mhalcrow@us.ibm.com>
Cc: Rajouri Jammu <rajouri.jammu@gmail.com>
Cc: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Paul E. McKenney [Thu, 20 Mar 2008 00:00:57 +0000 (17:00 -0700)]
rcu: fix misplaced mb() in rcu_enter/exit_nohz()
In the process of writing up the mechanical proof of correctness for the
dynticks/preemptable-RCU interface, I noticed misplaced memory barriers in
rcu_enter_nohz() and rcu_exit_nohz().
This patch puts them in the right place and adds a comment. The key thing to
keep in mind is that rcu_enter_nohz() is -exiting- the mode that can legally
execute RCU read-side critical sections.
The memory barrier must be between any potential RCU read-side critical
sections and the increment of the per-CPU dynticks_progress_counter, and thus
must come -before- this increment. And vice versa for rcu_exit_nohz().
The locking in the scheduler is probably saving us for the moment.
Also, switch to smp_mb() - we don't need a barrier for uniprocessor kernels.
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Acked-by: Steven Rostedt <srostedt@redhat.com>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Cc: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Stefan Bauer [Thu, 20 Mar 2008 00:00:55 +0000 (17:00 -0700)]
i810fb: fix console switch regression
Since
4c7ffe0b9f7f40bd818fe3af51342f64c483908e ("fbdev: prevent drivers that
have hardware cursors from calling software cursor code") every call of
i810fb_cursor fails with -ENXIO because of a incorrect "!".
This hasn't struck until
eaa0ff15c30dc9799eb4d12660edb73aeb6d32c5 ("fix !
versus & precedence in various places") surrounded the expression with braces,
so that the intended behavior was inverted. That caused 'pixel waste' - the
same line of multi-colored pixels repeated over the whole screen - during
console switch.
This switches back to the original pre-
4c7ffe0 behavior.
Signed-off-by: Stefan Bauer <stefan.bauer@cs.tu-chemnitz.de>
Tested-by: Stefan Bauer <stefan.bauer@cs.tu-chemnitz.de>
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Antonino Daplas <adaplas@pol.net>
Cc: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Duane Griffin [Thu, 20 Mar 2008 00:00:54 +0000 (17:00 -0700)]
jbd2: correctly unescape journal data blocks
Fix a long-standing typo (predating git) that will cause data corruption if a
journal data block needs unescaping. At the moment the wrong buffer head's
data is being unescaped.
To test this case mount a filesystem with data=journal, start creating and
deleting a bunch of files containing only JBD2_MAGIC_NUMBER (0xc03b3998), then
pull the plug on the device. Without this patch the files will contain zeros
instead of the correct data after recovery.
Signed-off-by: Duane Griffin <duaneg@dghda.com>
Acked-by: Jan Kara <jack@suse.cz>
Cc: <linux-ext4@vger.kernel.org>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Duane Griffin [Thu, 20 Mar 2008 00:00:53 +0000 (17:00 -0700)]
jbd: correctly unescape journal data blocks
Fix a long-standing typo (predating git) that will cause data corruption if a
journal data block needs unescaping. At the moment the wrong buffer head's
data is being unescaped.
To test this case mount a filesystem with data=journal, start creating and
deleting a bunch of files containing only JFS_MAGIC_NUMBER (0xc03b3998), then
pull the plug on the device. Without this patch the files will contain zeros
instead of the correct data after recovery.
Signed-off-by: Duane Griffin <duaneg@dghda.com>
Acked-by: Jan Kara <jack@suse.cz>
Cc: <linux-ext4@vger.kernel.org>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Alessandro Zummo [Thu, 20 Mar 2008 00:00:51 +0000 (17:00 -0700)]
rtc: fix kconfig help
Signed-off-by: Alessandro Zummo <a.zummo@towertech.it>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Ahmed S. Darwish [Thu, 20 Mar 2008 00:00:51 +0000 (17:00 -0700)]
smack: do not dereference NULL ipc object
In the SYSV ipc msgctl(),semctl(),shmctl() family, if the user passed *_INFO
as the desired operation, no specific object is meant to be controlled and
only system-wide information is returned. This leads to a NULL IPC object in
the LSM hooks if the _INFO flag is given.
Avoid dereferencing this NULL pointer in Smack ipc *ctl() methods.
Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com>
Acked-by: Casey Schaufler <casey@schaufler-ca.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
David Howells [Thu, 20 Mar 2008 00:00:50 +0000 (17:00 -0700)]
ROMFS: Fix up an error in iget removal
Fix up an error in iget removal in which romfs_lookup() making a successful
call to romfs_iget() continues through the negative/error handling (previously
the successful case jumped around the negative/error handling case):
(1) inode is initialised to NULL at the top of the function, eliminating the
need for specific negative-inode handling. This means the positive
success handling now flows straight through.
(2) Rename the labels to be clearer about what they mean.
Also make romfs_lookup()'s result variable of type long so as to avoid
32-bit/64-bit conversions with PTR_ERR() and friends.
Based upon a report and patch from Adam Richter.
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: "Adam J. Richter" <adam@yggdrasil.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Josef Bacik [Thu, 20 Mar 2008 00:00:49 +0000 (17:00 -0700)]
ext3: fix wrong gfp type under transaction
There are several places where we make allocations with GFP_KERNEL while under
a transaction, which could lead to an assertion panic or lockup if under
memory pressure. This patch switches these problem areas to use GFP_NOFS to
keep these problems from happening.
Signed-off-by: Josef Bacik <jbacik@redhat.com>
Cc: <linux-ext4@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Darrick J. Wong [Thu, 20 Mar 2008 00:00:48 +0000 (17:00 -0700)]
ibmpex: report temperatures in mC, not C
ibmpex's temperature sensors report incorrect units. Apply a conversion
factor so that tempertures report correctly. Until now, no systems seemed to
report temperatures this way, but evidently QS2x blades do.
Signed-off-by: Darrick J. Wong <djwong@us.ibm.com>
Cc: "Mark M. Hoffman" <mhoffman@lightlink.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Darrick J. Wong [Thu, 20 Mar 2008 00:00:48 +0000 (17:00 -0700)]
ibmpex: update Kconfig to list more supported models
Enhanced the list of supported machines.
Signed-off-by: Darrick J. Wong <djwong@us.ibm.com>
Cc: Mark M. Hoffman <mhoffman@lightlink.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Darrick J. Wong [Thu, 20 Mar 2008 00:00:47 +0000 (17:00 -0700)]
ibmpex: correct power use multipliers for QS2x blade
The QS2x blades ships with v2.54 of the firmware, which use the same
multiplier for all power meters.
Signed-off-by: Darrick J. Wong <djwong@us.ibm.com>
Cc: Mark M. Hoffman <mhoffman@lightlink.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Jan Kara [Thu, 20 Mar 2008 00:00:46 +0000 (17:00 -0700)]
quota: add possibly missing iput() when quotaon and quotaoff races
We should always put inode we have reference to, even if quota was reenabled
in the mean time.
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Pavel Emelyanov [Thu, 20 Mar 2008 00:00:45 +0000 (17:00 -0700)]
memcgroup: fix check for thread being a group leader in memcgroup
The check t->pid == t->pid is not the blessed way to check whether a task is a
group leader.
This is not about the code beautifulness only, but about pid namespaces fixes
- both the tgid and the pid fields on the task_struct are (slowly :( )
becoming deprecated.
Besides, the thread_group_leader() macro makes only one dereference :)
Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Cc: Balbir Singh <balbir@linux.vnet.ibm.com>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Paul Menage <menage@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:00:44 +0000 (17:00 -0700)]
jbd: fix jbd kernel-doc notation
Fix kernel-doc notation in jbd.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
NeilBrown [Thu, 20 Mar 2008 00:00:44 +0000 (17:00 -0700)]
md: remove the 'super' sysfs attribute from devices in an 'md' array
Exposing the binary blob which is the md 'super-block' via sysfs doesn't
really fit with the whole sysfs model, and ever since commit
8118a859dc7abd873193986c77a8d9bdb877adc8 ("sysfs: fix off-by-one error
in fill_read_buffer()") it doesn't actually work at all (as the size of
the blob is often one page).
(akpm: as in, fs/sysfs/file.c:fill_read_buffer() goes BUG)
So just remove it altogether. It isn't really useful.
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:00:43 +0000 (17:00 -0700)]
mm: rmap kernel-doc fixes
Correct kernel-doc function names and parameters in rmap.c.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:00:42 +0000 (17:00 -0700)]
mm: highmem kernel-doc additions
Add kernel-doc comments to highmem.c.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:00:42 +0000 (17:00 -0700)]
mm/oom_kill: fix kernel-doc
Fix kernel-doc notation in oom_kill.c.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:00:41 +0000 (17:00 -0700)]
mm/shmem and tiny-shmem: fix some kernel-doc
Convert tiny-shmem.c function comments to kernel-doc. Add parameters and
convert/fix other kernel-doc in shmem.c.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Randy Dunlap [Thu, 20 Mar 2008 00:00:40 +0000 (17:00 -0700)]
mm: fix various kernel-doc comments
Fix various kernel-doc notation in mm/:
filemap.c: add function short description; convert 2 to kernel-doc
fremap.c: change parameter 'prot' to @prot
pagewalk.c: change "-" in function parameters to ":"
slab.c: fix short description of kmem_ptr_validate()
swap.c: fix description & parameters of put_pages_list()
swap_state.c: fix function parameters
vmalloc.c: change "@returns" to "Returns:" since that is not a parameter
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Quentin Barnes [Thu, 20 Mar 2008 00:00:39 +0000 (17:00 -0700)]
aio: bad AIO race in aio_complete() leads to process hang
My group ran into a AIO process hang on a 2.6.24 kernel with the process
sleeping indefinitely in io_getevents(2) waiting for the last wakeup to come
and it never would.
We ran the tests on x86_64 SMP. The hang only occurred on a Xeon box
("Clovertown") but not a Core2Duo ("Conroe"). On the Xeon, the L2 cache isn't
shared between all eight processors, but is L2 is shared between between all
two processors on the Core2Duo we use.
My analysis of the hang is if you go down to the second while-loop
in read_events(), what happens on processor #1:
1) add_wait_queue_exclusive() adds thread to ctx->wait
2) aio_read_evt() to check tail
3) if aio_read_evt() returned 0, call [io_]schedule() and sleep
In aio_complete() with processor #2:
A) info->tail = tail;
B) waitqueue_active(&ctx->wait)
C) if waitqueue_active() returned non-0, call wake_up()
The way the code is written, step 1 must be seen by all other processors
before processor 1 checks for pending events in step 2 (that were recorded by
step A) and step A by processor 2 must be seen by all other processors
(checked in step 2) before step B is done.
The race I believed I was seeing is that steps 1 and 2 were
effectively swapped due to the __list_add() being delayed by the L2
cache not shared by some of the other processors. Imagine:
proc 2: just before step A
proc 1, step 1: adds to ctx->wait, but is not visible by other processors yet
proc 1, step 2: checks tail and sees no pending events
proc 2, step A: updates tail
proc 1, step 3: calls [io_]schedule() and sleeps
proc 2, step B: checks ctx->wait, but sees no one waiting, skips wakeup
so proc 1 sleeps indefinitely
My patch adds a memory barrier between steps A and B. It ensures that the
update in step 1 gets seen on processor 2 before continuing. If processor 1
was just before step 1, the memory barrier makes sure that step A (update
tail) gets seen by the time processor 1 makes it to step 2 (check tail).
Before the patch our AIO process would hang virtually 100% of the time. After
the patch, we have yet to see the process ever hang.
Signed-off-by: Quentin Barnes <qbarnes+linux@yahoo-inc.com>
Reviewed-by: Zach Brown <zach.brown@oracle.com>
Cc: Benjamin LaHaise <bcrl@kvack.org>
Cc: <stable@kernel.org>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
[ We should probably disallow that "if (waitqueue_active()) wake_up()"
coding pattern, because it's so often buggy wrt memory ordering ]
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Paul Mackerras [Thu, 20 Mar 2008 00:21:32 +0000 (11:21 +1100)]
[POWERPC] Update some defconfigs
Signed-off-by: Paul Mackerras <paulus@samba.org>
Michael Ellerman [Wed, 19 Mar 2008 06:10:55 +0000 (17:10 +1100)]
[POWERPC] Hide resources on Axon PCIE root complex nodes
The PCI bridge representing the PCIE root complex on Axon, contains
device BARs for a memory range and ROM that define inbound accesses.
This confuses the kernel resource management code -- the resources
need to be hidden when Axon is a host bridge.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Michael Ellerman [Fri, 14 Mar 2008 05:47:39 +0000 (16:47 +1100)]
[POWERPC] Fix cell IOMMU code to cope with empty dma-ranges and non-PCI devices
The cell IOMMU code to parse the dma-ranges properties, used for the fixed
mapping, was broken in two ways for some devices.
Firstly it didn't cope with empty dma-ranges properties. An empty property
implies no translation so can be safely skipped.
The code also wrongly assumed it would be looking at PCI devices, and hard
coded the number of address and size cells.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Paul Gortmaker [Tue, 18 Mar 2008 05:13:10 +0000 (16:13 +1100)]
[POWERPC] Fix build failure for tqm8540 and sbc85xx defconfigs
The wrapper script didn't have entries for the TQM8540 board and the
SBC8548 or SBC8560 boards. I've assumed that the TQM8540 console is
8250 based and not CPM based by looking at its defconfig. There was
also a trailing * on the TQM8555 entry that I removed too.
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Anton Blanchard [Mon, 17 Mar 2008 04:27:09 +0000 (15:27 +1100)]
[POWERPC] Fix PMU + soft interrupt disable bug
Since the PMU is an NMI now, it can come at any time we are only soft
disabled. We must hard disable around the two places we allow the kernel
stack SLB and r1 to go out of sync. Otherwise the PMU exception can
force a kernel stack SLB into another slot, which can lead to it
getting evicted, which can lead to a nasty unrecoverable SLB miss
in the exception entry code.
Signed-off-by: Anton Blanchard <anton@samba.org>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Roland McGrath [Thu, 13 Mar 2008 08:25:35 +0000 (19:25 +1100)]
[POWERPC] user_regset PTRACE_SETREGS regression fix
The PTRACE_SETREGS request was only recently added on powerpc,
and gdb does not use it. So it slipped through without getting
all the testing it should have had.
The user_regset changes had a simple bug in storing to all of
the 32-bit general registers block on 64-bit kernels. This bug
only comes up with PTRACE_SETREGS, not PPC_PTRACE_SETREGS.
It causes a BUG_ON to hit, so this fix needs to go in ASAP.
Signed-off-by: Roland McGrath <roland@redhat.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Linus Torvalds [Wed, 19 Mar 2008 04:34:48 +0000 (21:34 -0700)]
Merge branch 'fixes' of git://git./linux/kernel/git/djbw/async_tx
* 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/djbw/async_tx:
async_tx: avoid the async xor_zero_sum path when src_cnt > device->max_xor
fsldma: Fix the DMA halt when using DMA_INTERRUPT async_tx transfer.
Alexey Starikovskiy [Tue, 18 Mar 2008 23:45:12 +0000 (02:45 +0300)]
Revert "ACPI: EC: Handle IRQ storm on Acer laptops"
This reverts commit
2c81ce4c9c37b910210f2640c28e98a0c398dc26.
It caused several new troubles (eg suspend slowdown bisected down to
this patch by Pavel Machek), so just revert it for now.
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Cc: Pavel Machek <pavel@suse.cz>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Wed, 19 Mar 2008 04:27:13 +0000 (21:27 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/mingo/linux-2.6-sched-devel
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mingo/linux-2.6-sched-devel:
sched: tune multi-core idle balancing
sched: retune wake granularity
sched: wakeup-buddy tasks are cache-hot
sched: improve affine wakeups
sched, net: socket wakeups are sync
sched: clean up wakeup balancing, code flow
sched: clean up wakeup balancing, rename variables
sched: clean up wakeup balancing, move wake_affine()
Linus Torvalds [Wed, 19 Mar 2008 04:26:24 +0000 (21:26 -0700)]
IDE: Make taskfile interface more robust wrt unexpected end-of-command
Now that we handle all the special commands using REQ_TYPE_ATA_TASKFILE
rather than using the old REQ_TYPE_ATA_CMD model, we need to also
emulate the lack of full taskfile data that comes with the old command
model (ie when commands are generated with the HDIO_DRIVE_CMD ioctl
rather than using the HDIO_DRIVE_TASK[FILE] ioctls).
In particular, this means that we should handle command completion the
more relaxed way that the old drive_cmd_intr() code did. It allows
commands to finish early even if they don't use up all the data that we
thought we had for them.
This fixes a regression seen by Anders Eriksson where some SMART
commands sent by smartd would cause a boot-time system hang on his
machine because the IDE command handling code didn't realize that the
command had completed.
Tested-by: Anders Eriksson <aeriksson@fastmail.fm>
Cc: Jens Axboe <jens.axboe@oracle.com>
Cc: Ingo Molnar <mingo@elte.hu>
Acked-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Wed, 19 Mar 2008 04:13:19 +0000 (21:13 -0700)]
Merge branch 'slab-linus' of git://git./linux/kernel/git/christoph/vm
* 'slab-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/christoph/vm:
slub page alloc fallback: Enable interrupts for GFP_WAIT.
Ingo Molnar [Sun, 16 Mar 2008 10:14:30 +0000 (11:14 +0100)]
sched: tune multi-core idle balancing
WAKE_IDLE is too agressive on multi-core CPUs with the new
wake-affine code, keep it on for SMT/HT balancing alone
(where there's no cache affinity at all between logical CPUs).
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Ingo Molnar [Tue, 18 Mar 2008 17:47:57 +0000 (18:47 +0100)]
sched: retune wake granularity
reduce wake-up granularity for better interactivity.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Ingo Molnar [Sat, 15 Mar 2008 16:10:34 +0000 (17:10 +0100)]
sched: wakeup-buddy tasks are cache-hot
Wakeup-buddy tasks are cache-hot - this makes it a bit harder
for the load-balancer to tear them apart. (but it's still possible,
if the load is sufficiently assymetric)
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Ingo Molnar [Wed, 19 Mar 2008 00:42:00 +0000 (01:42 +0100)]
sched: improve affine wakeups
improve affine wakeups. Maintain the 'overlap' metric based on CFS's
sum_exec_runtime - which means the amount of time a task executes
after it wakes up some other task.
Use the 'overlap' for the wakeup decisions: if the 'overlap' is short,
it means there's strong workload coupling between this task and the
woken up task. If the 'overlap' is large then the workload is decoupled
and the scheduler will move them to separate CPUs more easily.
( Also slightly move the preempt_check within try_to_wake_up() - this has
no effect on functionality but allows 'early wakeups' (for still-on-rq
tasks) to be correctly accounted as well.)
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Ingo Molnar [Wed, 19 Mar 2008 00:44:24 +0000 (01:44 +0100)]
sched, net: socket wakeups are sync
'sync' wakeups are a hint towards the scheduler that (certain)
networking related wakeups likely create coupling between tasks.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Ingo Molnar [Sun, 16 Mar 2008 20:21:47 +0000 (21:21 +0100)]
sched: clean up wakeup balancing, code flow
Clean up the code flow. No code changed:
kernel/sched.o:
text data bss dec hex filename
42521 2858 232 45611 b22b sched.o.before
42521 2858 232 45611 b22b sched.o.after
md5:
09b31c44e9aff8666f72773dc433e2df sched.o.before.asm
09b31c44e9aff8666f72773dc433e2df sched.o.after.asm
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Ingo Molnar [Sun, 16 Mar 2008 19:56:26 +0000 (20:56 +0100)]
sched: clean up wakeup balancing, rename variables
rename 'cpu' to 'prev_cpu'. No code changed:
kernel/sched.o:
text data bss dec hex filename
42521 2858 232 45611 b22b sched.o.before
42521 2858 232 45611 b22b sched.o.after
md5:
09b31c44e9aff8666f72773dc433e2df sched.o.before.asm
09b31c44e9aff8666f72773dc433e2df sched.o.after.asm
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Ingo Molnar [Sun, 16 Mar 2008 19:36:10 +0000 (20:36 +0100)]
sched: clean up wakeup balancing, move wake_affine()
split out the affine-wakeup bits.
No code changed:
kernel/sched.o:
text data bss dec hex filename
42521 2858 232 45611 b22b sched.o.before
42521 2858 232 45611 b22b sched.o.after
md5:
9d76738f1272aa82f0b7affd2f51df6b sched.o.before.asm
09b31c44e9aff8666f72773dc433e2df sched.o.after.asm
(the md5's changed because stack slots changed and some registers
get scheduled by gcc in a different order - but otherwise the before
and after assembly is instruction for instruction equivalent.)
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Dan Williams [Wed, 19 Mar 2008 04:23:59 +0000 (21:23 -0700)]
async_tx: avoid the async xor_zero_sum path when src_cnt > device->max_xor
If the channel cannot perform the operation in one call to
->device_prep_dma_zero_sum, then fallback to the xor+page_is_zero path.
This only affects users with arrays larger than 16 devices on iop13xx or
32 devices on iop3xx.
Cc: <stable@kernel.org>
Cc: Neil Brown <neilb@suse.de>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Zhang Wei [Wed, 19 Mar 2008 01:45:00 +0000 (18:45 -0700)]
fsldma: Fix the DMA halt when using DMA_INTERRUPT async_tx transfer.
The DMA_INTERRUPT async_tx is a NULL transfer, thus the BCR(count register)
is 0. When the transfer started with a byte count of zero, the DMA
controller will triger a PE(programming error) event and halt, not a normal
interrupt. I add special codes for PE event and DMA_INTERRUPT
async_tx testing.
Signed-off-by: Zhang Wei <wei.zhang@freescale.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Linus Torvalds [Tue, 18 Mar 2008 15:43:59 +0000 (08:43 -0700)]
Merge branch 'audit.b49' of git://git./linux/kernel/git/viro/audit-current
* 'audit.b49' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/audit-current:
[PATCH] export sessionid alongside the loginuid in procfs
Eric Paris [Thu, 13 Mar 2008 12:15:31 +0000 (08:15 -0400)]
[PATCH] export sessionid alongside the loginuid in procfs
Signed-off-by: Eric Paris <eparis@redhat.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Linus Torvalds [Tue, 18 Mar 2008 14:49:59 +0000 (07:49 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jikos/hid
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
HID: update key codes for Apple aluminium
HID: fix comment in hid_input_report()
HID: BADPAD entry for NATSU Playstation USB adapter
HID: Use DIV_ROUND_UP
HID: remove HID_QUIRK_APPLE_ISO_KEYBOARD for 4th generation macbook
Linus Torvalds [Tue, 18 Mar 2008 14:48:23 +0000 (07:48 -0700)]
Merge branch 'release' of git://git./linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
ACPI: Set flag DOCK_UNDOCKING when triggered via sysfs
Revert "ACPI: video: Ignore devices that aren't present in hardware"
asus_acpi: remove misleading mask
Revert "ACPI: video: Ignore ACPI video devices that aren't present in hardware"
thermal: delete "default y"
thermal: re-document thermal units
Revert "thermal: fix generic thermal I/F for hwmon"
ACPI: fix ATA_ACPI build
ACPI: battery: Don't return -EFAIL on broken packages.
ACPI: lockdep warning on boot, 2.6.25-rc5
Linus Torvalds [Tue, 18 Mar 2008 14:46:19 +0000 (07:46 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
Input: ALPS - fix forward/back buttons reversed on Acer 5520-5290
Input: ALPS - put secondary device in proper place in sysfs
Input: wacom - add support for Bamboo1, BambooFun, and Cintiq 12WX
Input: document i8042.noloop
Input: add keyboard notifier documentation
Input: ads7846 - fix uninitialized var warning
Input: i8042 - add SNI RM support
Input: i8042 - add Lenovo 3000 N100 to nomux blacklist
Input: i8042 - fix warning on non-x86 builds
Input: cobalt_btns - assorted fixes
Linus Torvalds [Tue, 18 Mar 2008 14:44:21 +0000 (07:44 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jmorris/selinux-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/selinux-2.6:
make selinux_parse_opts_str() static
Linus Torvalds [Tue, 18 Mar 2008 14:43:14 +0000 (07:43 -0700)]
Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-block
* 'for-linus' of git://git.kernel.dk/linux-2.6-block:
Revert "unexport bio_{,un}map_user"
relay: fix subbuf_splice_actor() adding too many pages
The ps2esdi driver was marked as BROKEN more than two years ago due to being
Linus Torvalds [Tue, 18 Mar 2008 14:32:23 +0000 (07:32 -0700)]
Merge branch 'drm-fixes' of git://git./linux/kernel/git/airlied/drm-2.6
* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm/ati_pcigart: fix the PCIGART to use drm_pci to allocate GART table.
drm/radeon: fixup RV550 chip family
drm/via: attempt again to stabilise the AGP DMA command submission.
drm: Fix race that can lockup the kernel
Michael Hanselmann [Mon, 17 Mar 2008 21:23:52 +0000 (22:23 +0100)]
HID: update key codes for Apple aluminium
F5 and F6 have no second function printed on them. Thus their definitions have
been removed from the table.
KEY_CYCLEWINDOWS doesn't name the function of Mac OS X' Expose properly and
because we couldn't find a better key code, we decided to use KEY_FN_F4
instead.
We also changed KEY_BACK and KEY_FORWARD, which apply to browser functions, to
KEY_PREVIOUSSONG and KEY_NEXTSONG, since the keys are intended to control a
music player.
Signed-off-by: Michael Hanselmann <linux-kernel@hansmi.ch>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Jiri Kosina [Tue, 4 Mar 2008 12:53:33 +0000 (13:53 +0100)]
HID: fix comment in hid_input_report()
The hid_input_report() in debug mode of course outputs the report itself, not
the device report descriptor.
Fix this error in comment.
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Andrew Burton [Mon, 3 Mar 2008 09:49:59 +0000 (10:49 +0100)]
HID: BADPAD entry for NATSU Playstation USB adapter
Add quirk entry for BADPAD for the NATSU Playstation USB adapter. The
adapter is supported under Linux, but with bad direction detection.
Signed-off-by: Andrew Burton <adb@iinet.net.au>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Julia Lawall [Fri, 15 Feb 2008 12:53:11 +0000 (13:53 +0100)]
HID: Use DIV_ROUND_UP
The kernel.h macro DIV_ROUND_UP performs the computation (((n) + (d) - 1) /
(d)) but is perhaps more readable.
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Tobias Mueller [Fri, 14 Mar 2008 22:44:48 +0000 (23:44 +0100)]
HID: remove HID_QUIRK_APPLE_ISO_KEYBOARD for 4th generation macbook
4th generation MacBook (product id 0x022a) from Apple doesn't need
HID_QUIRK_APPLE_ISO_KEYBOARD fix anymore.
Signed-off-by: Tobias Mueller <Tobias_Mueller@twam.info>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Len Brown [Tue, 18 Mar 2008 09:17:15 +0000 (05:17 -0400)]
Merge branches 'release' and 'dock' into release
Holger Macht [Wed, 12 Mar 2008 00:07:27 +0000 (01:07 +0100)]
ACPI: Set flag DOCK_UNDOCKING when triggered via sysfs
begin_undock() is only called when triggered via a acpi notify handler
(pressing the undock button on the dock station), but complete_undock() is
always called after the eject. So if a undock is triggered through a sysfs
write, the flag DOCK_UNDOCKING has to be set for the dock station,
too. Otherwise this will freeze the system hard.
Signed-off-by: Holger Macht <hmacht@suse.de>
Acked-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Len Brown <len.brown@intel.com>
Len Brown [Tue, 18 Mar 2008 08:52:57 +0000 (04:52 -0400)]
Merge branches 'release', 'asus', 'bugzilla-8573', 'bugzilla-9995', 'bugzilla-10272', 'lockdep' and 'thermal' into release
Len Brown [Tue, 18 Mar 2008 08:04:35 +0000 (04:04 -0400)]
Revert "ACPI: video: Ignore devices that aren't present in hardware"
This reverts commit
0119509c4fbc9adcef1472817fda295334612976.
http://bugzilla.kernel.org/show_bug.cgi?id=9995
Signed-off-by: Len Brown <len.brown@intel.com>
Julia Lawall [Tue, 4 Mar 2008 23:00:13 +0000 (15:00 -0800)]
asus_acpi: remove misleading mask
led_out is boolean, so there is no functional change here,
but apparently an extra mask with 1 caused some style checkers
to flag this as logic bug.
Signed-off-by: Julia Lawall <julia@diku.dk>
Acked-by: Luca Tettamanti <kronos.it@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Len Brown <len.brown@intel.com>
Len Brown [Tue, 18 Mar 2008 05:43:53 +0000 (01:43 -0400)]
Revert "ACPI: video: Ignore ACPI video devices that aren't present in hardware"
This reverts commit
3fa2cdcc45a0176de15cac9dbf4ed2834ebf8932.
http://bugzilla.kernel.org/show_bug.cgi?id=9995
Signed-off-by: Len Brown <len.brown>
Len Brown [Tue, 18 Mar 2008 05:22:10 +0000 (01:22 -0400)]
thermal: delete "default y"
The generic thermal I/F gets selected by ACPI_THERMAL --
its only current customer.
it doesn't need to clutter other configs by default.
Signed-off-by: Len Brown <len.brown@intel.com>
Zhang, Rui [Tue, 18 Mar 2008 02:40:29 +0000 (10:40 +0800)]
thermal: re-document thermal units
From: Zhang Rui <rui.zhang@intel.com>
(reverting the previous sysfs patch also reverted a fix
to the thermal units documentation, which is restored by this commit)
The generic thermal driver shows temperature in millidegree Celsius.
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Len Brown [Tue, 18 Mar 2008 05:14:37 +0000 (01:14 -0400)]
Revert "thermal: fix generic thermal I/F for hwmon"
This reverts commit
3152fb9f11cdd2fd8688c2c5cb805e5c09b53dd9.
This broke libsensors.
Acked-by: Zhang Rui <rui.zhang@intel.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Len Brown <len.brown@intel.com>
Laszlo Kajan [Tue, 18 Mar 2008 04:39:55 +0000 (00:39 -0400)]
Input: ALPS - fix forward/back buttons reversed on Acer 5520-5290
ALPS_FW_BK_1 protocol flavor seems to have forward and backward
keys reversed.
Signed-off-by: Laszlo Kajan <kajla@bioinfo.pl>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dmitry Torokhov [Tue, 18 Mar 2008 04:29:18 +0000 (00:29 -0400)]
Input: ALPS - put secondary device in proper place in sysfs
Secondary input device did not have parent set up causing it
to appear in the root of sysfs device hierarchy.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Len Brown [Tue, 18 Mar 2008 04:26:07 +0000 (00:26 -0400)]
ACPI: fix ATA_ACPI build
drivers/ata/libata-acpi.c fails to build
drivers/built-in.o: In function `ata_acpi_associate':
(.text+0x7106a): undefined reference to `register_hotplug_dock_device'
When CONFIG_ATA_ACPI=y and CONFIG_ACPI_DOCK=m
But if dock is selected from ata_acpi, dock will =y
when ata_acpi=y, avoiding this problem.
http://bugzilla.kernel.org/show_bug.cgi?id=10272
Signed-off-by: Len Brown <len.brown@intel.com>
Alexey Starikovskiy [Tue, 18 Mar 2008 02:37:42 +0000 (22:37 -0400)]
ACPI: battery: Don't return -EFAIL on broken packages.
Acer BIOS has a bug which is exposed when a dead battery is present.
The package template that is used to describe battery status is
over-written with sane values when the battery is live.
But when the batter is dead, a bogus reference in the template
is used. In this case, Linux returns a fault, when instead
it should simply return that it doesn't know the missing value.
http://bugzilla.kernel.org/show_bug.cgi?id=8573
http://bugzilla.kernel.org/show_bug.cgi?id=10202
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Len Brown <len.brown@intel.com>
Mark Lord [Mon, 17 Mar 2008 20:04:23 +0000 (16:04 -0400)]
pciehp: don't enable slot unless forced
This fixes a 2.6.25 regression reported by Alex Chiang.
Invoke pciehp_enable_slot() at startup only when pciehp_force=1.
Some HP equipment apparently cannot cope with it otherwise.
This restores the (previously working) 2.6.24 behaviour here,
while allowing machines that need a kick to use pciehp_force=1.
This was the original design back in October 2007,
but Kristen suggested we try without it first:
Kristen Carlson Accardi wrote:
>I think it would be ok to try allowing the slot to be enabled when not
>using pciehp_force mode. We can wrap it later if it proves to break things
This ended up breaking one of Alex's setups,
so it's time to put the wrapper back in now.
Signed-off-by: Mark Lord <mlord@pobox.com>
Acked-by: Alex Chiang <achiang@hp.com>
Acked-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Adrian Bunk [Mon, 17 Mar 2008 20:29:23 +0000 (22:29 +0200)]
make selinux_parse_opts_str() static
This patch makes the needlessly global selinux_parse_opts_str() static.
Signed-off-by: Adrian Bunk <bunk@kernel.org>
Acked-by: Eric Paris <eparis@redhat.com>
Signed-off-by: James Morris <jmorris@namei.org>
Jens Axboe [Mon, 17 Mar 2008 20:14:40 +0000 (21:14 +0100)]
Revert "unexport bio_{,un}map_user"
Outside users like asmlib uses the mapping functions. API wise, the
export is definitely sane. It's a better idea to keep this export
than to require external users to open-code this piece of code instead.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Christoph Lameter [Thu, 13 Mar 2008 06:57:49 +0000 (23:57 -0700)]
slub page alloc fallback: Enable interrupts for GFP_WAIT.
The fallback path needs to enable interrupts like done for
the other page allocator calls. This was not necessary with
the alternate fast path since we handled irq enable/disable in
the slow path. The regular fastpath handles irq enable/disable
around calls to the slow path so we need to restore the proper
status before calling the page allocator from the slowpath.
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Linus Torvalds [Mon, 17 Mar 2008 16:52:24 +0000 (09:52 -0700)]
Merge branch 'upstream-linus' of git://git./linux/kernel/git/jgarzik/libata-dev
* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev:
ahci: Add Marvell 6121 SATA support
pata_ali: use atapi_cmd_type() to determine cmd type instead of transfer size
ahci: implement skip_host_reset parameter
ahci: request all PCI BARs
devres: implement pcim_iomap_regions_request_all()
libata-acpi: improve dock event handling
Linus Torvalds [Mon, 17 Mar 2008 16:52:19 +0000 (09:52 -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:
virtio: fix race in enable_cb
virtio: Enable netpoll interface for netconsole logging
virtio: handle > 2 billion page balloon targets
virtio: Fix sysfs bits to have proper block symlink
virtio: Use spin_lock_irqsave/restore for virtio-pci
Al Viro [Sun, 16 Mar 2008 22:48:08 +0000 (22:48 +0000)]
hfs_bnode_find() can fail, resulting in hfs_bnode_split() breakage
oops and fs corruption; the latter can happen even on valid fs in case of oom.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Jose Alberto Reguero [Thu, 13 Mar 2008 22:22:24 +0000 (23:22 +0100)]
ahci: Add Marvell 6121 SATA support
Signed-off-by: Jose Alberto Reguero <jareguero@telefonica.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Tejun Heo [Tue, 11 Mar 2008 02:35:00 +0000 (11:35 +0900)]
pata_ali: use atapi_cmd_type() to determine cmd type instead of transfer size
pata_ali was using qc->nbytes to determine whether a command is
data transfer type or not. As now qc->nbytes can be extended by
padding and draining buffers, these tests are not useful anymore.
Use atapi_cmd_type() instead.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Tejun Heo [Mon, 10 Mar 2008 01:25:25 +0000 (10:25 +0900)]
ahci: implement skip_host_reset parameter
Under certain circumstances (SSP turned off by the BIOS) and for
debugging purposes, skipping global controller reset is helpful. Add
a kernel parameter for it.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Tejun Heo [Tue, 11 Mar 2008 10:52:31 +0000 (19:52 +0900)]
ahci: request all PCI BARs
ahci is often implemented with accompanying SFF compatible interface
and legacy IDE driver may attach to the legacy IO ports when the
controller is already claimed by ahci and vice-versa. This patch
makes ahci use pcim_iomap_regions_request_all() so that all IO regions
are claimed on attach.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Tejun Heo [Wed, 12 Mar 2008 06:26:34 +0000 (15:26 +0900)]
devres: implement pcim_iomap_regions_request_all()
Some drivers need to reserve all PCI BARs to prevent other drivers
misusing unoccupied BARs. pcim_iomap_regions_request_all() requests
all BARs and iomap specified BARs.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Tejun Heo [Wed, 12 Mar 2008 05:24:43 +0000 (14:24 +0900)]
libata-acpi: improve dock event handling
Improve ACPI hotplug handling such that dock event is handled properly.
* Register handlers for dock events.
* Directly detach device on EJECT_REQUEST instead of signaling hotplug
event. This prevents libata from accessing severed controller
and/or device.
* While at it, use named constants for ACPI events and move uevent
signaling inside host lock.
Original patch and testing by Holger Macht.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Cc: Holger Macht <hmacht@suse.de>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Christian Borntraeger [Fri, 14 Mar 2008 13:17:05 +0000 (14:17 +0100)]
virtio: fix race in enable_cb
There is a race in virtio_net, dealing with disabling/enabling the callback.
I saw the following oops:
kernel BUG at /space/kvm/drivers/virtio/virtio_ring.c:218!
illegal operation: 0001 [#1] SMP
Modules linked in: sunrpc dm_mod
CPU: 2 Not tainted
2.6.25-rc1zlive-host-10623-gd358142-dirty #99
Process swapper (pid: 0, task:
000000000f85a610, ksp:
000000000f873c60)
Krnl PSW :
0404300180000000 00000000002b81a6 (vring_disable_cb+0x16/0x20)
R:0 T:1 IO:0 EX:0 Key:0 M:1 W:0 P:0 AS:0 CC:3 PM:0 EA:3
Krnl GPRS:
0000000000000001 0000000000000001 0000000010005800 0000000000000001
000000000f3a0900 000000000f85a610 0000000000000000 0000000000000000
0000000000000000 000000000f870000 0000000000000000 0000000000001237
000000000f3a0920 000000000010ff74 00000000002846f6 000000000fa0bcd8
Krnl Code:
00000000002b819a:
a7110001 tmll %r1,1
00000000002b819e:
a7840004 brc 8,2b81a6
00000000002b81a2:
a7f40001 brc 15,2b81a4
>
00000000002b81a6:
a51b0001 oill %r1,1
00000000002b81aa:
40102000 sth %r1,0(%r2)
00000000002b81ae: 07fe bcr 15,%r14
00000000002b81b0:
eb7ff0380024 stmg %r7,%r15,56(%r15)
00000000002b81b6:
a7f13e00 tmll %r15,15872
Call Trace:
([<
000000000fa0bcd0>] 0xfa0bcd0)
[<
00000000002b8350>] vring_interrupt+0x5c/0x6c
[<
000000000010ab08>] do_extint+0xb8/0xf0
[<
0000000000110716>] ext_no_vtime+0x16/0x1a
[<
0000000000107e72>] cpu_idle+0x1c2/0x1e0
The problem can be triggered with a high amount of host->guest traffic.
I think its the following race:
poll says netif_rx_complete
poll calls enable_cb
enable_cb opens the interrupt mask
a new packet comes, an interrupt is triggered----\
enable_cb sees that there is more work |
enable_cb disables the interrupt |
. V
. interrupt is delivered
. skb_recv_done does atomic napi test, ok
some waiting disable_cb is called->check fails->bang!
.
poll would do napi check
poll would do disable_cb
The fix is to let enable_cb not disable the interrupt again, but expect the
caller to do the cleanup if it returns false. In that case, the interrupt is
only disabled, if the napi test_set_bit was successful.
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (cleaned up doco)
Amit Shah [Fri, 29 Feb 2008 10:54:50 +0000 (16:24 +0530)]
virtio: Enable netpoll interface for netconsole logging
Add a new poll_controller handler that the netpoll interface needs.
This enables netconsole logging from a kvm guest over the virtio
net interface.
Signed-off-by: Amit Shah <amitshah@gmx.net>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Rusty Russell [Tue, 18 Mar 2008 03:58:15 +0000 (22:58 -0500)]
virtio: handle > 2 billion page balloon targets
If the host asks for a huge target towards_target() can overflow, and
we up oops as we try to release more pages than we have. The simple
fix is to use a 64-bit value.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>