]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/log
linux-2.6-omap-h63xx.git
15 years agoata: add missing ATA_ID_* defines (take 2)
Bartlomiej Zolnierkiewicz [Mon, 18 Aug 2008 19:40:05 +0000 (21:40 +0200)]
ata: add missing ATA_ID_* defines (take 2)

Add missing ATA_ID_* defines and update {ata,atapi}_*()
inlines accordingly.  The currently unused defines are
needed for the forthcoming drivers/ide/ changes.

v2:
Add ATA_ID_SPG.

Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agosgiioc4: fixup message on resource allocation failure
Bartlomiej Zolnierkiewicz [Mon, 18 Aug 2008 19:40:04 +0000 (21:40 +0200)]
sgiioc4: fixup message on resource allocation failure

There can be more than one sgiioc4 card in the system so print
also PCI device name on resource allocation failure (so we know
which one is the problematic one).

Reported-by: Jeremy Higdon <jeremy@sgi.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agoide-cd: use bcd2bin/bin2bcd
Adrian Bunk [Mon, 18 Aug 2008 19:40:04 +0000 (21:40 +0200)]
ide-cd: use bcd2bin/bin2bcd

Change ide-cd to use the new bcd2bin/bin2bcd functions instead of the
obsolete BCD2BIN/BIN2BCD macros.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Acked-by: Borislav Petkov <petkovbb@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agocdrom: handle TOC
Alexander Inyukhin [Mon, 18 Aug 2008 19:40:04 +0000 (21:40 +0200)]
cdrom: handle TOC

This patch should fix TOC handling for cdroms that can not play audio.  It
extends commit af744e3294d09d706c4eae26cffaaa68a8d40337 ("cdrom: don't
check CDC_PLAY_AUDIO in cdrom_count_tracks()") with a safety check and
non-audio ioctls support.

Since CDC_PLAY_AUDIO flag was used not only to check ability to play audio
but also to ensure that audio_ioctl was not NULL, all TOC-related
operations had to use it.

As far as I understand, now audio_ioctl is never NULL, so a sanity check
during device registration should be sufficient.

It was tested on Optiarc AD7203A device, that has no ability to play
audio.

Cc: Tejun Heo <tj@kernel.org>
Cc: Jens Axboe <jens.axboe@oracle.com>
Cc: Borislav Petkov <petkovbb@googlemail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
[bart: remove now unneeded ->audio_ioctl check (noticed by Borislav)]
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agogdrom: add dummy audio_ioctl handler
Borislav Petkov [Mon, 18 Aug 2008 19:40:04 +0000 (21:40 +0200)]
gdrom: add dummy audio_ioctl handler

Make sure audio_ioctl is always defined even if being a dummy function
since the cdrom_ioctl interface assumes its existence and we don't
want to BUG on null ptr on some ioctls like, e.g. CDROMREADTOCENTRY,
CDROMREADTOCHDR etc. when we fix CDC_PLAY_AUDIO checking in cdrom.c.

Signed-off-by: Borislav Petkov <petkovbb@gmail.com>
Acked-by: Adrian McMenamin <adrian@mcmen.demon.co.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agoviocd: add dummy audio ioctl handler
Borislav Petkov [Mon, 18 Aug 2008 19:40:03 +0000 (21:40 +0200)]
viocd: add dummy audio ioctl handler

Make sure audio_ioctl is always defined even if being a dummy function
since the cdrom_ioctl interface assumes its existence and we don't
want to BUG on null ptr on some ioctls like, e.g. CDROMREADTOCENTRY,
CDROMREADTOCHDR etc. when we fix CDC_PLAY_AUDIO checking in cdrom.c.

Signed-off-by: Borislav Petkov <petkovbb@gmail.com>
Acked-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agocleanup powerpc/include/asm/ide.h
Adrian Bunk [Mon, 18 Aug 2008 19:40:03 +0000 (21:40 +0200)]
cleanup powerpc/include/asm/ide.h

This patch removes code that became unused through IDE changes and the
arch/ppc/ removal.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agodrivers/ide/pci/: use __devexit_p()
Adrian Bunk [Mon, 18 Aug 2008 19:40:03 +0000 (21:40 +0200)]
drivers/ide/pci/: use __devexit_p()

This patch adds missing __devexit_p's.

Reported-by: Russell King <rmk+lkml@arm.linux.org.uk>
Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
15 years agoMerge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Mon, 18 Aug 2008 19:10:14 +0000 (12:10 -0700)]
Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86: fix build warnings in real mode code
  x86, calgary: fix section mismatch warning - get_tce_space_from_tar
  x86: silence section mismatch warning - get_local_pda
  x86, percpu: silence section mismatch warnings related to EARLY_PER_CPU variables
  x86: fix i486 suspend to disk CR4 oops
  x86: mpparse.c: fix section mismatch warning
  x86: mmconf: fix section mismatch warning
  x86: fix MP_processor_info section mismatch warning
  x86, tsc: fix section mismatch warning
  x86: correct register constraints for 64-bit atomic operations

15 years agoMerge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Mon, 18 Aug 2008 19:09:56 +0000 (12:09 -0700)]
Merge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  lockdep: fix spurious 'inconsistent lock state' warning

15 years agoMerge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
Linus Torvalds [Mon, 18 Aug 2008 19:05:01 +0000 (12:05 -0700)]
Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc

* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc:
  powerpc: Use generic compat_sys_old_readdir
  powerpc/kexec: Fix up KEXEC_CONTROL_CODE_SIZE missed during conversion
  powerpc: Remove dead module_find_bug code
  powerpc: Add CMO enabled flag and paging space data to lparcfg
  powerpc: Fix CMM page loaning on 64k page kernel with 4k hardware pages
  powerpc: Make CMO paging space pool ID and page size available
  powerpc: Fix lockdep IRQ tracing bug
  powerpc: Fix TLB invalidation on boot on 32-bit
  powerpc: Fix loss of vdso on fork on 32-bit

