dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

16792 Commits

Author SHA1 Message Date
Matt Mackall 83d7dbc409 [PATCH] Make number of IDE interfaces configurable
Make IDE_HWIFS configurable if EMBEDDED

This lets us lop as much as 16k off an x86 build.  It's a little ugly, but
it's dead simple.  Note the fix for HWIFS < 2.

Sizing interfaces dynamically unfortunately turns out to be pretty
major surgery.

add/remove: 0/1 grow/shrink: 0/11 up/down: 0/-16182 (-16182)
function                                     old     new   delta
ide_hwifs                                  16920    1692  -15228
init_irq                                    1113     750    -363
ideprobe_init                                283     138    -145
ide_pci_setup_ports                         1329    1193    -136
save_match                                    85       -     -85
ide_register_hw_with_fixup                   367     287     -80
ide_setup                                   1364    1308     -56
is_chipset_set                                40       4     -36
create_proc_ide_interfaces                   225     205     -20
init_ide_data                                 84      67     -17
ide_probe_for_cmd640x                       1198    1183     -15
ide_unregister                              1452    1451      -1

Signed-off-by: Matt Mackall <mpm@selenic.com>
Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:04:07 -07:00
Hua Zhong ce42f19137 [PATCH] IDE error handling fixes
In 2.6.15.1 I encountered some IDE crashes when unplugging IDE cables to
emulate disk errors.  Below is a patch against 2.6.16 which I think still
applies.

1.  The first BUG_ON could trigger when a PREFLUSH IO fails (it would
   fail the original barrier request which hasn't been marked REQ_STARTED
   yet).

2. the rq could have been dequeued already (same as 1).

3.  HWGROUP(drive)->rq could be NULL because of the ide_error() several
   lines earlier.

Signed-off-by: Hua Zhong <hzhong@gmail.com>
Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:04:07 -07:00
Sergei Shtylylov dc844e0591 [PATCH] IDE: always release DMA engine
Release the DMA engine for the custom mapping IDE drivers also (for
example, siimage.c does allocate it in both I/O-mapped and custom-mapped
modes).  Remove useless code from the error path of
ide_allocate_dma_engine().

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:04:07 -07:00
Sergei Shtylylov 020e322de3 [PATCH] IDE: claim extra DMA ports regardless of channel
- Claim extra DMA I/O ports regardless of what IDE channels are
  present/enabled.

- Remove extra ports handling from ide_mapped_mmio_dma() since it's not
  applicable to the custom-mapping IDE drivers.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:04:07 -07:00
Alan Cox bbb3bbdb0f [PATCH] non-libata driver for Jmicron devices
Less functional than libata this just uses the merged interface provided for
dumb legacy OS's.  This is basically a bridge for people not yet ready to use
libata for some reason or another.

Port visibility is entirely dependant on the BIOS setup.

Signed-off-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:04:07 -07:00
OGAWA Hirofumi 2c136efcf6 [PATCH] pata_hpt366: fix typo
switch(reg1 & 0x700) {
		case 5:
			info_hpt366.private_data = &hpt366_40;
			break;
		case 9:
			info_hpt366.private_data = &hpt366_25;
			break;
		default:
			info_hpt366.private_data = &hpt366_33;
			break;
	}

The above runs always default part. It should be "(reg1 & 0x700) >> 8".

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:04:06 -07:00
Corey Minyard a51f4a81e7 [PATCH] IPMI: allow user to override the kernel IPMI daemon enable
After the previous patch to disable the kernel IPMI daemon if interrupts
were available, the issue of broken hardware was raised, and a reasonable
request to add an override was mode.  So here it is.

Allow the user to force the kernel ipmi daemon on or off.  This way,
hardware with broken interrupts or users that are not concerned with
performance can turn it on or off to their liking.

[akpm@osdl.org: save 4 bytes in vmlinux]
Signed-off-by: Corey Minyard <minyard@acm.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:03:42 -07:00
Olaf Hering 873ef76bdc [PATCH] restore parport_pc probing on powermac
The last change for partport_pc did fix the common case for all PowerMacs,
but it broke the case for PCI multiport IO cards.  In fact, the config
option CONFIG_PARPORT_PC_SUPERIO=y lead to a hard crash when cups probed
the parport driver.  It enables the winbond and smsc probing.

Remove the PARPORT_BASE check again, parport_pc_find_nonpci_ports() will
take care of it.  All powerpc configs should have
CONFIG_PARPORT_PC_SUPERIO=n, the code did not find anything on the chrp
boards we tested it on.

Tested on a G4/466 with a PCI card:

