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

17299 Commits

Author SHA1 Message Date
Alan Cox 29f3eb6463 pci: Additional search functions
In order to finish converting to pci_get_* interfaces we need to add a couple
of bits of missing functionaility

pci_get_bus_and_slot() provides the equivalent to pci_find_slot()
(pci_get_slot is already taken as a name for something similar but not the
same)

pci_get_device_reverse() is the equivalent of pci_find_device_reverse but
refcounting

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:12 -07:00
Alan Cox 11f242f04c PCI: quirks: switch quirks code offender to use pci_get API
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Brice Goglin 0306ebfa3b PCI: Improve pci_msi_supported() comments
Improve pci_msi_supported() comments.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Grant Grundler <grundler@parisc-linux.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Amol Lad 662a98fb8d PCI hotplug: ioremap balanced with iounmap
1. ioremap must be balanced by an iounmap and failing to do so can
   result in a memory leak.
2. Handle return value correctly

Tested (compilation only) with:
- allmodconfig

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Cc: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Kenji Kaneshige 6aa562c248 shpchp: remove unnecessary cmd_busy member from struct controller
This patch removes unnecessary cmd_busy member from struct
controller. Read command status register instead of using cmd_busy.

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Kenji Kaneshige d1729ccecd shpchp: fix command completion check
This patch fixes the problem that shpchp driver could mis-detect
command failures if the system was under heavy load.

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Alan Cox 094ed76e89 pci: Stamp out pci_find_* usage in fakephp
pci_find is not hotplug safe, so it really doesn't want to be in an
actual hotplug driver either.

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Zhang, Yanmin 0bed208efc PCI: fix pcie_portdrv_restore_config undefined without CONFIG_PM error
On Thu, 2006-09-28 at 03:42, Olaf Hering wrote:
> PCI-Express AER implemetation: pcie_portdrv error handler
> 
> This patch breaks if CONFIG_PM is not enabled,
> pcie_portdrv_restore_config() will be undefined.
I move the definition of pcie_portdrv_restore_config
out of CONFIG_PM.

Below patch is against 2.6.18-mm1. Could you try it?

Signed-off-by: Zhang Yanmin <yanmin.zhang@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Vojtech Pavlik ccc4c7bbd6 Fix DMA resource allocation in ACPIPnP
The ACPIPnP implementation had the understanding of Linux resource flags very
wrong, resulting in a nonfunctional implementation of DMA resource
allocation.

This was usually not a problem, since almost no on-board PnP devices use ISA
DMA, with the exception of ECP parallel ports. Even with that, parallel port
DMA is preconfigured by the BIOS, so this routine isn't normally called.

Except in the case where somebody does 'rmmod parport_pc; modprobe
parport_pc', where the rmmod case disables the ECP parallel port resources,
and they need to be enabled again to initialize the module. This didn't
work, resulting in a non-printing printer.

The application doing exactly the above to force reprobing of printers is
the YaST printer module. Thus without this fix YaST wedged the printer when
configuring it, and was not able to print a test page.

Reported-by: Ralf Flaxa <rf@suse.de>
Reproduced-by: Jiri Dluhos <jdluhos@suse.cz>
Signed-off-by: Vojtech Pavlik <vojtech@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
eiichiro.oiwa.nm@hitachi.com b5e4efe7e0 PCI: Turn pci_fixup_video into generic for embedded VGA
pci_fixup_video turns into generic code because there are many platforms need this fixup
for embedded VGA as well as x86. The Video BIOS integrates into System BIOS on a machine
has embedded VGA although embedded VGA generally don't have PCI ROM. As a result,
embedded VGA need the way that the sysfs rom points to the Video BIOS of System
RAM (0xC0000). PCI-to-PCI Bridge Architecture specification describes the condition whether
or not PCI ROM forwards VGA compatible memory address. fixup_video suits this specification.
Although the Video ROM generally implements in x86 code regardless of platform, some
application such as X Window System can run this code by dosemu86. Therefore,
pci_fixup_video should turn into generic code.


