firefly-linux-kernel-4.4.55.git
17 years agoide: au1xxx: fix use of mixed declarations and code
Ralf Baechle [Sat, 17 Mar 2007 20:57:24 +0000 (21:57 +0100)]
ide: au1xxx: fix use of mixed declarations and code

drivers/ide/mips/au1xxx-ide.c:684: warning: ISO C90 forbids mixed declarations and code

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
17 years agocmd64x: fix recovery time calculation (take 3)
Sergei Shtylyov [Sat, 17 Mar 2007 20:57:24 +0000 (21:57 +0100)]
cmd64x: fix recovery time calculation (take 3)

The driver wrongly takes the address setup time into account when calculating
the PIO recovery time -- this leads to slight overclocking of the PIO modes 0
and 1 (so, the prayers failed to help, as usual :-).  Rework the code to be
calculating recovery clock count as a difference between the total cycle count
and the active count (we don't need to calculate the recovery time itself since
it's not specified for the PIO modes 0 to 2, and for modes 3 and 4 this formula
gives enough recovery time anyway in the chip's supported PCI frequency range).

This patch has been inspired by reading the datasheets and looking at what the
libata driver does; it has been compile-tested only (as usual :-) but anyway,
the new code gives the same or longer recovery times than the old one...

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
17 years ago[PATCH] clockevents: Fix suspend/resume to disk hangs
Thomas Gleixner [Fri, 16 Mar 2007 23:25:52 +0000 (00:25 +0100)]
[PATCH] clockevents: Fix suspend/resume to disk hangs

I finally found a dual core box, which survives suspend/resume without
crashing in the middle of nowhere. Sigh, I never figured out from the
code and the bug reports what's going on.

The observed hangs are caused by a stale state transition of the clock
event devices, which keeps the RCU synchronization away from completion,
when the non boot CPU is brought back up.

The suspend/resume in oneshot mode needs the similar care as the
periodic mode during suspend to RAM. My assumption that the state
transitions during the different shutdown/bringups of s2disk would go
through the periodic boot phase and then switch over to highres resp.
nohz mode were simply wrong.

Add the appropriate suspend / resume handling for the non periodic
modes.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Sat, 17 Mar 2007 02:28:52 +0000 (19:28 -0700)]
Merge /pub/scm/linux/kernel/git/davem/net-2.6

* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [IPV6]: ipv6_fl_socklist is inadvertently shared.
  [TCP]: Fix tcp_mem[] initialization.
  [NET]: Copy mac_len in skb_clone() as well
  [IPV4]: Do not disable preemption in trie_leaf_remove().

17 years agoMerge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6
Linus Torvalds [Sat, 17 Mar 2007 02:28:33 +0000 (19:28 -0700)]
Merge /pub/scm/linux/kernel/git/davem/sparc-2.6

* master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [SPARC64]: Get DEBUG_PAGEALLOC working again.

17 years agoMerge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
Linus Torvalds [Sat, 17 Mar 2007 02:28:15 +0000 (19:28 -0700)]
Merge branch 'upstream' of git://ftp.linux-mips.org/upstream-linus

* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
  [MIPS] Kconfig: Move missplaced NR_CPUS default from SMTC to VSMP.
  [MIPS] Lockdep: Fix recursion bug.
  [MIPS] RTLX: Handle copy_*_user return values.
  [MIPS] RTLX: Protect rtlx_{read,write} with mutex.
  [MIPS] RTLX: Harden against compiler reordering and optimization.
  [MIPS] RTLX: Don't use volatile; it's fragile.
  [MIPS] Lasat: Downgrade 64-bit kernel from experimental to broken.
  [MIPS] Compat: Fix build if CONFIG_SYSVIPC is disabled.
  [CHAR] lcd: Fix two warnings.
  [MIPS] FPU ownership management & preemption fixes
  [MIPS] Check FCSR for pending interrupts, alternative version
  [MIPS] IP27, IP35: Fix warnings.

17 years ago[PATCH] fix MTIME_SEC_MAX on 32-bit
Thomas Gleixner [Fri, 16 Mar 2007 22:15:57 +0000 (14:15 -0800)]
[PATCH] fix MTIME_SEC_MAX on 32-bit

The maximum seconds value we can handle on 32bit is LONG_MAX.

Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] i386: fix typo in sync_constant_test_bit()'s name
Jeremy Fitzhardinge [Fri, 16 Mar 2007 21:38:37 +0000 (13:38 -0800)]
[PATCH] i386: fix typo in sync_constant_test_bit()'s name

Fix typo in sync_constant_test_bit()'s name, so sync_bitops.h is consistent
with bitops.h

Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] spi_s3c24xx.c: warning fix
Arnaud Patard (Rtp [Fri, 16 Mar 2007 21:38:36 +0000 (13:38 -0800)]
[PATCH] spi_s3c24xx.c: warning fix

The set_cs field of struct s3c24xx_spi is declared as returning a int but
the value returned but set_cs is never fixed.  Moreover, the default
function for set_cs and the set_cs defintion in the platform data are
returning void.

I'm proposing to change the prototype to void (*set_cs)(...). By doing
this, I'm also fixing 2 build warnings:

  drivers/spi/spi_s3c24xx.c: In function 's3c24xx_spi_probe':
  drivers/spi/spi_s3c24xx.c:330: warning: assignment from incompatible pointer type
  drivers/spi/spi_s3c24xx.c:335: warning: assignment from incompatible pointer type

Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] fix process crash caused by randomisation and 64k pages
James Bottomley [Fri, 16 Mar 2007 21:38:35 +0000 (13:38 -0800)]
[PATCH] fix process crash caused by randomisation and 64k pages

This bug was seen on ppc64, but it could have occurred on any
architecture with a page size of 64k or above.  The problem is that in
fs/binfmt_elf.c:randomize_stack_top() randomizes the stack to within
0x7ff pages.  On 4k page machines, this is 8MB; on 64k page boxes, this
is 128MB.

The problem is that the new binary layout (selected in
arch_pick_mmap_layout) places the mapping segment 128MB or the stack
rlimit away from the top of the process memory, whichever is larger.  If
you chose an rlimit of less than 128MB (most defaults are in the 8Mb
range) then you can end up having your entire stack randomized away.

The fix is to make randomize_stack_top() only steal at most 8MB, which this
patch does.  However, I have to point out that even with this, your stack
rlimit might not be exactly what you get if it's > 128MB, because you're
still losing the random offset of up to 8MB.

