This patch changes sata_promise so that the PATA ports
on TX2plus chips are bound to the pdc_pata_ops structure.
This means that operations called from the SATA ops
structures don't need any SATA-vs-PATA tests any more.
Instead, operations that depend on a port being SATA or
PATA are separated into different procedures.
* pdc_cable_type() is split into a PATA version and a
SATA version
* pdc_error_handler() is split into a PATA version and a
SATA version, that both call a common version after
setting up the `hardreset' function pointer
* pdc_old_check_atapi_dma() is now only used for SATAI
ports, so is renamed to pdc_old_sata_check_atapi_dma()
and simplified
* pdc_sata_scr_{read,write}() are now only used for SATA
ports, so their is-not-SATA tests are removed
* pdc_port_start() is split into three procedures: a wrapper
which performs the ->ops adjustment on TX2plus PATA ports,
a procedure with the common code, and a procedure with
the SATA-specific code (this bit might be cleaned up by
Tejun's new init model)
Tested on 20619, 20575, and 20775 chips.
Signed-off-by: Mikael Pettersson <mikpe@it.uu.se>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The recent change which moved cable detection from
pdc_pre_reset() to the new ->cable_detect hook only
added the hook for SATAII chips, leaving SATAI chips
and the 20619 without the hook. Fixed by this patch.
Signed-off-by: Mikael Pettersson <mikpe@it.uu.se>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Both old-IDE and libata should be able handle all controllers and
devices found using normal resource reservation methods.
This eliminates the awful, low-performing split-driver configuration
where old-IDE drove the PATA portion of a PCI device, in PIO-only mode,
and libata drove the SATA portion of the /same/ PCI device, in DMA mode.
Typically vendors would ship SATA hard drive / PATA optical
configuration, which would lend itself to slow (PIO-only) CD-ROM
performance.
For Intel users running in combined mode, it is now wholly dependent on
your driver choice (potentially link order, if you compile both drivers
in) whether old-IDE or libata will drive your hardware.
In either case, you will get full performance from both SATA and PATA
ports now, without having to pass a kernel command line parameter.
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The previous commit erroneously noted that the !IORDY filter was turned
on. No true, that change was split out into this commit.
Originally authored and signed-off-by Alan Cox.
Signed-off-by: Jeff Garzik <jeff@garzik.org>
With Tejun having added adev->ap some time ago we can get rid of the
almost unused port being passed to mode filters. And while we are
doing filters, lets turn on the !IORDY filter as well.
Signed-off-by: Alan Cox <alan@redhat.com>
With some hand massaging from
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Now that we have ata_do_set_mode() available for drivers to use we don't
actually need ->post_set_mode() as the driver can wrap set_mode nicely
and do stuff before or after (eg PCMCIA needs before), so we can kill off
a method in all the structs
While I was at it I added kernel-doc to the function involved.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
This alone isn't sufficient to save the universe from prehistoric disks
and controllers but it is a first important step. Split off a separate
function to provide a mode filter when controller iordy is not available.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
This splits set_mode into do_set_mode and the wrapper so that a driver can
call the standard method inside its own. This in theory also obsoletes
->post_set_mode().
Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Tejun Heo <htejun@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Drag pata_hpt37x kicking and screaming in the direction of
drivers/ide/pci/hpt366.c and all the work that Sergei has been doing
there. Plenty left to be done but this is a good snapshot for folks to
work on and to review
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Fix suspend/resume support
Write 0x5B to 0 not 0x5C
The former is important as we must kill the FIFO on a resume
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
We end up shifting a few bits of logic around in this driver but the
basic change is the same.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
This changeset revolves around the fact that all the SiS controllers have
the same enable bits, but differing cable detection methods. Previously
that meant each type had its own error_handler methods. Instead we can
now implement different ->cable_detect methods and share a single
error_handler which does the filtering by enable bits.
In addition we had some auto const arrays that should be static const. I'm
not sure if gcc already treats them intelligently but adding the static
will make sure.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
There are two changes here. Firstly we switch to a cable detect method,
secondly the old code forgot to call ata_std_prereset() but somehow
managed to work anyway. Fix the missing call.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
All patches authored and signed-off-by Alan Cox, sent on Mar 7, 2007.
I merely combined them all into a single patch.
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Added Support for Marvell 7042 Chip - 7042 has same capabilities & behavior
as 6042.
Signed-off-by: Thomas A. Morrison <tmorrison@empirix.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Support for the PCI CMD640 (not VLB)
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2.6.21-rc has horrible problems with libata and PATA cable types (and
thus speeds). This occurs because Tejun fixed a pile of other bugs and
we now do cable detect enforcement for drive side detection properly.
Unfortunately we don't do the process around cable detection right. Tejun
identified the problem and pointed to the right Annex in the spec, this patch
implements the rest of the needed changes.
We add a ->cable_detect() method called after the identify
sequence which allows a host to do host side detection at this point
should it wish, or to modify the results of the drive side identify.
This separate ->cable_detect method also cleans up a lot of code because
many drivers have their own error_handler methods which really just set
the cable type.
If there is no ->cable_detect method the cable type is left alone so a
driver setting it earlier (eg because it has the SATA flags set or
because it uses the old error_handler approach) will still do the right
thing (or at least the same thing) as before.
This patch simply adds the cable_detect method and helpers it doesn't use
them but other follow up patches will (ie Adrian please don't submit
patches to unexport them ;))
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Since commit:553c4aa630af7bc885e056d0436e4eb7f238579b
ata_pci_device_do_resume() can return error code, all callers was updated
except this one.
Signed-off-by: Monakhov Dmitriy <dmonakhov@openvz.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Warn the user if a drive's transfer rate is limited because of a 40-wire
cable detection.
Signed-off-by: Robert Hancock <hancockr@shaw.ca>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Resending, with s/printk/DPRINTK/ as pointed out by Alan.
Fix libata to perform CDB len validation per device
rather than per host. This way, validation still works
when we have a mix of 12-byte and 16-byte devices on
a common host interface.
Signed-off-by: Mark Lord <mlord@pobox.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
It used to be impossible to get from ata_device to ata_port but that is
no longer true. Various methods have been cleaned up over time but
dev_config still takes both and most users don't need both anyway. Tidy
this one up
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The chips covered by sata_mv have a 32-bit DMA boundary they must not
cross, not a 64K boundary. We are merely limited to a 64K maximum
segment size. Therefore, the DMA scatter/gather table fill code can be
greatly simplified, and we need not cut in half the S/G table size as
reported to the SCSI layer.
Also, the driver forget to turn on 64-bit DMA at the PCI layer. All
other data structures (both hardware and software) have been prepped for
64-bit PCI DMA. It was simply never turned on. <fingers crossed> let's
see if it still works...
Signed-off-by: Jeff Garzik <jeff@garzik.org>
the patch below fixes compilation breakage of smc911x driver when
ENABLE_SMC_DEBUG_PKTS equals to 1.
Signed-off-by: Vitaly Wool <vitalywool@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
A few corrections related to time_after and time_before in
drivers/net/eexpress.c as suggested by Marcin slusarz.
Signed-off-by: Shani Moideen <shani.moideen@wipro.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Patch to add NAPI support to sb1250-mac.c (rev 2). This patch differs from
the last in that the NAPI support isn't marked as experimental, nor is it
configurable (ie. once applied - NAPI is enabled all the time). This was
based on feedback from Ralf and others.
Signed-off-by: Mark Mason <mason@broadcom.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
It appears that some systems still like e100 better if it uses
I/O access mode. Setting the new parameter use_io=1 will cause
all driver instances to use io mapping to access the register
space on the e100 device.
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Seved Torstendahl <seved.torstendahl@netinsight.net> suggested to
let the module parameter for invalid eeprom checksum control the valid
mac address test.
If this bypass happens we should print a different message,
or at least one that is correct, maybe something like below
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Certain resources may only be allocated when first logical port is available,
and must be removed when last logical port has been removed.
Signed-off-by: Thomas Klein <tklein@de.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Create symbolic link from each logical port to ehea driver
Signed-off-by: Thomas Klein <tklein@de.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Remove the apparently redundant include of <linux/pm_legacy.h>.
Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
NetXen: Fix vmalloc errors on seen on some X86 high end machines.
Signed-off by: Milan Bag <mbag@netxen.com>
Acked-by: Mithlesh Thukral <mithlesh@netxen.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
NetXen: Fix PPC architecture specific bugs
Fixes some issues seen on Big endian machines.
Signed-off by: Milan Bag <mbag@netxen.com>
Signed-off by: Mithlesh Thukral <mithlesh@netxen.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
NetXen: Port Swap feature
This patch will allow a port numbers on the card to be swapped in
host driver. This feature is applicable to cards having more than
1 port.
Signed-off by: Milan Bag <mbag@netxen.com>
Signed-off by: Mithlesh Thukral <mithlesh@netxen.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
NetXen: Fix the multi PCI function for cards with more than 2 ports.
This patch fixes the working of multi PCI capable driver on cards with
more than 2 ports by adding the addresses for their rings and sizes.
Signed-off by: Mithlesh Thukral <mithlesh@netxen.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
NetXen: Removal of redundant function call parameters and bug fixes.
This patch will remove the redundant paramters which were being passed to
many functions since now adapter->portnum can be used.
Signed-off-by: Mithlesh Thukral <mithlesh@netxen.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
NetXen: Make driver use multiple PCI functions.
This patch will make NetXen driver work with multiple PCI functions. This will
make the usage of memory resources as well as interrupts more independent
among different functions which results in better throughput. This change has
been done after the multiport support is added in firmware.
Signed-off by: Mithlesh Thukral <mithlesh@netxen.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
I was going to say that eepro100's speedo_rx_link() does the same DMA
abuse as e100, but then I noticed one little detail: eepro100 sets both
EL (end of list) and S (suspend) bits in the RFD as it chains it to the
RFD list. e100 was only setting the EL bit. Hmmm, that's interesting.
That means that if HW reads a RFD with the S-bit set, it'll process
that RFD and then suspend the receive unit. The receive unit will
resume when SW clears the S-bit. There is no need for SW to restart
the receive unit. Which means a lot of the receive unit state tracking
code in the driver goes away.
So here's a patch against 2.6.14. (Sorry for inlining it; the mailer
I'm using now will mess with the word wrap). I can't test this on
XScale (unless someone has an e100 module for Gumstix :) . It should
be doing exactly what eepro100 does with RFDs. I don't believe this
change will introduce a performance hit because the S-bit and EL-bit go
hand-in-hand meaning if we're going to suspend because of the S- bit,
we're on the last resource anyway, so we'll have to wait for SW to
replenish.
(cherry picked from 29e79da9495261119e3b2e4e7c72507348e75976 commit)
Add kernel-doc notation to drivers/net/mii.c functions.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/net/ibmveth.c:96:46: error: marked inline, but without a definition
drivers/net/ibmveth.c:96: warning: 'ibmveth_rxq_harvest_buffer' declared inline after being called
drivers/net/ibmveth.c:96: warning: previous declaration of 'ibmveth_rxq_harvest_buffer' was here
Just let the compiler decide, as it happens gcc 4.~ inlines it anyway.
drivers/net/ibmveth.c:957:71: warning: Using plain integer as NULL pointer
drivers/net/ibmveth.c:964:85: warning: Using plain integer as NULL pointer
Split the long lines as well, ugly, but < 80 columns.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The ucc_geth_memclean function can be called before the Tx BD rings, Rx
BD rings and associated socket buffers are allocated (for example if
ucc_fast_init fails). The current code doesn't check if p_tx_bd_ring[i]
is null, generating a kernel panic when trying to free the associated
socket buffers.
The function can also fail when accessing the uninitialized list_head
structures ugeth->group_hash_q and ugeth->ind_hash_q. In the current
implementation the list heads are initialized only when
maxGroupAddrInHash and maxIndAddrInHash are positive values, although I
think it's better to always initialize them.
Signed-off-by: Ionut Nicu <ionut.nicu@freescale.com>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Transmit on Demand: Fix spelling in config option, and make it actually enable TOD.
Signed-off-by: Michael Reiss <michael.f.reiss@freescale.com>
Signed-off-by: Michael Barkowski <michael.barkowski@freescale.com>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The rx interrupt coalescing table alignment was "guessed" to be 4,
but should be 64. The size should be 8 * number of queues + 4.
Verified in the MPC8323E manual.
Signed-off-by: Michael Barkowski <Michael.Barkowski@freescale.com>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Based partly on the gianfar driver, this patch fixes several
bugs which were causing NAPI to be completely unusable.
* An IRQ is still needed in NAPI, to kick off NAPI task,
and for Tx processing. Request the IRQ.
* If rx_work_limit = 0 we are not complete.
* While running Rx NAPI processing we must mask Rx events,
including Rx busy.
* ucc_geth_rx function does not need a lock.
Could lead to deadlock in NAPI case.
* There's no need to loop reading ucce multiple times in the ISR,
so while adding the call to schedule NAPI which was not there,
simplify the event processing into if-else format.
* Rx Busy now kicks off NAPI processing, while still
being counted as an error.
Signed-off-by: Michael Reiss <michael.f.reiss@freescale.com>
Signed-off-by: Michael Barkowski <michael.barkowski@freescale.com>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
migrate ucc_geth to use the common phylib code.
There are several side effects from doing this:
o deprecate 'interface' property specification present
in some old device tree source files in
favour of a split 'max-speed' and 'interface-type'
description to appropriately match definitions
in include/linux/phy.h. Note that 'interface' property
is still honoured if max-speed or interface-type
are not present (backward compatible).
o compile-time CONFIG_UGETH_HAS_GIGA is eliminated
in favour of probe time speed derivation logic.
o adjust_link streamlined to only operate on maccfg2
and upsmr.r10m, instead of reapplying static initial
values related to the interface-type.
o Addition of UEC MDIO of_platform driver requires
platform code add 'mdio' type to id list
prior to calling of_platform_bus_probe (separate patch).
o ucc_struct_init introduced to reduce ucc_geth_startup
complexity.
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Tested by Christoph Sager and Tomas Klas
zd1211b chip 0586:3412 v4810 high 00-13-49 AL7230B_RF pa0 g----
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This patch adds support for some new ZD1211B devices which ship with
the AL7230B RF.
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This change allows RF drivers to provide their own 6M band edge patching
implementation, while providing a generic implementation shared by most
currently supported RF's.
The upcoming ZD1211B/AL7230B code will use this to define its own
patching function, which is different from the other RF configurations.
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
The vendor driver only does the CR123 write for non-USB devices (which
don't exist on the consumer market)
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This patch implements the changes in the specifications for
2050radio_init that were recently posted.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
On Fri, Mar 30, 2007 at 01:05:59AM -0700, Andrew Morton wrote:
>...
> Changes since 2.6.21-rc5-mm2:
>...
> git-netdev-all.patch
>...
> git trees
>...
This patch makes the needlessly global PHY_DEVICES[] static.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Replacing with time_after in drivers/net/eexpress.c
Applies and compiles clean on latest tree.Not tested.
Signed-off-by: Shani Moideen <shani.moideen@wipro.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
There is no good reason for the asymmetry in the parameters of
eth_port_uc_addr_get() and eth_port_uc_addr_set(). Make them
symmetric. Remove some gratuitous block comments while we're here.
Signed-off-by: Gabriel Paubert <paubert@iram.es>
Signed-off-by: Dale Farnsworth <dale@farnsworth.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
This PHY support patch was written by Benjamin Li.
Signed-off-by: Benjamin Li <benjamin.li@qlogic.com>
Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The baycom_ser_fdx driver did not allow i/o ports >= 0x1000. Now that
there are pci cards (with rs232 ports) which use for example 0xb800 this
limit should not exists.
Also, for non kernel coders find the cause of problems was challenging so I
added extra logging.
Signed-off-by: Folkert van Heusden <folkert@vanheusden.com>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
strlcpy already accounts for the trailing zero in its length
computation, so there is no need to substract one to the buffer size.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Jan-Bernd Themann <themann@de.ibm.com>
Cc: Thomas Klein <osstklei@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Tested by TiCPU on irc
zd1211 chip 13b1:001e v4802 high 00-14-bf AL2230_RF pa0 g---
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Using monitor mode, Johannes Berg observed out that lots of corrupted
and otherwise invalid frames were being passed to the host.
When in monitor mode we were disabling the hardware filtering here, but
this is not how monitor mode should work.
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This is a backport of Helge Deller's recent patch for wireless-dev.git
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
After 13 years of use, it looks like my email address is finally going
to disappear. While this is likely to drop the amount of incoming spam
greatly ;-), it may also affect more appropriate messages, so let's
update my email address in various places. In addition, Host AP mailing
list is subscribers-only and linux-wireless can also be used for
discussing issues related to this driver which is now shown in
MAINTAINERS.
Signed-off-by: Jouni Malinen <j@w1.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This patch includes:
- code cleanup related to resource management
- extended error data gathering for resource management
- removing trailing whitespaces
Signed-off-by: Jan-Bernd Themann <themann@de.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The patch fixes bugs related to the probe / remove adapter
functionality (handling of OFDT nodes)
Signed-off-by: Jan-Bernd Themann <themann@de.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
NETPOLL support for Sibyte MAC
Signed-off-by: Manish Lachwani <mlachwani@mvista.com>
Signed-off-by: Deepak Saxena <dsaxena@mvista.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
- Remove unused variables from s2io_nic structure
- Changed the memory failure printk messages to print only in debug mode
- Updated the copyright messages
(Resending; due to patch being corrupted)
Signed-off-by: Santosh Rastapur <santosh.rastapur@neterion.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Do some minor rearrangement of data structures to try and optimize
cache usage.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Don't need to lock when processing transmit complete unless queue fills.
Modeled after tg3.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The following hardware error bits only show up on Genesis chipset
and are handled elsewhere, so they can be masked off.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Cleanup drivers/net/wireless/libertas/debugfs.c to use standard kernel
macros and functions.
Signed-off-by: Tony Breeds <tony@bakeyournoodle.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
The way airo.c keeps track of all its devices is complicated and buggy
as well (del_airo_dev forgets to free the memory add_airo_dev allocates).
It's cleaner to use the standard list primitives.
While we're at it, it's not necessary to put PCI cards in the list, because
the kernel already keeps track of them. We can take advantage of it and
use the .remove callback as it was meant to be.
This makes /sys/bus/pci/drivers/airo/{,un}bind work.
Signed-off-by: Michal Schmidt <mschmidt@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
It's unnecessary to check for NULL before calling kfree().
Signed-off-by: Michal Schmidt <mschmidt@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
In code manipulating the TM State Low register of 802.11 cores, two
different magic numbers are used to reference the 'G Mode Enable' bit.
One of these, 0x20000000, is clear, but the other, (0x800 << 18), is not.
This patch replaces both types with a defined constant. In addition, two
bits in the TM State High registers are given definitions to help in
following the code.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
ASUS A9Rp
Tested by Serge
zd1211b chip 0b05:171b v4802 high 00-17-31 AL2230_RF pa0 g--
ZyXEL G-202
Tested by Marcus D. Hanwell
zd1211b chip 0586:3410 v4810 high 00-13-49 AL2230_RF pa0 g---
US Robotics USR805423
Tested by Pascal S. de Kloe
FCC ID: RAXWN4501H
zd1211b chip 0baf:0121 v4810 high 00-14-c1 AL2230_RF pa0 g--N
Julien Pinon reports this also comes in AL2230S form
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
ZD1211 appears to be back in production: a number of new devices have
been appearing! Some of them are using new radios.
This patch adds support for the next generation AL2230 RF chip which has
been spotted in a few new devices.
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Suggested by Maxime Austruy, based on mac80211 changes from Stephen
Hemminger
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rev tulip version... things have changed since 2002!
Signed-off-by: Valerie Henson <val_henson@linux.intel.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Fix a problem with Tulip 21142 HP branded PCI cards (PN#: B5509-66001),
which feature a NatSemi DP83840A PHY.
Without that patch, it is impossible to properly initialize the card's PHY,
and it's thus impossible to monitor/configure it.
[VAL: I'm happy with the 1.5 ms max delay; it doesn't seem excessive.]
Signed-off-by: Thibaut VARENE <varenet@parisc-linux.org>
Cc: Jeff Garzik <jgarzik@pobox.com>
Acked-by: Grant Grundler <grundler@parisc-linux.org>
Signed-off-by: Valerie Henson <val_henson@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
From: Jim Gifford <maillist@jg555.com>, Grant Grundler <grundler@parisc-linux.org>, Peter Horton <pdh@colonel-panic.org>
With Grant's help I was able to get the tulip driver to work with 64 bit
MIPS.
[VAL: I'm happy with the 1.5 ms max delay; it doesn't seem excessive.]
Signed-off-by: Valerie Henson <val_henson@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Cc: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The tc35815 driver lacks a call to pci_dma_sync_single_for_device() on
receiving. Recent fix of MIPS dma_sync_single_for_cpu() reveal this
bug.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
use netdev_priv() instead of dev->priv
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Don Fry <pcnet32@verizon.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
The patch below moves the init_block out of the private struct and
only allocates init block with pci_alloc_consistent.
This has two effects:
1. Performance increase for non cache coherent machines, because the
CPU only data in the private struct are now cached
2. locks are working now for platforms, which need to have locks
in cached memory
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Acked-by: Don Fry <pcnet32@verizon.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
A patch to use ARRAY_SIZE macro already defined in kernel.h.
Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com>
Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Function `phy_mii_ioctl' returns physical device's information based on
user requests. When requested to return the basic mode control register
information (BMCR), the original implementation only returns the physical
device's duplex information and forgets to return speed information, which
should not be because BMCR register is used to hold both duplex and speed
information.
The patch checks the BMCR value against speed-related flags and fills the
return structure's speed field accordingly.
Signed-off-by: Shan <shanlu@cs.uiuc.edu>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Add support for WOL on Magic Packet and on link change
Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com>
Cc: Valerie Henson <val_henson@linux.intel.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Convert function documentation in drivers/net/phy/ to kernel-doc
and add it to DocBook.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Use the round_jiffies() function in e1000.
These timers all were of the "about once a second" or "about once every X
seconds" variety and several showed up in the "what wakes the cpu up" profiles
that the tickless patches provide. Some timers are highly dynamic based on
network load; but even on low activity systems they still show up so the
rounding is done only in cases of low activity, allowing higher frequency
timers in the high activity case.
The various hardware watchdogs are an obvious case; they run every 2 seconds
but aren't otherwise specific of exactly when they need to run.
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Acked-by: Auke Kok <auke-jan.h.kok@intel.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Current tc35815 driver is very obsolete and less maintained for a long
time. Replace it with a new driver based on one from CELF patch
archive.
Major advantages of CELF version (version 1.23, for kernel 2.6.10) are:
* Independent of JMR3927.
(Actually independent of MIPS, but AFAIK the chip is used only on
MIPS platforms)
* TX4938 support.
* 64-bit proof.
* Asynchronous and on-demand auto negotiation.
* High performance on non-coherent architecture.
* ethtool support.
* Many bugfixes and cleanups.
And improvoments since version 1.23 are:
* TX4939 support.
* NETPOLL support.
* NAPI support. (disabled by default)
* Reduce memcpy on receiving.
* PM support.
* Many cleanups and bugfixes.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
This patch makes the needlessly global vlan_strip_flag static.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Thanks to Jö Fahlke for donating hardware.
Signed-off-by: Ladislav Michl <ladis@linux-mips.org>
Forward porting of Ladis' 2.4 patch.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
This patch provides a functionality that allows parallel
RX processing on multiple RX queues by using dummy netdevices.
Signed-off-by: Jan-Bernd Themann <themann@de.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
This patch introduces functionality to dynamically add / remove
ehea ports via an userspace DLPAR tool. It creates a subnode for
each logical port in the sysfs.
Signed-off-by: Jan-Bernd Themann <themann@de.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
There are several uses of _ops structure in this driver that
can be converted to const.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Convert some initialized structures to C99 style.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Some code for Chelsio 1G boards was put in the driver
based on the vendor version (minus TOE). Well some of those board
versions are only supported with TOE on the vendor driver, so additional
dead code was added.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
In bcm43xx_ethtool, UTS_RELEASE is used. Replacing this with utsname()->release
avoids rebuilding this module each time the kernel version changes.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
It looks like some of the PC Card manfid/product strings were lost
when Host AP driver was converted to use PCMCIA_DEVICE_* helpers. This
patch adds back D-Link DWL-650 Rev. P1 using the same product ID
string match as the pcmcia-cs/cardmgr configuration used before.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
testing much?
Cc: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
The original macros result in gcc 4.2 warning about "cast from pointer
to integer of different size" on 64-bit systems.
Use of offsetof() on fields in substructures is widespread throughout
the kernel code and should work whether offsetof() is defined using
__compiler_offsetof() or a cast.
Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Add the Marvell Libertas 8388 802.11 USB driver.
Signed-off-by: Marcelo Tosatti <marcelo@kvack.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Michael Buesch commented that GFP_NOFS should not be used in a
network driver.
Signed-off-by: Ulrich Kunitz <kune@deine-taler.de>
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Add 'channels' sysfs entry for ipw2200. The entry exports channels
information for the user space.
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Just found a hole in my last patch. It was reported to me that shortly after we
integrated this patch. The report was of an oops that took place inside of
netif_rx when using the sis900 driver. Looking at my origional patch I noted
that there was a spot between the new skb_alloc and the refill_rx_ring label
where skb got reassigned to the pointer currently held in the rx_ring for the
purposes of receiveing the frame. The result of this is however that the buffer
that gets passed to netif_rx (if it is called), then gets placed right back into
the rx_ring. So if you receive frames fast enough the skb being processed by
the network stack can get corrupted. The reporter is testing out the fix I've
written for this below (I'm not near my hardware at the moment to test myself),
but I wanted to post it for review ASAP. I'll post test results when I hear
them, but I think this is a pretty straightforward fix. It just uses a separate
pointer to do the rx operation, so that we don't improperly reassign the pointer
that we use to refill the rx ring.
Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Simplify pegasus carrier detection; rely only on the periodic MII
polling. Reverts pieces of c43c49bd61.
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
* git://git.infradead.org/mtd-2.6: (46 commits)
[MTD] [MAPS] drivers/mtd/maps/ck804xrom.c: convert pci_module_init()
[MTD] [NAND] CM-x270 MTD driver
[MTD] [NAND] Wrong calculation of page number in nand_block_bad()
[MTD] [MAPS] fix plat-ram printk format
[JFFS2] Fix compr_rubin.c build after include file elimination.
[JFFS2] Handle inodes with only a single metadata node with non-zero isize
[JFFS2] Tidy up licensing/copyright boilerplate.
[MTD] [OneNAND] Exit loop only when column start with 0
[MTD] [OneNAND] Fix access the past of the real oobfree array
[MTD] [OneNAND] Update Samsung OneNAND official URL
[JFFS2] Better fix for all-zero node headers
[JFFS2] Improve read_inode memory usage, v2.
[JFFS2] Improve failure mode if inode checking leaves unchecked space.
[JFFS2] Fix cross-endian build.
[MTD] Finish conversion mtd_blkdevs to use the kthread API
[JFFS2] Obsolete dirent nodes immediately on unlink, where possible.
Use menuconfig objects: MTD
[MTD] mtd_blkdevs: Convert to use the kthread API
[MTD] Fix fwh_lock locking
[JFFS2] Speed up mount for directly-mapped NOR flash
...
This patch converts the pci_module_init() usage to pci_register_driver().
It's currently #if 0'ed, but still not a bad idea to change it.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
irqreturn.h for irqreturn_t and dma_addr_t being u128 warnings ;-)
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This patch provides MTD support for NAND flash devices on CM-x270 modules.
Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6: (78 commits)
USB: update MAINAINERS and CREDITS for Freescale USB driver
USB: update gadget files for fsl_usb2_udc driver
USB: add Freescale high-speed USB SOC device controller driver
USB: quirk for broken suspend of IT8152F/G
USB: iowarrior.c: timeouts too small in usb_control_msg calls
USB: dell device id for option.c
USB: Remove Huawei unusual_devs entry
USB: CP2101 New Device IDs
USB: add picdem device to ldusb
usbfs micro optimitation
USB: remove ancient/broken CRIS hcd
usb ethernet gadget, workaround network stack API glitch
USB: add "busnum" attribute for USB devices
USB: cxacru: ADSL state management
usbatm: Detect usb device shutdown and ignore failed urbs
USB: Remove duplicate define of OHCI_QUIRK_ZFMICRO
USB: BandRich BandLuxe HSDPA Data Card Driver
USB gadget rndis: fix struct rndis_packet_msg_type unaligned bug
USB Elan FTDI: check for driver registration status
USB: sierra: add more checks on shutdown
...
* 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb: (184 commits)
V4L/DVB (5563): Radio-maestro.c Replace radio_ioctl to use video_ioctl2
V4L/DVB (5562): Radio-gemtek-pci.c Replace gemtek_pci_ioctl to use video_ioctl2
V4L/DVB (5560): Ivtv: fix incorrect bitwise-and for command flags.
V4L/DVB (5558): Opera: use 7-bit i2c addresses
V4L/DVB (5557): Cafe_ccic: check return value of pci_enable_device
V4L/DVB (5556): Radio-gemtek.c Replace gemtek_ioctl to use video_ioctl2
V4L/DVB (5555): Radio-aimslab.c Replace rt_ioctl to use video_ioctl2
V4L/DVB (5554): Fix: vidioc_g_parm were not zeroing the memory
V4L/DVB (5553): Replace typhoon_do_ioctl to use video_ioctl2
V4L/DVB (5552): Plan-b: Switch to refcounting PCI API
V4L/DVB (5551): Plan-b: header change
V4L/DVB (5550): Radio-sf16fmi.c Replace fmi_do_ioctl to use video_ioctl2
V4L/DVB (5549): Radio-sf16fmr2.c Replace fmr2_do_ioctl to use video_ioctl2
V4L/DVB (5548): Fix v4l2 buffer to the length
V4L/DVB (5547): Add ENUM_FRAMESIZES and ENUM_FRAMEINTERVALS ioctls
V4L/DVB (5546): Radio-terratec.c Replace tt_do_ioctl to use video_ioctl2
V4L/DVB (5545): Saa7146: Release capture buffers on device close
V4L/DVB (5544): Budget-av: Make inversion setting configurable, add KNC ONE V1.0 card
V4L/DVB (5543): Tda10023: Add support for frontend TDA10023
V4L/DVB (5542): Budget-av: Remove polarity switching of the clock for DVB-C
...
Update gadget_chip.c, ether.c for newly added Freescale Highspeed USB
device driver.
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Freescale high-speed USB SOC can be found on some Freescale processors
among different architectures. It supports both host and device functions.
This driver adds its device support for Linux USB Gadget layer.
It is tested on MPC8349 and MPC8313, but should work on other platforms
with minor tweaks. The driver passed USBCV 1.3 compliance tests. Note
that this driver doesn't yet include OTG support.
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jiang Bo <tanya.jiang@freescale.com>
Signed-off-by: Bruce Schmid <duck@freescale.com>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Here's a patch which adds my device to the list.
This patch enables the broken suspend quirk for the PCI OHCI controller
present in the IT8152F/G RISC-to-PCI Companion Chip.
Signed-off-by: Raphael Assenat <raph@8d.com>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
The driver uses usb_control_msg() for exchanging data with the device.
When the driver lived freeley _outside_ the kernel tree (pre 2.6.21) the
timeouts for these calls where set to 5*HZ for reading, 1HZ for writing.
(These timeouts seemed to work fine for all users of the driver, at
least nobody complained in the last 2 years.
The current code (2.6.21-rc5) removed the 'HZ' from the timeouts and
left the driver with 5 jiffies for reading and 1 jiffy for writing. My
new machine is fast, but not that fast.
The patch also removes a useless debug statement, which was left over
from testing a broken firmware version
From: Eberhard Fahle <e.fahle@wayoda.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Per the Rui Santos and the hardware manufacturers, this actually inhibits
useful parts of the hardware. The correct way to use this hardware is with the
software at http://www.kanoistika.sk/bobovsky/archiv/umts/ and the manufacturers
are also planning on including Linux drivers/material in future revisions.
CC: Rui Santos <rsantos@grupopie.com>
CC: <johann.wilhelm@student.tugraz.at>
CC: <zihan@huawei.com>
CC: <wanganyu1983@huawei.com>
CC: <dingjianjian@huawei.com>
Signed-off-by: Phil Dibowitz <phil@ipom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Remove the old crisv10 HCD ... it can't have built for some time,
doesn't even have a Kconfig entry, was the last driver not to have
been converted to the "hcd" framework, and considering the usbcore
changes since its last patch was merged, has just got to buggy as
all get-out.
I'm told Axis has a new driver, and will be submitting it soon.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Mikael Starvik <mikael.starvik@axis.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Another workaround for the glitch in the network layer, whereby one call
ignores the (otherwise kernel-wide) convention that free() calls should
not oops when passed nulls. This code already handles that API glitch in
most other paths.
From: Erik Hovland <erik@hovland.org>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This patch (as903) adds a "busnum" sysfs attribute for USB devices.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
The device has commands to start/stop the ADSL function, so this adds a
sysfs attribute to allow it to be started/stopped/restarted. It also stops
polling the device for status when the ADSL function is disabled.
There are no problems with sending multiple start or stop commands, even
with a fast loop of them the device still works. There is no need to
protect the restart process from further user actions while it's waiting
for 1.5s.
Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Cc: Duncan Sands <duncan.sands@math.u-psud.fr>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Detect usb device shutdown and ignore failed urbs. This happens when the
driver is unloaded or the device is unplugged.
I'm not sure what other urb statuses should be ignored, and the warning
message doesn't need to be shown when the module is unloaded or the device
is removed.
Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Cc: Duncan Sands <duncan.sands@math.u-psud.fr>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Remove duplicate define of OHCI_QUIRK_ZFMICRO from ftdi-elan.c, its already
defined in drivers/ush/host/ohci.c
Signed-off-by: "S.Caglar Onur" <caglar@pardus.org.tr>
Cc: <tony.olech@elandigitalsystems.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Add the detection for the BandRich BandLuxe C100/C100S/C120 HSDPA Data
Card. With the vendor and product IDs are set properly, the data card can
be detected and works fine.
Signed-off-by: Leon Leong <upleong@bandrich.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
skb_push function may return a pointer which is not aligned as required
by struct rndis_packet_msg_type. Using attribute trick to fix this bug.
Signed-off-by: Roy Huang <roy.huang@analog.com>
Signed-off-by: Jie Zhang <jie.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Add checking of driver registration status and release allocated resources
if it failed.
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Cc: Pete Zaitcev <zaitcev@redhat.com>
Cc: "Luiz Fernando N. Capitulino" <lcapitulino@mandriva.com.br>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Use the new ohci-pci quirk infrastructure to address the problem it was
created to address: a quirk specific to the Portege 4000, in buzilla as
http://bugzilla.kernel.org/show_bug.cgi?id=6723
Also fix a misuse of "__devinit" for the quirk functions. It must not
be used without first ensuring that the references from the quirk tables
are gone, and that the function using those quirk tables is also gone.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Update "usbnet" so that ethtool reports the name of the minidriver in use
(e.g. asix, cdc_ether, dm9601, rndis_host) instead of "usbnet". This is a
better match to how other network drivers work, resolving a minor open issue.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Cleanups to the rndis_host code, and a tweak that helps talking to
PXA hardware. Mostly from Ole André Vadla Ravnås <oleavr@gmail.com>
- Prevent SET_INTERFACE requests, they give PXA hardware bad indigestion
- For paranoia, null a pointer after freeing its data
- Wrap up ActiveSync oddities for RNDIS_QUERY in one routine
- Use that wrapper when getting the Ethernet address
- Whitespace fixes
Plus add a comment noting the open issues about some RNDIS clients still
needing TBD kinds of browbeating to accept non-jumbogram packets.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This patch (as897) changes the autosuspend timer code to use the
standard types and macros in dealing with jiffies values.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Add the "bus zero" feature to the usbmon. If a user process specifies bus
with number zero, it receives events from all buses. This is useful when
we wish to see initial enumeration when a bus is created, typically after
a modprobe. Until now, an application had to loop until a new bus could
be open, then start capturing on it. This procedure was cumbersome and
could lose initial events. Also, often it's too bothersome to find exactly
to which bus a specific device is attached.
Paolo Albeni provided the original concept implementation. I added the
handling of "bus->monitored" flag and generally fixed it up.
Signed-off-by: Pete Zaitcev <zaitcev@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Some host controller drivers may need a PIO fallback when a DMA channel
is temporarily unavailable. This patch provides an address that such
drivers can use for PIO in those cases, and nulls that field out when
no such address is available (highmem) which should help usbmon.
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
this driver does
- ignore errors during open
- submit a running urb
- use down_interruptible not handling signals
- GFP_KERNEL with a spinlock held
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This patch (as877) adds a "last_busy" field to struct usb_device, for
use by the autosuspend framework. Now if an autosuspend call comes at
a time when the device isn't busy but hasn't yet been idle for long
enough, the timer can be set to exactly the desired value. And we
will be ready to handle things like HID drivers, which can't maintain
a useful usage count and must rely on the time-of-last-use to decide
when to autosuspend.
The patch also makes some related minor improvements:
Move the calls to the autosuspend condition-checking routine
into usb_suspend_both(), which is the only place where it
really matters.
If the autosuspend timer is already running, don't stop
and restart it.
Replace immediate returns with gotos so that the optional
debugging ouput won't be bypassed.
If autoresume is disabled but the device is already awake,
don't return an error for an autoresume call.
Don't try to autoresume a device if it isn't suspended.
(Yes, this undercuts the previous change -- so sue me.)
Don't duplicate existing code in the autosuspend work routine.
Fix the kerneldoc in usb_autopm_put_interface(): If an
autoresume call fails, the usage counter is left unchanged.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
omninet kills all URBs in close. However write() returns as soon as
the URB has been submitted. Killing the last URB means a race that
can lose that date written in the last call to write().
As a fix this is moved to shutdown().
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
we report errors to the caller. THis patch adds error handling to the driver.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
- report errors
- cleanup in error case
- use of endianness macros
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
this driver ignores errors while starting the transmit queue. It will
never be reported stopped as the completion handler won't run
and it will never be started again as it will be considered started.
This patch adds error handling.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
this driver sets intfdata to NULL while it still can be read and happily followed.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This patch adds the USB ID of the ADS Tech USBX-707 USB IR blaster (that
comes with the ADS Tech PTV-305 grabber card), which has a ftdi232bm
inside hooked up to a pic.
With this it should be fairly straightforward to make at least lirc
receiving work with this device. I will submit a patch to lirc for that
as soon as I have one ready, I'm getting data with minicom with this
patch, but need to figure out some more details such as best/correct
baudrate.
Signed-off-by: Jelle Foks <jelle@foks.8m.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
this has the same race as the visor driver. The counter must be incremented
under the lock it is checked under.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
- proper endianness macros
- scheduling in interrupt in error case
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Naranjo Manuel Francisco <naranjo.manuel@gmail.com>
o The "real" usb-devices export now a device node which can
populate /dev/bus/usb.
o The usb_device class is optional now and can be disabled in the
kernel config. Major/minor of the "real" devices and class devices
are the same.
o The environment of the usb-device event contains DEVNUM and BUSNUM to
help udev and get rid of the ugly udev rule we need for the class
devices.
o The usb-devices and usb-interfaces share the same bus, so I used
the new "struct device_type" to let these devices identify
themselves. This also removes the current logic of using a magic
platform-pointer.
The name of the device_type is also added to the environment
which makes it easier to distinguish the different kinds of devices
on the same subsystem.
It looks like this:
add@/devices/pci0000:00/0000:00:1d.1/usb2/2-1
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb2/2-1
SUBSYSTEM=usb
SEQNUM=1533
MAJOR=189
MINOR=131
DEVTYPE=usb_device
PRODUCT=46d/c03e/2000
TYPE=0/0/0
BUSNUM=002
DEVNUM=004
This udev rule works as a replacement for usb_device class devices:
SUBSYSTEM=="usb", ACTION=="add", ENV{DEVTYPE}=="usb_device", \
NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", MODE="0644"
Updated patch, which needs the device_type patches in Greg's tree.
I also got a bugzilla assigned for this. :)
https://bugzilla.novell.com/show_bug.cgi?id=250659
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This patch (as874) adds another piece to the user-visible part of the
USB autosuspend interface. The new power/level sysfs attribute allows
users to force the device on (with autosuspend off), force the device
to sleep (with autoresume off), or return to normal automatic operation.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Add logical channel support for ATI Remote Wonder II
The ATI Remote Wonder II can be configured with one of 16 unique logical
channels. Allowing up to 16 remotes to be used independently within
range of each other. This change adds functionality to configure the
receiver and filter the input data to respond or exclude remotes
configured with different logical channels.
Signed-off-by: Peter Stokes <linux@dadeos.freeserve.co.uk>
Acked-by: Ville Syrjala <syrjala@sci.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
the sierra driver does not directly use usb_kill_urb(). It uses a wrapper.
This wrapper means that callbacks which are running are not killed during
close, resubmitting and illicitly pushing data into the tty layer.
The whole purpose of usb_kill_urb() is subverted. The wrapper must be removed.
The same problem as the option driver.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
the option driver does not directly use usb_kill_urb(). It uses a wrapper.
This wrapper means that callbacks which are running are not killed during
close, resubmitting and illicitly pushing data into the tty layer.
The whole purpose of usb_kill_urb() is subverted. The wrapper must be removed.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Matthias Urlichs <smurf@smurf.noris.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This patch (as872) adds some WARN_ON()s to various error checks which
are never supposed to fail. Unsettlingly, one of them has shown up in
a user's log! Maybe making the warning more visible and having the
call-stack information available will help pinpoint the source of the
problem.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
NULL checks should be before the first dereference.
Spotted by the Coverity checker.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Am Montag, 19. 2007 10:25 schrieb Adrian Bunk:
> The Coverity checker spotted the following NULL dereference:
And this fixes an oops upon allocation failures.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This fixes:
- breaking DMA rules about buffers
- usage of _global_ variables to save a single device's attributes
- racy access to urb->status
- smp monotonity issue with statistics
- use of one buffer for many simultaneous URBs
- error handling introduced
- several instances of following NULL pointers
- use after free
- unnecessary GFP_ATOMIC
- GFP_KERNEL in interrupt
- various cleanups
- write room granularity issue that bit cdc-acm
- race in shutdown
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
io_edgeport is using a global variable without locking.
This is _the_ classical race condition. This patch switches to atomic_t.
Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>