Signed-off-by: Eiichiro Oiwa <eiichiro.oiwa.nm@hitachi.com>
Acked-by: Alan Cox <alan@redhat.com>
Acked-by: Jesse Barnes <jesse.barnes@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:11 -07:00
Daniel Ritz bacedce32b PCI: add ICH7/8 ACPI/GPIO io resource quirks
Signed-off-by: Daniel Ritz <daniel.ritz@gmx.ch>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:10 -07:00
Andrew Morton 3ec6a8d02e PCI: pcie-check-and-return-bus_register-errors fix
__must_check goes on the declaration, not the definition.

Cc: "Randy.Dunlap" <rdunlap@xenotime.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:10 -07:00
Daniel Drake 09d6029f43 PCI: VIA IRQ quirk behaviour change
The most recent VIA IRQ quirk changes have broken various VIA devices for
some users.  We are not able to add these devices to the blacklist as they
are also available in PCI-card form, and running the quirk on these devices
brings us back to square one (running the VIA quirk on non-VIA boards where
the quirk is not needed).

This patch, based on suggestions from Sergey Vlasov, implements a scheme
similar to but more restrictive than the scheme we had in 2.6.16 and
earlier.  It runs the quirk on all VIA hardware, but *only* if a VIA
southbridge was detected on the system.

To further reduce the amount of quirked devices, this patch includes a
change suggested by Linus at http://lkml.org/lkml/2005/9/27/113 This
ensures that devices bound to non-legacy IO-APIC interrupt lines are not
quirked.  We have made one change to Linus' suggestion: we do a comparison
of ">15" rather than ">=15", as 15 is still in the legacy interrupt range.