0001:10:13.0 Serial controller: Timedia Technology Co Ltd PCI2S550 (Dual 16550 UART) (rev 01) (prog-if 02 [16550])
        Subsystem: Timedia Technology Co Ltd Unknown device 5079
        Control: I/O+ Mem- BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping+ SERR- FastB2B-
        Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
        Interrupt: pin A routed to IRQ 53
        Region 0: I/O ports at f2000800 [size=32]
        Region 2: I/O ports at f2000870 [size=8]
        Region 3: I/O ports at f2000860 [size=8]

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:03:41 -07:00
Alan Cox 17a4506d0e [PATCH] ISDN warning fixes
Clean up warnings in drivers/isdn by using long not int for the values
where we pass void * and cast to integer types.  The code is ok (ok passing
the stuff this way isn't pretty but the code is valid).  In all the cases I
checked out the right thing happens anyway but this removes all the
warnings.

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Jeff Garzik <jeff@garzik.org>
Acked-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:03:41 -07:00
Jeff Garzik fcc7a8c463 [PATCH] drivers/char/ip2: kill unused code, label
Kill warning:

drivers/char/ip2/ip2main.c: In function ‘ip2_loadmain’:
drivers/char/ip2/ip2main.c:782: warning: label ‘out_class’ defined but not used

This driver's initialization (and cleanup of errors during init) is
extremely convoluted, and could stand to be transformed into the standard
unwinding-goto style of error cleanup.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Acked-by: Michael H. Warfield <mhw@wittsend.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:03:41 -07:00
Jeff Garzik 397f4ebf4f [PATCH] ipmi: fix uninitialized data bug
gcc issues the following warning:

drivers/char/ipmi/ipmi_si_intf.c: In function ‘init_ipmi_si’:
drivers/char/ipmi/ipmi_si_intf.c:1729: warning: ‘data.irq’ may be used uninitialized in this function

This is indeed a bug.  data.irq is completely uninitialized in some code
paths.  Worse than that, data from a previous decode_dmi() run can easily
leak through successive calls.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Acked-by: Corey Minyard <minyard@acm.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-03 08:03:41 -07:00
Jeff Garzik 7525d4bf99 [PATCH] hp100: fix conditional compilation mess
The previous hp100 changeset attempted to kill warnings, but was only
tested on !CONFIG_ISA platforms.  The correct conditional compilation
setup involves tested CONFIG_ISA rather than just MODULE.

Fixes link on CONFIG_ISA platforms (i386) in current -git.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 19:46:18 -07:00
Linus Torvalds 829d464e60 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband:
  IB/ehca: Tweak trace message format
  IB/ehca: Fix device registration
  IB/ipath: Fix RDMA reads
  RDMA/cma: Optimize error handling
  RDMA/cma: Eliminate unnecessary remove_list
  RDMA/cma: Set status correctly on route resolution error
  RDMA/cma: Fix device removal race
  RDMA/cma: Fix leak of cm_ids in case of failures
2006-10-02 15:29:11 -07:00
Hoang-Nam Nguyen e5a0106901 IB/ehca: Tweak trace message format
Add an extra space to make things more readable.

Signed-off-by: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-10-02 14:52:17 -07:00
Hoang-Nam Nguyen 0f248d9cde IB/ehca: Fix device registration
Move the call to ib_register_device() later, since a device should not
be registered until it is completely read to be used.  This fixes
crashes that occur if an upper-layer driver such as IPoIB is loaded
before the ehca module.

Signed-off-by: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-10-02 14:52:17 -07:00
Ralph Campbell 13b18c8617 IB/ipath: Fix RDMA reads
The PSN used to generate the request following a RDMA read was
incorrect and some state booking wasn't maintained correctly.  This
patch fixes that.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
2006-10-02 14:52:17 -07:00
Krishna Kumar 3f168d2b66 RDMA/cma: Optimize error handling
Reorganize code relating to cma_get_net_info() and rdam_create_id() to
optimize error case handling (no need to alloc memory/etc. as part of
rdma_create_id() if input parameters are wrong).

Signed-off-by: Krishna Kumar <krkumar2@in.ibm.com>
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-10-02 14:52:16 -07:00
Krishna Kumar 94de178ac6 RDMA/cma: Eliminate unnecessary remove_list
Eliminate remove_list by using list_del_init() instead during device
removal handling.

Signed-off-by: Krishna Kumar <krkumar2@in.ibm.com>
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-10-02 14:52:16 -07:00
Sean Hefty 8f0472d331 RDMA/cma: Set status correctly on route resolution error
On reporting a route error, also include the status for the error,
rather than indicating a status of 0 when an error has occurred.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-10-02 14:52:15 -07:00
Krishna Kumar 6e35aabee1 RDMA/cma: Fix device removal race
The race is as follows:

A process : cma_process_remove() calls cma_remove_id_dev(),
	    which sets id state to CMA_DEVICE_REMOVAL and
	    calls wait_event(dev_remove).

B process : cma_req_handler() had incremented dev_remove,
	    and calls cma_acquire_ib_dev() and on failure
	    calls cma_release_remove(), which does a
	    wake_up of cma_process_remove(). Then
	    cma_req_handler() calls rdma_destroy_id();

A Process : cma_remove_id_dev() gets woken and checks the
	    state of id, and since it is still (wrongly)
	    CMA_DEVICE_REMOVAL, it calls notify_user(id)
	    and if that fails, the caller - cma_process_remove()
	    calls rdma_destroy_id(id). Two processes can
	    call rdma_destroy_id(), resulting in one
	    de-referencing kfreed id_priv.

Fix is for process B to set CMA_DESTROYING in cma_req_handler()
so that process A will return instead of doing a rdma_destroy_id().

Signed-off-by: Krishna Kumar <krkumar2@in.ibm.com>
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-10-02 14:52:15 -07:00
Krishna Kumar 675a027c3d RDMA/cma: Fix leak of cm_ids in case of failures
cma_connect_ib() and cma_connect_iw() leak cm_id's in failure cases.

Signed-off-by: Krishna Kumar <krkumar2@in.ibm.com>
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-10-02 14:52:15 -07:00
Dave Jones 11dc10195a [WATCHDOG] improve machzwd detection
On a machine with no machzwd, loading the module prints out..

machzwd: MachZ ZF-Logic Watchdog driver initializing.
0xffff
machzwd: Watchdog using action = RESET

- the 0xffff printk is unnecessary
- 0xffff seems to be 'hardware not present'
- fix CodingStyle. (This driver could use some more work here)

Signed-off-by: Dave Jones <davej@redhat.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Signed-off-by: Andrew Morton <akpm@osdl.org>
2006-10-02 23:14:38 +02:00
Samuel Tardieu 795b89d207 [WATCHDOG] use ENOTTY instead of ENOIOCTLCMD in ioctl()
Return ENOTTY instead of ENOIOCTLCMD in user-visible ioctl() results

The watchdog drivers used to return ENOIOCTLCMD for bad ioctl() commands.
ENOIOCTLCMD should not be visible by the user, so use ENOTTY instead.

Signed-off-by: Samuel Tardieu <sam@rfc1149.net>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
2006-10-02 23:08:34 +02:00
Ben Dooks 25ff3780d4 [WATCHDOG] s3c24XX nowayout
If the driver is not configured for `no way out`,
then the open method should not automatically allow
the setting of allow_close to CLOSE_STATE_ALLOW.

The setting of allow_close nullifies the use of
the magic close via the write path. It means that
in the default state, the watchdog will shut-down
even if the magic close has not been issued.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2006-10-02 23:07:18 +02:00
Vitaly Wool 65a64ec3b4 [WATCHDOG] pnx4008: add cpu_relax()
Added cpu_relax as suggested by Alan Cox.

Signed-off-by: Vitaly Wool <vitalywool@gmail.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2006-10-02 23:05:38 +02:00
Wim Van Sebroeck 99d2853ac9 [WATCHDOG] pnx4008_wdt.c - spinlock fixes.
Add io spinlocks to prevent possible race
conditions between start and stop operations
that are issued from different child processes
where the master process opened /dev/watchdog.

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2006-10-02 23:05:28 +02:00
Wim Van Sebroeck f676449785 [WATCHDOG] pnx4008_wdt.c - remove patch
Change remove code so that we first detach
the driver from userspace, then clean up the
clock and then clean up the memory we allocated.

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2006-10-02 23:05:16 +02:00
Wim Van Sebroeck 2898172708 [WATCHDOG] pnx4008_wdt.c - nowayout patch
Change nowayout to: WATCHDOG_NOWAYOUT as defined
in include/linux/watchdog.h .

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2006-10-02 23:05:06 +02:00
Vitaly Wool 9325fa3615 [WATCHDOG] pnx4008: add watchdog support
Add watchdog support for Philips PNX4008 ARM board inlined.

Signed-off-by: Vitaly Wool <vitalywool@gmail.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2006-10-02 23:02:37 +02:00
Jiri Slaby 92dd9994c3 [WATCHDOG] i8xx_tco remove pci_find_device.
Use refcounting for pci device obtaining.
Use PCI_DEVICE macro.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Cc: Andrew Morton <akpm@osdl.org>
2006-10-02 22:56:20 +02:00
Jiri Slaby 02be2ee9e0 [WATCHDOG] alim remove pci_find_device
Convert pci_find_device to pci_get_device + pci_dev_put
in alim watchdog cards' drivers (refcounting).

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Signed-off-by: Andrew Morton <akpm@osdl.org>
2006-10-02 22:55:51 +02:00
Linus Torvalds 95f3eff699 Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6: (37 commits)
  [netdrvr] hp100: encapsulate all non-module code
  drivers/net/wireless/{airo,ipw2100}: fix error handling bugs
  [netdrvr] phy: Fix bugs in error handling
  [PATCH] spidernet: Use pci_dma_mapping_error()
  [PATCH] sky2: version 1.9
  [PATCH] sky2: fragmented receive for large MTU
  [PATCH] sky2: use netif_tx_lock instead of LLTX
  [PATCH] sky2: incremental transmit completion
  [PATCH] sky2: name irq after eth for irqbalance
  [PATCH] sky2: workarounds for some 88e806x chips
  [PATCH] sky2: use standard pci register capabilties for error register
  [PATCH] sky2: gigabit full duplex negotiation
  e100, e1000, ixgb: increment version numbers
  ixgb: convert to netdev_priv(netdev)
  ixgb: combine more rx descriptors to improve performance
  e1000: possible memory leak in e1000_set_ringparam
  e1000: Janitor: Use #defined values for literals
  e1000: don't strip vlan ID if 8021q claims it
  e1000: rework polarity, NVM, eeprom code and fixes.
  e1000: driver state fixes (race fix)
  ...
2006-10-02 08:56:58 -07:00
Linus Torvalds 3e04767a46 Merge git://git.infradead.org/mtd-2.6
* git://git.infradead.org/mtd-2.6:
  [MTD] Cleanup of 'ioremap balanced with iounmap for drivers/mtd subsystem'
  [MTD] fix nftl_write warning
  [MTD] fix printk warning
  [MTD ONENAND] Check OneNAND lock scheme & all block unlock command support
  [MTD ONENAND] Remove unused MTD_ONENAND_SYNC_READ configuration
  [MTD ONENAND] Fix OneNAND probe
  [MTD NAND] Provide prototype for newly-exported nand_wait_ready()
  [MTD] Remove #ifndef __KERNEL__ hack in <mtd/mtd-abi.h>
  [MTD NAND] Allow override of page read and write functions.
  [MTD NAND] Allocate chip->buffers separately to allow it to be overridden
  [MTD NAND] Split nand_scan() into two parts; allow board driver to intervene
  [MTD NAND] Export nand_wait_ready() for use by board drivers
2006-10-02 08:22:17 -07:00
Linus Torvalds a12f66fccf Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (35 commits)
  Input: wistron - add support for Acer TravelMate 2424NWXCi
  Input: wistron - fix setting up special buttons
  Input: add KEY_BLUETOOTH and KEY_WLAN definitions
  Input: add new BUS_VIRTUAL bus type
  Input: add driver for stowaway serial keyboards
  Input: make input_register_handler() return error codes
  Input: remove cruft that was needed for transition to sysfs
  Input: fix input module refcounting
  Input: constify input core
  Input: libps2 - rearrange exports
  Input: atkbd - support Microsoft Natural Elite Pro keyboards
  Input: i8042 - disable MUX mode on Toshiba Equium A110
  Input: i8042 - get rid of polling timer
  Input: send key up events at disconnect
  Input: constify psmouse driver
  Input: i8042 - add Amoi to the MUX blacklist
  Input: logips2pp - add sugnature 56 (Cordless MouseMan Wheel), cleanup
  Input: add driver for Touchwin serial touchscreens
  Input: add driver for Touchright serial touchscreens
  Input: add driver for Penmount serial touchscreens
  ...
2006-10-02 08:20:33 -07:00
Cedric Le Goater 9ec52099e4 [PATCH] replace cad_pid by a struct pid
There are a few places in the kernel where the init task is signaled.  The
ctrl+alt+del sequence is one them.  It kills a task, usually init, using a
cached pid (cad_pid).

This patch replaces the pid_t by a struct pid to avoid pid wrap around
problem.  The struct pid is initialized at boot time in init() and can be
modified through systctl with

	/proc/sys/kernel/cad_pid

[ I haven't found any distro using it ? ]

It also introduces a small helper routine kill_cad_pid() which is used
where it seemed ok to use cad_pid instead of pid 1.

[akpm@osdl.org: cleanups, build fix]
Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Cc: Eric W. Biederman <ebiederm@xmission.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:25 -07:00
Arnd Bergmann 135ab6ec8f [PATCH] remove remaining errno and __KERNEL_SYSCALLS__ references
The last in-kernel user of errno is gone, so we should remove the definition
and everything referring to it.  This also removes the now-unused lib/execve.c
file that was introduced earlier.

Also remove every trace of __KERNEL_SYSCALLS__ that still remained in the
kernel.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: Andi Kleen <ak@muc.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Ian Molton <spyro@f2s.com>
Cc: Mikael Starvik <starvik@axis.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
Cc: Richard Curnow <rc@rc0.org.uk>
Cc: William Lee Irwin III <wli@holomorphy.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
Cc: Chris Zankel <chris@zankel.net>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:23 -07:00
Arnd Bergmann 3db03b4afb [PATCH] rename the provided execve functions to kernel_execve
Some architectures provide an execve function that does not set errno, but
instead returns the result code directly.  Rename these to kernel_execve to
get the right semantics there.  Moreover, there is no reasone for any of these
architectures to still provide __KERNEL_SYSCALLS__ or _syscallN macros, so
remove these right away.

[akpm@osdl.org: build fix]
[bunk@stusta.de: build fix]
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: Andi Kleen <ak@muc.de>
Acked-by: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Ian Molton <spyro@f2s.com>
Cc: Mikael Starvik <starvik@axis.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
Cc: Richard Curnow <rc@rc0.org.uk>
Cc: William Lee Irwin III <wli@holomorphy.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
Cc: Chris Zankel <chris@zankel.net>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Cc: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:23 -07:00
Serge E. Hallyn 96b644bdec [PATCH] namespaces: utsname: use init_utsname when appropriate
In some places, particularly drivers and __init code, the init utsns is the
appropriate one to use.  This patch replaces those with a the init_utsname
helper.

Changes: Removed several uses of init_utsname().  Hope I picked all the
	right ones in net/ipv4/ipconfig.c.  These are now changed to
	utsname() (the per-process namespace utsname) in the previous
	patch (2/7)

[akpm@osdl.org: CIFS fix]
Signed-off-by: Serge E. Hallyn <serue@us.ibm.com>
Cc: Kirill Korotaev <dev@openvz.org>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Herbert Poetzl <herbert@13thfloor.at>
Cc: Andrey Savochkin <saw@sw.ru>
Cc: Serge Hallyn <serue@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:21 -07:00
Serge E. Hallyn e9ff3990f0 [PATCH] namespaces: utsname: switch to using uts namespaces
Replace references to system_utsname to the per-process uts namespace
where appropriate.  This includes things like uname.

Changes: Per Eric Biederman's comments, use the per-process uts namespace
	for ELF_PLATFORM, sunrpc, and parts of net/ipv4/ipconfig.c

[jdike@addtoit.com: UML fix]
[clg@fr.ibm.com: cleanup]
[akpm@osdl.org: build fix]
Signed-off-by: Serge E. Hallyn <serue@us.ibm.com>
Cc: Kirill Korotaev <dev@openvz.org>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Herbert Poetzl <herbert@13thfloor.at>
Cc: Andrey Savochkin <saw@sw.ru>
Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Cc: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:21 -07:00
Andrew Morton ca8af48676 [PATCH] isdn: work around excessive udelay()
As reported in http://bugzilla.kernel.org/show_bug.cgi?id=6970, ISDN can issue
excessively-long udelays, which triggers a build-time error on ARM.

This is very sucky of ISDN, but I doubt if anyone is going to suddenly fix it.
So change the macro to do the microsecond counting itself.

Cc: <tch@wpkg.org>
Cc: Karsten Keil <kkeil@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:16 -07:00
Tilman Schmidt fd0fbcc27f [PATCH] isdn4linux: Gigaset driver: fix __must_check warning
This patch to the Siemens Gigaset driver fixes the compile warning
"ignoring return value of 'class_device_create_file', declared with
attribute warn_unused_result" appearing with CONFIG_ENABLE_MUST_CHECK=y in
release 2.6.18-rc1-mm1.

Signed-off-by: Tilman Schmidt <tilman@imap.cc>
Acked-by: Hansjoerg Lipp <hjlipp@web.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:16 -07:00
Ankita Garg 8bb31b9d53 [PATCH] Linux Kernel Dump Test Module
A simple module to test Linux Kernel Dump mechanism.  This module uses
jprobes to install/activate pre-defined crash points.  At different crash
points, various types of crashing scenarios are created like a BUG(),
panic(), exception, recursive loop and stack overflow.  The user can
activate a crash point with specific type by providing parameters at the
time of module insertion.  Please see the file header for usage
information.  The module is based on the Linux Kernel Dump Test Tool by
Fernando <http://lkdtt.sourceforge.net>.

This module could be merged with mainline. Jprobes is used here so that the
context in which crash point is hit, could be maintained. This implements
all the crash points as done by LKDTT except the one in the middle of
tasklet_action().

Signed-off-by: Ankita Garg <ankita@in.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:16 -07:00
Cedric Le Goater 782237a241 [PATCH] s390: update fs3270 to use a struct pid
Replaces the pid_t value with a struct pid to avoid pid wrap around
problems.

Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Acked-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:15 -07:00
Eric W. Biederman 2425c08b37 [PATCH] usb: fixup usb so it uses struct pid
The problem with remembering a user space process by its pid is that it is
possible that the process will exit, pid wrap around will occur.
Converting to a struct pid avoid that problem, and paves the way for
implementing a pid namespace.

Also since usb is the only user of kill_proc_info_as_uid rename
kill_proc_info_as_uid to kill_pid_info_as_uid and have the new version take
a struct pid.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:15 -07:00
Jeff Dike b68e31d0eb [PATCH] const struct tty_operations
As part of an SMP cleanliness pass over UML, I consted a bunch of
structures in order to not have to document their locking.  One of these
structures was a struct tty_operations.  In order to const it in UML
without introducing compiler complaints, the declaration of
tty_set_operations needs to be changed, and then all of its callers need to
be fixed.

This patch declares all struct tty_operations in the tree as const.  In all
cases, they are static and used only as input to tty_set_operations.  As an
extra check, I ran an i386 allyesconfig build which produced no extra
warnings.

53 drivers are affected.  I checked the history of a bunch of them, and in
most cases, there have been only a handful of maintenance changes in the
last six months.  serial_core.c was the busiest one that I looked at.

Signed-off-by: Jeff Dike <jdike@addtoit.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:14 -07:00
Eric W. Biederman 609d7fa956 [PATCH] file: modify struct fown_struct to use a struct pid
File handles can be requested to send sigio and sigurg to processes.  By
tracking the destination processes using struct pid instead of pid_t we make
the interface safe from all potential pid wrap around problems.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:14 -07:00
Eric W. Biederman bde0d2c98b [PATCH] vt: Make vt_pid a struct pid (making it pid wrap around safe).
I took a good hard look at the locking and it appears the locking on vt_pid
is the console semaphore.  Every modified path is called under the console
semaphore except reset_vc when it is called from fn_SAK or do_SAK both of
which appear to be in interrupt context.  In addition I need to be careful
because in the presence of an oops the console_sem may be arbitrarily
dropped.

Which leads me to conclude the current locking is inadequate for my needs.

Given the weird cases we could hit because of oops printing instead of
introducing an extra spin lock to protect the data and keep the pid to
signal and the signal to send in sync, I have opted to use xchg on just the
struct pid * pointer instead.

Due to console_sem we will stay in sync between vt_pid and vt_mode except
for a small window during a SAK, or oops handling.  SAK handling should
kill any user space process that care, and oops handling we are broken
anyway.  Besides the worst that can happen is that I try to send the wrong
signal.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Cc: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:14 -07:00
Eric W. Biederman 81af8d67d4 [PATCH] vt: rework the console spawning variables
This is such a rare path it took me a while to figure out how to test
this after soring out the locking.

This patch does several things.
- The variables used are moved into a structure and declared in vt_kern.h
- A spinlock is added so we don't have SMP races updating the values.
- Instead of raw pid_t value a struct_pid is used to guard against
  pid wrap around issues, if the daemon to spawn a new console dies.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Cc: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02 07:57:13 -07:00
Richard Purdie d14b272bc6 [ARM] 3848/1: pxafb: Add option of fixing video modes and spitz QVGA mode support
Add the ability to have pxafb use only certain fixed video modes
(selected on a per platform basis). This is useful on production
hardware such as the Zaurus cxx00 models where the valid modes are
known in advance and any other modes could result in hardware damage.

Following this, add support for the cxx00 QVGA mode. Mode information
is passed to the lcd_power call to allowing the panel drivers to
configure the display hardware accordingly (corgi_lcd already contains
the functionality for the cxx00 panel).

This mirrors the setup already used by w100fb.

Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-02 13:33:37 +01:00
David Woodhouse 07bd1c4a82 [POWERPC] Use check_legacy_ioport() for ISAPnP
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-10-02 20:27:36 +10:00
Olaf Hering 61e37ca22b [POWERPC] Avoid NULL pointer in gpio1_interrupt
gpio1_interrupt() may dereference a NULL pointer if ioremap() fails.
But, maybe no gpio interrupt happens in the first place?

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-10-02 20:27:26 +10:00
Amol Lad 76a5027c37 [MTD] Cleanup of 'ioremap balanced with iounmap for drivers/mtd subsystem'
Updated version of patch, in response to comments from Francois Romieu
<romieu@fr.zoreil.com>

Remove gratuitous casts from iounmap and initialisation of variables.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2006-10-02 09:48:23 +01:00
Frederik Deweerdt 553a801208 [MTD] fix nftl_write warning
Building 2.6.18-mm2 issues the following warning if CONFIG_NFTL_RW is not set:

  CC [M]  drivers/mtd/nftlcore.o
drivers/mtd/nftlcore.c:183: warning: 'nftl_write' defined but not used
The following patch only compiles nftl_write if CONFIG_NFTL_RW is set.

Signed-off-by: Frederik Deweerdt <frederik.deweerdt@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2006-10-02 09:42:25 +01:00
Ashutosh Naik bb0885900d Input: wistron - add support for Acer TravelMate 2424NWXCi
The key mappings are the same as the older Acer TravelMate 240.

Signed-off-by: Ashutosh Naik <ashutosh.naik@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2006-10-01 22:07:14 -04:00
Reiner Herrmann cde45f19ca Input: wistron - fix setting up special buttons
If either wifi or bluetooth button has been detected, the code
would break off the loop. But there are laptops that have both
types of buttons, so the loop has to continue checking.

Signed-off-by: Reiner Herrmann <reiner@reiner-h.de>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2006-10-01 21:58:51 -04:00
Matthew Garrett 75fde2eddc [SERIAL] add PNP IDs for FPI based touchscreens
The Compaq TC1000 and Fujitsu Stylistic range of tablet machines use
touchscreens from FPI. These are implemented as serial interfaces,
generally exposed in the ACPIPNP information on the system. This patch
adds them to the 8250_pnp driver tables, avoiding the need to mess
around with setserial to set them up.

I haven't been able to confirm what FUJ02B5, FUJ02BA and FUJ02BB are.
FUJ02B1 refers to the controller for the system hotkeys. FUJ02BC appears
to be the last in the range - after this, they moved to Wacom-based
systems.

Signed-off-by: Matthew Garrett <mjg59@srcf.ucam.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 21:27:15 +01:00
Linus Torvalds d834c16516 pccard_store_cis: fix wrong error handling
The test for the error from pcmcia_replace_cis() was incorrect, and
would always trigger (because if an error didn't happen, the "ret" value
would not be zero, it would be the passed-in count).

Reported and debugged by Fabrice Bellet <fabrice@bellet.info>

Rather than just fix the single broken test, make the code in question
use an understandable code-sequence instead, fixing the whole function
to be more readable.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 13:17:44 -07:00
Dave Jones e480af09c4 [SERIAL] tickle NMI watchdog on serial output.
Serial is _slow_ sometimes. So slow, that the NMI watchdog kicks in.

NMI Watchdog detected LOCKUP on CPU2CPU 2
Modules linked in: loop usb_storage md5 ipv6 parport_pc lp parport autofs4 i2c_dev i2c_core rfcomm l2cap bluetooth sunrpc pcdPid: 3138, comm: gpm Not tainted 2.6.11-1.1290_FC4smp
RIP: 0010:[<ffffffff80273b8a>] <ffffffff80273b8a>{serial_in+106}
RSP: 0018:ffff81003afc3d50  EFLAGS: 00000002
RAX: 0000000000000020 RBX: 0000000000000020 RCX: 0000000000000000
RDX: 00000000000003fd RSI: 0000000000000005 RDI: ffffffff804dcd60
RBP: 00000000000024fc R08: 000000000000000a R09: 0000000000000033
R10: ffff81001beb7c20 R11: 0000000000000020 R12: ffffffff804dcd60
R13: ffffffff804ade76 R14: 000000000000002b R15: 000000000000002c
FS:  00002aaaaaac4920(0000) GS:ffffffff804fca00(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
CR2: 00002aaaaabcb000 CR3: 000000003c0d0000 CR4: 00000000000006e0
Process gpm (pid: 3138, threadinfo ffff81003afc2000, task ffff81003eb63780)
Stack: ffffffff80275f2e 0000000000000000 ffffffff80448380 0000000000007d6b
       000000000000002c fffffffffffffbbf 0000000000000292 0000000000008000
       ffffffff80138e8c 0000000000007d97
Call Trace:<ffffffff80275f2e>{serial8250_console_write+270} <ffffffff80138e8c>{__call_console_drivers+76}
       <ffffffff8013914b>{release_console_sem+315} <ffffffff80260325>{con_open+149}
       <ffffffff80254e99>{tty_open+537} <ffffffff80192713>{chrdev_open+387}
       <ffffffff80188824>{dentry_open+260} <ffffffff80188994>{filp_open+68}
       <ffffffff80187b73>{get_unused_fd+227} <ffffffff80188a6c>{sys_open+76}
       <ffffffff8010ebc6>{tracesys+209}

Code: 0f b6 c0 c3 66 90 41 57 49 89 f7 41 56 41 be 00 01 00 00 41
console shuts up ...

I initially did the patch below a year ago for the Fedora kernel, and have
been keeping it up to date since.  I recently got the same thing happening
on a vanilla kernel, so figured it was time to repost this.

Signed-off-by: Dave Jones <davej@redhat.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 20:03:19 +01:00
Andrew Morton 4e9011d50d [PATCH] rtc-sysfs fix
It's not clear how this thinko got through..

Cc: Olaf Hering <olaf@aepfle.de>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <alessandro.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 10:39:01 -07:00
Jeff Garzik 9a29230825 [MTD] fix printk warning
gcc spits out this warning:

drivers/mtd/mtd_blkdevs.c: In function ‘do_blktrans_request’:
drivers/mtd/mtd_blkdevs.c:72: warning: format ‘%ld’ expects type ‘long int’, but argument 2 has type ‘unsigned int’

This could be fixed any number of ways, including use of BUG().
rq_data_dir() only returns 0 or 1, so this entire case is superfluous.
I did the most simple fix.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2006-10-01 17:57:26 +01:00
David Woodhouse 8a84fc15ae Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Manually resolve conflict in include/mtd/Kbuild

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2006-10-01 17:55:53 +01:00
Russell King a6b93a9085 [SERIAL] Fix oops when removing suspended serial port
A serial card might have been removed when the system is resumed.
This results in a suspended port being shut down, which results in
the ports shutdown method being called twice in a row.  This causes
BUGs.  Avoid this by tracking the suspended state separately from
the initialised state.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:17:40 +01:00
Russell King fe59d5372a [SERIAL] Fix resume handling bug
Unfortunately, pcmcia_dev_present() returns false when a device is
suspended, so checking this on resume does not work too well.  Omit
this test.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:14:07 +01:00
Russell King bcf5111a58 [SERIAL] Remove wrong asm/serial.h inclusions
asm/serial.h is supposed to contain the definitions for the architecture
specific 8250 ports for the 8250 driver.  It may also define BASE_BAUD,
but this is the base baud for the architecture specific ports _only_.

Therefore, nothing other than the 8250 driver should be including this
header file.  In order to move towards this goal, here is a patch which
removes some of the more obvious incorrect includes of the file.

Acked-by: Paul Fulghum <paulkf@microgate.com>
Acked-by: Tony Luck <tony.luck@intel.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Acked-by: David Howells <dhowells@redhat.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:09:16 +01:00
Alexey Dobriyan 1d5e799663 [SERIAL] CONFIG_PM=n slim: drivers/serial/8250_pci.c
Remove some code which is unneeded if CONFIG_PM=n.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:07:08 +01:00
Jonathan McDowell 255341c6fd [SERIAL] OMAP1510 serial fix for 115200 baud
The patch below is necessary for 115200 baud on an OMAP1510 internal UART.
It's been in the linux-omap tree for some time and with it applied to a
vanilla Linus git tree the serial console on the Amstrad Delta (which is
OMAP1510 based and whose initial bootloader runs at 115200) works fine (it
doesn't without it).

Signed-off-by: Jonathan McDowell <noodles@earth.li>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:07:06 +01:00
Ram Gupta 80e3c2b659 [SERIAL] returning proper error from serial core driver
Fix the issue of returning 0 even in case of error from uart_set_info
function.  Now it returns the error EBUSY when it can not set new port.

Signed-off-by: Ram Gupta <r.gupta@astronautics.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:07:00 +01:00
Sergei Shtylyov 6c6a2334a1 [SERIAL] Make uart_line_info() correctly tell MMIO from I/O port
/proc/tty/driver/serial incorrectly claims that UARTs having iotype of
UPIO_MEM32, UPIO_AU, or UPIO_TSI are I/O mapped.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:57 +01:00
Sergei Shtylyov a4b775735c [SERIAL] suspend/resume handlers don't have level arg anymore
8250.c and serial_txx9.c port suspend/resume handler still have this obsolete
argument documented...

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:54 +01:00
Sergei Shtylyov 0b30d668a2 [SERIAL] 8250 resourse management fixes
I think register ranges obviously need to be claimed/released for all UARTs
including those with UPIO_MEM32 and UPIO_TSI iotype.

Also, serial8250_request_rsa_resources() returns false positives with
UPIO_MEM32, UPIO_AU, and UPIO_TSI iotype -- I don't think this makes any sense.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:49 +01:00
Russell King f3d106881b [SERIAL] serial_cs: Add quirk for brainboxes 2-port RS232 card
Mauro Ziliani reports that this card has a higher clock rate.
Rather than tweak the 8250 driver to handle this, add a quirk to
pass the correct clock rate to the driver.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:45 +01:00
Russell King 20f130495c [SERIAL] serial_cs: handle Nokia multi->single port bodge via config quirk
According to the existing code, Nokia only make single-port cards,
but are detected as multi-port cards.  Handle this in roughly the
same way via the config quirk - forcing it to be a real single port
card (info->multi=0) changes the way we allocate the IO memory,
which might stop the card working.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:41 +01:00
Russell King efd92dfaad [SERIAL] serial_cs: add configuration quirk
Add a quirk primerily to handle tweaks to the link->conf structure,
eg as required for Socket cards.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:37 +01:00
Russell King 7ef057fa70 [SERIAL] serial_cs: Convert Oxford 950 / Possio GCC wakeup quirk
Move the Oxford Semi OX950 / Possio GCC wakeup handling to a quirk
wakeup handler.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:34 +01:00
Russell King eee3a883ce [SERIAL] serial_cs: convert IBM post-init handling to a quirk
Move IBM quirk handling into its own quirk entry.  Note that doing
quirk handling after we've registered the ports is racy, but since
I don't know if moving this will have an undesired effect, it's
probably better to leave where it is.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:30 +01:00
Russell King a8244b564c [SERIAL] serial_cs: allow wildcarded quirks
Some quirks we will introduce next apply to (eg) all cards of one
manufacturer.  Therefore, we need a way to list these in the quirk
table - use ~0 - this is not a possible device ID value.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:27 +01:00
Russell King 1fbbac4bcb [SERIAL] serial_cs: convert multi-port table to quirk table
- rename multi_id table to serial_quirk / quirks[]
- use named initialisers
- store a pointer to the quirk table in the serial_info structure
  so we can use the quirk table entry later.
- apply multi-port quirk after the multi-port guessing code,
  but only if it's != -1.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:23 +01:00
Russell King 43549ad7a7 [SERIAL] serial_cs: Use clean up multiport card detection
- Use ARRAY_SIZE() instead of home grown based version.
- use parse->manfid.card rather than le16_to_cpu(buf[1]) -
  manfid.card is already converted to this format.
- use info->prodid in subsequent tests rather than
  parse->manfid.card.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:20 +01:00
Russell King de6cc84f72 [SERIAL] Remove m32r_sio dependency on asm/serial.h
m32r_sio re-uses a custom defined BASE_BAUD from asm/serial.h,
and replaces SERIAL_PORT_DFNS with its own driver private copy.
Since asm/serial.h is supposed to define 8250-based ports using
these symbols, this isn't a sane idea.

Hence, eliminate asm/serial.h from m32r_sio.c.

Acked-by: Hirokazu Takata <takata@linux-m32r.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2006-10-01 17:06:03 +01:00
Jeff Garzik 15a7c3bbe3 [libata] pata_artop: kill gcc warning
gcc complains thusly:

drivers/ata/pata_artop.c: In function ‘artop_init_one’:
drivers/ata/pata_artop.c:429: warning: ‘info’ may be used uninitialized in this function

While this warning is indeed bogus, even with improved static analysis
and value range propagation, gcc will probably never be able to detect
this.

Add a BUG_ON() to trap invalid driver_data entries in the PCI table.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-10-01 10:38:22 -04:00
Jeff Garzik 2c81fbc4cf [netdrvr] hp100: encapsulate all non-module code
The previous '#ifndef MODULE' block did not cover all the
static-build-only code.  Now it does.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-10-01 07:32:20 -04:00
Jeff Garzik de897881e4 drivers/net/wireless/{airo,ipw2100}: fix error handling bugs
airo:
* fix oops, if !CONFIG_PROC_FS (create_proc_entry always returns NULL)

* handle pci_register_driver() failure.  if it fails, we really do
  want to exit, rather than (as a comment indicates) return success
  because-we-are-a-library.

* #if 0 have_isa_dev variable, which is assigned a value but never used

ipw2100:
* handle sysfs_create_group() failure

* handle driver_create_file() failure

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-10-01 07:31:09 -04:00
Jeff Garzik b7a00ecd55 [netdrvr] phy: Fix bugs in error handling
The recent __must_check stuff flagged some error handling bugs.

phy/fixed.c:
* handle device_bind_driver() failure

phy/phy_device.c:
* handle device_bind_driver() failure
* release rwsem upon failure

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-10-01 07:27:46 -04:00
Linus Torvalds 82965addad Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/agpgart
* master.kernel.org:/pub/scm/linux/kernel/git/davej/agpgart:
  [AGPGART] printk fixups.
  [AGPGART] Use pci_get_slot not pci_find_slot
2006-10-01 00:40:55 -07:00
Linus Torvalds f0b364a13d Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq
* master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq:
  [CPUFREQ] Make acpi-cpufreq unsticky again.
  [CPUFREQ] longhaul: remove duplicated code.
  [CPUFREQ] Longhaul - Disable arbiter CLE266
  [CPUFREQ] Fix section mismatch warning
  [CPUFREQ] Fix cut-n-paste bug in suspend printk
2006-10-01 00:40:35 -07:00
Amol Lad 65da4d81f4 [PATCH] ioremap balanced with iounmap for drivers/serial/sunsu.c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: David S. Miller <davem@sunset.davemloft.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Amol Lad af907dc8cd [PATCH] ioremap balanced with iounmap for drivers/serial/mux.c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Amol Lad a141a04330 [PATCH] ioremap balanced with iounmap for drivers/serial/mpsc.c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Mark A. Greer <mgreer@mvista.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Amol Lad be618f550c [PATCH] ioremap balanced with iounmap for drivers/serial/mpc52xx_uart.c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Amol Lad 6257b3bdfd [PATCH] ioremap balanced with iounmap for drivers/serial/ip22zilog.c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Amol Lad f466413261 [PATCH] ioremap balanced with iounmap for drivers/serial/ioc4_serial.c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Brent Casavant <bcasavan@sgi.com>
Cc: Pat Gefre <pfg@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Amol Lad d9964d5c90 [PATCH] ioremap balanced with iounmap for drivers/serial/8250_gsc.c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Amol Lad f12ad7d59a [PATCH] ioremap balanced with iounmap for drivers/serial/8250_acorn,c
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:32 -07:00
Dave Hansen d8c76e6f45 [PATCH] r/o bind mount prepwork: inc_nlink() helper
This is mostly included for parity with dec_nlink(), where we will have some
more hooks.  This one should stay pretty darn straightforward for now.

Signed-off-by: Dave Hansen <haveblue@us.ibm.com>
Acked-by: Christoph Hellwig <hch@lst.de>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:30 -07:00
Dave Hansen 9a53c3a783 [PATCH] r/o bind mounts: unlink: monitor i_nlink
When a filesystem decrements i_nlink to zero, it means that a write must be
performed in order to drop the inode from the filesystem.

We're shortly going to have keep filesystems from being remounted r/o between
the time that this i_nlink decrement and that write occurs.

So, add a little helper function to do the decrements.  We'll tie into it in a
bit to note when i_nlink hits zero.

Signed-off-by: Dave Hansen <haveblue@us.ibm.com>
Acked-by: Christoph Hellwig <hch@lst.de>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:30 -07:00
Badari Pulavarty 543ade1fc9 [PATCH] Streamline generic_file_* interfaces and filemap cleanups
This patch cleans up generic_file_*_read/write() interfaces.  Christoph
Hellwig gave me the idea for this clean ups.

In a nutshell, all filesystems should set .aio_read/.aio_write methods and use
do_sync_read/ do_sync_write() as their .read/.write methods.  This allows us
to cleanup all variants of generic_file_* routines.

Final available interfaces:

generic_file_aio_read() - read handler
generic_file_aio_write() - write handler
generic_file_aio_write_nolock() - no lock write handler

__generic_file_aio_write_nolock() - internal worker routine

Signed-off-by: Badari Pulavarty <pbadari@us.ibm.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:28 -07:00
Badari Pulavarty ee0b3e671b [PATCH] Remove readv/writev methods and use aio_read/aio_write instead
This patch removes readv() and writev() methods and replaces them with
aio_read()/aio_write() methods.

Signed-off-by: Badari Pulavarty <pbadari@us.ibm.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:28 -07:00
Badari Pulavarty 027445c372 [PATCH] Vectorize aio_read/aio_write fileop methods
This patch vectorizes aio_read() and aio_write() methods to prepare for
collapsing all aio & vectored operations into one interface - which is
aio_read()/aio_write().

Signed-off-by: Badari Pulavarty <pbadari@us.ibm.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: Michael Holzheu <HOLZHEU@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:28 -07:00
Corey Minyard df3fe8defe [PATCH] ipmi: don't start kipmid if the IPMI driver can use interrupts
If the driver has interrupts available to it, there is really no reason to
have a kernel daemon push the IPMI state machine.

Note that I have experienced machines where the interrupts do not work
correctly.  This was a long time ago and hopefully things are better now.
If some machines still have broken interrupts, a blacklist will need to be
added.

Signed-off-by: Corey Minyard <minyard@acm.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:26 -07:00
David Brownell dcb9c39236 [PATCH] omap_cf works again (sync with linux-omap tree)
This syncs the omap_cf driver with the one from the linux-omap tree.  Changes
include fixing build warnings (section mismatch, unused return value) and
coping with various pcmcia core changes related to managing i/o memory and irq
resources.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
Atsushi Nemoto 391b1fe67d [PATCH] RTC: rtc-ds1553, rtc-ds1742 update
Check return value of sysfs_create_bin_file().  Fix polarity of
RTC_BATT_FLAG bit in DS1742.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
David Brownell 90b4d648f0 [PATCH] AT91rm9200 RTC can issue system wakeup events
This lets the at91rm9200 RTC alarm be a system wakeup irq, according to the
setting of /sys/devices/platform/at91_rtc/power/wakeup.  User code can set the
alarm, put the system into a low power mode, and then rely on it waking up no
later than the specified moment.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
David Brownell ff8371ac9a [PATCH] constify rtc_class_ops: update drivers
Update RTC framework so that drivers can constify their method tables, moving
them from ".data" to ".rodata".  Then update the drivers.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
David Brownell db621f174d [PATCH] RTC class: error checks
The rtc_is_valid_tm() routine needs to treat some of the fields it checks as
unsigned, to prevent wrongly accepting invalid rtc_time structs; this is the
same approach used elsewhere in the RTC code for such tests.

Conversely, rtc_proc_show() is missing one invalid-day-of-month test that
rtc_is_valid_tm() makes: there is no day zero.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
David Brownell 818a8674b0 [PATCH] RTC class uses subsys_init
This makes RTC core components use "subsys_init" instead of "module_init", as
appropriate for subsystem infrastructure.  This is mostly useful for
statically linking drivers in other parts of the tree that may provide an RTC
interface as a secondary functionality (e.g.  part of a multifunction chip);
they won't need to worry so much about drivers/Makefile link order.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Acked-by: Oleg Verych <olecom@flower.upol.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
David Brownell 9e86ecb659 [PATCH] RTC class: Kconfig improvements
Small updates to make the RTC class Kconfig text be more informative.  This
should help folk used to the drivers/char/rtc.c support, or a single RTC, be
slightly less surprised by the differences.

Also, adds a new RTC_DEBUG option to predefine DEBUG in the framework and its
drivers, while debugging.  That's getting to be a standard idiom, and it's
pretty useful.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Acked-by: Oleg Verych <olecom@flower.upol.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
Jean-Baptiste Maneyrol 1713e903c6 [PATCH] rtc driver rtc-pcf8563 century bit inversed
The century bit PCF8563_MO_C in the month register is misinterpreted.  It
is set to 1 for the 20th century and 0 for 21th, and the driver is
expecting the opposite behavior.

Acked-by: Alessandro Zummo <a.zummo@towertech.it>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
Jiri Slaby 365e02237b [PATCH] Char: specialix, kill unneeded page alloc
The driver is allocating a page but doesn't actually use it for anything.

(History from the old ->write method before Linus cleaned it up)

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:25 -07:00
Peter Zijlstra 6e9a4738c9 [PATCH] completions: lockdep annotate on stack completions
All on stack DECLARE_COMPLETIONs should be replaced by:
DECLARE_COMPLETION_ONSTACK

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Acked-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:24 -07:00
Eric Sesterhenn 397d6140e9 [PATCH] Remove unnecessary check in drivers/rtc/rtc-v3020.c
Looks like the probe function always gets a valid pdev, and checking it
after dereferencing it is pretty useless.  This patch removes the check
(cid #1365)

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: Raphael Assenat <raph@raphnet.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:24 -07:00
Soos Peter 710b8b5f43 [PATCH] hdaps: support Lenovo ThinkPad T60
Support hdaps on Lenovo ThinkPad T60.  It was tested with pivot utility
from http://www.kernel.org/pub/linux/kernel/people/rml/hdaps and it seems
to be OK.

Cc: Jean Delvare <khali@linux-fr.org>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Robert Love <rml@novell.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:24 -07:00
Eric Sesterhenn 095d030cff [PATCH] Off-by-one in drivers/char/mwave/mwavedd.c
This fixes two off by ones in the mwave driver, found
via find -iname \*.[ch] | xargs grep "> ARRAY_SIZE("

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:24 -07:00
Peter Zijlstra b2e9c7d07f [PATCH] sysrq: disable lockdep on reboot
SysRq : Emergency Sync
Emergency Sync complete
SysRq : Emergency Remount R/O
Emergency Remount complete
SysRq : Resetting
BUG: warning at kernel/lockdep.c:1816/trace_hardirqs_on() (Not tainted)

Call Trace:
 [<ffffffff8026d56d>] show_trace+0xae/0x319
 [<ffffffff8026d7ed>] dump_stack+0x15/0x17
 [<ffffffff802a68d1>] trace_hardirqs_on+0xbc/0x13d
 [<ffffffff803a8eec>] sysrq_handle_reboot+0x9/0x11
 [<ffffffff803a8f8d>] __handle_sysrq+0x99/0x130
 [<ffffffff803a903b>] handle_sysrq+0x17/0x19
 [<ffffffff803a36ee>] kbd_event+0x32e/0x57d
 [<ffffffff80401e35>] input_event+0x42d/0x45b
 [<ffffffff804063eb>] atkbd_interrupt+0x44d/0x53d
 [<ffffffff803fe5c5>] serio_interrupt+0x49/0x86
 [<ffffffff803ff2a4>] i8042_interrupt+0x202/0x21a
 [<ffffffff80210cf0>] handle_IRQ_event+0x2c/0x64
 [<ffffffff802bfd8b>] __do_IRQ+0xaf/0x114
 [<ffffffff8026ea24>] do_IRQ+0xf8/0x107
 [<ffffffff8025f886>] ret_from_intr+0x0/0xf
DWARF2 unwinder stuck at ret_from_intr+0x0/0xf
Leftover inexact backtrace:
 <IRQ> <EOI> [<ffffffff80258e36>] mwait_idle+0x3f/0x54
 [<ffffffff8024a33a>] cpu_idle+0xa2/0xc5
 [<ffffffff8026c34e>] rest_init+0x2b/0x2d
 [<ffffffff809708bc>] start_kernel+0x24a/0x24c
 [<ffffffff8097028b>] _sinittext+0x28b/0x292

Since we're shutting down anyway, don't bother being smart,
just turn the thing off.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Acked-by: Ingo Molnar <mingo@elte.hu>
Cc: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:24 -07:00
Alan Cox 74ae322181 [PATCH] cardbus: switch to ref counting/hotplug safe API
Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:23 -07:00
Alan Cox df10f4edd5 [PATCH] i2o: Switch to pci_get API
Use the safe ref-counted API for the bridge check

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Markus Lidel <Markus.Lidel@shadowconnect.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:23 -07:00
Alan Cox 1aff0ecafb [PATCH] ip2: use newer pci_get functions
This is one of a series of patches I plan to gradually trickle into the
tree which eliminates almost all remaining use of pci_find_* and lets me
build a pci_find_* free kernel for all but some obscure ISDN and SCSI
drivers.  This is important as all pci_find_* users are not hotplug safe -
even if they are not the device being plugged.

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:23 -07:00
Olaf Hering 30cbc22217 [PATCH] update legacy io handling for pmac
ppc can boot one single binary on prep, chrp and pmac boards.  ppc64 can
boot one single binary on pseries and G5 boards.  pmac has no legacy io,
probing for PC style legacy hardware (or accessing the legacy io area
regulary) may lead to a hard crash:

* add check for parport_pc, exit on pmac.  32bit chrp has no
  ->check_legacy_ioport, the probe is always called.  64bit chrp has
  check_legacy_ioport, check for a "parallel" node

* add check for isapnp, only PReP boards may have real ISA slots.  32bit
  PReP will have no ->check_legacy_ioport, the probe is always called.

* update code in i8042_platform_init.  Run ->check_legacy_ioport first,
  always call request_region.  No functional change.  Remove whitespace
  before i8042_reset init.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:23 -07:00
Corey Minyard c69c31270c [PATCH] IPMI: per-channel command registration
This patch adds the ability to register for a command per-channel in the
IPMI driver.

If your BMC supports multiple channels, incoming messages can be useful to
have the ability to register to receive commands on a specific channel
instead the current behaviour of all channels.

Signed-off-by: David Barksdale <amatus@ocgnet.org>
Signed-off-by: Corey Minyard <minyard@acm.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:23 -07:00
Pierre Ossman 643f720cea [PATCH] mmc (mainly): add "or later" clause to licence statement.
Clarify my (Pierre's) position on which GPL versions apply.  The patch only
touches the source files where I am the only major author.  The people who
have made the minor commits to the files have been contacted and have no
issues with this change.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:23 -07:00
Jiri Slaby e4e040887b [PATCH] isicom: correct firmware loading
- loading of firmware didn't fail when something went wrong (returned 0).

- pointer to frame was incremented only by sizeof(frame) excluding its
  data contents -- bad idea.

- tell the card we're ready just after checking is complete, not before.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:22 -07:00
Rolf Eike Beer 328a338f6f [PATCH] rtc: remove superfluous call to call to cdev_del()
If cdev_add() fails there is no good reason to call cdev_del().

Signed-off-by: Rolf Eike Beer <eike-kernel@sf-tec.de>
Cc: Alessandro Zummo <alessandro.zummo@towertech.it>
Cc: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:22 -07:00
Metathronius Galabant cc088d10d0 [PATCH] cciss: remove unneeded spaces in output for attached volumes
It removes the awkwards spaces after the "=" when displaying the
geometry of the attached volumes.

Before:
cciss: using DAC cycles
     blocks= 286734240 block_size= 512
     heads= 255, sectors= 32, cylinders= 35139

After:
cciss: using DAC cycles
     blocks=286734240 block_size=512
     heads=255, sectors=32, cylinders=35139

Signed-off-by: Metathronius Galabant <m.galabant@gmail.com>
Acked-by: Mike Miller <mike.miller@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:22 -07:00
Paul Fulghum a077c1a075 [PATCH] synclink_gt: increase max devices
Increase maximum number of devices.

Signed-off-by: Paul Fulghum <paulkf@microgate.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:22 -07:00
Paul Fulghum cb10dc9ac7 [PATCH] synclink_gt: add bisync and monosync modes
Add bisync and monosync serial protocol support to the synclink_gt driver.

Signed-off-by: Paul Fulghum <paulkf@microgate.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:22 -07:00
Paul Collins e3e5fc91d9 [PATCH] leds: turn LED off when changing triggers
I was playing with LED triggers when I noticed that changing from heartbeat
(or ide-disk) to "none" at the right moment would leave the LED stuck on.
This is easy to reproduce by doing "find / >/dev/null" with the ide-disk
trigger enabled and then switching to "none".

Here is a patch that fixes the problem by explicitly turning the LED off
after removing the existing trigger.

Signed-off-by: Paul Collins <paul@ondioline.org>
Acked-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:21 -07:00
Alexey Dobriyan c53421b18f [PATCH] proper flags type of spin_lock_irqsave()
Convert various spin_lock_irqsave() callers to correctly use `unsigned long'.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
Cc: "Luck, Tony" <tony.luck@intel.com>
Acked-by: Kyle McMartin <kyle@mcmartin.ca>
Cc: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:21 -07:00
Josef 'Jeff' Sipek 4636d93b46 [PATCH] EICON ISDN: Removed unused definitions for OS_SEEK_*
EICON ISDN: Removed unused definitions for OS_SEEK_*

Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
Cc: Karsten Keil <kkeil@suse.de>
Acked-by: Armin Schindler <armin@melware.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:21 -07:00
Josef 'Jeff' Sipek 930ff81c59 [PATCH] MBCS: Use SEEK_{SET, CUR, END} instead of hardcoded values
MBCS: Use SEEK_{SET,CUR,END} instead of hardcoded values

Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:21 -07:00
Alan Cox edceeaf50b [PATCH] via* : switch to pci_get_device refcounted PCI API
If we can clean up these remainders we can finally delete pci_find_*

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Greg KH <greg@kroah.com>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:21 -07:00
Alan Cox 40cddf2cbd [PATCH] sis5513: Switch to pci refcounting
Mirrors the drivers/ata version, hold a reference to the host bridge while we
are doing setup.

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:20 -07:00
Alan Cox 970a61363b [PATCH] serverworks: Switch to pci refcounted interfaces
As we don't support hotplug we end up leaking an isa_dev reference which if
unload was ever added we would drop at the end of unloading.  This is fine
because we do genuinely need the isa_dev pointer until unload.

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:20 -07:00
Alan Cox 1424e50448 [PATCH] piix: Use refcounted interface when searching for a 450NX
Simple conversion

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:20 -07:00
Alan Cox c7bce3097c [PATCH] serial: Fix up offenders peering at baud bits directly
Stop some other people peering into the baud bits on their own and make
them use the tty_get_baud_rate() helper as a preperation for the move to
the new termios.  Corrected dependancy previous one had on new termios
structs

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:20 -07:00
Mike Miller (OS Dev) 00988a3514 [PATCH] cciss: support for >2TB logical volumes
Add support for logical volumes >2TB.  All SAS/SATA controllers support
large volumes.

Signed-off-by: Mike Miller <mike.miller@hp.com>
Cc: Jens Axboe <axboe@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:20 -07:00
Arjan van de Ven 5c87579e65 [PATCH] maximum latency tracking infrastructure
Add infrastructure to track "maximum allowable latency" for power saving
policies.

The reason for adding this infrastructure is that power management in the
idle loop needs to make a tradeoff between latency and power savings
(deeper power save modes have a longer latency to running code again).  The
code that today makes this tradeoff just does a rather simple algorithm;
however this is not good enough: There are devices and use cases where a
lower latency is required than that the higher power saving states provide.
 An example would be audio playback, but another example is the ipw2100
wireless driver that right now has a very direct and ugly acpi hook to
disable some higher power states randomly when it gets certain types of
error.

The proposed solution is to have an interface where drivers can

* announce the maximum latency (in microseconds) that they can deal with
* modify this latency
* give up their constraint

and a function where the code that decides on power saving strategy can
query the current global desired maximum.

This patch has a user of each side: on the consumer side, ACPI is patched
to use this, on the producer side the ipw2100 driver is patched.

A generic maximum latency is also registered of 2 timer ticks (more and you
lose accurate time tracking after all).

While the existing users of the patch are x86 specific, the infrastructure
is not.  I'd like to ask the arch maintainers of other architectures if the
infrastructure is generic enough for their use (assuming the architecture
has such a tradeoff as concept at all), and the sound/multimedia driver
owners to look at the driver facing API to see if this is something they
can use.

[akpm@osdl.org: cleanups]
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Jesse Barnes <jesse.barnes@intel.com>
Cc: "Brown, Len" <len.brown@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:19 -07:00
Richard Knutsson 6e21828743 [PATCH] Generic boolean
This patch defines:
* a generic boolean-type, named 'bool'
* aliases to 0 and 1, named 'false' and 'true'

Removing colliding definitions of 'bool', 'false' and 'true'.

Signed-off-by: Richard Knutsson <ricknu-0@student.ltu.se>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:18 -07:00
Keith Mannthey 53947027ad [PATCH] hot-add-mem x86_64: use CONFIG_MEMORY_HOTPLUG_SPARSE
Migate CONFIG_MEMORY_HOTPLUG to CONFIG_MEMORY_HOTPLUG_SPARSE where needed.

Signed-off-by: Keith Mannthey <kmannth@us.ibm.com>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Andi Kleen <ak@muc.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:18 -07:00
Keith Mannthey 8c2676a587 [PATCH] hot-add-mem x86_64: memory_add_physaddr_to_nid node fixup
In cases where the acpi memory-add event does not containe the pxm (node)
infomation allow the driver to look up node info based on the address.  The
acpi_get_node call returns -1 if it can't decode the pxm info, this causes
add_memory to panic.  acpi_get_node would have to decode the resource from the
handle (a lenghty proposition).  This seems to be the cleanist point to
interject the hook.

[kamezawa.hiroyu@jp.fujitsu.com: build fixes]
[y-goto@jp.fujitsu.com: build fixes]
Signed-off-by: Keith Mannthey <kmannth@us.ibm.com>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Andi Kleen <ak@muc.de>
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Signed-off-by: Yasunori Goto <y-goto@jp.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:18 -07:00
Alan Cox 236561e5df [PATCH] PCI quirks update
This fixes two things

Firstly someone mistakenly used "errata" for the singular.  This causes
Dave Woodhouse to emit diagnostics whenever the string is read, and so
should be fixed.

Secondly the AMD AGP tunnel has an erratum which causes hangs if you try
and do direct PCI to AGP transfers in some cases.  We have a flag for
PCI/PCI failures but we need a different flag for this really as in this
case we don't want to stop PCI/PCI transfers using things like IOAT and the
new RAID offload work.

I'll post some updates to make proper use of the PCIAGP flag in the
media/video drivers to Mauro.

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-01 00:39:17 -07:00
Jeff Garzik e993835441 Merge branch 'master' into upstream 2006-09-30 23:55:03 -04:00
Jeff Garzik 1c7da74c4a Merge branch 'master' into upstream 2006-09-30 23:45:41 -04:00
Jeff Garzik 1bdfd554be [PATCH] SCSI: fix request flag-related build breakage
The ->flags in struct request was split into two variables, in a recent
changeset.  The merge of this change forgot to update SCSI's libsas,
probably because libsas was a very recent merge.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-30 19:33:43 -07:00
Linus Torvalds 56f29d7fe4 Merge branch 'block' of git://brick.kernel.dk/data/git/linux-2.6-block
* 'block' of git://brick.kernel.dk/data/git/linux-2.6-block: (67 commits)
  [PATCH] blk_queue_start_tag() shared map race fix
  [PATCH] Update axboe@suse.de email address
  [PATCH] fix creating zero sized bio mempools in low memory system
  [PATCH] CONFIG_BLOCK: blk_congestion_wait() fix
  [PATCH] CONFIG_BLOCK internal.h cleanups
  [PATCH] BLOCK: Make USB storage depend on SCSI rather than selecting it [try #6]
  [PATCH] BLOCK: Make it possible to disable the block layer [try #6]
  [PATCH] BLOCK: Remove no-longer necessary linux/buffer_head.h inclusions [try #6]
  [PATCH] BLOCK: Remove no-longer necessary linux/mpage.h inclusions [try #6]
  [PATCH] BLOCK: Move the msdos device ioctl compat stuff to the msdos driver [try #6]
  [PATCH] BLOCK: Move the Ext3 device ioctl compat stuff to the Ext3 driver [try #6]
  [PATCH] BLOCK: Move the Ext2 device ioctl compat stuff to the Ext2 driver [try #6]
  [PATCH] BLOCK: Move the ReiserFS device ioctl compat stuff to the ReiserFS driver [try #6]
  [PATCH] BLOCK: Move common FS-specific ioctls to linux/fs.h [try #6]
  [PATCH] BLOCK: Move the loop device ioctl compat stuff to the loop driver [try #6]
  [PATCH] BLOCK: Move __invalidate_device() to block_dev.c [try #6]
  [PATCH] BLOCK: Dissociate generic_writepages() from mpage stuff [try #6]
  [PATCH] BLOCK: Remove dependence on existence of blockdev_superblock [try #6]
  [PATCH] BLOCK: Move extern declarations out of fs/*.c into header files [try #6]
  [PATCH] BLOCK: Don't call block_sync_page() from AFS [try #6]
  ...
2006-09-30 12:07:01 -07:00
David Howells 65934a9a02 [PATCH] BLOCK: Make USB storage depend on SCSI rather than selecting it [try #6]
This makes CONFIG_USB_STORAGE depend on CONFIG_SCSI rather than selecting it,
as selecting it makes CONFIG_USB_STORAGE override the dependencies of SCSI,
causing it to turn on even if they aren't all met.

Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2006-09-30 20:52:32 +02:00
David Howells 9361401eb7 [PATCH] BLOCK: Make it possible to disable the block layer [try #6]
Make it possible to disable the block layer.  Not all embedded devices require
it, some can make do with just JFFS2, NFS, ramfs, etc - none of which require
the block layer to be present.

This patch does the following:

 (*) Introduces CONFIG_BLOCK to disable the block layer, buffering and blockdev
     support.

 (*) Adds dependencies on CONFIG_BLOCK to any configuration item that controls
     an item that uses the block layer.  This includes:

     (*) Block I/O tracing.

     (*) Disk partition code.

     (*) All filesystems that are block based, eg: Ext3, ReiserFS, ISOFS.

     (*) The SCSI layer.  As far as I can tell, even SCSI chardevs use the
     	 block layer to do scheduling.  Some drivers that use SCSI facilities -
     	 such as USB storage - end up disabled indirectly from this.

     (*) Various block-based device drivers, such as IDE and the old CDROM
     	 drivers.

     (*) MTD blockdev handling and FTL.

     (*) JFFS - which uses set_bdev_super(), something it could avoid doing by
     	 taking a leaf out of JFFS2's book.

 (*) Makes most of the contents of linux/blkdev.h, linux/buffer_head.h and
     linux/elevator.h contingent on CONFIG_BLOCK being set.  sector_div() is,
     however, still used in places, and so is still available.

 (*) Also made contingent are the contents of linux/mpage.h, linux/genhd.h and
     parts of linux/fs.h.

 (*) Makes a number of files in fs/ contingent on CONFIG_BLOCK.

 (*) Makes mm/bounce.c (bounce buffering) contingent on CONFIG_BLOCK.

 (*) set_page_dirty() doesn't call __set_page_dirty_buffers() if CONFIG_BLOCK
     is not enabled.

 (*) fs/no-block.c is created to hold out-of-line stubs and things that are
     required when CONFIG_BLOCK is not set:

     (*) Default blockdev file operations (to give error ENODEV on opening).

 (*) Makes some /proc changes:

     (*) /proc/devices does not list any blockdevs.

     (*) /proc/diskstats and /proc/partitions are contingent on CONFIG_BLOCK.

 (*) Makes some compat ioctl handling contingent on CONFIG_BLOCK.

 (*) If CONFIG_BLOCK is not defined, makes sys_quotactl() return -ENODEV if
     given command other than Q_SYNC or if a special device is specified.

 (*) In init/do_mounts.c, no reference is made to the blockdev routines if
     CONFIG_BLOCK is not defined.  This does not prohibit NFS roots or JFFS2.

 (*) The bdflush, ioprio_set and ioprio_get syscalls can now be absent (return
     error ENOSYS by way of cond_syscall if so).

 (*) The seclvl_bd_claim() and seclvl_bd_release() security calls do nothing if
     CONFIG_BLOCK is not set, since they can't then happen.

Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2006-09-30 20:52:31 +02:00
David Howells 863d5b822c [PATCH] BLOCK: Move the loop device ioctl compat stuff to the loop driver [try #6]
Move the loop device ioctl compat stuff from fs/compat_ioctl.c to the loop
driver so that the loop header file doesn't need to be included.

Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2006-09-30 20:52:27 +02:00
Jens Axboe 9bf09c2385 [PATCH] SCSI: scsi_done_q is unused
It is a leftover from before the softirq completion was migrated
to the block layer.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
2006-09-30 20:31:11 +02:00
Linus Torvalds e823aff2d6 Merge branch 'drm-patches' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6
* 'drm-patches' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: (36 commits)
  drm: Use register writes instead of BITBLT_MULTI packets for buffer swap blits
  drm: use radeon specific names for radeon flags
  drm: add device/vendor id to drm_device_t for compat with FreeBSD drivers
  drm: allow multiple addMaps with the same 32-bit map offsset.
  drm: fd.o Bug #7595: Avoid u32 overflows in radeon_check_and_fixup_offset().
  drm: Fix hashtab implementation leaking illegal error codes to user space.
  drm: domain changes broke ppc r200
  drm: fixup setversion return codes..
  drm: fixup i915 error codes
  drm: realign sosme radeon code with drm git tree
  drm: realign via driver with drm git tree
  drm: remove hash tables on drm exit
  drm: cleanups
  drm: i810_dma.c: fix pointer arithmetic for 64-bit target
  drm: avoid kernel oops in some error paths calling drm_lastclose
  drm: allow detection of new VIA chipsets
  drm: fix i965 build bug
  drm: remove FALSE/TRUE that snuck in with simple memory manager changes.
  drm: Add support for Intel i965G chipsets.
  drm: add better explanation for i830/i915
  ...
2006-09-30 11:29:54 -07:00
Jens Axboe a3b05e8f58 [PATCH] Kill various deprecated/unused block layer defines/functions
Signed-off-by: Jens Axboe <axboe@suse.de>
2006-09-30 20:29:38 +02:00
Jens Axboe cdd6026217 [PATCH] Remove ->rq_status from struct request
After Christophs SCSI change, the only usage left is RQ_ACTIVE
and RQ_INACTIVE. The block layer sets RQ_INACTIVE right before freeing
the request, so any check for RQ_INACTIVE in a driver is a bug and
indicates use-after-free.

So kill/clean the remaining users, straight forward.

Signed-off-by: Jens Axboe <axboe@suse.de>
2006-09-30 20:29:23 +02:00
Jens Axboe c00895ab2f [PATCH] Remove ->waiting member from struct request
As the comments indicates in blkdev.h, we can fold it into ->end_io_data
usage as that is really what ->waiting is. Fixup the users of
blk_end_sync_rq().

Signed-off-by: Jens Axboe <axboe@kernel.dk>
2006-09-30 20:29:12 +02:00
Jens Axboe 4aff5e2333 [PATCH] Split struct request ->flags into two parts
Right now ->flags is a bit of a mess: some are request types, and
others are just modifiers. Clean this up by splitting it into
->cmd_type and ->cmd_flags. This allows introduction of generic
Linux block message types, useful for sending generic Linux commands
to block devices.

Signed-off-by: Jens Axboe <axboe@suse.de>
2006-09-30 20:23:37 +02:00
Jean Delvare 77ed74da26 [PATCH] i2c: Prevent deadlock on i2c client registration
Delay the call to adapter->client_register() until after we are
certain that the client registration is a success. At this point the
client is fully initialized and we no longer hold the adapter->clist
mutex, so this should prevent the deadlocks if the client_register()
callback needs to take that mutex too, as is the case for the bttv
driver.

This fixes bug #7234.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-30 10:58:47 -07:00
Linus Torvalds 5ffd1a6aaa Merge master.kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb
* master.kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb: (180 commits)
  V4L/DVB (4641): Trivial: use lowercase letters in hex subsystem ids
  V4L/DVB (4639): Cx88: add autodetection for alternate revision of Leadtek PVR
  V4L/DVB (4638): Basic DVB-T and analog TV support for the HVR1300.
  V4L/DVB (4637): Add a default method for VIDIOC_G_PARM
  V4L/DVB (4635): Extend bttv and saa7134 to check for both AGP and PCI PCI failure case
  V4L/DVB (4634): Zr36120: implement pcipci checks
  V4L/DVB (4632): Zoran: Implement pcipci failure check
  V4L/DVB (4631): Av7110: remove V4L2_CAP_VBI_CAPTURE flag
  V4L/DVB (4630): Av7110: FW_LOADER depemdency fixed
  V4L/DVB (4629): Saa7134: add card support for Proteus Pro 2309
  V4L/DVB (4628): Fix VIDIOC_ENUMSTD ioctl in videodev.c
  V4L/DVB (4627): Vivi crashes with mplayer
  V4L/DVB (4626): On saa7111/7113, LUMA_CTRL need a different value
  V4L/DVB (4624): Tvaudio: Replaced kernel_thread() with kthread_run()
  V4L/DVB (4622): Copy-paste bug in videodev.c
  V4L/DVB (4620): Fix AGC configuration for MOD3000P-based boards
  V4L/DVB (4619): Fixes some I2C dependencies on V4L devices
  V4L/DVB (4617): Problem with dibusb-mb.c USB IDs
  V4L/DVB (4616): [PATCH] Nebula DigiTV USB RC support
  V4L/DVB (4614): Export symbol saa7134_tvaudio_setmute from saa7134 for saa7134-alsa
  ...
2006-09-30 09:39:15 -07:00
Linus Torvalds 0cd43f83d3 Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6
* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6: (48 commits)
  ieee1394: raw1394: arm functions slept in atomic context
  ieee1394: sbp2: enable auto spin-up for all SBP-2 devices
  MAINTAINERS: updates to IEEE 1394 subsystem maintainership
  ieee1394: ohci1394: check for errors in suspend or resume
  set power state of firewire host during suspend
  ieee1394: ohci1394: more obvious endianess handling
  ieee1394: ohci1394: fix endianess bug in debug message
  ieee1394: sbp2: don't prefer MODE SENSE 10
  ieee1394: nodemgr: grab class.subsys.rwsem in nodemgr_resume_ne
  ieee1394: nodemgr: fix rwsem recursion
  ieee1394: sbp2: more help in Kconfig
  ieee1394: sbp2: prevent rare deadlock in shutdown
  ieee1394: sbp2: update includes
  ieee1394: sbp2: better handling of transport errors
  ieee1394: sbp2: recheck node generation in sbp2_update
  ieee1394: sbp2: safer agent reset in error handlers
  ieee1394: sbp2: handle "sbp2util_node_write_no_wait failed"
  CONFIG_PM=n slim: drivers/ieee1394/ohci1394.c
  ieee1394: safer definition of empty macros
  video1394: add poll file operation support
  ...
2006-09-30 09:38:19 -07:00
Linus Torvalds db1a19b38f Merge branch 'intelfb-patches' of master.kernel.org:/pub/scm/linux/kernel/git/airlied/intelfb-2.6
* 'intelfb-patches' of master.kernel.org:/pub/scm/linux/kernel/git/airlied/intelfb-2.6:
  intelfbhw.c: intelfbhw_get_p1p2 defined but not used
  intelfb: fix mtrr_reg signedness
  intelfb: update doc and Kconfig (supported devices)
  intelfb: add preliminary i2c support
  intelfb: add preliminary i2c support
  intelfb: add preliminary i2c support
  intelfb: add preliminary i2c support
  intelfb: add preliminary i2c support
  intelfb: add preliminary i2c support
  intelfb: add preliminary i2c support
  intelfb: add preliminary i2c support
  intelfb: add vsync interrupt support
  intelfb: add vsync interrupt support
  intelfb: add vsync interrupt support
  intelfb: add vsync interrupt support
  intelfb: add vsync interrupt support
2006-09-30 09:36:56 -07:00
Tejun Heo 360f654e7c [PATCH] libata: turn off NCQ if queue depth is adjusted to 1
Turn off NCQ if queue depth is adjusted to 1.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-09-30 07:39:24 -04:00
Linus Torvalds bf60362566 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [ATM]: [lec] use refcnt to protect lec_arp_entries outside lock
  [ATM]: [lec] add reference counting to lec_arp entries
  [ATM]: [lec] use work queue instead of timer for lec arp expiry
  [ATM]: [lec] old_close is no longer used
  [ATM]: [lec] convert lec_arp_table to hlist
  [ATM]: [lec] header indent, comment and whitespace cleanup
  [ATM]: [lec] indent, comment and whitespace cleanup [continued]
  [ATM]: [lec] indent, comment and whitespace cleanup
  [SCTP]: Do not timestamp every SCTP packet.
  [SCTP]: Use correct mask when disabling PMTUD.
  [SCTP]: Include sk_buff overhead while updating the peer's receive window.
  [SCTP]: Enable Nagle algorithm by default.
  [BNX2]: Disable MSI on 5706 if AMD 8132 bridge is present.
  [NetLabel]: audit fixups due to delayed feedback
2006-09-29 18:54:48 -07:00
Michael Chan f9317a40c4 [BNX2]: Disable MSI on 5706 if AMD 8132 bridge is present.
MSI is defined to be 32-bit write.  The 5706 does 64-bit MSI writes
with byte enables disabled on the unused 32-bit word.  This is legal
but causes problems on the AMD 8132 which will eventually stop
responding after a while.

Without this patch, the MSI test done by the driver during open will
pass, but MSI will eventually stop working after a few MSIs are
written by the device.

AMD believes this incompatibility is unique to the 5706, and
prefers to locally disable MSI rather than globally disabling it
using pci_msi_quirk.

Update version to 1.4.45.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-29 17:06:23 -07:00
David S. Miller fbe96f92b3 [SERIAL] sunzilog: Mark sunzilog_init_hw as __devinit.
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-29 16:12:43 -07:00
Linus Torvalds 9a69d1aecc Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband: (33 commits)
  IB/ipath: Fix lockdep error upon "ifconfig ibN down"
  IB/ipath: Fix races with ib_resize_cq()
  IB/ipath: Support new PCIE device, QLE7142
  IB/ipath: Set CPU affinity early
  IB/ipath: Fix EEPROM read when driver is compiled with -Os
  IB/ipath: Fix and recover TXE piobuf and PBC parity errors
  IB/ipath: Change HT CRC message to indicate how to resolve problem
  IB/ipath: Clean up module exit code
  IB/ipath: Call mtrr_del with correct arguments
  IB/ipath: Flush RWQEs if access error or invalid error seen
  IB/ipath: Improved support for PowerPC
  IB/ipath: Drop unnecessary "(void *)" casts
  IB/ipath: Support multiple simultaneous devices of different types
  IB/ipath: Fix mismatch in shifts and masks for printing debug info
  IB/ipath: Fix compiler warnings and errors on non-x86_64 systems
  IB/ipath: Print more informative parity error messages
  IB/ipath: Ensure that PD of MR matches PD of QP checking the Rkey
  IB/ipath: RC and UC should validate SLID and DLID
  IB/ipath: Only allow complete writes to flash
  IB/ipath: Count SRQs properly
  ...
2006-09-29 15:18:22 -07:00
Yoichi Yuasa ae1390d8c3 [PATCH] i2c-sibyte: Fix modular build breakage
Fix undefined reference in i2c_sibyte_exit().

   drivers/built-in.o: In function `i2c_sibyte_exit':
   i2c-sibyte.c:(.exit.text+0x368): undefined reference to `i2c_del_bus'
   i2c-sibyte.c:(.exit.text+0x368): relocation truncated to fit: R_MIPS_26 against `i2c_del_bus'
   i2c-sibyte.c:(.exit.text+0x38c): undefined reference to `i2c_del_bus'
   i2c-sibyte.c:(.exit.text+0x38c): relocation truncated to fit: R_MIPS_26 against `i2c_del_bus'

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:34:17 -07:00
Alan Cox 5f412b2424 [PATCH] Fix locking for tty drivers when doing urgent characters
If you send a priority character (as is done for flow control) then the tty
driver can either have its own method for "jumping the queue" or the characrer
can be queued normally.  In the latter case we call the write method but
without the atomic_write_lock taken elsewhere.

Make this consistent.  Note that the send_xchar method if implemented remains
outside of the lock as it can jump ahead of a current write so must not be
locked out by it.

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:24 -07:00
Alan Cox 67cc0161ec [PATCH] specialix - remove private speed decoding
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:24 -07:00
Alan Cox 1db27c11e9 [PATCH] istallion: Remove private baud rate decoding, which is also broken in this case on some platforms
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:24 -07:00
Alan Cox d720bc4b8f [PATCH] generic_serial: remove private decoding of baud rate bits
The driver has no business doing this work itself any more and hasn't for some
years.  When the new speed stuff goes in this will break entirely so fix it up
ready.

Also remove a #if 0 around a comment....

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:24 -07:00
Atsushi Nemoto 13c73f045f [PATCH] RTC: more XSTP/VDET support for rtc-rs5c348 driver
If the chip detected "oscillator stop" condition, show an warning message.
And initialize it with the Epoch time instead of leaving it with unknown
date/time.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Acked-by: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:24 -07:00
Eric Sesterhenn 8c6ba51bda [PATCH] Uninitialized variable in drivers/net/wan/syncppp.c
For len equal to 4, we never call sppp_lcp_conf_parse_options(),
therefore rmagic does not get initialized.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Acked-by: Paul Fulghum <paulkf@microgate.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:23 -07:00
Akinobu Mita 4050914f7c [PATCH] rate limiting for the ldisc open failure messages
This patch limits the messages when ldisc open faulures happen.  It happens
under memory pressure.

Signed-off-by: Akinobu Mita <mita@miraclelinux.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:23 -07:00
Geoff Levand 153dcc54df [PATCH] mem driver: fix conditional on isa i/o support
This change corrects the logic on the preprocessor conditionals that
include support for ISA port i/o (/dev/ioports) into the mem character
driver.

This fixes the following error when building for powerpc platforms with
CONFIG_PCI=n.

  drivers/built-in.o: undefined reference to `pci_io_base'

Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com>
Acked-by: Linas Vepstas <lins@austin.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:22 -07:00
Serge E. Hallyn a7422bf8a6 [PATCH] loop: forward-port resource leak checks from Solar
Forward port of the patch by Solar and ported by Julio.

Compiles, boots, and passes my looptorturetest.sh.

Signed-off-by: Serge E. Hallyn <serue@us.ibm.com>
Cc: Julio Auto <mindvortex@gmail.com>
Cc: Solar Designer <solar@openwall.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:22 -07:00
Pavel Machek af3ffa6758 [PATCH] Fix typo in rtc kconfig
Fix simple typo in RTC_HCTOSYS option.

Signed-off-by: Pavel Machek <pavel@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:21 -07:00
Arjan van de Ven e8106b941c [PATCH] lockdep: core, add enable/disable_irq_irqsave/irqrestore() APIs
Introduce the disable_irq_nosync_lockdep_irqsave() and
enable_irq_lockdep_irqrestore() APIs.  These are needed for NE2000; basically
NE2000 calls disable_irq and enable_irq as locking against the IRQ handler,
but both in cases where interrupts are on and off.  This means that lockdep
needs to track the old state of the virtual irq flags on disable_irq, and
restore these at enable_irq time.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:20 -07:00
Alexey Dobriyan 92e9a8507b [PATCH] windfarm_smu_sat.c: simplify around i2c_add_driver()
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:19 -07:00
Alan Cox 28298232a1 [PATCH] tty: Fix bits and note more bits to fix
If your driver implements "break on" and "break off" this ensures you won't
get multiple overlapping requests or requests in parallel.  If your driver
has its own break handling then its still your problem as the driver
author.

Break is also now serialized against writes from user space properly but no
new guarantees are made driver level about writes from the line discipline
itself (eg flow control or echo)

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:18 -07:00
Alan Cox de2a84f2be [PATCH] solaris emulation: incorrect tty locking
[akpm@osdl.org: build fix]
[akpm@osdl.org: warning fix]
Signed-off-by: Alan Cox <alan@redhat.com>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:18 -07:00
Rolf Eike Beer 3e26a423e7 [PATCH] Return better error codes if drivers/char/raw.c module init fails
Currently this module just returns 1 if anything on module init fails. Store
the error code of the different function calls and return their error on
problems.

Signed-off-by: Rolf Eike Beer <eike-kernel@sf-tec.de>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
[ Fixed to not unregister twice on error ]
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:16 -07:00
Arjan van de Ven 5785c95bae [PATCH] tty: make termios_sem a mutex
[akpm@osdl.org: fix]
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Arjan van de Ven <arjan@infradead.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:16 -07:00
Alan Cox 808a0d389f [PATCH] tty: lock ticogwinsz
Now we lock the set ioctl its trivial to lock the get one so the data
copied is consistent.  At the moment we have the BKL here but this removes
the need for it and is a step in the right direction

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:16 -07:00
Alan Cox 1266b1e1ae [PATCH] tty: trivial kzalloc opportunity
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:16 -07:00
Catalin Marinas 254e948b29 [PATCH] Fix memory leak in vc_resize/vc_allocate
Memory leaks can happen in the vc_resize() function in drivers/char/vt.c
because of the vc->vc_screenbuf variable overriding in vc_allocate().  The
kmemleak reported trace is as follows:

  <__kmalloc>
  <vc_resize>
  <fbcon_init>
  <visual_init>
  <vc_allocate>
  <con_open>
  <tty_open>
  <chrdev_open>

This patch no longer allocates a screen buffer in vc_allocate() if it was
already allocated by vc_resize().

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Acked-by: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:14 -07:00
Peter Korsgaard b22b4cdd53 [PATCH] fix serial/amba-pl011.c console Kconfig
Fix the Kconfig entry for console on AMBA PL011 to match the code.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:14 -07:00
Ben Dooks d202a6c088 [PATCH] Remove old drivers/char/s3c2410_rtc.c
This can now be removed, since there is now a drivers/rtc/rtc-s3c.c driver.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:13 -07:00
Alexey Dobriyan 7dd7d6912b [PATCH] CONFIG_PM=n slim: drivers/parport/parport_serial.c
Remove some code which is unneeded if CONFIG_PM=n.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:13 -07:00
Anatoli Antonovitch 2b33b4dcbe [PATCH] atiixp: ATI SB600 IDE support for various modes
Support SB600 SATA legacy IDE (DMA enable).

Signed-off-by: Anatoli Antonovitch <antonovi@ati.com>
Cc: Jeff Garzik <jeff@garzik.org>
Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:12 -07:00
Sukadev Bhattiprolu f400e198b2 [PATCH] pidspace: is_init()
This is an updated version of Eric Biederman's is_init() patch.
(http://lkml.org/lkml/2006/2/6/280).  It applies cleanly to 2.6.18-rc3 and
replaces a few more instances of ->pid == 1 with is_init().

Further, is_init() checks pid and thus removes dependency on Eric's other
patches for now.

Eric's original description:

	There are a lot of places in the kernel where we test for init
	because we give it special properties.  Most  significantly init
	must not die.  This results in code all over the kernel test
	->pid == 1.

	Introduce is_init to capture this case.

	With multiple pid spaces for all of the cases affected we are
	looking for only the first process on the system, not some other
	process that has pid == 1.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Sukadev Bhattiprolu <sukadev@us.ibm.com>
Cc: Dave Hansen <haveblue@us.ibm.com>
Cc: Serge Hallyn <serue@us.ibm.com>
Cc: Cedric Le Goater <clg@fr.ibm.com>
Cc: <lxc-devel@lists.sourceforge.net>
Acked-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:12 -07:00
Alan Cox ca9bda00b4 [PATCH] tty locking on resize
The current kernel serializes console resizes but does not serialize the
resize against the tty structure updates.  This means that while two
parallel resizes cannot mess up the console you can get incorrect results
reported.

Secondly while doing this I added vc_lock_resize() to lock and resize the
console.  This leaves all knowledge of the console_sem in the vt/console
driver and kicks it out of the tty layer, which is good

Thirdly while doing this I decided I couldn't stand "disallocate" any
longer so I switched it to "deallocate".

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Paul Fulghum <paulkf@microgate.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:12 -07:00
Adam Tlalka d4328b40af [PATCH] console utf-8 mode fixes
Fix utf-8 mode so alternate charset modes always work according to control
sequences interpreted in do_con_trol function preserving backward US-ASCII
and VT100 semigraphics compatibility.

Malformed utf-8 sequences are represented as sequences of replacement
glyphs,original codes or '?' as a last resort.

unicode-xterm, gnome-terminal, kconsole and other terminal emulators in
utf-8 mode respect acsc, enacs, rmacs sequences.  Also I found that some
important system programs (from Debian distro) uses acsc in utf-8 mode -
dselect, aptitude, w3m for example.

Signed-off-by: Adam Tlalka <atlka@pg.gda.pl>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:11 -07:00
Dmitry Torokhov 08c67d2a5d [PATCH] ucb1x00-ts: handle errors from input_register_device()
ucb1x00-ts: handle errors from input_register_device()

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:10 -07:00
Alexey Dobriyan 527063ba98 [PATCH] tty_io.c: keep davej sane
Just comment and next "while" look _very_ wrong.  Place { correctly to hint
unsuspecting ones that it's the end of the loop actually.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Cc: Dave Jones <davej@redhat.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:10 -07:00
Rolf Eike Beer d6bd3a39f7 [PATCH] Move valid_dma_direction() from x86_64 to generic code
As suggested by Muli Ben-Yehuda this function is moved to generic code as
may be useful for all archs.

[akpm@osdl.org: fix]
Signed-off-by: Rolf Eike Beer <eike-kernel@sf-tec.de>
Cc: Muli Ben-Yehuda <muli@il.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:10 -07:00
Alan Cox d09d7ddf30 [PATCH] There is no devfs, there has never been a devfs, we have always been at war with...
Jon Smirl noted a couple of tty driver functions now are quite misleadingly
named with the death of devfs.  A quick grep found another case in the lp
driver.

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:10 -07:00
Jan Beulich c24c95a085 [PATCH] fix Intel RNG detection
Previously, since determination whether there was an Intel random number
generator was based on a single bit, on systems with a matching bridge
device but without a firmware hub, there was a 50% chance that the code
would incorrectly decide that the system had an RNG.  This patch adds
detection of the firmware hub to better qualify the existence of an RNG.

There is one issue with the patch: I was unable to determine the LPC
equivalent for the PCI bridge 8086:2430 (since the old code didn't care
about which of the many devices provided by the ICH/ESB it was chose to use
the PCI bridge device, but the FWH settings live in the LPC device, so the
device list needed to be changed).

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:09 -07:00
Shem Multinymous 2e0c1f6ce7 [PATCH] DMI: Decode and save OEM String information
This teaches dmi_decode() how to decode and save OEM Strings (type 11) DMI
information, which is currently discarded silently.  Existing code using
DMI is not affected.  Follows the "System Management BIOS (SMBIOS)
Specification" (http://www.dmtf.org/standards/smbios), and also the
userspace dmidecode.c code.

OEM Strings are the only safe way to identify some hardware, e.g., the
ThinkPad embedded controller used by the soon-to-be-submitted tp_smapi
driver.  This will also let us eliminate the long whitelist in the mainline
hdaps driver (in a future patch).

Signed-off-by: Shem Multinymous <multinymous@gmail.com>
Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:09 -07:00
Sukadev Bhattiprolu 563d075702 [PATCH] kthread: drivers/base/firmware_class.c
Replace kernel_thread() call in drivers/base/firmware_class.c with
kthread_create() since kernel_thread() is deprecated in drivers.

Signed-off-by: Sukadev Bhattiprolu <sukadev@us.ibm.com>
Cc: Cedric Le Goater <clg@fr.ibm.com>
Cc: Serge E. Hallyn <serue@us.ibm.com>
Cc: Dave Hansen <haveblue@us.ibm.com>
Cc: Manuel Estrada Sainz <ranty@debian.org>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:08 -07:00
Komal Shah ad4e09b16a [PATCH] OMAP: Add keypad driver
This patch adds support for keypad driver running on different TI
OMAP(http://www.ti.com/omap) processor based boards like OSK, H2, H3, H4,
Persuas and Nokia 770.

Signed-off-by: Komal Shah <komal_shah802003@yahoo.com>
Acked-by: Dmitry Torokhov <dtor@mail.ru>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:07 -07:00
Komal Shah 7768a13c25 [PATCH] OMAP: Add Watchdog driver support
Add Texas Instruments (TI) OMAP1/2 (http://www.ti.com/omap) based
processors, like OMAP1610/1710/242x.

[akpm@osdl.org: cleanups]
Cc: <gdavis@mvista.com>
Cc: "Komal Shah" <komal_shah802003@yahoo.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:07 -07:00
Komal Shah f1b7c5f459 [PATCH] OMAP: Add smc91x support for TI OMAP2420 H4 board
Add smc91x support for TI OMAP2420 H4 EVM board.

Cc: <nico@cam.org>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:07 -07:00
Rolf Eike Beer 92a0f861fe [PATCH] Fix parameter names in drivers/base/class.c
Change parameter names to match arguments of functions.

Signed-off-by: Rolf Eike Beer <eike-kernel@sf-tec.de>
Cc: Martin Waitz <tali@admingilde.org>
Cc: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:06 -07:00
Serge E. Hallyn 6c9979185c [PATCH] kthread: convert loop.c to kthread
Convert loop.c from the deprecated kernel_thread to kthread.  This patch
simplifies the code quite a bit and passes similar testing to the previous
submission on both emulated x86 and s390.

Changes since last submission:
	switched to using a rather simple loop based on
	wait_event_interruptible.

Signed-off-by: Serge E. Hallyn <serue@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:06 -07:00
Chris Boot cfedc920a7 [PATCH] Make net48xx-led use scx200_gpio_ops
Make the next48xx LED code use scx200_gpio_ops instead of raw SCx200 GPIO
accesses.

Signed-off-by: Chris Boot <bootc@bootc.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:06 -07:00
Chris Boot 58012cd788 [PATCH] scx200_gpio export cleanups
Use EXPORT_SYMBOL_GPL for new symbols, and declare the struct in the header
file for access by other modules.

Signed-off-by: Chris Boot <bootc@bootc.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:06 -07:00
Adrian Bunk 6299a2dec8 [PATCH] drivers/char/pc8736x_gpio.c: remove unused static functions
drivers/char/pc8736x_gpio.c:192: warning: #pc8736x_gpio_set_high# defined but not used
drivers/char/pc8736x_gpio.c:197: warning: #pc8736x_gpio_set_low# defined but not used

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Acked-by: Jim Cromie <jim.cromie@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:05 -07:00
Jim Cromie c8ad9681fd [PATCH] drivers/char/scx200_gpio.c: make code static
This patch makes a needlessly global variable static.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Jim Cromie  <jim.cromie@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:05 -07:00
Steven Rostedt 358333a0cb [PATCH] remove unnecessary barrier in rtc_get_rtc_time
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:05 -07:00
David Woodhouse 4efd587bf9 [PATCH] Fix uninitialised spinlock in via-pmu-backlight code.
The uninitialised pmu_backlight_lock causes the current Fedora test kernel
(which has spinlock debugging enabled) to panic on suspend.

This is suboptimal, so I fixed it.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Michael Hanselmann <linux-kernel@hansmi.ch>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-09-29 09:18:03 -07:00
Jeff Garzik 4f931374ec [libata] DocBook minor updates, fixes
Update copyright year, fix minor stuff 'make xmldocs' complains about.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-09-29 05:07:25 -04:00
Linus Torvalds 3dcbbcda7c Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (160 commits)
  [ETHTOOL]: Remove some entries from non-root command list.
  [Bluetooth]: Fix section mismatch of bt_sysfs_cleanup()
  [Bluetooth]: Don't update disconnect timer for incoming connections
  [ETHTOOL]: let mortals use ethtool
  [NetLabel]: add audit support for configuration changes
  [TCP]: Fix and simplify microsecond rtt sampling
  [TCP] tcp-lp: prevent chance for oops
  [SUNRPC]: Remove unnecessary check in net/sunrpc/svcsock.c
  [IPVS] bug: endianness breakage in ip_vs_ftp
  [IPVS]: ipvs annotations
  [NETFILTER]: h323 annotations
  [NETFILTER]: ipt annotations
  [NETFILTER]: NAT annotations
  [NETFILTER]: conntrack annotations
  [NETFILTER]: netfilter misc annotations
  [NET]: Annotate dst_ops protocol
  [NET]: is it Andy or Andi ??
  [IPVS]: Make sure ip_vs_ftp ports are valid: module_param_array approach
  [IPVS]: Reverse valid ip_vs_ftp ports fix: port check approach
  [IrDA] stir4200: removing undocumented bits handling
  ...
2006-09-28 23:03:42 -07:00
Linus Torvalds c972398b78 Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6:
  USB: fix build error in ohci driver
2006-09-28 22:59:32 -07:00
Samuel Ortiz febac9b937 [IrDA] stir4200: removing undocumented bits handling
FIFOCTL_RXERR and FIFOCTL_TXERR are undocumented bits, according to the
Sigmatel datasheet. We should thus not take any assumption on their values
and semantics.

Problem spotted by andrzej zaborowski <balrogg@gmail.com>
Signed-off-by: Samuel Ortiz <samuel@sortiz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:02:54 -07:00
Linus Walleij (LD/EAB 895de090d4 [IrDA] smsc-ircc: More laptops detected
This patch detects the smsc-ircc chipset on the nx1000
(including nx7000 and nx7010) and the nx5000 HP/Compaq laptop series.

Patch from "Linus Walleij (LD/EAB)" <linus.walleij@ericsson.com>
Signed-off-by: Samuel Ortiz <samuel@sortiz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:02:53 -07:00
Lamarque Vieira Souza 2fd19a687c [IrDA] nsc-ircc: Configuration base address for PC87383
According to NatSemi datasheet, the configuration base address for the PC8738x
family is 0x2e or 0x164. 0x0 doesn't appear in any datasheet.

Patch from Lamarque Vieira Souza <lamarque@gmail.com>
Signed-off-by: Samuel Ortiz <samuel@sortiz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:02:52 -07:00
Stephen Hemminger 7fa6b06689 [NET] loopback: minor statistics optimization
The loopback device status structure is a singleton and doesn't
need to be allocated. Add ethtool_ops hooks to show checksum always on,
and make ethtool_ops const.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:02:49 -07:00
Samuel Ortiz 778e6398d3 [IrDA]: irda-usb needs firmware loader
With the inclusion of the stir421x code, we now need to select FW_LOADER
whenever we try to build the irda-usb code.

Signed-off-by: Samuel Ortiz <samuel@sortiz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:02:47 -07:00
Michal Ostrowski c9aa689537 [PPPOE]: Advertise PPPoE MTU
PPPoE must advertise the underlying device's MTU via the ppp channel
descriptor structure, as multilink functionality depends on it.

Signed-off-by: Michal Ostrowski <mostrows@earthlink.net>
Acked-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:44 -07:00
Michael Chan 1533d38215 [TG3]: Update version and reldate.
Update version to 3.66.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:43 -07:00
Michael Chan b16250e3d1 [TG3]: Add 5709 self-test support.
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:42 -07:00
Michael Chan 715116a126 [TG3]: Add 5709 PHY support.
Add support for the 5709 10/100 PHY.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:41 -07:00
Michael Chan b5d3772ccb [TG3]: Add basic 5906 support.
Add support for the new 5709 device.  This is a new 10/100 Mbps chip.
The mailbox access and firmware interface are quite different from
all other tg3 chips.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:40 -07:00
Michael Chan 7a6f436944 [TG3]: Add tg3_poll_fw().
Put the firmware polling logic into a separate function.  This makes
the code cleaner.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:39 -07:00
Michael Chan 126a336822 [TG3]: Add 5722 and 5756 support.
Add IDs to support 5722 and 5756.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:38 -07:00
Michael Chan 3f7045c1f2 [TG3]: PHY fixes.
Some PHY related fixes:

1. Fix Serdes WoL.
2. Fix loopback test on 10/100 only devices.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:36 -07:00
Michael Chan 130b8e4d0e [TG3]: Improve ASF heartbeat.
Change to a different ASF heartbeat message code to improve
reliability.

There were some reports of unintended resets on real time kernels
where the timer may be slow and cause the heartbeat to be late.
Netpoll will also have the same problem because the timer irq will
be unavailable.

Using the new heartbeat code, the ASF firmware will also check the
ring condition before resetting the chip when the heartbeat is
expiring.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:35 -07:00
Michael Chan 3d3ebe741b [TG3]: Improve 5704S autoneg.
Improve 5704S autoneg logic by using a serdes_counter field to keep
track of the transient states.  This eliminates a 200 msec busy
loop in the code.  Autoneg will take its course without the driver
busy waiting for it to finish.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:34 -07:00
Marcel Holtmann 7785162cf2 [Bluetooth] Code cleanup for the HCI UART driver
This patch cleans up the Bluetooth HCI UART driver a bit.

Signed-off-by: Pavel Machek <pavel@suse.cz>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2006-09-28 18:01:30 -07:00
Marcel Holtmann 62ae15919b [Bluetooth] Add support for Canyon CN-BTU1 dongle
This patch adds the vendor and product id of the Canycon CN-BTU1
dongle and sets a flag to send HCI_Reset as the first command.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2006-09-28 18:01:29 -07:00
Marcel Holtmann 0ac53939a0 [Bluetooth] Add HCI device identifier for SDIO cards
This patch assigns the next free HCI device identifier to Bluetooth
devices based on the SDIO interface.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2006-09-28 18:01:28 -07:00
Marcel Holtmann 9c724357f4 [Bluetooth] Code cleanup of the drivers source code
This patch is an attempt to cleanup the drivers source code to make all
Bluetooth drivers look more unique.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2006-09-28 18:01:27 -07:00
Al Viro fd68322209 [IPV4]: inet_addr_type() annotations
argument and inferred net-endian variables in callers annotated.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:07 -07:00
Al Viro 60cad5da57 [IPV4]: annotate inetdev.h helpers
inet_confirm_addr(), inet_ifa_byprefix(), ip_dev_find(), inet_make_mask() and
inet_ifa_match() annotated, along with inferred net-endian variables

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:01:05 -07:00
Al Viro a144ea4b7a [IPV4]: annotate struct in_ifaddr
ifa_local, ifa_address, ifa_mask, ifa_broadcast and ifa_anycast are
net-endian.  Annotated them and variables that are inferred to be
net-endian.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 18:00:55 -07:00
Al Viro 2a50f28c32 [ATALK]: endianness annotations
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 17:53:58 -07:00
Randy Dunlap 1618cb0c9c [NETDEV] config: revert part of previous patch
Net devices should depend on NETDEVICES, so revert part of
Paolo's previous patch.

See http://marc.theaimsgroup.com/?l=linux-kernel&m=115566326218740&w=2
for history.

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 17:53:56 -07:00
Chuck Short 83e331e2a4 [IRDA] via-ircc: fix memory leak
Fix memory leak.

Coverity id# 653

patch location:
http://www.kernel.org/git/?p=linux/kernel/git/bcollins/ubuntu-dapper.git;a=commitdiff;h=a1f34cb68b16807ed9d5ebb0f6a6ec5ff8a5fc78

Signed-off-by: Chuck Short <zulcss@gmail.com>
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-09-28 17:53:55 -07:00
Jeff Garzik 2d2744fc8b [libata] PCI ID table cleanup in various drivers
* Use PCI_VDEVICE() macro
* const-ify pci_device_id table
* standardize list terminator as "{ }"
* convert spaces to tab in pci_driver struct (Alan-ism)
* various minor whitespace cleanups

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-09-28 20:21:59 -04:00
Greg Kroah-Hartman 6e3ce3ae8e USB: fix build error in ohci driver
Thanks to Andrew for the original patch for this.
I need to upgrade my version of gcc to catch these things...

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 17:06:45 -07:00
Dave Jones 2cc1a4134f [AGPGART] printk fixups.
Signed-off-by: Dave Jones <davej@redhat.com>
2006-09-28 19:50:07 -04:00
Linus Torvalds 2ff712585a Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/hwmon-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/hwmon-2.6: (39 commits)
  hwmon: Remove Yuan Mu's address
  hwmon: Fix unchecked return status, SMSC chips
  hwmon: Fix unchecked return status, batch 6
  w83792d: Fix unchecked return status
  w83l785ts: Fix unchecked return status
  w83781d: Fix unchecked return status
  vt8231: Fix unchecked return status
  Fix unchecked return status, batch 5
  hwmon: Fix unchecked return status, batch 4
  hwmon: Fix unchecked return status, batch 3
  hwmon: Fix unchecked return status, batch 2
  w83627ehf: Fix unchecked return status
  pc87360: Check for error on sysfs files creation
  pc87360: Delete sysfs files on device deletion
  pc87360: Move some code around
  hwmon: Fix unchecked return status, batch 1
  vt1211: Document module parameters
  vt1211: Add documentation
  hwmon: New driver for the VIA VT1211
  w83791d: Documentation update
  ...
2006-09-28 16:23:27 -07:00
Alan Stern 6174d0fd35 USB: g_file_storage: Set sense info Valid bit only when needed
Strictly speaking, the Valid bit in SCSI sense data is supposed to
be set only when the Information field contains a valid number.  This
patch (as793) turns off the Valid bit when the Information field
hasn't been set.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:47 -07:00
Alan Stern e0318ebff4 USB: fix autosuspend when CONFIG_PM isn't set
This patch (as791b) fixes things up to avoid compiler warnings or
errors when CONFIG_USB_SUSPEND or CONFIG_PM isn't set.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:46 -07:00
Alan Stern 8d1a243ba5 OHCI: add auto-stop support
This patch (as790b) adds "autostop" support to ohci-hcd: the driver
will automatically stop the host controller when no devices have been
connected for at least one second.  This feature is useful when the
USB autosuspend facility isn't available, such as when
CONFIG_USB_SUSPEND hasn't been set.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:46 -07:00
Alan Stern 1f7e1a3b7e OHCI: remove existing autosuspend code
The autosuspend technique used by ohci-hcd doesn't mesh well with the
newer USB core autosuspend code.  This patch (as789) removes ohci-hcd's
autosuspend support.  Now the driver will be usable, but it won't
automatically go into a low-power state when no devices are connected.
That's for a later patch.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:46 -07:00
Alan Stern d19ac7da72 USB: allow both root-hub interrupts and polling
Originally I didn't think any host controller driver would ever use
interrupts and polling at the same time, but it turns out ohci-hcd wants
to do exactly that.  This patch (as788) makes it possible.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:45 -07:00
Alan Stern 2de9eaefa7 USB: g_file_storage: fix "ignoring return value" warnings
This patch (as792) fixes "ignoring return value" warnings in
file_storage.c.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:45 -07:00
Alan Stern efd54a3641 USB: dummy-hcd: fix "warn-unused-result" messages
This patch (as758) fixes the "warn-unused-result" messages in dummy-hcd.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:45 -07:00
Alan Stern bd859281c0 USB: create new workqueue thread for USB autosuspend
This patch (as787) creates a new workqueue thread to handle delayed
USB autosuspend requests.  Previously the code used keventd.  However
it turns out that the hub driver's suspend routine calls
flush_scheduled_work(), making it a poor candidate for running in
keventd (the call immediately deadlocks).  The solution is to use a
new thread instead of keventd.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:44 -07:00
Jan Mate 6a9fb06039 USB Storage: unusual_devs.h entry for Sony Ericsson P990i
USB Storage: this patch adds support for Sony Ericsson P990i

Signed-off-by: Jan Mate <mate@fiit.stuba.sk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:44 -07:00
Henrik Kretzschmar 0eebe6ac7c USB: microtek usb scanner: Scsi_Cmnd conversion
Converts obsolete typedef'd Scsi_Cmnd into struct scsi_cmnd.

Signed-off-by: Henrik Kretzschmar <henne@nachtwindheim.de>
Cc: James Bottomley <James.Bottomley@steeleye.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:44 -07:00
Henrik Kretzschmar 701f35af28 USB: fixes kerneldoc errors in usbcore-auto(susp/res)-patch
Fixes kerneldoc errors on usb/core/driver.c, which occured in 2.6.18-rc6-mm2
gregkh-usb-usbcore-add-autosuspend-autoresume-infrastructure.patch

Signed-off-by: Henrik Kretzschmar <henne@nachtwindheim.de>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:44 -07:00
Raghavendra Biligiri 931e24b93a USB: add Raritan KVM USB Dongle to the HID_QUIRK_NOGET blacklist
During Installation the host tries to enumerate the keyboard/mouse
dongle for the Raritan KVM.At this time timeouts have been observed
Adding the Raritan KVM USB dongle to the blacklist fixes this issue.

Signed-off-by: Raghavendra Biligiri <Raghavendra_Biligiri@Dell.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-28 15:36:44 -07:00