The true fix should be to leave an explicit gap for the randomization plus
a buffer when determining mmap_base, but that would involve fixing all the
architectures.

Cc: Arjan van de Ven <arjan@infradead.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] initialise pi_lock if CONFIG_RT_MUTEXES=N
Zilvinas Valinskas [Fri, 16 Mar 2007 21:38:34 +0000 (13:38 -0800)]
[PATCH] initialise pi_lock if CONFIG_RT_MUTEXES=N

Fixes a bogus lockdep warning which causes lockdep to disable itself.

Acked-by: Ingo Molnar <mingo@elte.hu>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] oom fix: prevent oom from killing a process with children/sibling unkillable
Ankita Garg [Fri, 16 Mar 2007 21:38:33 +0000 (13:38 -0800)]
[PATCH] oom fix: prevent oom from killing a process with children/sibling unkillable

Looking at oom_kill.c, found that the intention to not kill the selected
process if any of its children/siblings has OOM_DISABLE set, is not being
met.

Signed-off-by: Ankita Garg <ankita@in.ibm.com>
Acked-by: Nick Piggin <npiggin@suse.de>
Acked-by: William Irwin <wli@holomorphy.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] change misleading EFI partition support description
Johannes Berg [Fri, 16 Mar 2007 21:38:32 +0000 (13:38 -0800)]
[PATCH] change misleading EFI partition support description

Remove the misleading "Presently only useful on the IA-64 platform" text
from the EFI partition Kconfig.

EFI partitions are also used by Apple on their Intel-based machines and
thus you need EFI partition support if you (for example) want to attach
such a machine in target disk mode.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Acked-by: Matt Domsch <Matt_Domsch@dell.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] futex: PI state locking fix
Ingo Molnar [Fri, 16 Mar 2007 21:38:31 +0000 (13:38 -0800)]
[PATCH] futex: PI state locking fix

Testing of -rt by IBM uncovered a locking bug in wake_futex_pi(): the PI
state needs to be locked before we access it.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Chuck Ebbert <cebbert@redhat.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] tpm_infineon: maintainer
Marcel Selhorst [Fri, 16 Mar 2007 21:38:31 +0000 (13:38 -0800)]
[PATCH] tpm_infineon: maintainer

Signed-off-by: Marcel Selhorst <tpm@selhorst.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] Initialise SAK member for each virtual console to prevent oops
Bernhard Walle [Fri, 16 Mar 2007 21:38:30 +0000 (13:38 -0800)]
[PATCH] Initialise SAK member for each virtual console to prevent oops

Initialise the SAK member of the vc_cons variable on all virtual terminals,
not only the first one.  This prevents an oops when trying Sysrq-C on e.g.
the second virtual terminal:

  kernel BUG at kernel/workqueue.c:212!
  invalid opcode: 0000 [1] SMP
  CPU 0
  Modules linked in: i915 drm deflate zlib_deflate twofish twofish_common serpent blowfish des ce
  Pid: 0, comm: swapper Not tainted 2.6.21-rc3-default #15
  RIP: 0010:[<ffffffff8028c955>]  [<ffffffff8028c955>] queue_work+0x32/0x51
  RSP: 0018:ffffffff805fada8  EFLAGS: 00010013
  RAX: ffffffff80683f38 RBX: ffffffff804ae700 RCX: 0000000000000000
  RDX: 0000000000000000 RSI: ffffffff80683f30 RDI: ffff81000134a840
  RBP: 0000000000000001 R08: 0000000000000005 R09: 0000000000000002
  R10: ffffffff805990e0 R11: ffff810037f4c0f0 R12: 000000000000006b
  R13: ffff81007aa23000 R14: 0000000000000001 R15: 0000000000000096
  FS:  0000000000000000(0000) GS:ffffffff804d8000(0000) knlGS:0000000000000000
  CS:  0010 DS: 0018 ES: 0018 CR0: 000000008005003b
  CR2: 00002b72026e9000 CR3: 0000000079175000 CR4: 00000000000006e0
  Process swapper (pid: 0, threadinfo ffffffff8059e000, task ffffffff80490840)
  Stack:  0000000000000096 ffffffff803635db ffffffff805fadf8 0000000000000001
   ffff8100013c2e40 0000000000000025 ffff81007c931c00 ffff81007aa23000
   0000000000000001 ffffffff8035e3ee 0000000000000092 ffff810037cc8000
  Call Trace:
   <IRQ>  [<ffffffff803635db>] __handle_sysrq+0x98/0x129
   [<ffffffff8035e3ee>] kbd_event+0x32e/0x56a
   [<ffffffff8037d502>] input_event+0x422/0x44a
   [<ffffffff80381d71>] atkbd_interrupt+0x449/0x503
   [<ffffffff8037a42d>] serio_interrupt+0x37/0x6f
   [<ffffffff8037affb>] i8042_interrupt+0x1f4/0x20a
   [<ffffffff8026bd20>] smp_send_timer_broadcast_ipi+0x2d/0x4e
   [<ffffffff8020eee5>] handle_IRQ_event+0x25/0x53
   [<ffffffff802a924c>] handle_edge_irq+0xe4/0x128
   [<ffffffff802562ac>] call_softirq+0x1c/0x28
   [<ffffffff802632eb>] do_IRQ+0x6c/0xd3
   [<ffffffff8024f4e7>] mwait_idle+0x0/0x45
   [<ffffffff80255631>] ret_from_intr+0x0/0xa
   <EOI>  [<ffffffff80248a4d>] datagram_poll+0x0/0xc8
   [<ffffffff8024f529>] mwait_idle+0x42/0x45
   [<ffffffff80242c05>] cpu_idle+0x8b/0xae
   [<ffffffff805a8779>] start_kernel+0x2b9/0x2c5
   [<ffffffff805a815e>] _sinittext+0x15e/0x162

  Code: 0f 0b eb fe 48 8b 07 48 63 d2 48 f7 d0 48 8b 3c d0 e8 13 ff
  RIP  [<ffffffff8028c955>] queue_work+0x32/0x51
   RSP <ffffffff805fada8>
  Kernel panic - not syncing: Aiee, killing interrupt handler!