There is still a downside to this patch: if the user inserts a VIA PCI card
into a VIA-based motherboard, in some circumstances the quirk will also run
on the VIA PCI card.  This corner case is hard to avoid.

Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:10 -07:00
Eric Sesterhenn 9ef9977cab pciehp: Remove unnecessary check in pciehp_ctrl.c
this was spotted by coverity (cid #819). We dereference p_slot
earlier in the function, and i found no way it could become NULL
anywhere.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:10 -07:00
Kenji Kaneshige dd5619cb44 pciehp - add missing locking
This patch fixes the problem that system will panic if multiple power
on/off operations are issued to the same slot in parallel. This
problem can be easily reproduced by commands below.

    # while true; do echo 1 > power; echo 0 > power; done &
    # while true; do echo 1 > power; echo 0 > power; done &

The cause is lack of locking for enable/disable operations. This patch
fixes this problem.

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:10 -07:00
Kenji Kaneshige 49ed2b4963 pciehp: fix improper info messages
The slot number displayed in info messages would cause a confusion
because those are displayed in several ways (decimal and hex).
Furthermore, those slot number is not same as slot name (directory
name). This patch fixes those improper info messages.

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:10 -07:00
Kenji Kaneshige b4a1efffcf shpchp: fix shpchp_wait_cmd in poll
This patch fixes the problem that issuing SHPC command in poll mode
always fails with the following message.

        shpchp: Command not completed in 2000 msec

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-18 11:36:10 -07:00
Stefan Weinhuber 867dcd0f32 [S390] dasd: clean up timer.
Clean up dasd timer when when a dasd device is set offline.

Signed-off-by: Stefan Weinhuber <wein@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2006-10-18 18:30:53 +02:00
Melissa Howland 2c91971f84 [S390] monwriter find header logic.
Fix logic for finding matching buffers.

Signed-off-by: Melissa Howland <melissah@us.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2006-10-18 18:30:49 +02:00
Cornelia Huck 85a4aa64a8 [S390] cio: sch_no -> schid.sch_no conversion.
Overlooked one sch_no -> schid.sch_no conversion.

Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2006-10-18 18:30:47 +02:00
Peter Oberparleiter 8b42f5c202 [S390] cio: invalid device operational notification
Reset device operational notification flag when channel paths become
unavailable during path verification.

Signed-off-by: Peter Oberparleiter <peter.oberparleiter@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2006-10-18 18:30:43 +02:00
Ben Collins 996f324767 [valkyriefb] Ifdef for when CONFIG_NVRAM isn't enabled.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:53:37 -04:00
Ben Collins f3f6f9aace [platinumfb] Ifdef for when CONFIG_NVRAM isn't enabled.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:52:48 -04:00
Ben Collins b023429ca3 [igafb] Add pci dev table for module auto loading.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:50:49 -04:00
Ben Collins 4938d3f4f8 [controlfb] Ifdef for when CONFIG_NVRAM isn't enabled.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:49:31 -04:00
Ben Collins d57cdcffe1 [hid-core] TurboX Keyboard needs NOGET quirk.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:47:37 -04:00
Ben Collins d77f09e51f [ixj] Add pci dev table for module auto loading.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:45:30 -04:00
Ben Collins 0128873278 [initio] Add pci dev table for module auto loading.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:40:57 -04:00
Ben Collins 3985b97744 [fdomain] Add pci dev table for module auto loading.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:38:41 -04:00
Ben Collins 745b5715fa [BusLogic] Add pci dev table for auto module loading.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:36:57 -04:00
Ben Collins 4596c75c23 [mv643xx] Add pci device table for auto module loading.
Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:33:03 -04:00
Ben Collins 5cacb9f8bc [alim7101] Add pci dev table for auto module loading.
Also fixes comment for nowayout module param.

Signed-off-by: Ben Collins <bcollins@ubuntu.com>
2006-10-18 08:24:30 -04:00
David S. Miller 872ec64847 [SPARC] {bbc_,}envctrl: Use call_usermodehelper().
We should not be calling kernel_execve() directly and this
causes module build failures because kernel_execve() is not
exported to modules.

Signed-off-by: David S. Miller <davem@davemloft.net>
2006-10-17 19:28:52 -07:00
Ben Collins b48194bf0d [SPARC]: Fix some section mismatch warnings in sparc drivers.
Signed-off-by: Ben Collins <ben.collins@ubuntu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-10-17 19:28:51 -07:00
Linus Torvalds 9950421c1e Fix USB gadget net2280.c compile
It would fail the compile due to the newly added error checking testing
a bad macro for a "return value" unless USB_GADGET_DEBUG_FILES was
enabled.

Pointed out by Stephen Hemminger.

Acked-by: Stephen Hemminger <shemminger@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-17 18:03:33 -07:00
Linus Torvalds 699ddda6ec 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: (47 commits)
  USB: Add device id for Sierra Wireless MC8755
  USB: cleanup sierra wireless driver a bit
  USB: Sierra Wireless driver update
  USB: ftdi_sio whitespace fixes
  USB-SERIAL:cp2101 Add new device ID
  USB/gadget/net2280: handle sysfs errors
  usbtouchscreen: fix data reading for ITM touchscreens
  UEAGLE: fix ueagle-atm Oops
  USB: xpad: dance pad support
  USB: input: extract() and implement() are bit field manipulation routines
  USB: Memory leak in drivers/usb/serial/airprime.c
  USB Storage: unusual_devs.h entry for Sony Ericsson P990i
  USB: fix usbatm tiny race
  USB: unusual_devs entry for Nokia 6234
  USB: mos7840.c: fix a check-after-dereference
  USB: ftdi-elan.c: remove dead code
  USB: Mitsumi USB FDD 061M: UNUSUAL_DEV multilun fix
  USB: fix dereference in drivers/usb/misc/adutux.c
  USB: add USB serial mos7720 driver
  USB: move trancevibrator.c to the proper usb directory
  ...
2006-10-17 15:05:22 -07:00
Linus Torvalds acbb67d51e 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/mthca: Use mmiowb after doorbell ring
  IB/ipath: Initialize diagpkt file on device init only
  RDMA/amso1100: Fix a NULL dereference in error path
  RDMA/amso1100: pci_module_init() conversion
2006-10-17 15:04:45 -07:00
Jan Luebbe ab352c2687 USB: Add device id for Sierra Wireless MC8755
Adds the device id used by the UMTS cards in Lenovo X60s notebooks sold
in Europe.

Signed-off-by: Jan Luebbe <jluebbe@lasnet.de>
Cc: Kevin Lloyd <linux@sierrawireless.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:34 -07:00
Greg Kroah-Hartman 964ee1deb3 USB: cleanup sierra wireless driver a bit
This saves over 30 lines and fixes a warning from sparse and allows
debugging to work dynamically like all other usb-serial drivers.

Cc: Kevin Lloyd <linux@sierrawireless.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:34 -07:00
Kevin Lloyd 033a3fb980 USB: Sierra Wireless driver update
The largest feature in this patch is that it adds significant throughput
increase to the Sierra driver and adds support for modem status line
control (e.g. the DTR line). This patch also updates the current sierra.c
driver so that it supports both 3-port Sierra devices and 1-port legacy
devices and removes Sierra's references in other related files (Kconfig and
airprime.c).