15 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6
Linus Torvalds [Mon, 18 Aug 2008 19:03:23 +0000 (12:03 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
  lmb: Fix reserved region handling in lmb_enforce_memory_limit().
  sparc64: Fix cmdline_memory_size handling bugs.
  sparc64: Fix overshoot in nid_range().

15 years agoMerge branch 'pci-for-jesse' of git://git.kernel.org/pub/scm/linux/kernel/git/tip...
Jesse Barnes [Mon, 18 Aug 2008 16:54:13 +0000 (09:54 -0700)]
Merge branch 'pci-for-jesse' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip into x86-merge

Conflicts:

drivers/pci/probe.c

15 years agoremoved unused #include <version.h>
Huang Weiyi [Sat, 16 Aug 2008 23:50:47 +0000 (07:50 +0800)]
removed unused #include <version.h>

The drivers below do not use LINUX_VERSION_CODE nor KERNEL_VERSION.
  drivers/net/wireless/ath5k/base.c
  drivers/net/wireless/b43/main.c
  drivers/net/wireless/ipw2100.c
  drivers/net/wireless/ipw2200.c
  drivers/net/wireless/iwlwifi/iwl-3945.c
  drivers/net/wireless/iwlwifi/iwl-4965.c
  drivers/net/wireless/iwlwifi/iwl-5000.c
  drivers/net/wireless/iwlwifi/iwl-agn.c
  drivers/net/wireless/iwlwifi/iwl-core.c
  drivers/net/wireless/iwlwifi/iwl-eeprom.c
  drivers/net/wireless/iwlwifi/iwl-hcmd.c
  drivers/net/wireless/iwlwifi/iwl-power.c
  drivers/net/wireless/iwlwifi/iwl3945-base.c

This patch removes the said #include <version.h>.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agort2x00: Fix txdone_entry_desc_flags
Jochen Friedrich [Fri, 15 Aug 2008 12:47:46 +0000 (14:47 +0200)]
rt2x00: Fix txdone_entry_desc_flags

txdone_entry_desc_flags is used with __set_bit and test_bit which
bit-shift the values, so don't bit-shift the flags in the enum.
Also make sure flags are initialized before being used.

Signed-off-by: Jochen Friedrich <jochen@scram.de>
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agob43: Fix for another Bluetooth Coexistence SPROM Programming error for BCM4306
Larry Finger [Thu, 14 Aug 2008 23:57:11 +0000 (18:57 -0500)]
b43: Fix for another Bluetooth Coexistence SPROM Programming error for BCM4306

In trying to help users on the Ubuntu Bugzilla, I discovered another
BCM4306 with the Bluetooth Coexistence programming error in the SPROM.

This patch is contingent on the one that added the Linksys device with
subdevice code of 0x0014.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agomac80211: remove kdoc references to IEEE80211_HW_HOST_GEN_BEACON_TEMPLATE
Luis R. Rodriguez [Thu, 14 Aug 2008 18:43:20 +0000 (11:43 -0700)]
mac80211: remove kdoc references to IEEE80211_HW_HOST_GEN_BEACON_TEMPLATE

IEEE80211_HW_HOST_GEN_BEACON_TEMPLATE was made unnecessary in
the recent revamp on beacon configuration.

Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agop54u: reset skb's data/tail pointer on requeue
Christian Lamparter [Wed, 13 Aug 2008 21:41:48 +0000 (23:41 +0200)]
p54u: reset skb's data/tail pointer on requeue

(Only important for USB V1 Adaptors)

If an incoming frame wasn't accepted by p54_rx function
the skb will be reused for new frames...

But, we must not forget to set the skb's data pointers into
the same state in which it was initialized by p54u_init_urbs.

Otherwise we either end up with 16 bytes less on every requeue,
or if a new frame is worthy enough to be accepted, the data is
in the wrong place (urb->transfer_buffer wasn't updated!) and mac80211
has a hard time to recognize it...

Signed-off-by: Christian Lamparter <chunkeey@web.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agop54: move p54_vdcf_init to the right place.
Christian Lamparter [Wed, 13 Aug 2008 21:41:45 +0000 (23:41 +0200)]
p54: move p54_vdcf_init to the right place.

priv->tx_hdr_len is set by the driver _after_ it called p54_init_common.
While this isn't much a problem for any PCI or ISL3887 cards/sticks,
because they don't need any extra header and therefore tx_hdr_len is
zero for them...

Signed-off-by: Christian Lamparter <chunkeey@web.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agoiwlwifi: fix printk newlines
Jiri Slaby [Mon, 11 Aug 2008 21:49:41 +0000 (23:49 +0200)]
iwlwifi: fix printk newlines

Add newlines at printk outputs to not break dmesg.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Zhu Yi <yi.zhu@intel.com>
Cc: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agortl8187: Add USB ID for Netgear WG111V3
matthieu Barthélemy [Mon, 11 Aug 2008 04:34:59 +0000 (23:34 -0500)]
rtl8187: Add USB ID for Netgear WG111V3

Add the USB ID for a Netgear WG111v3.

Signed-off-by: matthieu Barthélemy <bonsouere@gmail.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agob43: Fix for SPROM coding error in Linksys WMP54G (BCM4306/3)
Larry Finger [Sun, 10 Aug 2008 15:19:33 +0000 (10:19 -0500)]
b43: Fix for SPROM coding error in Linksys WMP54G (BCM4306/3)

The Linksys WMP54G (BCM4306/3) card in a PCI format has an SPROM coding
error and needs the fix found for several other cards.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@kernel.org> [2.6.25.x, 2.6.26.x]
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agomac80211: update new sta's rx timestamp
Ron Rindjunsky [Sat, 9 Aug 2008 21:54:34 +0000 (00:54 +0300)]
mac80211: update new sta's rx timestamp

This patch fixes needless probe request caused by zero value in
sta->last_rx inside ieee80211_associated flow

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agoath5k: Don't fiddle with MSI on suspend/resume.
Michael Karcher [Thu, 7 Aug 2008 17:34:01 +0000 (19:34 +0200)]
ath5k: Don't fiddle with MSI on suspend/resume.

Commit 256b152b005e319f985f50f2a910a75ba0def74f (ath5k: don't enable
MSI, we cannot handle it yet) has removed msi support, but overlooked
the suspend/resume code. This patch completes msi removal.

I don't consider this patch copyrightable, and thus put it into the
public domain. The result is of course a base.c file dual-licensed under
3-clause-BSD and GPL.

Signed-off-by: Michael Karcher <kernel@mkarcher.dialup.fu-berlin.de>
Acked-by: Nick Kossifidis <mickflemm@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agossb: allow compilation on systems without PCI
Holger Schurig [Thu, 7 Aug 2008 16:24:12 +0000 (18:24 +0200)]
ssb: allow compilation on systems without PCI

Makes ssb work on system without a PCI bus.

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agorfkill: protect suspended rfkill controllers
Henrique de Moraes Holschuh [Sat, 2 Aug 2008 17:56:25 +0000 (14:56 -0300)]
rfkill: protect suspended rfkill controllers

Guard rfkill controllers attached to a rfkill class against state changes
after class suspend has been issued.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Acked-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agop54: Fix regression due to "net: Delete NETDEVICES_MULTIQUEUE kconfig option"
Christian Lamparter [Sun, 10 Aug 2008 00:20:47 +0000 (19:20 -0500)]
p54: Fix regression due to "net: Delete NETDEVICES_MULTIQUEUE kconfig option"

Commit b19fa1f, entitled "net: Delete NETDEVICES_MULTIQUEUE kconfig
option" breaks p54pci and p54usb.

Additionally, the old logic always tx'ed cts frames (if enabled)
with a short preamble when [rate > 3]. (i.e. with any 802.11g rate).
Of course this isn't that bad, but it's still wrong!

(This patch also clarifies the meanings of some of the fields in the tx
header for the hardware. -- JWL)

Signed-off-by: Christian Lamparter <chunkeey@web.de>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: <stable@kernel.org> [2.6.25.x, 2.6.26.x]
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agoath9k: work around gcc ICEs (again)
Adrian Bunk [Tue, 5 Aug 2008 19:06:51 +0000 (22:06 +0300)]
ath9k: work around gcc ICEs (again)

(I missed the fact that the original post said to apply this patch
twice... -- JWL)

Original commit log message:

This patch works around an internal compiler error (gcc bug #37014) in
all gcc 4.2 compilers and the gcc 4.3 series up to at least 4.3.1
on at least powerpc and mips.

Many thanks to Andrew Pinski for analyzing the gcc bug.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
15 years agoInput: remove version.h from drivers that don't need it
Huang Weiyi [Mon, 18 Aug 2008 14:57:10 +0000 (10:57 -0400)]
Input: remove version.h from drivers that don't need it

If a driver dies not use LINUX_VERSION_CODE nor KERNEL_VERSION
then it does not need to include version.h

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
15 years agoInput: cobalt_btns - add missing MODULE_LICENSE
Martin Michlmayr [Fri, 15 Aug 2008 19:06:21 +0000 (15:06 -0400)]
Input: cobalt_btns - add missing MODULE_LICENSE

Export the module license and other information about the Cobalt
button module in order to avoid the following warning:

| WARNING: modpost: missing MODULE_LICENSE() in drivers/input/misc/cobalt_btns.o

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Acked-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
15 years ago[Bluetooth] Consolidate maintainers information
Marcel Holtmann [Mon, 18 Aug 2008 11:23:53 +0000 (13:23 +0200)]
[Bluetooth] Consolidate maintainers information

The Bluetooth entries for the MAINTAINERS file are a little bit too
much. Consolidate them into two entries. One for Bluetooth drivers and
another one for the Bluetooth subsystem.

Also the MODULE_AUTHOR should indicate the current maintainer of the
module and actually not the original author. Fix all Bluetooth modules
to provide current maintainer information.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
15 years ago[Bluetooth] Fix userspace breakage due missing class links
Marcel Holtmann [Mon, 18 Aug 2008 11:23:53 +0000 (13:23 +0200)]
[Bluetooth] Fix userspace breakage due missing class links

The Bluetooth adapters and connections are best presented via a class
in sysfs. The removal of the links inside the Bluetooth class broke
assumptions by userspace programs on how to find attached adapters.

This patch creates adapters and connections as part of the Bluetooth
class, but it uses different device types to distinguish them. The
userspace programs can now easily navigate in the sysfs device tree.

The unused platform device and bus have been removed to keep the
code simple and clean.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
15 years ago[Bluetooth] Add SCO support to btusb driver
Marcel Holtmann [Mon, 18 Aug 2008 11:23:52 +0000 (13:23 +0200)]
[Bluetooth] Add SCO support to btusb driver

The new generic driver for Bluetooth USB devices was missing proper
SCO support. The driver now claims the second interface for these USB
devices to allow the flow of SCO packets. It also handles switching
of the alternate setting and re-submission of isochronous URBs.

The btusb driver is now a full replacement for hci_usb and thus the
experimental tag has been removed and this driver is promoted as
preferred one.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
15 years agolockdep: fix spurious 'inconsistent lock state' warning
Dmitry Baryshkov [Mon, 18 Aug 2008 00:26:37 +0000 (04:26 +0400)]
lockdep: fix spurious 'inconsistent lock state' warning

Since f82b217e3513fe3af342c0f3ee1494e86250c21c lockdep can output spurious
warnings related to hwirqs due to hardirq_off shrinkage from int to bit-sized
flag. Guard it with double negation to fix the warning.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agopkt_sched: Fix return value corruption in HTB and TBF.
David S. Miller [Mon, 18 Aug 2008 06:55:36 +0000 (23:55 -0700)]
pkt_sched: Fix return value corruption in HTB and TBF.

Based upon a bug report by Josip Rodin.

Packet schedulers should only return NET_XMIT_DROP iff
the packet really was dropped.  If the packet does reach
the device after we return NET_XMIT_DROP then TCP can
crash because it depends upon the enqueue path return
values being accurate.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agox86: fix build warnings in real mode code
Andi Kleen [Mon, 18 Aug 2008 07:06:01 +0000 (09:06 +0200)]
x86: fix build warnings in real mode code

This recent patch

commit c3965bd15118742d72b4bc1a290d37b3f081eb98
Author: Paul Jackson <pj@sgi.com>
Date:   Wed May 14 08:15:34 2008 -0700

    x86 boot: proper use of ARRAY_SIZE instead of repeated E820MAX constant

caused these new warnings during a normal build:

In file included from linux-2.6/arch/x86/boot/memory.c:17:
linux-2.6/include/linux/log2.h: In function '__ilog2_u32':
linux-2.6/include/linux/log2.h:34: warning: implicit declaration of function 'fls'
linux-2.6/include/linux/log2.h: In function '__ilog2_u64':
linux-2.6/include/linux/log2.h:42: warning: implicit declaration of function 'fls64'
linux-2.6/include/linux/log2.h: In function '__roundup_pow_of_two ':
linux-2.6/include/linux/log2.h:63: warning: implicit declaration of function 'fls_long'

I tried to fix them in log2.h, but it's difficult because the real mode
environment is completely different from a normal kernel environment. Instead
define an own ARRAY_SIZE macro in boot.h, similar to the other private
macros there.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86, calgary: fix section mismatch warning - get_tce_space_from_tar
Marcin Slusarz [Sun, 17 Aug 2008 15:50:52 +0000 (17:50 +0200)]
x86, calgary: fix section mismatch warning - get_tce_space_from_tar

WARNING: vmlinux.o(.text+0x27032): Section mismatch in reference from the function get_tce_space_from_tar() to the function .init.text:calgary_bus_has_devices()
The function get_tce_space_from_tar() references
the function __init calgary_bus_has_devices().
This is often because get_tce_space_from_tar lacks a __init
annotation or the annotation of calgary_bus_has_devices is wrong.

get_tce_space_from_tar is called only from __init function (calgary_init)
and calls __init function (calgary_bus_has_devices).
So annotate it properly.

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Cc: Chandru Siddalingappa <chandru@in.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86: silence section mismatch warning - get_local_pda
Marcin Slusarz [Sun, 17 Aug 2008 15:50:51 +0000 (17:50 +0200)]
x86: silence section mismatch warning - get_local_pda

Take out part of get_local_pda referencing __init function (free_bootmem)
to new (static) function marked as __ref. It's safe to do because free_bootmem
is called before __init sections are dropped.

WARNING: vmlinux.o(.cpuinit.text+0x3cd7): Section mismatch in reference from the function get_local_pda() to the function .init.text:free_bootmem()
The function __cpuinit get_local_pda() references
a function __init free_bootmem().
If free_bootmem is only used by get_local_pda then
annotate free_bootmem with a matching annotation.

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Cc: Mike Travis <travis@sgi.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86, percpu: silence section mismatch warnings related to EARLY_PER_CPU variables
Marcin Slusarz [Sun, 17 Aug 2008 15:50:50 +0000 (17:50 +0200)]
x86, percpu: silence section mismatch warnings related to EARLY_PER_CPU variables

Quoting Mike Travis in "x86: cleanup early per cpu variables/accesses v4"
(23ca4bba3e20c6c3cb11c1bb0ab4770b724d39ac):

    The DEFINE macro defines the per_cpu variable as well as the early
    map and pointer.  It also initializes the per_cpu variable and map
    elements to "_initvalue".  The early_* macros provide access to
    the initial map (usually setup during system init) and the early
    pointer.  This pointer is initialized to point to the early map
    but is then NULL'ed when the actual per_cpu areas are setup.  After
    that the per_cpu variable is the correct access to the variable.

As these variables are NULL'ed before __init sections are dropped
(in setup_per_cpu_maps), they can be safely annotated as __ref.

This change silences following section mismatch warnings:

WARNING: vmlinux.o(.data+0x46c0): Section mismatch in reference from the variable x86_cpu_to_apicid_early_ptr to the variable .init.data:x86_cpu_to_apicid_early_map
The variable x86_cpu_to_apicid_early_ptr references
the variable __initdata x86_cpu_to_apicid_early_map
If the reference is valid then annotate the
variable with __init* (see linux/init.h) or name the variable:
*driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console,

WARNING: vmlinux.o(.data+0x46c8): Section mismatch in reference from the variable x86_bios_cpu_apicid_early_ptr to the variable .init.data:x86_bios_cpu_apicid_early_map
The variable x86_bios_cpu_apicid_early_ptr references
the variable __initdata x86_bios_cpu_apicid_early_map
If the reference is valid then annotate the
variable with __init* (see linux/init.h) or name the variable:
*driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console,

WARNING: vmlinux.o(.data+0x46d0): Section mismatch in reference from the variable x86_cpu_to_node_map_early_ptr to the variable .init.data:x86_cpu_to_node_map_early_map
The variable x86_cpu_to_node_map_early_ptr references
the variable __initdata x86_cpu_to_node_map_early_map
If the reference is valid then annotate the
variable with __init* (see linux/init.h) or name the variable:
*driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console,

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Cc: Mike Travis <travis@sgi.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86: fix i486 suspend to disk CR4 oops
David Fries [Mon, 18 Aug 2008 04:03:40 +0000 (23:03 -0500)]
x86: fix i486 suspend to disk CR4 oops

arch/x86/power/cpu_32.c __save_processor_state calls read_cr4()
only a i486 CPU doesn't have the CR4 register.  Trying to read it
produces an invalid opcode oops during suspend to disk.

Use the safe rc4 reading op instead. If the value to be written is
zero the write is skipped.

arch/x86/power/hibernate_asm_32.S
done: swapped the use of %eax and %ecx to use jecxz for
the zero test and jump over store to %cr4.
restore_image: s/%ecx/%eax/ to be consistent with done:

In addition to __save_processor_state, acpi_save_state_mem,
efi_call_phys_prelog, and efi_call_phys_epilog had checks added
(acpi restore was in assembly and already had a check for
non-zero).  There were other reads and writes of CR4, but MCE and
virtualization shouldn't be executed on a i486 anyway.

Signed-off-by: David Fries <david@fries.net>
Acked-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agopkt_sched: Fix missed RCU unlock in dev_queue_xmit()
David S. Miller [Mon, 18 Aug 2008 06:37:16 +0000 (23:37 -0700)]
pkt_sched: Fix missed RCU unlock in dev_queue_xmit()

Noticed by Jarek Poplawski.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agoipv6: Fix the return interface index when get it while no message is received.
Yang Hongyang [Mon, 18 Aug 2008 06:21:52 +0000 (23:21 -0700)]
ipv6: Fix the return interface index when get it while no message is received.

When get receiving interface index while no message is received,
the bounded device's index of the socket should be returned.

RFC 3542:
   Issuing getsockopt() for the above options will return the sticky
   option value i.e., the value set with setsockopt().  If no sticky
   option value has been set getsockopt() will return the following
   values:

   -  For the IPV6_PKTINFO option, it will return an in6_pktinfo
      structure with ipi6_addr being in6addr_any and ipi6_ifindex being
      zero.

Signed-off-by: Yang Hongyang <yanghy@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agox86: mpparse.c: fix section mismatch warning
Marcin Slusarz [Sun, 10 Aug 2008 22:09:38 +0000 (00:09 +0200)]
x86: mpparse.c: fix section mismatch warning

WARNING: vmlinux.o(.text+0x118f7): Section mismatch in reference from the function construct_ioapic_table() to the function .init.text:MP_bus_info()
The function construct_ioapic_table() references
the function __init MP_bus_info().
This is often because construct_ioapic_table lacks a __init
annotation or the annotation of MP_bus_info is wrong.

construct_ioapic_table is called only from construct_default_ISA_mptable which is __init

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86: mmconf: fix section mismatch warning
Marcin Slusarz [Sun, 10 Aug 2008 22:11:13 +0000 (00:11 +0200)]
x86: mmconf: fix section mismatch warning

WARNING: arch/x86/kernel/built-in.o(.cpuinit.text+0x1591): Section mismatch in reference from the function init_amd() to the function .init.text:check_enable_amd_mmconf_dmi()
The function __cpuinit init_amd() references
a function __init check_enable_amd_mmconf_dmi().
If check_enable_amd_mmconf_dmi is only used by init_amd then
annotate check_enable_amd_mmconf_dmi with a matching annotation.

check_enable_amd_mmconf_dmi is only called from init_amd which is __cpuinit

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86: fix MP_processor_info section mismatch warning
Marcin Slusarz [Sun, 10 Aug 2008 22:12:37 +0000 (00:12 +0200)]
x86: fix MP_processor_info section mismatch warning

WARNING: arch/x86/kernel/built-in.o(.cpuinit.text+0x1fe7): Section mismatch in reference from the function MP_processor_info() to the variable .init.data:x86_quirks
The function __cpuinit MP_processor_info() references
a variable __initdata x86_quirks.
If x86_quirks is only used by MP_processor_info then
annotate x86_quirks with a matching annotation.

MP_processor_info uses x86_quirks which is __init and is used only from
smp_read_mpc and construct_default_ISA_mptable which are __init

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86, tsc: fix section mismatch warning
Marcin Slusarz [Sun, 10 Aug 2008 22:07:44 +0000 (00:07 +0200)]
x86, tsc: fix section mismatch warning

WARNING: vmlinux.o(.text+0x7950): Section mismatch in reference from the function native_calibrate_tsc() to the function .init.text:tsc_read_refs()
The function native_calibrate_tsc() references
the function __init tsc_read_refs().
This is often because native_calibrate_tsc lacks a __init
annotation or the annotation of tsc_read_refs is wrong.

tsc_read_refs is called from native_calibrate_tsc which is not __init
and native_calibrate_tsc cannot be marked __init

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agox86: correct register constraints for 64-bit atomic operations
Mathieu Desnoyers [Sat, 16 Aug 2008 07:39:26 +0000 (03:39 -0400)]
x86: correct register constraints for 64-bit atomic operations

x86_64 add/sub atomic ops does not seems to accept integer values bigger
than 32 bits as immediates. Intel's add/sub documentation specifies they
have to be passed as registers.

The only operations in the x86-64 architecture which accept arbitrary
64-bit immediates is "movq" to any register; similarly, the only
operation which accept arbitrary 64-bit displacement is "movabs" to or
from al/ax/eax/rax.

http://gcc.gnu.org/onlinedocs/gcc-4.3.0/gcc/Machine-Constraints.html

states :

e
    32-bit signed integer constant, or a symbolic reference known to fit
    that range (for immediate operands in sign-extending x86-64
    instructions).
Z
    32-bit unsigned integer constant, or a symbolic reference known to
    fit that range (for immediate operands in zero-extending x86-64
    instructions).

Since add/sub does sign extension, using the "e" constraint seems appropriate.

It applies to 2.6.27-rc, 2.6.26, 2.6.25...

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
15 years agosch_prio: Use NET_XMIT_SUCCESS instead of "0" constant.
David S. Miller [Mon, 18 Aug 2008 05:45:17 +0000 (22:45 -0700)]
sch_prio: Use NET_XMIT_SUCCESS instead of "0" constant.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agosch_prio: Use return value from inner qdisc requeue
Jussi Kivilinna [Mon, 18 Aug 2008 05:43:56 +0000 (22:43 -0700)]
sch_prio: Use return value from inner qdisc requeue

Use return value from inner qdisc requeue when value returned isn't
NET_XMIT_SUCCESS, instead of always returning NET_XMIT_DROP.

Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopkt_sched: No longer destroy qdiscs from RCU.
David S. Miller [Mon, 18 Aug 2008 05:31:26 +0000 (22:31 -0700)]
pkt_sched: No longer destroy qdiscs from RCU.

We can now kill them synchronously with all of the
previous dev_deactivate() cures.

This makes netdev destruction and shutdown saner as
the qdiscs hold references to the device.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopkt_sched: Grab correct lock in notify_and_destroy().
Jarek Poplawski [Mon, 18 Aug 2008 05:02:11 +0000 (22:02 -0700)]
pkt_sched: Grab correct lock in notify_and_destroy().

From: Jarek Poplawski <jarkao2@gmail.com>

When we are destroying non-root qdiscs, we need to lock
the root of the qdisc tree not the the qdisc itself.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopkt_sched: Simplify dev_deactivate() polling loop.
David S. Miller [Mon, 18 Aug 2008 04:58:07 +0000 (21:58 -0700)]
pkt_sched: Simplify dev_deactivate() polling loop.

The condition under which the previous qdisc has no more references
after we've attached &noop_qdisc is that both RUNNING and SCHED
are both seen clear while holding the root lock.

So just make specifically that check in the polling loop, instead
of this overly complex "check without then check with lock held"
sequence.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agonet: Change handling of the __QDISC_STATE_SCHED flag in net_tx_action().
Jarek Poplawski [Mon, 18 Aug 2008 04:54:43 +0000 (21:54 -0700)]
net: Change handling of the __QDISC_STATE_SCHED flag in net_tx_action().

Change handling of the __QDISC_STATE_SCHED flag in net_tx_action() to
enable proper control in dev_deactivate(). Now, if this flag is seen
as unset under root_lock means a qdisc can't be netif_scheduled.

Signed-off-by: Jarek Poplawski <jarkao2@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopkt_sched: Add 'deactivated' state.
David S. Miller [Mon, 18 Aug 2008 04:51:03 +0000 (21:51 -0700)]
pkt_sched: Add 'deactivated' state.

This new state lets dev_deactivate() mark a qdisc as having been
deactivated.

dev_queue_xmit() and ing_filter() check for this bit and do not
try to process the qdisc if the bit is set.

dev_deactivate() polls the qdisc after setting the bit, waiting
for both __QDISC_STATE_RUNNING and __QDISC_STATE_SCHED to clear.

This isn't perfect yet, but subsequent changesets will make it so.
This part is just one piece of the puzzle.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 years agopowerpc: Use generic compat_sys_old_readdir
Christoph Hellwig [Sat, 16 Aug 2008 17:57:30 +0000 (03:57 +1000)]
powerpc: Use generic compat_sys_old_readdir

Use the generic compat_sys_old_readdir instead of the powerpc one which
is almost the same except for the almost complete lack of error
handling.

Note that we can't just use SYSCALL() in systbl.h because the native
syscall is named old_readdir, not sys_old_readdir.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc/kexec: Fix up KEXEC_CONTROL_CODE_SIZE missed during conversion
Paul Collins [Sat, 16 Aug 2008 08:55:54 +0000 (18:55 +1000)]
powerpc/kexec: Fix up KEXEC_CONTROL_CODE_SIZE missed during conversion

Commit 163f6876f5c3ff8215e900b93779e960a56b3694 missed one, resulting in
the following compile error:

  AS      arch/powerpc/kernel/misc_32.o
arch/powerpc/kernel/misc_32.S: Assembler messages:
arch/powerpc/kernel/misc_32.S:902: Error: unsupported relocation against KEXEC_CONTROL_CODE_SIZE
make[2]: *** [arch/powerpc/kernel/misc_32.o] Error 1
make[1]: *** [arch/powerpc/kernel] Error 2
make: *** [vmlinux] Error 2

I grepped arch/ and found no further instances.

Signed-off-by: Paul Collins <paul@ondioline.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc: Remove dead module_find_bug code
Steven Rostedt [Sat, 16 Aug 2008 03:56:44 +0000 (13:56 +1000)]
powerpc: Remove dead module_find_bug code

Doing some various "make randconfig", I came across an error when
CONFIG_BUG was not set:

arch/powerpc/kernel/module.c: In function 'module_find_bug':
arch/powerpc/kernel/module.c:111: error: increment of pointer to unknown structure
arch/powerpc/kernel/module.c:111: error: arithmetic on pointer to an incomplete type
arch/powerpc/kernel/module.c:112: error: dereferencing pointer to incomplete type

Looking further into this, I found that module_find_bug, defined in
powerpc arch code, is not called anywhere, so this just removes it.

There is a static module_find_bug in lib/bug.c but that is a separate issue.

Signed-off-by: Steven Rostedt <srostedt@redhat.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc: Add CMO enabled flag and paging space data to lparcfg
Robert Jennings [Fri, 15 Aug 2008 19:10:18 +0000 (05:10 +1000)]
powerpc: Add CMO enabled flag and paging space data to lparcfg

Add a field in lparcfg output to indicate whether the kernel is
running on a dedicated or shared memory lpar.  Added fields to show
the paging space pool IDs and the CMO page size.

Submitted-by: Robert Jennings <rcj@linux.vnet.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc: Fix CMM page loaning on 64k page kernel with 4k hardware pages
Brian King [Fri, 15 Aug 2008 19:09:33 +0000 (05:09 +1000)]
powerpc: Fix CMM page loaning on 64k page kernel with 4k hardware pages

If the firmware page size used for collaborative memory overcommit
is 4k, but the kernel is using 64k pages, the page loaning is currently
broken as it only marks the first 4k page of each 64k page as loaned.
This fixes this to iterate through each 4k page and mark them all as
loaned/active.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: Robert Jennings <rcj@linux.vnet.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc: Make CMO paging space pool ID and page size available
Robert Jennings [Fri, 15 Aug 2008 19:07:31 +0000 (05:07 +1000)]
powerpc: Make CMO paging space pool ID and page size available

During platform setup, save off the primary/secondary paging space
pool IDs and the page size.  Added accessors in hvcall.h for these
variables.  This is needed for a subsequent fix.

Submitted-by: Robert Jennings <rcj@linux.vnet.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc: Fix lockdep IRQ tracing bug
Benjamin Herrenschmidt [Fri, 15 Aug 2008 07:11:31 +0000 (17:11 +1000)]
powerpc: Fix lockdep IRQ tracing bug

A small bogon sneaked into the ppc64 lockdep support.  A test is
branching slightly off causing a clobbered register value to
overwrite the irq state under some circumstances.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc: Fix TLB invalidation on boot on 32-bit
Rocky Craig [Thu, 14 Aug 2008 13:11:54 +0000 (23:11 +1000)]
powerpc: Fix TLB invalidation on boot on 32-bit

The intent of "flush_tlbs" is to invalidate all TLB entries by doing a
TLB invalidate instruction for all pages in the address range 0 to
0x00400000.  A loop counter is set up at the high value and
decremented by page size.  However, the loop is only done once as the
sense of the conditional branch at the loop end does not match the
setup/decrement.  This fixes it to do the whole range by correcting
the branch condition.

Signed-off-by: Rocky Craig <rocky.craig@hp.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agopowerpc: Fix loss of vdso on fork on 32-bit
Benjamin Herrenschmidt [Tue, 12 Aug 2008 07:03:26 +0000 (17:03 +1000)]
powerpc: Fix loss of vdso on fork on 32-bit

When we fork, init_new_context() improperly resets the vdso_base
of the new context to 0.  That means that the new process loses
access to the vdso for signal trampolines.

The initialization should be unnecessary anyway as the context
on a fresh mm should be 0 in the first place and binfmt_elf
will initialize that value for a newly loaded process.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc
Linus Torvalds [Sun, 17 Aug 2008 20:01:30 +0000 (13:01 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc:
  sdricoh_cs: removed unused #include <version.h>
  s3cmci: attach get_cd host ops
  s3cmci: fix sparse errors from non-exported functions

15 years agosdricoh_cs: removed unused #include <version.h>
Huang Weiyi [Sat, 16 Aug 2008 23:51:10 +0000 (07:51 +0800)]
sdricoh_cs: removed unused #include <version.h>

The drivers below do not use LINUX_VERSION_CODE nor KERNEL_VERSION.
  drivers/mmc/host/sdricoh_cs.c

This patch removes the said #include <version.h>.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
15 years agos3cmci: attach get_cd host ops
Ben Dooks [Tue, 12 Aug 2008 08:24:50 +0000 (09:24 +0100)]
s3cmci: attach get_cd host ops

Attach the routine to get_cd to allow the MMC core to find out whether
there is a card present or not without the tedious process of trying to
send commands to the card or not.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
15 years agos3cmci: fix sparse errors from non-exported functions
Ben Dooks [Fri, 8 Aug 2008 09:55:41 +0000 (10:55 +0100)]
s3cmci: fix sparse errors from non-exported functions

Fix the following sparse errors by making the functions
static and fixing the check for host->base.

598:6: warning: symbol 's3cmci_dma_done_callback' was not declared. Should it be static?
744:6: warning: symbol 's3cmci_dma_setup' was not declared. Should it be static?
1209:20: warning: Using plain integer as NULL pointer

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
15 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
Linus Torvalds [Sun, 17 Aug 2008 16:20:33 +0000 (09:20 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: hda - Fix capture source widgets on ALC codecs

15 years agosecurity.h: fix build failure
Alexander Beregalov [Sun, 17 Aug 2008 01:34:20 +0000 (05:34 +0400)]
security.h: fix build failure

security.h: fix build failure

include/linux/security.h: In function 'security_ptrace_traceme':
include/linux/security.h:1760: error: 'parent' undeclared (first use in this function)

Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Tested-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: James Morris <jmorris@namei.org>
15 years agoALSA: hda - Fix capture source widgets on ALC codecs
Takashi Iwai [Fri, 15 Aug 2008 14:46:42 +0000 (16:46 +0200)]
ALSA: hda - Fix capture source widgets on ALC codecs

On some Realtek codecs like ALC882 or ALC883, the capture source is
no mux but sum widget.  We have to initialize all channels properly
for this type, otherwise noises may come in from the unused route.

The patch assures to mute unused routes, and unmute the currently
selected route.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Tested-by: Daniel J Blueman <daniel.blueman@gmail.com>
15 years agoremoved unused #include <version.h>
Huang Weiyi [Sat, 16 Aug 2008 23:51:05 +0000 (07:51 +0800)]
removed unused #include <version.h>

The drivers below do not use LINUX_VERSION_CODE nor KERNEL_VERSION.
  drivers/char/pcmcia/ipwireless/tty.c
  drivers/char/synclink_gt.c
  drivers/char/xilinx_hwicap/xilinx_hwicap.c

This patch removes the said #include <version.h>.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoMerge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sun, 17 Aug 2008 00:16:07 +0000 (17:16 -0700)]
Merge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  lockdep: fix build if CONFIG_PROVE_LOCKING not defined
  lockdep: use WARN() in kernel/lockdep.c
  lockdep: spin_lock_nest_lock(), checkpatch fixes
  lockdep: build fix

15 years agoMerge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sun, 17 Aug 2008 00:15:32 +0000 (17:15 -0700)]
Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  sched: scale sysctl_sched_shares_ratelimit with nr_cpus
  sched: fix rt-bandwidth hotplug race
  sched: fix the race between walk_tg_tree and sched_create_group

15 years agoMerge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 17 Aug 2008 00:14:07 +0000 (17:14 -0700)]
Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (32 commits)
  x86: add MAP_STACK mmap flag
  x86: fix section mismatch warning - spp_getpage()
  x86: change init_gdt to update the gdt via write_gdt, rather than a direct write.
  x86-64: fix overlap of modules and fixmap areas
  x86, geode-mfgpt: check IRQ before using MFGPT as clocksource
  x86, acpi: cleanup, temp_stack is used only when CONFIG_SMP is set
  x86: fix spin_is_contended()
  x86, nmi: clean UP NMI watchdog failure message
  x86, NMI: fix watchdog failure message
  x86: fix /proc/meminfo DirectMap
  x86: fix readb() et al compile error with gcc-3.2.3
  arch/x86/Kconfig: clean up, experimental adjustement
  x86: invalidate caches before going into suspend
  x86, perfctr: don't use CCCR_OVF_PMI1 on Pentium 4Ds
  x86, AMD IOMMU: initialize dma_ops after sysfs registration
  x86m AMD IOMMU: cleanup: replace LOW_U32 macro with generic lower_32_bits
  x86, AMD IOMMU: initialize device table properly
  x86, AMD IOMMU: use status bit instead of memory write-back for completion wait
  x86: silence mmconfig printk
  x86, msr: fix NULL pointer deref due to msr_open on nonexistent CPUs
  ...

15 years agoMove sysctl check into debugging section and don't make it default y
Andi Kleen [Sat, 16 Aug 2008 05:53:05 +0000 (07:53 +0200)]
Move sysctl check into debugging section and don't make it default y

I noticed that sysctl_check.o was the largest object file in
a allnoconfig build in kernel/*.

  36243       0       0   36243    8d93 kernel/sysctl_check.o

This is because it was default y and && EMBEDDED. But I don't
really see a need for a non kernel developer to have their
sysctls checked all the time.

So move the Kconfig into the kernel debugging section and
also drop the default y and the EMBEDDED check.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agoMerge master.kernel.org:/home/rmk/linux-2.6-arm
Linus Torvalds [Sat, 16 Aug 2008 23:48:45 +0000 (16:48 -0700)]
Merge master.kernel.org:/home/rmk/linux-2.6-arm

* master.kernel.org:/home/rmk/linux-2.6-arm: (38 commits)
  [ARM] 5191/1: ARM: remove CVS keywords
  [ARM] pxafb: fix the warning of incorrect lccr when lcd_conn is specified
  [ARM] pxafb: add flag to specify output format on LDD pins when base is RGBT16
  [ARM] pxafb: fix the incorrect configuration of GPIO77 as ACBIAS for TFT LCD
  [ARM] 5198/1: PalmTX: PCMCIA fixes
  [ARM] Fix a pile of broken watchdog drivers
  [ARM] update mach-types
  [ARM] 5196/1: fix inline asm constraints for preload
  [ARM] 5194/1: update .gitignore
  [ARM] add proc-macros.S include to proc-arm940 and proc-arm946
  [ARM] 5192/1: ARM TLB: add v7wbi_{possible,always}_flags to {possible,always}_tlb_flags
  [ARM] 5193/1: Wire up missing syscalls
  [ARM] traps: don't call undef hook functions with spinlock held
  [ARM] 5183/2: Provide Poodle LoCoMo GPIO names
  [ARM] dma-mapping: provide sync_range APIs
  [ARM] dma-mapping: improve type-safeness of DMA translations
  [ARM] Kirkwood: instantiate the orion_spi driver in the platform code
  [ARM] prevent crashing when too much RAM installed
  [ARM] Kirkwood: Instantiate mv_xor driver
  [ARM] Orion: Instantiate mv_xor driver for 5182
  ...

15 years agoFix header export of videodev2.h, ivtv.h, ivtvfb.h
David Woodhouse [Sat, 16 Aug 2008 10:55:04 +0000 (11:55 +0100)]
Fix header export of videodev2.h, ivtv.h, ivtvfb.h

The exported copy of videodev2.h contains this line:

#define #include <sys/time.h>

This is because for some reason it defines __user for itself -- despite
the fact that we remove all instances of __user when exporting headers.
_All_ pointers in userspace are user pointers. Fix it by removing the
unnecessary '#define __user' from the file.

The new headers ivtv.h and ivtvfb.h would have the same problem... if
whoever put them there had actually remembered to add them to the Kbuild
file while he was at it. Fix those too, and export them as was
presumably intended.

Note that includes of <linux/compiler.h> are also stripped by the header
export process, so those don't need to be conditional.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Acked-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years agomm: VM_flags comment fixes
Hugh Dickins [Sat, 16 Aug 2008 10:07:21 +0000 (11:07 +0100)]
mm: VM_flags comment fixes

Try to comment away a little of the confusion between mm's vm_area_struct
vm_flags and vmalloc's vm_struct flags: based on an idea by Ulrich Drepper.

Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
15 years ago[ARM] 5191/1: ARM: remove CVS keywords
Adrian Bunk [Sun, 10 Aug 2008 14:25:55 +0000 (15:25 +0100)]
[ARM] 5191/1: ARM: remove CVS keywords

This patch removes CVS keywords that weren't updated for a long time.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[SCSI] ibmvfc: Driver version 1.0.2
Brian King [Fri, 15 Aug 2008 15:59:28 +0000 (10:59 -0500)]
[SCSI] ibmvfc: Driver version 1.0.2

Bump driver version to 1.0.2.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] ibmvfc: Add details to async event log
Brian King [Fri, 15 Aug 2008 15:59:27 +0000 (10:59 -0500)]
[SCSI] ibmvfc: Add details to async event log

When logging async events, also print the payload in addition to the
event received.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] ibmvfc: Sanitize response lengths
Brian King [Fri, 15 Aug 2008 15:59:26 +0000 (10:59 -0500)]
[SCSI] ibmvfc: Sanitize response lengths

Sanitize the response lengths in order to prevent possible oopses
in the command response path.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] ibmvfc: Fix for lost async events
Brian King [Fri, 15 Aug 2008 15:59:23 +0000 (10:59 -0500)]
[SCSI] ibmvfc: Fix for lost async events

If the client virtual fibre channel adapter is already logged into the
server and does an NPIV Login again, the async queue, which is used for
reporting Link Up/Link Down type of events, does not get reset on the
server side. Fix up the client driver so that we also do not reset it.
This fixes a problem of lost async events following relogins.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] ibmvfc: Fixup host state during reinit
Brian King [Fri, 15 Aug 2008 15:59:22 +0000 (10:59 -0500)]
[SCSI] ibmvfc: Fixup host state during reinit

If an ELS is received while the virtual fibre channel adapter is going
through its discovery, a flag is set which causes discovery to get
re-driven. However, the hosts's state does not get set back to
IBMVFC_INITIALIZING and scsi_block_requests does not get called again,
which can result in queuecommand ops getting sent during
discovery. This should not occur and may cause problems. One example
is that we may no longer be logged into the target we send the command
to, resulting in a failure which should not have occurred.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] ibmvfc: Fix another hang on module removal
Brian King [Fri, 15 Aug 2008 15:59:21 +0000 (10:59 -0500)]
[SCSI] ibmvfc: Fix another hang on module removal

This fixes a hang on module removal. The module removal code was setting
the hosts's state to IBMVFC_HOST_OFFLINE before tearing down the kernel
thread, but, due to a bug in ibmvfc_wait_while_resetting, was not waiting
for the kernel thread's offlining work to be done prior to destroying
the kernel thread, which left the scsi host in a blocked state which we
never got out of.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[ARM] pxafb: fix the warning of incorrect lccr when lcd_conn is specified
Eric Miao [Sat, 16 Aug 2008 07:50:51 +0000 (03:50 -0400)]
[ARM] pxafb: fix the warning of incorrect lccr when lcd_conn is specified

The newly introduced "lcd_conn" field for connected LCD panel type will
cause the original code to generate the warnings of incorrect lccr*.
This is unnecessary since well encoded LCD_* flags will not generate
incorrect combinition of lccr* bits. Skip the check if "lcd_conn" is
specified.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] pxafb: add flag to specify output format on LDD pins when base is RGBT16
Eric Miao [Fri, 15 Aug 2008 06:50:44 +0000 (02:50 -0400)]
[ARM] pxafb: add flag to specify output format on LDD pins when base is RGBT16

Another fix of inconsistent shift of the LCD_BIAS_ACTIVE_* and
LCD_PCLK_EDGE_* is also included.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] pxafb: fix the incorrect configuration of GPIO77 as ACBIAS for TFT LCD
Eric Miao [Sat, 16 Aug 2008 07:59:11 +0000 (03:59 -0400)]
[ARM] pxafb: fix the incorrect configuration of GPIO77 as ACBIAS for TFT LCD

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
Tested-by: Alex Osborne <ato@meshy.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[ARM] 5198/1: PalmTX: PCMCIA fixes
Marek Vašut [Sat, 16 Aug 2008 14:34:11 +0000 (15:34 +0100)]
[ARM] 5198/1: PalmTX: PCMCIA fixes

Fix GPIO handling in the PCMCIA driver.

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
15 years ago[SCSI] ibmvscsi: Fixup desired DMA value for shared memory partitions
Brian King [Fri, 15 Aug 2008 15:48:47 +0000 (10:48 -0500)]
[SCSI] ibmvscsi: Fixup desired DMA value for shared memory partitions

When running ibmvscsi in a shared memory partition, it must provide
a default value for the amount of DMA resources it will need in order to
perform reasonably well. This was being calculated in sectors rather than
bytes, as it should. This patch fixes this.

Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] megaraid_sas: remove sysfs dbg_lvl world writeable permissions
Joe Malicki [Thu, 14 Aug 2008 21:14:48 +0000 (17:14 -0400)]
[SCSI] megaraid_sas: remove sysfs dbg_lvl world writeable permissions

/sys/bus/pci/drivers/megaraid_sas/dbg_lvl defaults to being
world-writable, which seems bad (letting any user affect kernel driver
behavior and logging level).

This turns off group and user write permissions, so that on typical
production systems only root can write to it.

[jejb: fix up rejections]
Signed-off-by: Joseph Malicki <jmalicki@metacarta.com>
Acked-by: "Yang, Bo" <Bo.Yang@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] qla2xxx: Update version number to 8.02.01-k7.
Andrew Vasquez [Thu, 14 Aug 2008 04:37:02 +0000 (21:37 -0700)]
[SCSI] qla2xxx: Update version number to 8.02.01-k7.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] qla2xxx: Explicitly tear-down vports during PCI remove_one().
Andrew Vasquez [Thu, 14 Aug 2008 04:37:01 +0000 (21:37 -0700)]
[SCSI] qla2xxx: Explicitly tear-down vports during PCI remove_one().

During internal testing, we've seen issues (hangs) with the
'deferred' vport tear-down-processing typically accompanied with
the fc_remove_host() call.  This is due to the current
implementation's back-end vport handling being performed by the
physical-HA's DPC thread where premature shutdown could lead to
latent vport requests without a processor.

This should also address a problem reported by Gal Rosen
(http://marc.info/?l=linux-scsi&m=121731664417358&w=2) where the
driver would attempt to awaken a previously torn-down DPC thread
from interrupt context by implicitly calling wake_up_process()
rather than the driver's qla2xxx_wake_dpc() helper.  Rather, than
reshuffle the remove_one() device-removal code, during unload,
depend on the driver's timer to wake-up the DPC process, by
limiting wake-ups based on an 'unloading' flag.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] qla2xxx: Reference proper ha during SBR handling.
Andrew Vasquez [Thu, 14 Aug 2008 04:37:00 +0000 (21:37 -0700)]
[SCSI] qla2xxx: Reference proper ha during SBR handling.

The executing-HA of an SRB can be referenced from the sp->fcport.
Use this correct value while processing status-continuation data
and abort processing.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] qla2xxx: Set npiv_supported flag for FCoE HBAs.
Mike Hernandez [Thu, 14 Aug 2008 04:36:59 +0000 (21:36 -0700)]
[SCSI] qla2xxx: Set npiv_supported flag for FCoE HBAs.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] qla2xxx: Don't leak SG-DMA mappings while aborting commands.
Andrew Vasquez [Thu, 14 Aug 2008 04:36:58 +0000 (21:36 -0700)]
[SCSI] qla2xxx: Don't leak SG-DMA mappings while aborting commands.

Original code inadvertently cleared an SRB's 'flags' while
aborting; causing a follow-on scsi_dma_unmap() to be potentially
missed.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] qla2xxx: Correct vport-state management issues during ISP-ABORT.
Andrew Vasquez [Thu, 14 Aug 2008 04:36:57 +0000 (21:36 -0700)]
[SCSI] qla2xxx: Correct vport-state management issues during ISP-ABORT.

* Use correct 'ha' to mark a device lost from ISR.
  I/Os will always be returned on the physical-HA.
  qla2x00_mark_device_lost() should be called with the HA bound
  to the fcport.
* Mark *all* devices lost during ISP-ABORT (bighammer).

These fixes correct issues discovered locally where during
link-perturbation and heavy vport-I/O fcport/rport states would
stray and an rport's scsi-target lost (timed-out).

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] qla2xxx: Correct synchronization of software/firmware fcport states.
Andrew Vasquez [Thu, 14 Aug 2008 04:36:56 +0000 (21:36 -0700)]
[SCSI] qla2xxx: Correct synchronization of software/firmware fcport states.

Greg Wettstein (greg@enjellic.com) noted:

http://article.gmane.org/gmane.linux.scsi/43409

on a reboot of a previously recognized SCST target, the initiator
driver would be unable to re-recognize the device as a target.
It turns out that prior to the SCST software reloading and
returning it's "target-capable" abilities in the PRLI payload,
the HBA would be re-initialized as an initiator-only type port.
Since initiators typically classify themselves as an FCP-2
capable device, both software and firmware do not perform an
explicit logout during port-loss.  Unfortunately, as can be seen
by the failure case, when the port (now target-capable) returns,
firmware performs an ADISC without a follow-on PRLI, leaving
stale 'initiator-only' data in the firmware's port database.

Correct the discrepancy by performing the explicit logout during
the transport's request to terminate-rport-io, thus synchronizing
port states and ensuring a follow-on PRLI is performed.

Reported-by: Greg Wettstein <greg@enjellic.com>
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Cc: Stable Tree <stable@kernel.org>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] scsi_dh: Initialize lun_state in check_ownership()
Chandra Seetharaman [Wed, 13 Aug 2008 00:26:59 +0000 (17:26 -0700)]
[SCSI] scsi_dh: Initialize lun_state in check_ownership()

lun_state need to be initialized inside check_ownership().

Signed-off-by: Chandra Seetharaman <sekharan@us.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
15 years ago[SCSI] scsi_dh: Do not use scsilun in rdac hardware handler
Chandra Seetharaman [Wed, 13 Aug 2008 00:26:58 +0000 (17:26 -0700)]
[SCSI] scsi_dh: Do not use scsilun in rdac hardware handler

RDAC storage controller doesn't seem to use the scsilun format. It uses
only the last byte for LUN.

Signed-off-by: Chandra Seetharaman <sekharan@us.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>