Signed-off-by: Bernhard Walle <bwalle@suse.de>
Acked-by: Eric Biederman <ebiederm@xmission.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] hwmon: Build fix for SENSORS_W83793
Stefano Brivio [Fri, 16 Mar 2007 21:38:29 +0000 (13:38 -0800)]
[PATCH] hwmon: Build fix for SENSORS_W83793

We need vid_which_vrm and vid_from_reg in the w83793 module.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] nfs: nfs_getattr() can't call nfs_sync_mapping_range() for non-regular files
Trond Myklebust [Fri, 16 Mar 2007 21:38:28 +0000 (13:38 -0800)]
[PATCH] nfs: nfs_getattr() can't call nfs_sync_mapping_range() for non-regular files

Looks like we need a check in nfs_getattr() for a regular file. It makes
no sense to call nfs_sync_mapping_range() on anything else. I think that
should fix your problem: it will stop the NFS client from interfering
with dirty pages on that inode's mapping.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Acked-by: Olof Johansson <olof@lixom.net>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] nfs: fix congestion control
Peter Zijlstra [Fri, 16 Mar 2007 21:38:26 +0000 (13:38 -0800)]
[PATCH] nfs: fix congestion control

The current NFS client congestion logic is severly broken, it marks the
backing device congested during each nfs_writepages() call but doesn't
mirror this in nfs_writepage() which makes for deadlocks.  Also it
implements its own waitqueue.

Replace this by a more regular congestion implementation that puts a cap on
the number of active writeback pages and uses the bdi congestion waitqueue.

Also always use an interruptible wait since it makes sense to be able to
SIGKILL the process even for mounts without 'intr'.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Acked-by: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: Christoph Lameter <clameter@engr.sgi.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] fix rescan_partitions to return errors properly
suzuki [Fri, 16 Mar 2007 21:38:25 +0000 (13:38 -0800)]
[PATCH] fix rescan_partitions to return errors properly

The only error code which comes from the partition checkers is -1, when
they finds an EIO.  As per the discussion, ENOMEM values were ignored,
as they might scare the users.

So, with the current code, we end up returning -1 and not EIO for the
ioctl() calls.  Which doesn't give any clue to the user of what went
wrong.

Signed-off-by: Suzuki K P <suzuki@in.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] swsusp: fix suspend when console is in VT_AUTO+KD_GRAPHICS mode
Andrew Johnson [Fri, 16 Mar 2007 21:38:24 +0000 (13:38 -0800)]
[PATCH] swsusp: fix suspend when console is in VT_AUTO+KD_GRAPHICS mode

When the console is in VT_AUTO+KD_GRAPHICS mode, switching to the
SUSPEND_CONSOLE fails, resulting in vt_waitactive() waiting indefinitely or
until the task is interrupted.  This patch tests if a console switch can
occur in set_console() and returns early if a console switch is not
possible.

[akpm@linux-foundation.org: cleanup]
Signed-off-by: Andrew Johnson <ajohnson@intrinsyc.com>
Acked-by: Pavel Machek <pavel@ucw.cz>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
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>
17 years ago[PATCH] smbfs: double free memory corruption
Vasily Averin [Fri, 16 Mar 2007 21:38:24 +0000 (13:38 -0800)]
[PATCH] smbfs: double free memory corruption

smbfs allocates rq_trans2buffer to handle server's multi transaction2 response
messages.  As struct smb_request may be reused, rq_trans2buffer is freed
before each new request.  However if last servers's response is not multi but
single trans2 message then new rq_trans2buffer is not allocated but last
smb_rput still tries to free it again.

To prevent this issue rq_trans2buffer pointer should be set to NULL after
kfree.

Signed-off-by: Vasily Averin <vvs@sw.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] bool fbdevs must depend on FB = y
Geert Uytterhoeven [Fri, 16 Mar 2007 21:38:23 +0000 (13:38 -0800)]
[PATCH] bool fbdevs must depend on FB = y