Signed-off-by: Kevin Lloyd  <linux@sierrawireless.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:34 -07:00
David Brownell 5c09d144ff USB: ftdi_sio whitespace fixes
Whitespace fixups for drivers/usb/serial/ftdi_sio.c ...
removing end-of-line whitespace, and space-before-tab.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:34 -07:00
Craig Shelley 61926b975d USB-SERIAL:cp2101 Add new device ID
This patch adds device ID 0xEA61. This is another factory default ID
used by SILabs.

Signed-off-by: Craig Shelley <craig@microtron.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:34 -07:00
Jeff Garzik b3899dacaf USB/gadget/net2280: handle sysfs errors
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:34 -07:00
Daniel Ritz 5dfb5f1d06 usbtouchscreen: fix data reading for ITM touchscreens
ITM devices seem to report only garbage when not touched. update usbtouchscreen
to do data reading like itmtouch. also fix wrong mask on pressure bits.

Signed-off-by: Daniel Ritz <daniel.ritz@gmx.ch>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:34 -07:00
matthieu castet 9ab99c8c51 UEAGLE: fix ueagle-atm Oops
The array of attribute passed to sysfs_create_group() must be
NULL-terminated.

The sysfs entries are created before the start of the modem state machine
to avoid to stop it in case of errors in sysfs creation.  Also
{destroy,create}_fs_entries are removed as they do nothing.

Signed-off-by: Laurent Riffard <laurent.riffard@free.fr>
Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Dominic Cerquetti deb8ee43a2 USB: xpad: dance pad support
Adds support for dance pads to the xpad driver. Dance pads require the
d-pad to be mapped to four buttons instead of two axes, so that
combinations of up/down and left/right can be hit simultaneously.
Known dance pads are detected, and there is a module parameter added
to default unknown xpad devices to map the d-pad to buttons if this is
desired. (dpad_to_buttons). Minor modifications were made to port the
changes in the original patch to a newer kernel version.