Frame buffer device drivers that cannot be built as modules must depend on
`FB = y'.  Correct the 3 remaining offenders.

Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
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>
17 years ago[PATCH] eCryptfs: fix possible NULL ptr deref in ecryptfs_d_release()
Michael Halcrow [Fri, 16 Mar 2007 21:38:22 +0000 (13:38 -0800)]
[PATCH] eCryptfs: fix possible NULL ptr deref in ecryptfs_d_release()

ecryptfs_d_release() first dereferences a pointer (via
ecryptfs_dentry_to_lower()) and then afterwards checks to see if the
pointer it just dereferenced is NULL (via ecryptfs_dentry_to_private()).

This patch moves all of the work done on the dereferenced pointer inside a
block governed by the condition that the pointer is non-NULL.

Signed-off-by: Michael Halcrow <mhalcrow@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] hrtimer: fix up unlocked access to wall_to_monotonic
Thomas Gleixner [Fri, 16 Mar 2007 21:38:21 +0000 (13:38 -0800)]
[PATCH] hrtimer: fix up unlocked access to wall_to_monotonic

commit f4304ab21513b834c8fe3403927c60c2b81a72d7 (HZ free NTP) moved the
access to wall_to_monotonic in hrtimer_get_softirq_time() out of the
xtime_lock protection.

Move it back into the seq_lock section.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: John Stultz <johnstul@us.ibm.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] SPI: at25: do not use pointer before assignment
Atsushi Nemoto [Fri, 16 Mar 2007 21:38:20 +0000 (13:38 -0800)]
[PATCH] SPI: at25: do not use pointer before assignment

Prevents a potential oops with CONFIG_SPI_DEBUG given flakey hardware or
incorrect configuration.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] hrtimer: prevent overrun DoS in hrtimer_forward()
Thomas Gleixner [Fri, 16 Mar 2007 21:38:20 +0000 (13:38 -0800)]
[PATCH] hrtimer: prevent overrun DoS in hrtimer_forward()

hrtimer_forward() does not check for the possible overflow of
timer->expires.  This can happen on 64 bit machines with large interval
values and results currently in an endless loop in the softirq because the
expiry value becomes negative and therefor the timer is expired all the
time.

Check for this condition and set the expiry value to the max.  expiry time
in the future.  The fix should be applied to stable kernel series as well.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Ingo Molnar <mingo@elte.hu>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] savagefb: Fix compile error if debugging is enabled
Antonino A. Daplas [Fri, 16 Mar 2007 21:38:18 +0000 (13:38 -0800)]
[PATCH] savagefb: Fix compile error if debugging is enabled

SavagePrintRegs() requires struct savagefb_par.

Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] savagefb: Fix black screen on load in Savage IX
Antonino A. Daplas [Fri, 16 Mar 2007 21:38:18 +0000 (13:38 -0800)]
[PATCH] savagefb: Fix black screen on load in Savage IX

This is a hack that seems to kick start the 2D engine of the Savage IX in some
Toshiba laptops.  Without this, the laptop starts with a black screen and
occasionally crashes X.

Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] sstfb: fix pixclock setting on Voodoo 1/2 cards
Ondrej Zajicek [Fri, 16 Mar 2007 21:38:16 +0000 (13:38 -0800)]
[PATCH] sstfb: fix pixclock setting on Voodoo 1/2 cards

Pixclock setting in sstfb didn't work with my Voodoo 2 card with ICS 5342 DAC
(this DAC requires two consecutive writes to one of its registers to program
pixclock - maybe first write merged with second).

Signed-off-by: Ondrej Zajicek <santiago@crfreenet.org>
Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] gpio_direction_output() needs an initial value
David Brownell [Fri, 16 Mar 2007 21:38:14 +0000 (13:38 -0800)]
[PATCH] gpio_direction_output() needs an initial value

It's been pointed out that output GPIOs should have an initial value, to
avoid signal glitching ...  among other things, it can be some time before
a driver is ready.  This patch corrects that oversight, fixing

 - documentation
 - platforms supporting the GPIO interface
 - users of that call (just one for now, others are pending)

There's only one user of this call for now since most platforms are still
using non-generic GPIO setup code, which in most cases already couples the
initial value with its "set output mode" request.

Note that most platforms are clear about the hardware letting the output
value be set before the pin direction is changed, but the s3c241x docs are
vague on that topic ...  so those chips might not avoid the glitches.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Acked-by: Andrew Victor <andrew@sanpeople.com>
Acked-by: Milan Svoboda <msvoboda@ra.rockwell.com>
Acked-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] spi: destroy workqueue after spi_unregister_master
Chris Lesiak [Fri, 16 Mar 2007 21:38:13 +0000 (13:38 -0800)]
[PATCH] spi: destroy workqueue after spi_unregister_master

Fix a bug in the cleanup of an spi_bitbang bus.

The workqueue associated with the bus was destroyed before the call to
spi_unregister_master.  That meant that spi devices on that bus would be
unable to do IO in their remove method.  The shutdown flag should have been
able to prevent a segfault, but was never getting set.  By waiting to
destroy the workqueue until after the master is unregistered, devices are
able to do IO in their remove methods.  An added benefit is that neither
the shutdown flag nor a wait for the queue of messages to empty is needed.

Signed-off-by: Chris Lesiak <chris.lesiak@licor.com>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] dio: invalidate clean pages before dio write
Zach Brown [Fri, 16 Mar 2007 21:38:11 +0000 (13:38 -0800)]
[PATCH] dio: invalidate clean pages before dio write

This patch fixes a user-triggerable oops that was reported by Leonid
Ananiev as archived at http://lkml.org/lkml/2007/2/8/337.

dio writes invalidate clean pages that intersect the written region so that
subsequent buffered reads go to disk to read the new data.  If this fails
the interface tries to tell the caller that the cache is inconsistent by
returning EIO.

Before this patch we had the problem where this invalidation failure would
clobber -EIOCBQUEUED as it made its way from fs/direct-io.c to fs/aio.c.
Both fs/aio.c and bio completion call aio_complete() and we reference freed
memory, usually oopsing.

This patch addresses this problem by invalidating before the write so that
we can cleanly return -EIO before ->direct_IO() has had a chance to return
-EIOCBQUEUED.

There is a compromise here.  During the dio write we can fault in mmap()ed
pages which intersect the written range with get_user_pages() if the user
provided them for the source buffer.  This is a crazy thing to do, but we
can make it mostly work in most cases by trying the invalidation again.
The compromise is that we won't return an error if this second invalidation
fails if it's an AIO write and we have -EIOCBQUEUED.

This was tested by having two processes race performing large O_DIRECT and
buffered ordered writes.  Within minutes ext3 would see a race between
ext3_releasepage() and jbd holding a reference on ordered data buffers and
would cause invalidation to fail, panicing the box.  The test can be found
in the 'aio_dio_bugs' test group in test.kernel.org/autotest.  After this
patch the test passes.

Signed-off-by: Zach Brown <zach.brown@oracle.com>
Signed-off-by: Benjamin LaHaise <bcrl@kvack.org>
Cc: Leonid Ananiev <leonid.i.ananiev@linux.intel.com>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] mm: fix madvise infinine loop
Nick Piggin [Fri, 16 Mar 2007 21:38:10 +0000 (13:38 -0800)]
[PATCH] mm: fix madvise infinine loop

madvise(MADV_REMOVE) can go into an infinite loop or cause an oops if the
call covers a region from the start of a vma, and extending past that vma.

Signed-off-by: Nick Piggin <npiggin@suse.de>
Cc: Badari Pulavarty <pbadari@us.ibm.com>
Acked-by: Hugh Dickins <hugh@veritas.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] ufs2: tindirect truncate fix
Evgeniy Dushistov [Fri, 16 Mar 2007 21:38:09 +0000 (13:38 -0800)]
[PATCH] ufs2: tindirect truncate fix

During modification of code to support UFS2 writing, the case with
"three indirect" blocks in truncate path was missed, this patch fixes
this situation.

Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru>
Acked-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] ufs: zeroize the rest of block in truncate
Evgeniy Dushistov [Fri, 16 Mar 2007 21:38:09 +0000 (13:38 -0800)]
[PATCH] ufs: zeroize the rest of block in truncate

This patch fix behaviour in such test scenario:

  lseek(fd, BIG_OFFSET)
  write(fd, buf, sizeof(buf))
  truncate(BIG_OFFSET)
  truncate(BIG_OFFSET + sizeof(buf))
  read(fd, buf...)

Because of if file big enough(BIG_OFFSET) we start allocate space by block,
ordinary block size > page size, so we should zeroize the rest of block in
truncate(except last framgnet, about which VFS should care), to not get
garbage, when we extend file.

Also patch corrects conversion from pointer to block to physical block number,
this helps in case of not common used UFS types.

And add to debug output inode number.

Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] ufs: prepare write + change blocks on the fly
Evgeniy Dushistov [Fri, 16 Mar 2007 21:38:08 +0000 (13:38 -0800)]
[PATCH] ufs: prepare write + change blocks on the fly

This fixes "change blocks numbers on the fly" in case when "prepare
write page" is in the call chain, in this case some buffers may be not
uptodate and not mapped, we should care to map them and load from disk.

This patch was tested with:
 - ufs regressions simple tests
 - fsx-linux
 - ltp(20060306)
 - untar and build kernel

Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] ufs2: more correct work with time
Evgeniy Dushistov [Fri, 16 Mar 2007 21:38:07 +0000 (13:38 -0800)]
[PATCH] ufs2: more correct work with time

This patch corrects work with time in UFS2 case.

1) According to UFS2 disk layout modification/access and so on "time"
   should be hold in two variables one 64bit for seconds and another 32bit for
   nanoseconds,

   at now for some unknown reason we suppose that "inode time" holds in
   three variables 32bit for seconds, 32bit for milliseconds and 32bit for
   nanoseconds.

2) We set amount of nanoseconds in "VFS inode" to 0 during read, instead of
   getting values from "on disk inode"(this should close
   http://bugzilla.kernel.org/show_bug.cgi?id=7991).

Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru>
Cc: Bjoern Jacke <bjoern@j3e.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] swsusp: disable nonboot CPUs before entering platform suspend
Rafael J. Wysocki [Fri, 16 Mar 2007 21:38:06 +0000 (13:38 -0800)]
[PATCH] swsusp: disable nonboot CPUs before entering platform suspend

Prevent the WARN_ON() in arch/x86_64/kernel/acpi/sleep.c:init_low_mapping()
from triggering by disabling nonboot CPUs before we finally enter the
platform suspend.

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] swsusp: Fix resume error path in platform mode
Rafael J. Wysocki [Fri, 16 Mar 2007 21:38:06 +0000 (13:38 -0800)]
[PATCH] swsusp: Fix resume error path in platform mode

If swsusp is using the platform mode during the resume and the image cannot
be read, the platform mode should be switched off before software_resume()
returns.  Make it happen.

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] rm pointless dmaengine exports
David Brownell [Fri, 16 Mar 2007 21:38:05 +0000 (13:38 -0800)]
[PATCH] rm pointless dmaengine exports

This removes several pointless exports from drivers/dma/dmaengine.c; the
dma_async_memcpy_*() functions are inlined by <linux/dmaengine.h> so those
exports are inappropriate.

It also moves the existing EXPORT_SYMBOL declarations next to their functions,
so it's now trivial to confirm one-to-one correspondence between exports and
nonstatic symbols.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Acked-by: Chris Leech <christopher.leech@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] fix read past end of array in md/linear.c
Andy Isaacson [Fri, 16 Mar 2007 21:38:04 +0000 (13:38 -0800)]
[PATCH] fix read past end of array in md/linear.c

When iterating through an array, one must be careful to test one's index
variable rather than another similarly-named variable.

The loop will read off the end of conf->disks[] in the following
(pathological) case:

  % dd bs=1 seek=840716287 if=/dev/zero of=d1 count=1
  % for i in 2 3 4; do dd if=/dev/zero of=d$i bs=1k count=$(($i+150)); done
  % ./vmlinux ubd0=root ubd1=d1 ubd2=d2 ubd3=d3 ubd4=d4
  # mdadm -C /dev/md0 --level=linear --raid-devices=4 /dev/ubd[1234]

adding some printks, I saw this:

  [42949374.960000] hash_spacing = 821120
  [42949374.960000] cnt          = 4
  [42949374.960000] min_spacing  = 801
  [42949374.960000] j=0 size=820928 sz=820928
  [42949374.960000] i=0 sz=820928 hash_spacing=820928
  [42949374.960000] j=1 size=64 sz=64
  [42949374.960000] j=2 size=64 sz=128
  [42949374.960000] j=3 size=64 sz=192
  [42949374.960000] j=4 size=1515870810 sz=1515871002

Cc: Gautham R Shenoy <ego@in.ibm.com>
Acked-by: Neil Brown <neilb@cse.unsw.edu.au>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] reduce pnp syslog spam
David Brownell [Fri, 16 Mar 2007 21:38:02 +0000 (13:38 -0800)]
[PATCH] reduce pnp syslog spam

Make some normal code paths in PNP stop issuing syslog spam.  Since PNP
issues calls regardless of device capablities, it's no surprise when some
of those devices don't support those calls!

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Adam Belay <ambx1@neo.rr.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[MIPS] Kconfig: Move missplaced NR_CPUS default from SMTC to VSMP.
Ralf Baechle [Fri, 16 Mar 2007 21:58:37 +0000 (21:58 +0000)]
[MIPS] Kconfig: Move missplaced NR_CPUS default from SMTC to VSMP.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] Lockdep: Fix recursion bug.
Ralf Baechle [Fri, 16 Mar 2007 16:10:36 +0000 (16:10 +0000)]
[MIPS] Lockdep: Fix recursion bug.

 trace_hardirqs_off -> atomic_inc -> local_irq_restore -> trace_hardirqs_off

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] RTLX: Handle copy_*_user return values.
Ralf Baechle [Fri, 16 Mar 2007 12:16:27 +0000 (12:16 +0000)]
[MIPS] RTLX: Handle copy_*_user return values.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] RTLX: Protect rtlx_{read,write} with mutex.
Ralf Baechle [Thu, 15 Mar 2007 17:13:47 +0000 (17:13 +0000)]
[MIPS] RTLX: Protect rtlx_{read,write} with mutex.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] RTLX: Harden against compiler reordering and optimization.
Ralf Baechle [Thu, 15 Mar 2007 17:10:16 +0000 (17:10 +0000)]
[MIPS] RTLX: Harden against compiler reordering and optimization.

RTLX communication is based on lock-free shared memory buffers.  It
happened to be working by luck so far but relies on the optimizer doing
certain optimizations but no reordering.

Fixed by inserting proper barriers in rtlx_read and rtlx_write, and careful
pointer dereferencing.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] RTLX: Don't use volatile; it's fragile.
Ralf Baechle [Thu, 15 Mar 2007 17:08:28 +0000 (17:08 +0000)]
[MIPS] RTLX: Don't use volatile; it's fragile.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] Lasat: Downgrade 64-bit kernel from experimental to broken.
Ralf Baechle [Tue, 13 Mar 2007 08:59:54 +0000 (08:59 +0000)]
[MIPS] Lasat: Downgrade 64-bit kernel from experimental to broken.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] Compat: Fix build if CONFIG_SYSVIPC is disabled.
Ralf Baechle [Sat, 10 Mar 2007 18:22:25 +0000 (18:22 +0000)]
[MIPS] Compat: Fix build if CONFIG_SYSVIPC is disabled.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[CHAR] lcd: Fix two warnings.
Ralf Baechle [Sat, 10 Mar 2007 04:56:33 +0000 (04:56 +0000)]
[CHAR] lcd: Fix two warnings.

In file included from drivers/char/lcd.c:23:
include/linux/mc146818rtc.h:104:1: warning: "RTC_IO_EXTENT" redefined
drivers/char/lcd.c:15:1: warning: this is the location of the previous definition
drivers/char/lcd.c:35: warning: 'lcd_lock' defined but not used

c316eb1eee2c803c33b1f826fe744c922d2e354f deleted the last code using
lcd_lock, so delete definition of lcd_lock.

The definition of RTC_IO_EXTENT is unused and probably always was only
debree copied from drivers/char/rtc.c.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] FPU ownership management & preemption fixes
Atsushi Nemoto [Fri, 9 Mar 2007 16:07:45 +0000 (01:07 +0900)]
[MIPS] FPU ownership management & preemption fixes

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] Check FCSR for pending interrupts, alternative version
Atsushi Nemoto [Fri, 9 Mar 2007 16:03:48 +0000 (01:03 +0900)]
[MIPS] Check FCSR for pending interrupts, alternative version

Commit 6d6671066a311703bca1b91645bb1e04cc983387 is incomplete and misses
non-r4k CPUs.  This patch reverts the commit and fixes in other way.

 o Do FCSR checking in caller of restore_fp_context.
 o Send SIGFPE if the signal handler set any FPU exception bits.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[MIPS] IP27, IP35: Fix warnings.
Ralf Baechle [Sat, 10 Mar 2007 03:26:56 +0000 (03:26 +0000)]
[MIPS] IP27, IP35: Fix warnings.

include/asm-mips/mach-ip27/dma-coherence.h:22: warning: 'plat_map_dma_mem' defined but not used
include/asm-mips/mach-ip27/dma-coherence.h:41: warning: 'plat_unmap_dma_mem' defined but not used
include/asm-mips/mach-ip32/dma-coherence.h:30: warning: 'plat_map_dma_mem' defined but not used
include/asm-mips/mach-ip32/dma-coherence.h:63: warning: 'plat_unmap_dma_mem' defined but not used

These functions are meant to be inlined anyway.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
17 years ago[SPARC64]: Get DEBUG_PAGEALLOC working again.
David S. Miller [Sat, 17 Mar 2007 00:20:28 +0000 (17:20 -0700)]
[SPARC64]: Get DEBUG_PAGEALLOC working again.

We have to make sure to use base-pagesize TLB entries even during the
early transition period where we need TLB miss handling but don't have
the kernel page tables setup yet for the linear region.

Also, it is necessary therefore to not use the 4MB TSB for these
translations, and instead use the normal kernel TSB.  This allows us
to also get rid of the 4MB tsb for debug builds which shrinks the
kernel a little bit.

Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[IPV6]: ipv6_fl_socklist is inadvertently shared.
Masayuki Nakagawa [Fri, 16 Mar 2007 23:14:03 +0000 (16:14 -0700)]
[IPV6]: ipv6_fl_socklist is inadvertently shared.

The ipv6_fl_socklist from listening socket is inadvertently shared
with new socket created for connection.  This leads to a variety of
interesting, but fatal, bugs. For example, removing one of the
sockets may lead to the other socket's encountering a page fault
when the now freed list is referenced.

The fix is to not share the flow label list with the new socket.

Signed-off-by: Masayuki Nakagawa <nakagawa.msy@ncos.nec.co.jp>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[TCP]: Fix tcp_mem[] initialization.
John Heffner [Fri, 16 Mar 2007 22:04:03 +0000 (15:04 -0700)]
[TCP]: Fix tcp_mem[] initialization.

Change tcp_mem initialization function.  The fraction of total memory
is now a continuous function of memory size, and independent of page
size.

Signed-off-by: John Heffner <jheffner@psc.edu>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[NET]: Copy mac_len in skb_clone() as well
Alexey Dobriyan [Fri, 16 Mar 2007 22:00:46 +0000 (15:00 -0700)]
[NET]: Copy mac_len in skb_clone() as well

ANK says: "It is rarely used, that's wy it was not noticed.
But in the places, where it is used, it should be disaster."

Signed-off-by: Alexey Dobriyan <adobriyan@sw.ru>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years ago[IPV4]: Do not disable preemption in trie_leaf_remove().
Robert Olsson [Fri, 16 Mar 2007 22:00:07 +0000 (15:00 -0700)]
[IPV4]: Do not disable preemption in trie_leaf_remove().

Hello, Just discussed this Patrick...

We have two users of trie_leaf_remove, fn_trie_flush and fn_trie_delete
both are holding RTNL. So there shouldn't be need for this preempt stuff.
This is assumed to a leftover from an older RCU-take.

> Mhh .. I think I just remembered something - me incorrectly suggesting
> to add it there while we were talking about this at OLS :) IIRC the
> idea was to make sure tnode_free (which at that time didn't use
> call_rcu) wouldn't free memory while still in use in a rcu read-side
> critical section. It should have been synchronize_rcu of course,
> but with tnode_free using call_rcu it seems to be completely
> unnecessary. So I guess we can simply remove it.

Signed-off-by: Robert Olsson <robert.olsson@its.uu.se>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
17 years agoLinux 2.6.21-rc4
Linus Torvalds [Fri, 16 Mar 2007 00:20:01 +0000 (17:20 -0700)]
Linux 2.6.21-rc4

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik...
Linus Torvalds [Thu, 15 Mar 2007 22:31:37 +0000 (15:31 -0700)]
Merge branch 'upstream-linus' of /linux/kernel/git/jgarzik/netdev-2.6

* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
  natsemi: Avoid IntrStatus lossage if RX state machine resets.
  natsemi: Fix NAPI for interrupt sharing
  natsemi: Consistently use interrupt enable/disable functions
  NetXen: Fix softlockup seen during hardware access
  NetXen: Bug fix for Jumbo frames on XG card
  skge: set mac address bonding fix

17 years ago[PATCH] sysfs: reinstate exclusion between method calls and attribute unregistration
Alan Stern [Thu, 15 Mar 2007 19:51:28 +0000 (15:51 -0400)]
[PATCH] sysfs: reinstate exclusion between method calls and attribute unregistration

This patch (as869) reinstates the mutual exclusion between sysfs
attribute method calls and attribute unregistration.  The
previously-reported deadlocks have been fixed, and this exclusion is
by far the simplest way to avoid races during driver unbinding.

The check for orphaned read-buffers has been moved down slightly, so
that the remainder of a partially-read buffer will still be available
to userspace even after the attribute has been unregistered.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Cc: Hugh Dickins <hugh@veritas.com>
Cc: Cornelia Huck <cornelia.huck@de.ibm.com>
Cc: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] sysfs and driver core: add callback helper, used by SCSI and S390
Alan Stern [Thu, 15 Mar 2007 19:50:34 +0000 (15:50 -0400)]
[PATCH] sysfs and driver core: add callback helper, used by SCSI and S390

This patch (as868) adds a helper routine for device drivers that need
to set up a callback to perform some action in a different process's
context.  This is intended for use by attribute methods that want to
unregister themselves or their parent device.  Attribute method calls
are mutually exclusive with unregistration, so such actions cannot be
taken directly.

Two attribute methods are converted to use the new helper routine: one
for SCSI device deletion and one for System/390 ccwgroup devices.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Cc: Hugh Dickins <hugh@veritas.com>
Cc: Cornelia Huck <cornelia.huck@de.ibm.com>
Cc: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jikos/hid
Linus Torvalds [Thu, 15 Mar 2007 17:50:54 +0000 (10:50 -0700)]
Merge branch 'for-linus' of /linux/kernel/git/jikos/hid

* 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jikos/hid:
  HID: zeroing of bytes in output fields is bogus
  HID: allocate hid_parser in a proper way

17 years agonatsemi: Avoid IntrStatus lossage if RX state machine resets.
broonie@sirena.org.uk [Wed, 14 Mar 2007 19:49:15 +0000 (19:49 +0000)]
natsemi: Avoid IntrStatus lossage if RX state machine resets.

This patch fixes the poll routine for the natsemi driver so that if the
driver detects an RX state machine lockup then no interrupts will be
lost while the driver recovers from that.

Signed-Off-By: Mark Brown <broonie@sirena.org.uk>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agonatsemi: Fix NAPI for interrupt sharing
broonie@sirena.org.uk [Wed, 14 Mar 2007 19:49:14 +0000 (19:49 +0000)]
natsemi: Fix NAPI for interrupt sharing

The interrupt status register for the natsemi chips is clear on read and
was read unconditionally from both the interrupt and from the NAPI poll
routine, meaning that if the interrupt service routine was called (for
example, due to a shared interrupt) while a NAPI poll was scheduled
interrupts could be missed.  This patch fixes that by ensuring that the
interrupt status register is only read by the interrupt handler when
interrupts are enabled from the chip.

It also reverts a workaround for this problem from the netpoll hook and
improves the trace for interrupt events.

Thanks to Sergei Shtylyov <sshtylyov@ru.mvista.com> for spotting the
issue, Mark Huth <mhuth@mvista.com> for a simpler method and Simon
Blake <simon@citylink.co.nz> for testing resources.

Signed-Off-By: Mark Brown <broonie@sirena.org.uk>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agonatsemi: Consistently use interrupt enable/disable functions
broonie@sirena.org.uk [Wed, 14 Mar 2007 19:49:13 +0000 (19:49 +0000)]
natsemi: Consistently use interrupt enable/disable functions

The natsemi drivers include functions for enabling and disabling
interrupts from the chip but these are not used in all code paths.  This
patch changes the code paths that touch the interrupt enable register to
use the functions.  In all cases this adds an extra PCI read to post the
operation but since none of these are in fast paths this shouldn't be
too much of a problem.

Signed-Off-By: Mark Brown <broonie@sirena.org.uk>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agoNetXen: Fix softlockup seen during hardware access
Linsys Contractor Mithlesh Thukral [Tue, 13 Mar 2007 12:15:06 +0000 (04:15 -0800)]
NetXen: Fix softlockup seen during hardware access

NetXen: This will fix a softlock seen on some machines.
The reason was too much time was spent waiting for hardware access
to go through.

Signed-off by: Mithlesh Thukral <mithlesh@netxen.com>

Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agoNetXen: Bug fix for Jumbo frames on XG card
Linsys Contractor Mithlesh Thukral [Tue, 13 Mar 2007 12:13:13 +0000 (04:13 -0800)]
NetXen: Bug fix for Jumbo frames on XG card

NetXen: Set the MTU for the right port depending upon the port number
for XG cards.

Signed-off by: Mithlesh Thukral <mithlesh@netxen.com>

Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agoskge: set mac address bonding fix
Stephen Hemminger [Mon, 12 Mar 2007 22:16:26 +0000 (15:16 -0700)]
skge: set mac address bonding fix

When bonding does fail over it calls set_mac_address.  When this happens
as the result of another port going down, the phy_mutex that is common to
both ports is held, so it deadlocks. Setting the address doesn't need to do
anything that needs the phy_mutex, it already has the RTNL to protect against
other admin actions.

This change just disables the receiver to avoid any hardware confusion
while address is changing.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
17 years agoDisable NMI watchdog by default properly
Linus Torvalds [Thu, 15 Mar 2007 00:50:48 +0000 (17:50 -0700)]
Disable NMI watchdog by default properly

This reverts commit 6ebf622b2577c50b1f496bd6a5e8739e55ae7b1c and
replaces it with one that actually works.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/mfasheh...
Linus Torvalds [Wed, 14 Mar 2007 22:29:08 +0000 (15:29 -0700)]
Merge branch 'upstream-linus' of /linux/kernel/git/mfasheh/ocfs2

* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/mfasheh/ocfs2:
  ocfs2_dlm: Add missing locks in dlm_empty_lockres
  ocfs2_dlm: Missing get/put lockres in dlm_run_purge_lockres
  configfs: add missing mutex_unlock()
  ocfs2: add some missing address space callbacks
  ocfs2: Concurrent access of o2hb_region->hr_task was not locked
  ocfs2: Proper cleanup in case of error in ocfs2_register_hb_callbacks()

17 years agoMerge master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog
Linus Torvalds [Wed, 14 Mar 2007 22:28:31 +0000 (15:28 -0700)]
Merge /linux/kernel/git/wim/linux-2.6-watchdog

* master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog:
  [WATCHDOG] i8xx TCO driver - mark for removal

17 years ago[PATCH] m68k dma-mapping: gfp_t annotations
Al Viro [Wed, 14 Mar 2007 09:20:40 +0000 (09:20 +0000)]
[PATCH] m68k dma-mapping: gfp_t annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] paride endianness annotations
Al Viro [Wed, 14 Mar 2007 09:20:30 +0000 (09:20 +0000)]
[PATCH] paride endianness annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] kill bogus casts in amd64 uaccess.h
Al Viro [Wed, 14 Mar 2007 09:20:20 +0000 (09:20 +0000)]
[PATCH] kill bogus casts in amd64 uaccess.h

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] atl1 trivial endianness misannotations
Al Viro [Wed, 14 Mar 2007 09:20:10 +0000 (09:20 +0000)]
[PATCH] atl1 trivial endianness misannotations

NB: driver is choke-full of code that will break on big-endian; as long
as the hardware is onboard-only we can live with that, but sooner or
later that'll need fixing.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] ANSIfy powerpc floppy.h
Al Viro [Wed, 14 Mar 2007 09:20:00 +0000 (09:20 +0000)]
[PATCH] ANSIfy powerpc floppy.h

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] hid-core endianness annotations
Al Viro [Wed, 14 Mar 2007 09:19:50 +0000 (09:19 +0000)]
[PATCH] hid-core endianness annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] cifs endianness annotations
Al Viro [Wed, 14 Mar 2007 09:19:40 +0000 (09:19 +0000)]
[PATCH] cifs endianness annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] C99 initializers, proper use of const in drivers/ps3
Al Viro [Wed, 14 Mar 2007 09:19:30 +0000 (09:19 +0000)]
[PATCH] C99 initializers, proper use of const in drivers/ps3

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] qeth gfp_t annotations
Al Viro [Wed, 14 Mar 2007 09:19:20 +0000 (09:19 +0000)]
[PATCH] qeth gfp_t annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] cciss endian annotations
Al Viro [Wed, 14 Mar 2007 09:19:10 +0000 (09:19 +0000)]
[PATCH] cciss endian annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] trivial ATA iomem annotations
Al Viro [Wed, 14 Mar 2007 09:19:00 +0000 (09:19 +0000)]
[PATCH] trivial ATA iomem annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] sparc: nr_free_pages() is unsigned long
Al Viro [Wed, 14 Mar 2007 09:18:50 +0000 (09:18 +0000)]
[PATCH] sparc: nr_free_pages() is unsigned long

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: William Irwin <wli@holomorphy.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] pasemi trivial iomem annotations
Al Viro [Wed, 14 Mar 2007 09:18:40 +0000 (09:18 +0000)]
[PATCH] pasemi trivial iomem annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] constant should be long
Al Viro [Wed, 14 Mar 2007 09:18:30 +0000 (09:18 +0000)]
[PATCH] constant should be long

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] dmfe trivial endianness annotations
Al Viro [Wed, 14 Mar 2007 09:18:20 +0000 (09:18 +0000)]
[PATCH] dmfe trivial endianness annotations

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] fastcall still doesn't make sense in paravirt
Al Viro [Wed, 14 Mar 2007 09:18:09 +0000 (09:18 +0000)]
[PATCH] fastcall still doesn't make sense in paravirt

Andi had removed a bunch of those, but one more had creeped in...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] misc NULL noise
Al Viro [Wed, 14 Mar 2007 09:17:59 +0000 (09:17 +0000)]
[PATCH] misc NULL noise

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] rtc-cmos needs RTC_ALWAYS_BCD known
Al Viro [Wed, 14 Mar 2007 09:16:54 +0000 (09:16 +0000)]
[PATCH] rtc-cmos needs RTC_ALWAYS_BCD known

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] sparc: have dma-mapping.h include generic/dma-mapping-broken in non-PCI case
Al Viro [Wed, 14 Mar 2007 09:16:44 +0000 (09:16 +0000)]
[PATCH] sparc: have dma-mapping.h include generic/dma-mapping-broken in non-PCI case

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] BLK_DEV_IDE_CELLEB dependency fix
Al Viro [Wed, 14 Mar 2007 09:16:34 +0000 (09:16 +0000)]
[PATCH] BLK_DEV_IDE_CELLEB dependency fix

It's bool and it depends on IDE => should depend on IDE=y

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] include of asm/pgtable.h in nfsfh is bogus
Al Viro [Wed, 14 Mar 2007 09:16:24 +0000 (09:16 +0000)]
[PATCH] include of asm/pgtable.h in nfsfh is bogus

not needed and actually breaks build on frv, while we are at it

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] m32r dma-mapping.h should simply include generic/dma-mapping-broken.h
Al Viro [Wed, 14 Mar 2007 09:16:14 +0000 (09:16 +0000)]
[PATCH] m32r dma-mapping.h should simply include generic/dma-mapping-broken.h

... instead of trying to duplicate its bits

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] fix ipath_dma_free_coherent() prototype
Al Viro [Wed, 14 Mar 2007 09:16:04 +0000 (09:16 +0000)]
[PATCH] fix ipath_dma_free_coherent() prototype

method gets u64, not dma_addr_t

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] stacktrace doesn't work on uml
Al Viro [Wed, 14 Mar 2007 09:15:54 +0000 (09:15 +0000)]
[PATCH] stacktrace doesn't work on uml

and no, it's not the case of "let's pull bits from underlying architecture"

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] zatm __init abuse
Al Viro [Wed, 14 Mar 2007 09:05:01 +0000 (09:05 +0000)]
[PATCH] zatm __init abuse

zatm_init() and zatm_start() should be __devinit (the former is
not module init, despite the name - it's a helper for PCI ->probe())

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years ago[PATCH] (uml) sparse flags for userland glue are missing $(CF)
Al Viro [Wed, 14 Mar 2007 09:04:51 +0000 (09:04 +0000)]
[PATCH] (uml) sparse flags for userland glue are missing $(CF)

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>