This patch was originally from Dominic Cerquetti originally written
for kernel 2.6.11.4, with minor modifications (API changes for USB,
spelling fixes to the documentation added in the original patch) made
to apply to the current kernel. I have modified Dominic's original
patch per some suggestions from Dmitry Torokhov. (There was nothing
in the patch format description about multiple From: lines, so I
haven't added myself.)

[akpm@osdl.org: cleanups]
Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
Acked-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Grant Grundler 4550718f6c USB: input: extract() and implement() are bit field manipulation routines
extract() and implement() have brain damaged attempts to handle 32-bit wide
"fields".

The problem is the index math in the original code didn't clear all the
relevant bits.  (offset >> 5) only compensated for 32-bit index.  We need
(offset >> 6) if we want to use 64-bit loads.

But it was also wrong in that it tried to use quasi-aligned loads.  Ie
"report" was only incremented in multiples of 4 bytes and then the offset
was masked off for values greater than 4 bytes.  The right way is to
pretend "report" points at a byte array.  And offset is then only minor
adjustment for < 8 bits of offset.  "n" (field width) can then be as big as
24 (assuming 32-bit loads) since "offset" will never be bigger than 7.

If someone needs either function to handle more than 24-bits, please
document why - point at a specification or specific USB hid device - in
comments in the code.

extract/implement() are also an eyesore to read.  Please banish whoever
wrote it to read CodingStyle 3 times in a row to a classroom full of 1st
graders armed with rubberbands.  Or just flame them.  Whatever.  Globbing
all the code together on two lines does NOT make it faster and is Just
Wrong.

I've tested this patch on j6000 (dual 750Mhz PA-RISC, 32-bit 2.6.12-rc5). 
Kyle McMartin tested on c3000 (up 400Mhz PA-RISC, same kernel).  "p2-mate"
(Peter De Schrijver?) tested on sb1250 (dual core Mips, broadcom "swarm"
eval board).

Signed-off-by: Grant Grundler <grundler@parisc-linux.org>
Signed-off-by: Matthew Wilcox <matthew@wil.cx>
Cc: Vojtech Pavlik <vojtech@suse.cz>
Cc: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Eric Sesterhenn 0e185b7922 USB: Memory leak in drivers/usb/serial/airprime.c
the commit
http://www.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=5dda171202f94127e49c12daf780cdae1b4e668b
added a memory leak.  In case we cant allocate an urb, we dont free the
buffer and leak it.  Coverity id #1438

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Acked-by: Andy Gay <andy@andynet.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Jan Mate c0fc0ee06f 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-10-17 14:46:33 -07:00
Andrew Morton 521b600b58 USB: fix usbatm tiny race
ia64:

drivers/usb/atm/usbatm.c: In function `usbatm_do_heavy_init':
drivers/usb/atm/usbatm.c:1004: warning: implicit declaration of function `get_current'
drivers/usb/atm/usbatm.c:1004: error: invalid type argument of `->'

Signed-off-by: Duncan Sands <baldrick@free.fr>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Alan Stern 3ccf25ce18 USB: unusual_devs entry for Nokia 6234
This patch (as803) adds an unusual_devs entry for the Nokia 6234
mobile phone.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Adrian Bunk ad18027f49 USB: mos7840.c: fix a check-after-dereference
This patch fixes an obvious check-after-dereference spotted by the
Coverity checker.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Adrian Bunk c19ecd6542 USB: ftdi-elan.c: remove dead code
The Coverity checker spotted this obviously dead code.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Tobias Lorenz 1ff15e8efc USB: Mitsumi USB FDD 061M: UNUSUAL_DEV multilun fix
From: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Phil Dibowitz <phil@ipom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Eric Sesterhenn a65dc301c7 USB: fix dereference in drivers/usb/misc/adutux.c
in two of the error cases, dev is still NULL,
and we dereference it. Spotted by coverity (cid#1428, 1429)

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Cc: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:33 -07:00
Greg Kroah-Hartman 0f64478cbc USB: add USB serial mos7720 driver
Add support for Moschip 7720 USB dual port usb to serial device.

This driver is originally based on the drivers/usb/io_edgeport.c driver.

Cleaned up and forward ported by me.

Cc: VijayaKumar <vijaykumar@aspirecom.net>
Cc: AjayKumar <ajay@aspirecom.net>
Cc: Gurudeva <gurudev@aspirecom.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Greg Kroah-Hartman 9fcde23527 USB: move trancevibrator.c to the proper usb directory
It's not a input driver, so it doesn't belong in the input directory.


Cc: Sam Hocevar <sam@zoy.org>
Cc: Dmitry Torokhov <dtor@insightbb.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Arnd Bergmann a9fc6338bd usbnet: add a mutex around phy register access
When working on the mcs7830, I noticed the need for a mutex in its
mdio_read/mdio_write functions. A related problem seems to be present
in the asix driver in the respective functions.

This introduces a mutex in the common usbnet driver and uses it
from the two hardware specific drivers.

Acked-by: David Hollis <dhollis@davehollis.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Arnd Bergmann c41286fd42 usbnet: improve generic ethtool support
This adds generic support for the ethtool commands get_settings,
set_settings, get_link and nway_reset to usbnet. These are now
implemented using mii functions when a low-level driver supports
mdio_read/mdio_write and does not override the usbnet ethtool
commands with its own.

Currently, this applies to the asix and the mcs7830 drivers.
I have tested it on mcs7830.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: David Hollis <dhollis@davehollis.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Arnd Bergmann 2a36d70834 USB: driver for mcs7830 (aka DeLOCK) USB ethernet adapter
This driver adds support for the DeLOCK USB ethernet adapter
and potentially others based on the MosChip MCS7830 chip.

It is based on the usbnet and asix drivers as well as the
original device driver provided by MosChip, which in turn
was based on the usbnet driver.

It has been tested successfully on an OHCI, but interestingly
there seems to be a problem with the mcs7830 when connected to
the ICH6/EHCI in my thinkpad: it keeps receiving lots of
broken packets in the RX interrupt. The problem goes away when
I'm using an active USB hub, so I assume it's not related to
the device driver, but rather to the hardware.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Akinobu Mita 27d39e2627 usb devio: handle class_device_create() error
This patch adds missing class_device_create() error check,
and makes notifier return NOTIFY_BAD.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Alexey Dobriyan f8ac232ad7 USB: drivers/usb/net/*: use BUILD_BUG_ON
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Alan Stern d5477c1111 usbcore: fix endpoint device creation
This patch (as800) straightens out the USB endpoint class device
creation routine, fixing a refcount bug in the process.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Alan Stern c40fd5ea56 usbcore: fix refcount bug in endpoint removal
This patch (as799) fixes a nasty refcount error in the USB endpoint class.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:32 -07:00
Linus Torvalds 22a60f1951 Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
  [ARM] switch to new pci_get_bus_and_slot API
  [ARM] Update mach-types
  [ARM] Fix Zaurii keyboard/touchscreen drivers
  [ARM] Fix fallout from IRQ regs changes
  [ARM] 3890/1: [Jornada7xx] Addition of MCU commands into jornada720.h
  [ARM] 3889/1: [Jornada7xx] Addition of correct SDRAM params into cpu-sa1110.c
  [ARM] 3888/1: add pxa27x SSP FSRT register bit definition
2006-10-17 14:46:31 -07:00
Alan Stern b62df45169 UHCI: workaround for Asus motherboard
This patch (as798) adds a workaround to uhci-hcd.  At least one Asus
motherboard is wired in such a way that any device attached to a
suspended UHCI controller will prevent the system from entering
suspend-to-RAM by immediately waking it up.  The only way around the
problem is to turn the controller off instead of suspending it.

This fixes Bugzilla #6193.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
Greg Kroah-Hartman 96a518928e USB: ftdi-elan: fix sparse warnings
Deleted some unused code that could do bad things on non-x86 platforms.

Also fixed some minor formatting errors.

Thanks to Al Viro for pointing out the sparse errors.

Cc: Tony Olech <tony.olech@elandigitalsystems.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
Oliver Neukum 516077c1ee USB: fix suspend support for usblp
this implements suspend support for usblp. According to the CUPS people
ENODEV will make CUPS retry the job. Thus it is returned in the runtime
case. My printer survives suspend/resume cycles with it.

Signed-off-by: Oliver Neukum <oliver@neukum.name>
Signed-off-by: Vojtech Pavlik <vojtech@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
Duncan Sands 44960af1b6 cxacru: add the ZTE ZXDSL 852
From http://doc.ubuntu-fr.org/materiel/zxdsl852.

Signed-off-by: Duncan Sands <baldrick@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
Duncan Sands 6a4f1b4135 speedtch: "extended reach"
The speedtouch modem setup code was reverse engineered many years
ago from a prehistoric windows driver. Less ancient windows drivers,
even those from a few years ago, perform extra initialization steps
which this patch adds to the linux driver.  David Woodhouse observed
that this initialization along with the firmware bin/sachu3/zzzlp2.eni
from the driver at
http://www.speedtouch.co.uk/downloads/330/301/UK3012%20Extended.zip
improves line sync speeds by about 20%.  He provided the original
patch, which I've modified to use symbolic names (BMaxDSL, ModemMode,
ModemOption) rather than magic numbers.  These names may not seem like
much of an improvement (after all, what is "ModemOption" exactly?),
but they do have one big advantage: they are the names used in the
windows registry.  I've made them available as module parameters.
Thanks are due to Aurelio Arroyo, who noticed the relationship
between these magic numbers and the entries in Phonebook.ini.

Signed-off-by: Duncan Sands <baldrick@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
Duncan Sands ccf40d62c7 usbatm: fix tiny race
If usbatm_do_heavy_init finishes before usbatm_heavy_init
writes the pid, the disconnect method could shoot down the
wrong process if the pid has been recycled.

Signed-off-by: Duncan Sands <baldrick@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
Alan Stern e4a20daa7b USB: unusual_devs entry for Nokia 6131
This patch (as796) adds an unusual_devs entry for the Nokia 6131, which
doesn't like large transfer sizes.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
Jarek Poplawski 762f007b05 USB: fix cdc-acm problems with hard irq? (inconsistent lock state)
Signed-off-by: Jarek Poplawski <jarkao2@o2.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
matthieu castet a7a0c9cd1f UEAGLE : comestic changes
Hi,

this patch does some cosmetic changes :
- dump firwmare version as soon as possible and export it on sysfs
- hint about wrong cmv/dsp
- Display a message to warn user when the modem is ready : it can help
  people to detect problems on the line without debug trace
- Fix wrong indent
- display modem type (pots/isdn)
- increase version number


Signed-off-by: Matthieu Castet <castet.matthieu@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
matthieu castet 531a39bbab UEAGLE : use interruptible sleep
this patch use wait_event_interruptible_timeout and msleep_interruptible
beacause uninterruptible sleep (task state 'D') is counted as 1 towards
load average, like running processes.


Signed-off-by: Matthieu Castet <castet.matthieu@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
matthieu castet 9ca5346483 UEAGLE : be suspend friendly
this patch avoid that the kernel thread block the suspend process.
Some work is still need to recover after a resume.

Signed-off-by: Matthieu Castet <castet.matthieu@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:31 -07:00
David Brownell 8442ae00d4 USB: ohci-pnx4008 build fixes
The OHCI bus glue for the Philips PNX chips is missing a few calls.

 - Bus suspend/resume were wrongly omitted in the original submission.
 - Two new calls were added since that glue was submitted:
     * Root hub irq enable call
     * Shutdown hook for usbcore

Plus usb_bus.hcpriv has now been removed from usbcore.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Oliver Neukum 1a2ea1dfc4 USB: suspend/resume support for kaweth
this adds support for suspend and resume to the kaweth driver.

Signed-off-by: Oliver Neukum <oliver@neukum.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Oliver Neukum fbe2bafcb0 USB: remove private debug macros from kaweth
this kills the private debug macros from the kaweth driver.

Signed-off-by: Oliver Neukum <oliver@neukum.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Chris Malley 91a9c9214e USB: Support for BT On-Air USB modem in cdc-acm.c
The patch below is a necessary workaround to support the BT On-Air USB modem, which
fails to initialise properly during normal probing thus:

Sep 30 17:34:57 sled kernel: drivers/usb/class/cdc-acm.c: Zero length descriptor references
Sep 30 17:34:57 sled kernel: cdc_acm: probe of 1-1.2:1.0 failed with error -22

Adding the patch below causes the probing section to be skipped, and the modem
then initialises correctly.

Signed-off-by: Chris Malley <mail@chrismalley.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Luiz Fernando N. Capitulino 931b0411ac airprime: New device ID.
Adds support for the verizon wireless Broadband Access, National Access V640
ExpressCard34 Qualcomm 3G CDMA.

Reported by Maciej A. __enczykowski <maze@google.com>

Signed-off-by: Luiz Fernando N. Capitulino <lcapitulino@mandriva.com.br>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Eric Sesterhenn 2daa48729d USB: fix use after free in wacom_sys.c
the following commit added a use after free
http://www.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=3D3bea733ab21247290bd552dd6a2cd3049af9adef
Found by coverity (cid #1441)

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: "Ping Cheng" <pingc@wacom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Eric Sesterhenn 2920349d43 USB: BUG_ON conversion for wacom.c
this patch converts two if () BUG(); construct to BUG_ON();
which occupies less space, uses unlikely and is safer when
BUG() is disabled.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Acked-by: "Ping Cheng" <pingc@wacom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Ping Cheng 8d32e3ae59 USB: Wacom driver updates
This fixes some issues with the current wacom driver due to the split of
the driver into different pieces and adds support for the Intuos3 4x6

Signed-off-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 14:46:30 -07:00
Greg Kroah-Hartman 64f89798da USB: revert EHCI VIA workaround patch
This reverts 26f953fd88 which caused
resume problems on the mac mini.

Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-10-17 13:57:18 -07:00
Stephen Hemminger 4e4bc305e1 sky2: GMAC pause frame
This reverts earlier change that attempted to fix flow control.
Device needs to discard pause frames, otherwise it hangs after a while.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:25 -07:00
Stephen Hemminger a052b52f4b sky2: accept multicast pause frames
When using flow control, the PHY needs to accept multicast pause frames.
Without this fix, these frames were getting discarded by the PHY before
doing any flow control.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:23 -07:00
Stephen Hemminger 52c89cac67 sky2: version 1.9
Mark version, this has been a lot of patches.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:18 -07:00
Stephen Hemminger b6d7773462 sky2: no message on rx fifo overflow
Under high load it is possible to make the receiver FIFO get overloaded.
The driver/hardware recover properly, so there is no reason to fill the log
with lots of extra messages, just update counter.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:16 -07:00
Stephen Hemminger 16ad91e1c6 sky2: flow control setting fixes
The result of flow control negotiation should not limit the next
negotiatition. If board is plugged into an old half duplex 10Mbit port,
without pause, then replugged into a gigabit port, it should negotiate
what is desired, not inherit that last negotiation.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:13 -07:00
Stephen Hemminger 7800fddcd0 sky2: don't reset PHY twice
Don't need to reset PHY twice on startup.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:10 -07:00
Stephen Hemminger 7c74ac1c23 sky2: use duplex result bits
The result of duplex negotiation is avaliable in the phy status
register, so use that to simplify code and avoid rereading the PHY.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:08 -07:00
Stephen Hemminger 0edea0f54e sky2: advertising register 16 bits
The advertising bits (from ethtool.h) fit in 16 bits.
2006-10-17 10:24:07 -07:00
Stephen Hemminger 709c6e7bb0 sky2: fiber pause bits
The advertisement bits for flow control are located in
different location on fiber (1000baseX)

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:24:04 -07:00
Stephen Hemminger ebc646f681 sky2: phy irq on shutdown
When PHY is turned off on shutdown, it causes the IRQ to get stuck on.
Make sure and disable the IRQ first, and if IRQ occurs when device
is not running, don't access PHY because that will hang.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:23:56 -07:00
Stephen Hemminger e561a83be5 sky2: turn of workaround timer
The workaround timer is not needed in most systems with proper IRQ
routing and by perodically waking up it adds to laptop power consumption.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:20:51 -07:00
Stephen Hemminger 2bffc23a01 sky2: MSI test is only a warning
Some motherboards don't implement MSI correctly. The driver handles this
but the warning is too verbose and overly cautious.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
2006-10-17 10:17:18 -07:00
Linus Torvalds 43f82216f0 Merge git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
* git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: fm801-gp - handle errors from pci_enable_device()
  Input: gameport core - handle errors returned by device_bind_driver()
  Input: serio core - handle errors returned by device_bind_driver()
  Lockdep: fix compile error in drivers/input/serio/serio.c
  Input: serio - add lockdep annotations
  Lockdep: add lockdep_set_class_and_subclass() and lockdep_set_subclass()
  Input: atkbd - supress "too many keys" error message
  Input: i8042 - supress ACK/NAKs when blinking during panic
  Input: add missing exports to fix modular build
2006-10-17 08:56:43 -07:00
Jeff Garzik 7786ce192f [PATCH] ISDN: check for userspace copy faults
Most of the ISDN ->readstat() implementations needed to check
copy_to_user() and put_user() return values.

Signed-off-by: Jeff Garzik <jeff@garzik.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-17 08:18:49 -07:00
Jeff Garzik 04518bfe8e [PATCH] ISDN: fix drivers, by handling errors thrown by ->readstat()
This is a particularly ugly on-failure bug, possibly security, since the
lack of error handling here is covering up another class of bug: failure to
handle copy_to_user() return values.

The I4L API function ->readstat() returns an integer, and by looking at
several existing driver implementations, it is clear that a negative return
value was meant to indicate an error.

Given that several drivers already return a negative value indicating an
errno-style error, the current code would blindly accept that [negative]
value as a valid amount of bytes read.  Obvious damage ensues.

Correcting ->readstat() handling to properly notice errors fixes the
existing code to work correctly on error, and enables future patches to
more easily indicate errors during operation.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Cc: Karsten Keil <kkeil@suse.de>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-17 08:18:49 -07:00