Commit Graph

22660 Commits (16574dccd8f62dc1b585325f8a6a0aab10047ed8)

Author SHA1 Message Date
Bryan O'Sullivan 9783ab4058 IB/ipath: Improve handling and reporting of parity errors
Mostly cleanup.

Signed-off-by: Dave Olson <dave.olson@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:58 -07:00
Bryan O'Sullivan 820054b7ca IB/ipath: Print better error messages if kernel is misconfigured
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:58 -07:00
Arthur Jones 569b87b47f IB/ipath: Force PIOAvail update entry point
Due to a chip bug, the PIOAvail register is not always updated to
memory.  This patch allows userspace to force an update.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:58 -07:00
Arthur Jones 7b196e2ff3 IB/ipath: Call free_irq() on chip specific initialization failure
In initialization, if we bailed at chip specific initialization, we
forgot to clean up the irq we had requested.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:58 -07:00
Bryan O'Sullivan 5a7d4eea91 IB/ipath: Discard multicast packets without a GRH
This patch fixes a bug where multicast packets without a GRH were not
being dropped as per the IB spec.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:57 -07:00
Bryan O'Sullivan 0ed3c594e3 IB/ipath: Fix calculation for number of kernel PIO buffers
If the module parameter "kpiobufs" is set too high, the calculation to
reset it to a sane value was incorrect.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:57 -07:00
Bryan O'Sullivan c8c6f5d496 IB/ipath: Remove unused ipath_read_kreg64_port()
Signed-off-by: Dave Olson <dave.olson@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:57 -07:00
Ralph Campbell dd5190b6be IB/ipath: Fix RDMA reads of length zero and error handling
Fix RDMA read response length checking for RDMA_READ_RESPONSE_ONLY to
allow a zero length response.  RDMA read responses which don't match
the expected length or occur in response to some other operation
should generate a completion queue error (see table 56, ch. 9.9.2.3 in
the IB spec).

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:57 -07:00
Mark Debbage c7e29ff11f IB/ipath: Allow receive ports mapped into userspace to be shared
Improve port-sharing performance by allowing any process to receive
packets from the shared hardware port under a spin lock for mutual
exclusion. Previously, one process was nominated as the master and
that process was responsible for receiving all packets from the shared
hardware port and either consuming them or forwarding them to their
destination. This led to starvation problems for other processes when
the master process was busy in computation phases.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:57 -07:00
Ralph Campbell 0a5a83cffc IB/ipath: Fix port sharing on powerpc
The port sharing feature mixed kernel virtual addresses as well as
physical addresses for the offset used to describe the mmap address to
map the InfiniPath hardware into user space.  This had a conflict on
powerpc.  The new scheme converts it to a physical address so it
doesn't conflict with chip addresses and yet still fits in 40/44 bits
so it isn't truncated by 32-bit applications calling mmap64().

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:56 -07:00
Bryan O'Sullivan 041eab9136 IB/ipath: Fix CQ flushing when QP is modified to error state
If a receive work request has been removed from the queue but has not
had a CQ entry generated for it and the QP is modified to the error
state, the completion entry generated is incorrect.  This patch fixes
the problem.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:56 -07:00
Bryan O'Sullivan 614d49a21e IB/ipath: Fix bad argument to clear_bit()
Code was converted from a &= ~mask to clear_bit, but the bit was left
shifted instead of being used directly, so we were either trashing
memory several pages away, or sometimes taking a kernel page fault on
an invalid page.

Signed-off-by: Dave Olson <dave.olson@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:56 -07:00
Bryan O'Sullivan 8ec1077b35 IB/ipath: Change packet problems vs chip errors handling and reporting
Some types of packet errors are moderately common with longer IB
cables and large clusters, and are not reported with prints by other
IB HCA drivers.  This suppresses those messages unless the new
__IPATH_ERRPKTDBG bit is set in ipath_debug.  Reporting of temporarily
disabled frequent error interrupts was also made clearer

We also distinguish between chip errors, and bad packets sent or
received in the wording of the messages.

Signed-off-by: Dave Olson <dave.olson@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:55 -07:00
Ralph Campbell 6f5c407460 IB/ipath: Fix PSN update for RC retries
This patch fixes a number of bugs with updating the PSN for retries of
RC requests.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:55 -07:00
Ralph Campbell 0434d271fd IB/ipath: Fix QP error completion queue entries
When switching to the QP error state, the completion queue entries
(error or flush) were not being generated correctly.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:55 -07:00
Bryan O'Sullivan 39c0d0b919 IB/ipath: Fix up some debug messages
ipath_dbg doesn't need the same prefixes that printk does.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:55 -07:00
Ralph Campbell 3859e39d75 IB/ipath: Support larger IB_QP_MAX_DEST_RD_ATOMIC and IB_QP_MAX_QP_RD_ATOMIC
This patch adds support for multiple RDMA reads and atomics to be sent
before an ACK is required to be seen by the requester.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:55 -07:00
Ralph Campbell 7b21d26dda IB/ipath: NMI cpu lockup if local loopback used
If a post send is done in loopback and there is no receive queue
entry, the sending QP is put on a timeout list for a while so the
receiver has a chance to post a receive buffer. If the another post
send is done, the code incorrectly tried to put the QP on the timeout
list again an corrupted the timeout list. This eventually leads to a
spin lock deadlock NMI due to the timer function looping forever with
the lock held.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:54 -07:00
Ralph Campbell 9f9630d5e1 IB/ipath: Fix SRQ limit event causing dropped CQ entry
A silly programming error causes a CQ entry to not be generated if a
SRQ limit event is generated.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:54 -07:00
Ralph Campbell 947d7617a1 IB/ipath: Don't initialize port memory for subports
A recent change was made to allocate memory for a port after CPU
affinity is set. That change didn't account for subports and was
trying to allocate memory for the port twice.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:54 -07:00
Bryan O'Sullivan 1908574559 IB/ipath: Definitions of two RXE parity err bits were reversed
The chip documentation on the expected TID vs eager TID parity error
bits was reversed from what was implemented in the RTL, for both
chips.  This corrects the definitions.

Signed-off-by: Dave Olson <dave.olson@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:54 -07:00
Bryan O'Sullivan 165c552c35 IB/ipath: Fix user memory region creation when IOMMU present
The loop which initializes the user memory region from an array of
pages was using the wrong limit for the array.  This worked OK when
dma_map_sg() returned the same number as the number of pages.  This
patch fixes the problem.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:54 -07:00
Bryan O'Sullivan 946db67fbf IB/ipath: Add ability to set and clear IB local loopback
This is a sticky state.  It is useful for diagnosing problems with
boards versus cable/switch problems.

Signed-off-by: Dave Olson <dave.olson@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:53 -07:00
Roland Dreier a89875fc7e IPoIB: Remove pointless opcode field from debugging output
There's no point in printing the opcode field in the completion
handling debugging output, since the type of completion is already
printed at the beginning of the line.  In fact the opcode field is not
even defined for completions with a status other than success.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:53 -07:00
Hal Rosenstock 9a4b65e357 IB/umad: Fix declaration of dev_map[]
The current ib_umad code never accesses bits past IB_UMAD_MAX_PORTS in
dev_map[].  We shouldn't declare it to be twice as big.

Pointed-out-by: Roland Dreier <rolandd@cisco.com>

Signed-off-by: Hal Rosenstock <halr@voltaire.com>
2007-04-18 20:20:53 -07:00
Roland Dreier 9b620d2a16 IB: Remove reference to obsolete CONFIG_IPATH_CORE
Since commit b1c1b6a3 ("IB/ipath: merge ipath_core and ib_ipath
drivers"), CONFIG_IPATH_CORE no longer exists, so there's no reason to
have a line for it in drivers/Makefile.

Pointed out by Robert P. J. Day <rpjday@mindspring.com>.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-18 20:20:53 -07:00
Linus Torvalds 245d95a423 Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband:
  IB/mthca: Fix data corruption after FMR unmap on Sinai
2007-04-17 16:50:59 -07:00
Olof Johansson 080dfbe176 Minor bug fixes to i2c-pasemi
* Last write during i2c_xfer is of the wrong byte (off-by-1).
* Read length is wrong for some of the reads (mistakenly used the PEC
  version)

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-17 16:36:28 -07:00
Jean Delvare 56a3b5ebee i2c-pasemi: Depend on PPC_PASEMI again
Looks like a local change I made to be able to test-compile the i2c-pasemi
driver leaked upstream.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-17 16:36:28 -07:00
Jean Delvare 33725ad36d hwmon/w83627ehf: Fix the fan5 clock divider write
Users have been complaining about the w83627ehf driver flooding their logs
with debug messages like:

w83627ehf 9191-0a10: Increasing fan 4 clock divider from 64 to 128

or:

w83627ehf 9191-0290: Increasing fan 4 clock divider from 4 to 8

The reason is that we failed to actually write the LSB of the encoded clock
divider value for that fan, causing the next read to report the same old value
again and again.

Additionally, the fan number was improperly reported, making the bug harder to
find.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-17 16:36:27 -07:00
Andrew Morton 94256dd680 drivers/macintosh/smu.c: fix locking snafu
It got its lock and unlock backwards.

Fixes http://bugzilla.kernel.org/show_bug.cgi?id=8334

(obviously, this code could be using plain old spin_lock_irq(), too)

Cc: <matthias.kaehlcke@gmail.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-17 16:36:27 -07:00
Ben Dooks 3d2c5b415c spi: fix use of set_cs in spi_s3c24xx driver
It turns out that the last patch to change set_cs to be kept in the
controller's structure instead of the platform data was an incomplete
change, and did not change the references to platfrom data in the setup
xfer code.  (This can prevent an oops.)

Reported-by: <Ling.Alex@iac.com.tw>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-17 16:36:27 -07:00
Benjamin Herrenschmidt 8a93258ce3 fix bogon in /dev/mem mmap'ing on nommu
While digging through my MAP_FIXED changes, I found that rather obvious
bug in /dev/mem mmap implementation for nommu archs. get_unmapped_area()
is expected to return an address, not a pfn.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-By: David Howells <dhowells@redhat.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-17 16:36:27 -07:00
Michael S. Tsirkin 608d8268be IB/mthca: Fix data corruption after FMR unmap on Sinai
In mthca_arbel_fmr_unmap(), the high bits of the key are masked off.
This gets rid of the effect of adjust_key(), which makes sure that
bits 3 and 23 of the key are equal when the Sinai throughput
optimization is enabled, and so it may happen that an FMR will end up
with bits 3 and 23 in the key being different.  This causes data
corruption, because when enabling the throughput optimization, the
driver promises the HCA firmware that bits 3 and 23 of all memory keys
will always be equal.

Fix by re-applying adjust_key() after masking the key.

Thanks to Or Gerlitz for reproducing the problem, and Ariel Shahar for
help in debug.

Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-16 14:10:55 -07:00
Linus Torvalds ff99e40230 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [SCSI] QLOGICPTI: Do not unmap DMA unless we actually mapped something.
2007-04-14 21:41:12 -07:00
Linus Torvalds 2951157f05 Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
  [SCSI] 3w-xxxx: fix oops caused by incorrect REQUEST_SENSE handling
2007-04-14 21:35:52 -07:00
David S. Miller 8d3ee2cb0a [SCSI] QLOGICPTI: Do not unmap DMA unless we actually mapped something.
We only map DMA when cmd->request_bufflen is non-zero for non-sg
buffers, we thus should make the same check when unmapping.

Based upon a report from Pasi Pirhonen.

Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-14 10:29:10 -07:00
James Bottomley 6e3b2bbb19 [SCSI] 3w-xxxx: fix oops caused by incorrect REQUEST_SENSE handling
3w-xxxx emulates a REQUEST_SENSE response by simply returning nothing.
Unfortunately, it's assuming that the REQUEST_SENSE command is
implemented with use_sg == 0, which is no longer the case.  The oops
occurs because it's clearing the scatterlist in request_buffer instead
of the memory region.

This is fixed by using tw_transfer_internal() to transfer correctly to
the scatterlist.

Acked-by: adam radford <aradford@gmail.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2007-04-14 08:49:03 -05:00
Olaf Kirch d791d413fd DVB: dvb-usb-remote - fix oops when changing keymap
DVB USB remotes do not support changing keycode maps but set
input_dev->keycodesize and input_dev->keycodemax without setting
input_dev->keycode. This causes kernel oops when user tries to
look up (or change) current keymap.

While the proper fix would be to make remotes handle keymap changes
we'll just remove keycodemax and keycodesize initialization so
EVIOCGKEYCODE and EVIOCSKEYCODE will simply return -EINVAL.

http://bugzilla.kernel.org/show_bug.cgi?id=8312

Signed-off-by: olaf.kirch@oracle.com
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-13 18:35:39 -07:00
Linus Torvalds 8a065975c1 Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband:
  RDMA/cxgb3: Add set_tcb_rpl_handler
2007-04-12 15:44:52 -07:00
Neil Brown 505fa2c4a2 [PATCH] md: fix calculation for size of filemap_attr array in md/bitmap
If 'num_pages' were ever 1 more than a multiple of 8 (32bit platforms)
or of 16 (64 bit platforms).  filemap_attr would be allocated one
'unsigned long' shorter than required.  We need a round-up in there.

Signed-off-by: Neil Brown <neilb@suse.de>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-12 15:31:42 -07:00
Bjorn Helgaas b6550777a3 [PATCH] cciss: unregister from SCSI before tearing down device resources
We must unregister from SCSI before we unmap device resources and unhook
the IRQ handler.  Otherwise, SCSI may send us more requests, and we won't
be able to handle them.

I see the following oops during every reboot of my HP DL360:

    ...
    Unmounting local filesystems...done.
    Rebooting... Completed flushing cache on controller 0
    BUG: unable to handle kernel paging request at virtual address f8808040
     printing eip:
    c02dc72b
    *pde = 02120067
    *pte = 00000000
    Oops: 0002 [#1]
    SMP
    Modules linked in:
    CPU:    1
    EIP:    0060:[<c02dc72b>]    Not tainted VLI
    EFLAGS: 00010046   (2.6.21-rc6 #1)
    EIP is at SA5_submit_command+0xb/0x20
    eax: f8808000   ebx: f7a00000   ecx: f79f0000   edx: 37a00000
    esi: f79f0000   edi: 00000000   ebp: 00000000   esp: dd717a44
    ds: 007b   es: 007b   fs: 00d8  gs: 0000  ss: 0068
    Process khelper (pid: 1427, ti=dd716000 task=c2260a70 task.ti=dd716000)
    Stack: c02df2c0 f7a00000 f7a00000 00d41008 c02df691 00000000 00000010 00000002
	   00000001 f79f0000 f7fff844 c1398420 00000000 00000000 00001000 230a3020
	   69666564 5420656e 50434f49 465f544b 4853554c 44414552 0a312009 66656423
    Call Trace:
     [<c02df2c0>] start_io+0x80/0x120
     [<c02df691>] do_cciss_request+0x331/0x350
     [<c014242a>] mempool_alloc+0x2a/0xe0
     [<c020ad71>] blk_alloc_request+0x61/0x80
     [<c020b02e>] get_request+0x15e/0x1e0
     [<c01595e0>] cache_alloc_refill+0xb0/0x1e0
     [<c021049d>] as_update_rq+0x2d/0x80
     [<c0210d28>] as_add_request+0x68/0x90
     [<c0207f99>] elv_insert+0x119/0x160
     [<c020bd0b>] __make_request+0xcb/0x320
     [<c0122ee0>] lock_timer_base+0x20/0x50
     [<c0123096>] del_timer+0x56/0x60
     [<c020a7b8>] blk_remove_plug+0x38/0x70
     [<c020a815>] __generic_unplug_device+0x25/0x30
     [<c020a835>] generic_unplug_device+0x15/0x30
    ...

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Acked-by: Mike Miller <mike.miller@hp.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-12 15:31:42 -07:00
Steve Wise 1ca19770c5 RDMA/cxgb3: Add set_tcb_rpl_handler
As of commit 6cdbd77e ("cxgb3 - missing CPL hanler and register
setting."), the cxgb3 ethernet NIC driver no longer handles SET_TCB
replies, so we need to do it in the iWARP driver.

Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Acked-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-12 10:37:11 -07:00
Linus Torvalds 73aba63c5d Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
  myri10ge: update driver version to 1.3.0-1.233
  myri10ge: more Intel chipsets providing aligned PCIe completions
  myri10ge: fix management of the firmware 4KB boundary crossing restriction
  cxgb3 - missing CPL hanler and register setting.
  cxgb3 - MAC watchdog update
  cxgb3 - avoid deadlock with mac watchdog
  skge: fix wake on lan
  sky2: phy workarounds for Yukon EC-U A1
  sky2: turn on clocks when doing resume
  sky2: turn carrier off when down
  skge: turn carrier off when down
  [PATCH] bcm43xx: Fix PPC machine checks and match loopback gain specs
  [PATCH] bcm43xx: Fix 802.11b/g scan limits to match regulatory reqs
  [PATCH] zd1211rw: Fix E2P_PHY_REG patching
  [PATCH] zd1211rw: Reject AL2230S devices
2007-04-11 15:40:45 -07:00
Linus Torvalds 29ac8cabd2 Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6:
  USB: Nikon D80 unusual device patch
  EHCI: fix remote wakeup regression in 2.6.21-rc
2007-04-11 15:40:03 -07:00
Dmitry Torokhov c48ea60359 [PATCH] PM: use kobject_name() to access kobject names
Noone should use kobj.name directly since it may contain garbage.
Objects with longer names have them stored in separately allocated
memory pointed to by kobj->k_name.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-11 15:39:39 -07:00
Emil Larsson 2ea547d2de USB: Nikon D80 unusual device patch
the Nikon D80 camera will not work without an UNUSUAL_DEV entry embodied
in the attached patch (made against 2.6.20.3). Hope you find it helpful,
or if not, pass it along to someone who does.

From: Emil Larsson <emil@swip.net>
Signed-off-by: Phil Dibowitz <phil@ipom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-04-11 10:44:15 -07:00
Alan Stern 61e8b858ab EHCI: fix remote wakeup regression in 2.6.21-rc
There is one significant difference between the behavior of root hubs
(as embodied in host controller hardware) and external hubs: When a
remote-wakeup signal is received, an external hub sends an interrupt
message at the _end_ of the resume sequence but a root hub generates
and interrupt at the _beginning_ of the resume sequence.  The host
system must poll for the end of the sequence.

When ehci-hcd was converted to interrupt-driven operation instead of
using polling, the remaining need for this particular poll was
overlooked.  This patch (as894) fixes the problem.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-04-11 10:44:15 -07:00
Jeff Garzik cec34dda71 Merge branch 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into upstream-fixes 2007-04-11 11:55:45 -04:00
Brice Goglin 4b2281c7aa myri10ge: update driver version to 1.3.0-1.233
Update the myri10ge driver version number to 1.3.0-1.233.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:44 -04:00
Brice Goglin f19baaeaad myri10ge: more Intel chipsets providing aligned PCIe completions
Add the Intel 5000 southbridge (aka Intel 6310/6311/6321ESB) PCIe ports
and the Intel E30x0 chipsets to the whitelist of aligned PCIe completion.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:44 -04:00
Brice Goglin ae8509b187 myri10ge: fix management of the firmware 4KB boundary crossing restriction
Simpler way of dealing with the firmware 4KB boundary crossing
restriction for rx buffers.  This fixes a variety of memory
corruption issues when using an "uncommon" MTU with a 16KB
page size.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:44 -04:00
Divy Le Ray 6cdbd77e88 cxgb3 - missing CPL hanler and register setting.
Remove specific CPL handler.
Add missing CPL handler.
Add missing register setting when the interface is brought up.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:43 -04:00
Divy Le Ray 59cf81076a cxgb3 - MAC watchdog update
The MAC watchdog was failing if the peer interface was brought down.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:43 -04:00
Divy Le Ray f2d961c982 cxgb3 - avoid deadlock with mac watchdog
Fix a deadlock when the interface s configured down and
the watchdog tack is sleeping on rtnl_lock.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:43 -04:00
Stephen Hemminger 692412b31f skge: fix wake on lan
Need to rework wake on lan code to setup properly and get activated
on shutdown (and suspend), not when ethtool is run.

This does not need to go to stable queue because wake on lan
was not even included in 2.6.20 (or earlier versions).

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:43 -04:00
Stephen Hemminger 9467a8fc89 sky2: phy workarounds for Yukon EC-U A1
The workaround Yukon EC-U wasn't comparing with correct
version and wasn't doing correct setup. Without it, 88e8056
throws all sorts of errors.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:43 -04:00
Stephen Hemminger 1ad5b4a5c2 sky2: turn on clocks when doing resume
Some of these chips are disabled until clock is enabled.
This fixes:
     http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=404107

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:43 -04:00
Stephen Hemminger 9a87240c67 sky2: turn carrier off when down
Driver needs to turn off carrier when down.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:42 -04:00
Stephen Hemminger e5b9ddd9a0 skge: turn carrier off when down
Driver needs to turn off carrier when down, otherwise it can
confuse bonding and bridging and looks like carrier is on immediately
when it is brought back up.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-11 11:54:42 -04:00
Cliff Brake ff78b20235 [PATCH] Input: ucb1400 - set up driver's name to show in sysfs
The UCB1400 is missing a name parameter in the device_driver struct.
This causes missing information in the /sys tree and seems to cause
other problems with the AC97 functionality. This was tested on a PXA270
system.

Signed-off-by: Cliff Brake <cbrake@bec-systems.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-10 17:26:33 -07:00
Linus Torvalds 0bce0b7a3b Merge branch 'for-2.6.21' of master.kernel.org:/pub/scm/linux/kernel/git/davej/agpgart
* 'for-2.6.21' of master.kernel.org:/pub/scm/linux/kernel/git/davej/agpgart:
  [AGPGART] intel_agp: fix G965 GTT size detect
2007-04-10 17:24:56 -07:00
Linus Torvalds c3474be4dd Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6:
  ieee1394: change deprecation status of dv1394
2007-04-10 17:24:36 -07:00
Linus Torvalds 5a92d635be 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:
  IPoIB/cm: Fix DMA direction typo
  IB/iser: Don't defer connection failure notification to workqueue
2007-04-10 17:23:52 -07:00
Linus Torvalds e676853c8c Merge branch 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid
* 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
  HID: Do not discard truncated input reports
2007-04-10 17:23:36 -07:00
Linus Torvalds 8bd51cce98 Merge master.kernel.org:/pub/scm/linux/kernel/git/bart/ide-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/bart/ide-2.6:
  ide: add "optical" to sysfs "media" attribute
  ide: ugly messages trying to open CD drive with no media present
  ide: correctly prevent IDE timer expiry function to run if request was already handled
2007-04-10 17:22:31 -07:00
Danny Kukawka a7a832de9e ide: add "optical" to sysfs "media" attribute
Add "optical" to sysfs "media" attribute as already in /proc

Signed-off-by: Danny Kukawka <dkukawka@suse.de>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-04-10 22:39:14 +02:00
Stuart Hayes 76ca1af10e ide: ugly messages trying to open CD drive with no media present
I get the following error messages when trying to open a CD device
(specifically, the Teac CD-ROM CD-224E) that has no media present:

hda: packet command error: status=3D0x51 { DriveReady SeekComplete Error }
hda: packet command error: error=3D0x54 { AbortedCommand LastFailedSense=0x05 }
ide: failed opcode was: unknown

This happens when a "start stop unit" command (0x1b 0 0 0 3 0 0 0 0 0)
is sent to the drive to try to close the CD-ROM tray, but this drive
doesn't have that capability (it's a slim portable-type CD-ROM), so it
reports sense key 5 (illegal request) with asc/ascq 24/0.  This is
exactly how SFF8090i says it should respond.

But ide-cd.c (in cdrom_decode_status() ) just sees sense key 5 and spews
out an error.  It then goes on to request sense data, and
cdrom_log_sense() understands this error and doesn't log it.

The patch, for kernel 2.6.20.4, suppresses this error message.

Signed-off-by: Stuart Hayes <stuart_hayes@dell.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-04-10 22:38:43 +02:00
Suleiman Souhlal 23450319e2 ide: correctly prevent IDE timer expiry function to run if request was already handled
It is possible for the timer expiry function to run even though the
request has already been handled: ide_timer_expiry() only checks that
the handler is not NULL, but it is possible that we have handled a
request (thus clearing the handler) and then started a new request
(thus starting the timer again, and setting a handler). 

A simple way to exhibit this is to set the DMA timeout to 1 jiffy and
run dd: The kernel will panic after a few minutes because
ide_timer_expiry() tries to add a timer when it's already active.

To fix this, we simply add a request generation count that gets
incremented at every interrupt, and check in ide_timer_expiry() that
we have not already handled a new interrupt before running the expiry
function.

Signed-off-by: Suleiman Souhlal <suleiman@google.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-04-10 22:38:37 +02:00
Larry Finger ec759a2b38 [PATCH] bcm43xx: Fix PPC machine checks and match loopback gain specs
The specifications for loopback_gain calculation and for G PHY
initialization have been updated. This patch implements them and
fixes a machine check error that occurs for PPC architecture with a
phy->rev of 1.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-04-10 14:35:57 -04:00
Larry Finger 81e880064d [PATCH] bcm43xx: Fix 802.11b/g scan limits to match regulatory reqs
In 802.11b/g mode, bcm43xx actively scans channels 1-14 no matter what
locale has been set, either in the sprom or by the locale option. This
behaviorviolates regulatory rules everywhere in the world except
Japan. This patch changes the default range to the correct value if the
locale has been set, and to channels 1-13 if no locale has been set.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-04-10 14:35:57 -04:00
Daniel Drake 92b3e2e925 [PATCH] zd1211rw: Fix E2P_PHY_REG patching
Due to conflicting/confusing defines in the vendor driver, we were
reading E2P_PHY_REG from the wrong location.

CR157 patching was slightly incorrect in that the vendor driver only
patches in an 8-bit value, whereas we were patching 24 bits.

Additionally, CR157 patching was happening on both zd1211 and zd1211b,
but this should only happen on zd1211.

Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: Ulrich Kunitz <kune@deine-taler.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-04-10 14:35:56 -04:00
Michael S. Tsirkin 6371ea3d48 IPoIB/cm: Fix DMA direction typo
Receive buffers need to be mapped with DMA_FROM_DEVICE.  Incorrectly
mapping with DMA_TO_DEVICE causes a hard lock on ppc64 machines with
an IOMMU.

This fixes <https://bugs.openfabrics.org/show_bug.cgi?id=431>

Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-10 08:58:30 -07:00
Daniel Drake ae6ead4623 [PATCH] zd1211rw: Reject AL2230S devices
zd1211rw currently detects AL2230S-based devices as AL2230, and hence
programs the RF incorrectly. Transmit silently fails on this
misconfiguration.

After this patch, AL2230S devices are rejected with an error message, to
avoid any confusion with an apparent driver bug.

Signed-off-by: Daniel Drake <dsd@gentoo.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-04-10 11:03:29 -04:00
Wang Zhenyu 52ea0718ea [AGPGART] intel_agp: fix G965 GTT size detect
On G965, I810_PGETBL_CTL is a mmio offset, but we wrongly take it
as pci config space offset in detecting GTT size. This one line patch
fixs this.

Signed-off-by: Wang Zhenyu <zhenyu.z.wang@intel.com>
Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-09 22:09:58 -04:00
Herbert Xu 699784b761 [SC92031]: Fix priv->lock context
The spin_lock calls made in dev->open and dev->close must disable
BH since open/close are made in process context.  Conversely, the
call in dev->hard_start_xmit does not need to disable BH since it
is already executing with BH disabled.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-09 13:31:14 -07:00
Linus Torvalds 90f30eccf4 Merge branch 'for-2.6.21' of master.kernel.org:/pub/scm/linux/kernel/git/davej/agpgart
* 'for-2.6.21' of master.kernel.org:/pub/scm/linux/kernel/git/davej/agpgart:
  [AGPGART] intel_agp: PCI id update for Intel 965GM
2007-04-09 11:45:18 -07:00
Stefan Richter 199c1167f5 ieee1394: change deprecation status of dv1394
Nobody ported ffmpeg from dv1394 to rawiso yet, and there is no
justification to remove dv1394 right now.

Nevertheless, a strong deprecation of this ABI makes a lot of sense,
especially as Kristian H's drivers shape up to be an attractive
alternative to the existing ones.  But we don't have a schedule at the
moment.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
2007-04-09 18:52:27 +02:00
David Brownell b6d2cccb55 [PATCH] omap_cf: oops-on-suspend fix
Convert omap_cf into a platform_driver ...  this resolves oopsing during
suspend/resume.

Evidently folk haven't tried suspend/resume on an OSK (the main platform
for this driver) since September or so, which is when platform_device
learned about suspend_late()/resume_early() and stopped being able to
suspend/resume without a platform_driver.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-08 19:47:55 -07:00
Wang Zhenyu 4598af33d9 [AGPGART] intel_agp: PCI id update for Intel 965GM
Update PCI id info for Intel 965GM chipset.

Signed-off-by: Wang Zhenyu <zhenyu.z.wang@intel.com>
Signed-off-by: Dave Jones <davej@redhat.com>
2007-04-08 21:31:58 -04:00
Michael Chan b8fa2f3a82 [TG3]: Fix crash during tg3_init_one().
The driver will crash when the chip has been initialized by EFI before
tg3_init_one().  In this case, the driver will call tg3_chip_reset()
before allocating consistent memory.

The bug is fixed by checking for tp->hw_status before accessing it
during tg3_chip_reset().

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-06 17:35:37 -07:00
Erez Zilber 1d426d6418 IB/iser: Don't defer connection failure notification to workqueue
When a connection is terminated asynchronously from the iSCSI layer's
perspective, iSER needs to notify the iSCSI layer that the connection
has failed.  This is done using a workqueue (switched to from the iSER
tasklet context).  Meanwhile, the connection object (that holds the
work struct) is released.  If the workqueue function wasn't called
yet, it will be called later with a NULL pointer, which will crash the
kernel.

The context switch (tasklet to workqueue) is not required, and
everything can be done from the iSER tasklet. This eliminates the NULL
work struct bug (and simplifies the code).

Signed-off-by: Erez Zilber <erezz@voltaire.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-04-05 09:46:04 -07:00
Adam Kropelin 8da7d1bae5 HID: Do not discard truncated input reports
Truncated reports should not be discarded since it prevents buggy
devices from communicating with userspace.

Prior to the regession introduced in 2.6.20, a shorter-than-expected
report in hid_input_report() was passed thru after having the missing
bytes cleared. This behavior was established over a few patches in the
2.6.early-teens days, including commit
cd6104572b.

This patch restores the previous behavior and fixes the regression.

Signed-off-by: Adam Kropelin <akropel1@rochester.rr.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2007-04-05 16:06:30 +02:00
Yoichi Yuasa ba6e8564f4 [PATCH] Fix build error on zs serial driver
drivers/tc/zs.c:73:24: error: asm/dec/tc.h: No such file or directory

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Acked-by: Maciej W. Rozycki <macro@linux-mips.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-04 21:12:47 -07:00
Mike Miller (OS Dev) 7f42d3b8a7 [PATCH] cciss: add init of drv->cylinders back to cciss_geometry_inquiry
This patch adds initialization of drv->cylinders back into the failing case in
cciss_geometry_inquiry. I inadvertently removed it in one my 2TB updates.

Signed-off-by: Mike Miller <mike.miller@hp.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-04 21:12:47 -07:00
Andrew Morton 2363cc0264 [PATCH] remove protection of LANANA-reserved majors
Revert all this.  It can cause device-mapper to receive a different major from
earlier kernels and it turns out that the Amanda backup program (via GNU tar,
apparently) checks major numbers on files when performing incremental backups.

Which is a bit broken of Amanda (or tar), but this feature isn't important
enough to justify the churn.

Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-04 21:12:47 -07:00
NeilBrown 5792a2856a [PATCH] md: avoid a deadlock when removing a device from an md array via sysfs
A device can be removed from an md array via e.g.
  echo remove > /sys/block/md3/md/dev-sde/state

This will try to remove the 'dev-sde' subtree which will deadlock
since
  commit e7b0d26a86

With this patch we run the kobject_del via schedule_work so as to
avoid the deadlock.

Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-04 21:12:47 -07:00
Linus Torvalds 8d00647f2c Merge branch 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6
* 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6:
  [S390] cio: Fix handling of interrupt for csch().
  [S390] page_mkclean data corruption.
2007-04-04 10:11:16 -07:00
Linus Torvalds bb4899dbef Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev:
  libata: Limit ATAPI DMA to R/W commands only for TORiSAN DVD drives (take 3)
  libata: Limit max sector to 128 for TORiSAN DVD drives (take 3)
  libata: Clear tf before doing request sense (take 3)
  libata: reorder HSM_ST_FIRST for easier decoding (take 3)
  libata bugfix: preserve LBA bit for HDIO_DRIVE_TASK
  2.6.21 fix lba48 bug in libata fill_result_tf()
2007-04-04 08:44:40 -07:00
Robert Hancock 36e337d024 [PATCH] libata: add NCQ blacklist entries from Silicon Image Windows driver (v2)
This adds some NCQ blacklist entries taken from the Silicon Image 3124/3132
Windows driver .inf files. There are some confirming reports of problems
with these drives under Linux (for example http://lkml.org/lkml/2007/3/4/178)
so let's disable NCQ on these drives.

 [ I'm personally starting to wonder whether we shouldn't disable NCQ by
   default, and perhaps have a white-list. There seems to be a *lot* of
   drives that do this wrong..   - Linus ]

Signed-off-by: Robert Hancock <hancockr@shaw.ca>
Acked-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-04 08:40:17 -07:00
Linus Torvalds b6d3d16e26 Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
  r8169: fix suspend/resume for down interface
  r8169: issue request_irq after the private data are completely initialized
  b44: fix IFF_ALLMULTI handling of CAM slots
  cxgb3 - Firwmare update
  cxgb3 - Tighten xgmac workaround
  cxgb3 - detect NIC only adapters
  cxgb3 - Safeguard TCAM size usage
2007-04-04 08:36:01 -07:00
Cornelia Huck 8c3ce5bece [S390] cio: Fix handling of interrupt for csch().
Wipe internal irb if the clear function bit is set before accumulating
bits from the irb in order to follow hardware behaviour.

Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-04-04 14:37:39 +02:00
Albert Lee 6f23a31d1c libata: Limit ATAPI DMA to R/W commands only for TORiSAN DVD drives (take 3)
patch 4/4:

  Limit ATAPI DMA to R/W commands only for TORiSAN DRD-N216 DVD-ROM drives
  (http://bugzilla.kernel.org/show_bug.cgi?id=6710)

Signed-off-by: Albert Lee <albertcc@tw.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-04 02:12:27 -04:00
Albert Lee 18d6e9d518 libata: Limit max sector to 128 for TORiSAN DVD drives (take 3)
patch 3/4:
  The TORiSAN drive locks up when max sector == 256.
  Limit max sector to 128 for the TORiSAN DRD-N216 drives.
  (http://bugzilla.kernel.org/show_bug.cgi?id=6710)

Signed-off-by: Albert Lee <albertcc@tw.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-04 02:12:27 -04:00
Albert Lee 56287768e3 libata: Clear tf before doing request sense (take 3)
patch 2/4:
  Clear tf before doing request sense.

This fixes the AOpen 56X/AKH timeout problem.
(http://bugzilla.kernel.org/show_bug.cgi?id=8244)

Signed-off-by: Albert Lee <albertcc@tw.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-04 02:12:27 -04:00
Mark Lord 277239f228 libata bugfix: preserve LBA bit for HDIO_DRIVE_TASK
Preserve the LBA bit in the DevSel/Head register for HDIO_DRIVE_TASK.

Signed-off-by:  Mark Lord <mlord@pobox.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-04 02:07:28 -04:00
Mark Lord 4742d54fa4 2.6.21 fix lba48 bug in libata fill_result_tf()
Current 2.6.21 libata does the following:

void ata_tf_read(struct ata_port *ap, struct ata_taskfile *tf)
{
        struct ata_ioports *ioaddr = &ap->ioaddr;

        tf->command = ata_check_status(ap);
	...
        if (tf->flags & ATA_TFLAG_LBA48) {
                iowrite8(tf->ctl | ATA_HOB, ioaddr->ctl_addr);
                tf->hob_feature = ioread8(ioaddr->error_addr);
                ...
        }
}
...
static void fill_result_tf(struct ata_queued_cmd *qc)
{
        struct ata_port *ap = qc->ap;

        ap->ops->tf_read(ap, &qc->result_tf);
        qc->result_tf.flags = qc->tf.flags;
}

Based on this, those last two statements fill_result_tf()
appear to me to be in the wrong order, in that the tf->flags
are uninitialized at the point where tf_read() is invoked.
So for lba48 commands, tf_read() won't be reading back the
full lba48 register contents..

Correct?

This patch corrects fill_result_tf() so that the flags
get copied to result_tf before they are used by tf_read().

Signed-off-by:  Mark Lord <mlord@pobox.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-04 02:07:28 -04:00
Francois Romieu 1371fa6db0 r8169: fix suspend/resume for down interface
The PM hooks are no-op if the r8169 interface is down (i.e. !IFF_UP).
However, as the chipset is enabled, the device will not work after a
suspend/resume cycle. The patch always issue the required PCI suspend
sequence and removes the module unload/reload workaround.

Signed-off-by: Arnaud Patard <apatard@mandriva.com>
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-03 22:31:10 -04:00
Francois Romieu 99f252b097 r8169: issue request_irq after the private data are completely initialized
The irq handler schedules a NAPI poll request unconditionally as soon as
the status register is not clean. It has been there - and wrong - for
ages but a recent timing change made it apparently easier to trigger.

Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Cc: Jay Cliburn <jacliburn@bellsouth.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-03 22:31:10 -04:00
Bill Helfinstine cda22aa94d b44: fix IFF_ALLMULTI handling of CAM slots
If you set the IFF_ALLMULTI flag on a b44 device, or if you join more than
B44_MCAST_TABLE_SIZE multicast groups, the device will stop receiving unicast
messages.  This is because the __b44_set_mac_addr call sets the zeroth CAM
entry to the MAC address of the device, and then the loop at line 1722
proceeds to overwrite it unless the value of i is set by the __b44_load_mcast
call.  However, when IFF_ALLMULTI is set, that call is bypassed, leaving i set
to zero.

Fixed by starting the loop at 1 to make it skip the CAM entry for the MAC
address.

Signed-off-by: Bill Helfinstine <bhelf@flitterfly.whirpon.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-03 22:31:09 -04:00
Divy Le Ray 7f672cf5b2 cxgb3 - Firwmare update
Introduce FW micro version.
Bump up FW version to 3.3.0

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-03 22:31:09 -04:00
Divy Le Ray 6d6dabac38 cxgb3 - Tighten xgmac workaround
Run the watchdog task when the link is up.
Flush the XGMAC Tx FIFO when the link drops.

Also remove a statistics update that should have gone
in the previous modification of xgmac.c.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-03 22:31:09 -04:00
Divy Le Ray 8ac3ba68e2 cxgb3 - detect NIC only adapters
Differentiate NIC only adapters from RNICs.
Initialize offload capabilities for RNICs only.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-03 22:31:09 -04:00
Divy Le Ray 9f238486f5 cxgb3 - Safeguard TCAM size usage
Ensure that the TCAM active region size is at least 16.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-03 22:31:09 -04:00
Eric W. Biederman 348e3fd194 [PATCH] msi: synchronously mask and unmask msi-x irqs.
This is a simplified and actually more comprehensive form of a bug
fix from Mitch Williams <mitch.a.williams@intel.com>.

When we mask or unmask a msi-x irqs the writes may be posted because
we are writing to memory mapped region.  This means the mask and
unmask don't happen immediately but at some unspecified time in the
future.  Which is out of sync with how the mask/unmask logic work
for ioapic irqs.

The practical result is that we get very subtle and hard to track down
irq migration bugs.

This patch performs a read flush after writes to the MSI-X table for mask
and unmask operations.  Since the SMP affinity is set while the interrupt
is masked, and since it's unmasked immediately after, no additional flushes
are required in the various affinity setting routines.

The testing by Mitch Williams on his especially problematic system should
still be valid as I have only simplified the code, not changed the
functionality.

We currently have 7 drivers: cciss, mthca, cxgb3, forceth, s2io,
pcie/portdrv_core, and qla2xxx in 2.6.21 that are affected by this
problem when the hardware they driver is plugged into the right slot.

Given the difficulty of reproducing this bug and tracing it down to
anything that even remotely resembles a cause, even if people are
being affected we aren't likely to see many meaningful bug reports, and
the people who see this bug aren't likely to be able to reproduce this
bug in a timely fashion.  So it is best to get this problem fixed
as soon as we can so people don't have problems.

Then if people do have a kernel message stating "No irq for vector" we
will know it is yet another novel cause that needs a complete new
investigation.

Cc: Greg KH <greg@kroah.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Mitch Williams <mitch.a.williams@intel.com>
Acked-by: "Siddha, Suresh B" <suresh.b.siddha@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-03 14:02:49 -07:00
Linus Torvalds 59117d3f4e Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [SCSI]: Fix scsi_send_eh_cmnd scatterlist handling
  [SPARC]: Add unsigned to unused bit field in a.out.h
2007-04-02 15:23:08 -07:00
Linus Torvalds 856fc004b8 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [TCP]: Do receiver-side SWS avoidance for rcvbuf < MSS.
  [BNX2]: Fix nvram write logic.
  [IPv6]: Fix incorrect length check in rawv6_sendmsg()
  [NET_SCHED]: cls_basic: fix memory leak in basic_destroy
  [NET]: Change "not found" return value for rule lookup
2007-04-02 15:22:20 -07:00
David S. Miller 8cc574a3c5 [SCSI]: Fix scsi_send_eh_cmnd scatterlist handling
This fixes a regression caused by commit:

2dc611de5a

The sense buffer code in scsi_send_eh_cmnd was changed to use
alloc_page() and a scatter list, but the sense data copy was not
updated to match so what we actually get in the sense buffer is total
grabage starting with the kernel address of the struct page we got.
Basically the stack frame of scsi_send_eh_cmd() is what ends up
in the sense buffer.

Depending upon how pointers look on a given platform, you can
end up getting sr_ioctl.c errors when you mount a cdrom.  If
the CDROM gives a check condition for GPCMD_GET_CONFIGURATION issued
by drivers/cdrom/cdrom.c:cdrom_mmc_profile(), sr_ioctl will
spit out this error message in sr_do_ioctl() with the way pointers
are on sparc64:

		default:
			printk(KERN_ERR "%s: CDROM (ioctl) error, command: ", cd->cdi.name);
			__scsi_print_command(cgc->cmd);
			scsi_print_sense_hdr("sr", &sshdr);
			err = -EIO;

This is the error Tom Callaway reported in:

http://marc.info/?l=linux-sparc&m=117407453208101&w=2

Anyways, fix this by using page_address(sgl.page) which is OK
because we know this is low-mem due to GFP_ATOMIC.

Signed-off-by: David S. Miller <davem@davemloft.net>
Acked-by: Christoph Hellwig <hch@lst.de>
2007-04-02 14:26:22 -07:00
Linus Torvalds 5c0efdbc1b Merge branch 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb
* 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb:
  V4L/DVB (5496): Pluto2: fix incorrect TSCR register setting
  V4L/DVB (5495): Tda10086: fix DiSEqC message length
2007-04-02 13:52:10 -07:00
Michael Chan c873879c4d [BNX2]: Fix nvram write logic.
The nvram dword alignment logic was broken when writing less than 4
bytes on a non-aligned offset.  It was missing logic to round the
length to 4 bytes.

The page erase code is also moved so that it is only called when
using non-buffered flash for better code clarity.

Update version to 1.5.7.

Based on initial patch from Tony Cureington <tony.cureington@hp.com>.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-02 13:30:55 -07:00
Michal Januszewski f991519c19 [PATCH] vt: fix potential race in VT_WAITACTIVE handler
On a multiprocessor machine the VT_WAITACTIVE ioctl call may return 0 if
fg_console has already been updated in redraw_screen() but the console
switch itself hasn't been completed.  Fix this by checking fg_console in
vt_waitactive() with the console sem held.

Signed-off-by: Michal Januszewski <spock@gentoo.org>
Acked-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-02 10:06:09 -07:00
David Brownell bcd9b89c02 [PATCH] rtc-cmos lockdep fix, irq updates
Lockdep reported cmos_suspend() and cmos_resume() calling rtc_update_irq()
with IRQs enabled; not allowed.

Also fix problems seen on some hardware, whereby false alarm IRQs could be
reported (primarily to userspace); and update two comments to match changes
in ACPI.  Those make up most of this patch, by volume.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-02 10:06:09 -07:00
Petr Vandrovec a2b091dbfb [PATCH] Correctly report PnP 64bit resources
Change PnP resource handling code to use proper type for resource start and
length.  Fixes bogus regions reported in /proc/iomem.

I've also made some pointer constant, as they are constant...

Signed-off-by: Petr Vandrovec <petr@vandrovec.name>
Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-02 10:06:08 -07:00
Adrian Bunk bf703c3f19 [PATCH] drivers/mfd/sm501.c: fix an off-by-one
Fix an off-by-one spotted by the Coverity checker.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Cc: Ben Dooks <ben-linux@fluff.org>
Cc: Vincent Sanders <vince@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-02 10:06:08 -07:00
Andreas Oberritter 1489f90a49 V4L/DVB (5496): Pluto2: fix incorrect TSCR register setting
The ADEF bits in the TSCR register have different meanings in read and
write mode. For this reason ADEF has to be reset on every
read-modify-write operation.
This patch introduces a special write function for this register, which
takes care of it.

Thanks to Holger Magnussen for pointing my nose at this problem.

Signed-off-by: Andreas Oberritter <obi@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-02 11:03:05 -03:00
Andreas Oberritter d420cb4469 V4L/DVB (5495): Tda10086: fix DiSEqC message length
Setting the message length to zero means to send one byte, so you need a
subtraction instead of an addition.

Signed-off-by: Andreas Oberritter <obi@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-02 11:03:04 -03:00
Linus Torvalds 2e175a9004 Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
  [ARM] 4298/1: fix memory barriers for DMA coherent and SMP platforms
  [ARM] 4295/2: Fix error-handling in pxaficp_ir.c (version 2)
  [ARM] Fix __NR_kexec_load
  [ARM] Export dma_channel_active()
  [ARM] 4296/1: ixp4xx: compile fix
  [ARM] 4289/1: AT91: SAM9260 NAND flash timing
2007-04-01 14:43:57 -07:00
Guennadi Liakhovetski 9a4d93d49d [ARM] 4295/2: Fix error-handling in pxaficp_ir.c (version 2)
This patch addresses the following issues with the pxa2xx FIr driver:

1. increment overrun error counter and not frame error counter on ICSR1_ROR bit set in ICSR1.
2. drop frames reported with the frame error from the IC.
3. when resetting the receiver and preparing it for the next DMA in pxa_irda_fir_irq() actually clear the Rx FIFO. See description in Table 11-2 in PXA270 Developer's Manual of the RXE bit.

Correction added in version 2: clearing the IC Rx FIFO also has to be done in pxa_irda_fir_dma_tx_irq()

Signed-off-by: G. Liakhovetski <gl@dsa-ac.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2007-04-01 22:38:01 +01:00
Linus Torvalds f5ef2abcbe driver core: do not wait unnecessarily in driver_unregister()
Ingo reported that built-in drivers suffered bootup hangs with certain
driver unregistry sequences, due to sysfs breakage.

Do the minimal fix for v2.6.21: only wait if the driver is a module.

Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-01 10:54:13 -07:00
Linus Torvalds a5bd1786fb Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
  Revert "ACPI: parse 2nd MADT by default"
2007-03-30 11:49:37 -07:00
Len Brown 4e381a4f06 Revert "ACPI: parse 2nd MADT by default"
This reverts commit 09fe58356d.
http://bugzilla.kernel.org/show_bug.cgi?id=8283

Signed-off-by: Len Brown <len.brown@intel.com>
2007-03-30 14:16:10 -04:00
Jens Axboe 964429252a [PATCH] Maxtor 6B250S0/BANC1B70 hangs with NCQ
I've seen this several times on this drive, completely reproducible.

Once it has hung, power needs to be cut from the drive to recover it, a
simple reboot is not enough.  So I'd suggest disabling NCQ on this
drive.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Acked-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-30 11:13:06 -07:00
Linus Torvalds efab03d998 Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
  NetXen: Fix hardware access for ppc architecture.
  sis190: new PHY support
  atl1: save mac address on remove
2007-03-29 13:22:07 -07:00
Linus Torvalds 9415fddd99 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [IFB]: Fix crash on input device removal
  [BNX2]: Fix link interrupt problem.
2007-03-29 13:15:13 -07:00
Patrick McHardy c01003c205 [IFB]: Fix crash on input device removal
The input_device pointer is not refcounted, which means the device may
disappear while packets are queued, causing a crash when ifb passes packets
with a stale skb->dev pointer to netif_rx().

Fix by storing the interface index instead and do a lookup where neccessary.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Acked-by: Jamal Hadi Salim <hadi@cyberus.ca>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-29 11:46:52 -07:00
Ralf Baechle 96fac9dc95 [PATCH] Wire up DEC serial drivers in Kconfig
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-29 08:22:25 -07:00
Tilman Schmidt 35dc845782 [PATCH] drivers/isdn/gigaset: mark some static data as const (v2)
Mark some static arrays as const that aren't and shouldn't be modified, and
remove incorrect static attribute from some variables.

Signed-off-by: Tilman Schmidt <tilman@imap.cc>
Signed-off-by: Hansjoerg Lipp <hjlipp@web.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-29 08:22:25 -07:00
Linsys Contractor Adhiraj Joshi d8d79201eb NetXen: Fix hardware access for ppc architecture.
NetXen: Fix for hardware access on big endian machine.

Signed-off-by: Adhiraj Joshi <adhiraj@netxen.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-29 08:26:05 -04:00
Francois Romieu bd7a444889 sis190: new PHY support
Reported to work on the WinFast 761GXK8MB-RS motherboard.

Plain 10/100 Mbps.

Signed-off-by: Paul Gibbons <paul@pkami.e7even.com>
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-29 08:26:05 -04:00
Chris Snook 8c754a04ff atl1: save mac address on remove
Some atl1 boards get their MAC address written directly to the register
by the BIOS during POST, rather than storing it in EEPROM that's
accessible to the driver.  If the MAC register on one of these boards
is changed and then the module is unloaded, the permanent MAC address
will be forgotten until the box is rebooted.  We should save the
permanent address during removal if we've been messing with it.

Signed-off-by: Chris Snook <csnook@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-29 08:26:05 -04:00
Michael Chan db8b22550d [BNX2]: Fix link interrupt problem.
bnx2_has_work()'s logic is flawed and can cause the driver to miss
a link event.  The fix is to compare the status block's attn_bits
and attn_bits_ack to determine if there is a link event.

Update version to 1.5.6.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-28 20:23:52 -07:00
Linus Torvalds d0a9af8091 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [VIDEO]: Fix section mismatch in cg3.c
  [SPARC]: sparc64 gcc-4.2.0 20070317 -Werror failure
  [VIDEO] ffb: Fix two DAC handling bugs.
  [SPARC32]: Fix SMP build regression
  [DRM]: Delete sparc64 FFB driver code that never gets built.
2007-03-28 14:01:21 -07:00
Linus Torvalds a26b5fce06 Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband:
  IB/iser: Handle aborting a command after it is sent
  IB/mthca: Fix thinko in init_mr_table()
  RDMA/cxgb3: Fix resource leak in cxio_hal_init_ctrl_qp()
2007-03-28 14:00:01 -07:00
Jiri Kosina 4dfc896e90 [PATCH] oprofile: fix potential deadlock on oprofilefs_lock
nmi_cpu_setup() is called from hardirq context and acquires oprofilefs_lock.
alloc_event_buffer() and oprofilefs_ulong_from_user() acquire this lock
without disabling irqs, which could deadlock.

Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-28 13:58:02 -07:00
Linus Torvalds 2ba302c633 Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev:
  ata: NCQ is broken on Maxtor 6L250S0
  pata_pdc202xx_old: LBA48 bug
  libata: IDENTIFY backwards for drive side cable detection
  ahci.c: walkaround for SB600 SATA internal error issue
  [libata] Disable ACPI by default; fix namespace problems
2007-03-28 13:46:00 -07:00
Robert Reif a71775147f [VIDEO]: Fix section mismatch in cg3.c
Fix section mismatch warning by moving data into __devinitdata section.
Add __devinit to initialization functions.

Signed-off-by: Robert Reif <reif@earthlink.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-28 12:50:56 -07:00
Jeff Garzik a9c87a10db Merge branch 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into upstream-fixes 2007-03-28 02:21:18 -04:00
Cyrill V. Gorcunov c14bac628b SUN3/3X Lance trivial fix improved
This patch adds checking for allocated DVMA memory and granted IRQ line.

Signed-off-by: Cyrill V. Gorcunov <gorcunov@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:51 -04:00
Gabriel Paubert fadac4060c mv643xx_eth: Fix use of uninitialized port_num field
In this driver, the default ethernet address is first set by by calling
eth_port_uc_addr_get() which reads the relevant registers of the
corresponding port as initially set by firmware. However that function
used the port_num field accessed through the private area of net_dev
before it was set.

The result was that one board I have ended up with the unicast address
set to 00:00:00:00:00:00 (only port 1 is connected on this board). The
problem appeared after commit 84dd619e4d.

This patch fixes the bug by setting mp->port_num prior to calling
eth_port_uc_get_addr().

Signed-off-by: Gabriel Paubert <paubert@iram.es>
Signed-off-by: Dale Farnsworth <dale@farnsworth.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:51 -04:00
Ayaz Abdulla 3ba4d093fe forcedeth: fix tx timeout
The tx timeout routine was waking the tx queue conditionally. However,
it must call it unconditionally since the dev_watchdog has halted the tx
queue before calling the timeout function.

Signed-Off-By: Ayaz Abdulla <aabdulla@nvidia.com>

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:51 -04:00
Ayaz Abdulla fcc5f2665c forcedeth: fix nic poll
The nic poll routine was missing the call to the optimized irq routine.
This patch adds the missing call for the optimized path.

See http://bugzilla.kernel.org/show_bug.cgi?id=7950 for more information.

Signed-Off-By: Ayaz Abdulla <aabdulla@nvidia.com>

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:51 -04:00
Ron Mercer b3b1514c90 qla3xxx: bugfix: Jumbo frame handling.
Fixed rx checksum bits. Turn on TCP processing for rx checksum.
Fixed max frame length register write.  It wasn't getting set
in multi-port system. Set rx buffer queue length properly
for jumbo frames.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:50 -04:00
Ron Mercer f67cac0190 qla3xxx: bugfix: Dropping interrupt under heavy network load.
Update the rx queue pointer when exiting NAPI poll rather than
at the end of each iteration.  Remove unnecessary PCI flushes
that occurred after every write.  Now write all regs and
flush once.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:50 -04:00
Ron Mercer b6967eb9cb qla3xxx: bugfix: Multi segment sends were getting whacked.
The proper header length was not being used.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:50 -04:00
Ron Mercer d8a759ff41 qla3xxx: bugfix: Add tx control block memset.
This was removed in a previous patch to increase performance, but
caused a transmit error for the 4032 chip.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:50 -04:00
Jay Cliburn de815a14e9 atl1: remove unnecessary crc inversion
The original vendor driver contained a private ether_crc_le() function
that produced an inverted crc.  When we changed to the kernel version of
ether_crc_le(), we neglected to undo the inversion.  Let's do it now.
Discovered by and patch proffered by Jose Alberto Reguero.

Signed-off-by: Jose Alberto Reguero <jareguero@telefonica.net>
Signed-off-by: Jay Cliburn <jacliburn@bellsouth.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:50 -04:00
Brice Goglin 917690cd03 myri10ge: correctly detect when TSO should be used
Correctly detect when TSO should be used on transmit by looking at the
skb->gso_size rather than seeing if the frame was larger than our MTU.
The old method causes problems when a host with a large (jumbo) MTU is
sending to a host with a small (standard) MTU.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:18:50 -04:00
Paul Rolland 7acfaf3037 ata: NCQ is broken on Maxtor 6L250S0
With this applied, my machine has stopped all those painful messages.
dmesg now says :

root@riri:/Kernels# dmesg | grep LBA
ata1.00: 490234752 sectors, multi 0: LBA48 NCQ (not used)
ata2.00: 640 sectors, multi 1: LBA
ata3.00: 490234752 sectors, multi 0: LBA48 NCQ (not used)

Signed-off-by: Paul Rolland <rol@as2917.net>
Acked-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>
2007-03-28 02:05:13 -04:00
Alan Cox 5e5188108b pata_pdc202xx_old: LBA48 bug
In LBA48 mode we have to help the controller to get anything to work. The
chip provides a register giving word counts meant for ATAPI use which we
can use. However we need to load the count in words not bytes..

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:05:13 -04:00
Tejun Heo 8c3c52a8f0 libata: IDENTIFY backwards for drive side cable detection
For drive side cable detection to work correctly, drives need to be
identified backwards such that the slave device releases PDIAG- before
the mater drive tries to detect cable type.  ata_bus_probe() was fixed
by commit f31f0cc2f0 but the new EH path
wasn't fixed.  This patch makes new EH path do IDENTIFY backwards.

ata_dev_configure() for new devices are still performed master first.
This is to keep the detection messages in forward order.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:04:27 -04:00
Conke Hu 55a61604cd ahci.c: walkaround for SB600 SATA internal error issue
There is a HW issue in ATI SB600 SATA that PxSERR.E should not be
set on some conditions, for example, when there is no media in SATA
CD/DVD drive or media is not ready, AHCI controller fails to execute
ATAPI commands and reports PORT_IRQ_TF_ERR, but ATI SB600 SATA
controller sets PxSERR.E at the
same time, which is not necessary.
    This patch is just to ignore the INTERNAL ERROR in such case.
Without this patch, ahci error handler will report many errors as
below:
    ----------- cut from dmesg -----------
ata9: soft resetting port
ata9: SATA link up 1.5 Gbps (SStatus 113 SControl 300)
ata9.00: configured for UDMA/33
ata9: EH complete
ata9.00: exception Emask 0x40 SAct 0x0 SErr 0x800 action 0x2
ata9.00: (irq_stat 0x40000001)
ata9.00: cmd a0/00:00:00:00:20/00:00:00:00:00/a0 tag 0 cdb 0x0 data 0
        res 51/24:03:00:00:20/00:00:00:00:00/a0 Emask 0x40 (internal error)
ata9: soft resetting port
ata9: SATA link up 1.5 Gbps (SStatus 113 SControl 300)
ata9.00: configured for UDMA/33
ata9: EH complete
ata9.00: exception Emask 0x40 SAct 0x0 SErr 0x800 action 0x2
ata9.00: (irq_stat 0x40000001)
ata9.00: cmd a0/01:00:00:00:00/00:00:00:00:00/a0 tag 0 cdb 0x43 data 12 in
        res 51/24:03:00:00:00/00:00:00:00:00/a0 Emask 0x40 (internal error)
    -------- end cut ---------

Signed-off-by: Conke Hu <conke.hu@amd.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 02:04:27 -04:00
Jeff Garzik d7d0dad62a [libata] Disable ACPI by default; fix namespace problems
Not yet ready to turn on ATA ACPI by default, for either PATA or SATA.

Also, rename the global-scope module parameter variable 'noacpi' to
something more libata-specific, reducing the potential for namespace
collision.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-28 01:57:37 -04:00
David Woodhouse 83b5db89c8 [PATCH] bcm43xx: Fix machine check on PPC for version 1 PHY
Recent changes in the specs that were introduced in commit
740ac4fb08 were incorrect and resulted in machine check
errors on the PPC architecture for G PHY's with a revision number equal to 1. The
two offending changes are reverted.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-03-27 13:16:53 -04:00
Stefano Brivio 7265c5d10d [PATCH] bcm43xx: fix radio_set_tx_iq
Fix a duplicated leftshift in bcm43xx_radio_set_tx_iq. data_high values are
already leftshifted. Thanks to Michael Buesch for spotting this.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-03-27 13:16:52 -04:00
Larry Finger be10d3860e [PATCH] bcm43xx: Fix code for confusion between PHY revision and PHY version
There are several places where the PHY version and revision were interchanged.
These are changed in the specifications on 2/13/07 and now use "analog" instead
instead of "version" to help reduce confusion.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-03-27 13:16:52 -04:00
Linus Torvalds d459094083 Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
  [SCSI] gdth: fix oops in gdth_copy_cmd()
  [SCSI] mptsas: Fix oops for insmod during kexec
  [SCSI] lpfc: avoid double-free during PCI error failure
2007-03-27 10:06:30 -07:00
Linus Torvalds d0d87aae79 Merge git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb
* git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb:
  V4L/DVB (5472): Isl6421: don't reference freed memory
  V4L/DVB (5441): Saa7146: Fix allocation of clipping memory
  V4L/DVB (5421): Fix suspend/resume in msp3400 and tuner
  V4L/DVB (5415): Msp_attach must return 0 if no msp3400 was found.
  V4L/DVB (5408): Fix SECAM handling on saa7115
  V4L/DVB (5400): Core: fix several locking related problems
  V4L/DVB (5390): Radio: Fix error in Kbuild file
  V4L/DVB (5332): Ir_rc5_timer_end decoder lockup fix
2007-03-27 09:23:59 -07:00
Linus Torvalds 5158074971 Merge git://kvm.qumranet.com/home/avi/kvm
* git://kvm.qumranet.com/home/avi/kvm:
  KVM: always reload segment selectors
  KVM: Prevent system selectors leaking into guest on real->protected mode transition on vmx
2007-03-27 09:22:05 -07:00
Vasily Averin d1985ad1da [PATCH] i2o: block IO errors on i2o disk
I2O subsystem has been broken in mainstream several months ago (after
2.6.18).  Commit 4aff5e2333 from Jens
Axboe split struct request ->flags into two parts: cmd_type and
cmd_flags.

In i2o layer this patch has replaced flag REQ_SPECIAL by the according
cmd_type.  However i2o has used REQ_SPECIAL not as command type but as
driver-specific flag for the debug purposes.  As result all i2o requests
have type "special" now, are not processed to the hardware and fail with
I/O error:

   i2o/hda:<3>Buffer I/O error on device i2o/hda, logical block 0
  Buffer I/O error on device i2o/hda, logical block 0
  Buffer I/O error on device i2o/hda, logical block 0
   unable to read partition table
  block-osm: device added (TID: 207): i2o/hda

The following patch removes the extra debug checks without any drawbacks and
restores the normal driver's work.

Signed-off-by:	Vasily Averin <vvs@sw.ru>
Acked-by: Markus Lidel <Markus.Lidel@shadowconnect.com>
Cc: Jens Axboe <jens.axboe@oracle.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:16 -07:00
Yoichi Yuasa 88f45005ce [PATCH] Fix struct device member name in PCMCIA au1000_generic
drivers/pcmcia/au1000_generic.c: In function 'au1x00_pcmcia_socket_probe':
  drivers/pcmcia/au1000_generic.c:375: error: 'struct device' has no member named 'dev'

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Jaroslav Kysela <perex@suse.cz>
Cc: Takashi Iwai <tiwai@suse.de>
Cc: Greg KH <greg@kroah.com>
Cc: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:16 -07:00
Adrian Bunk 74b9a29786 [PATCH] drivers/eisa/pci_eisa.c:pci_eisa_init() should be init
WARNING: drivers/built-in.o - Section mismatch: reference to .init.text:eisa_root_register from .text between 'pci_eisa_init' (at offset 0xabf670) and 'virtual_eisa_release'

AFAIK a PCI to EISA bridge isn't anything hotpluggable, so
pci_eisa_init() can become __init.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:15 -07:00
Adrian Bunk e9d5a46115 [PATCH] drivers/spi/: fix section mismatches
WARNING: drivers/built-in.o - Section mismatch: reference to .init.text:spi_register_master from .text between 'spi_bitbang_start' (at offset 0x84e11a) and 'bitbang_work'
  WARNING: drivers/built-in.o - Section mismatch: reference to .init.text:spi_alloc_master from .text between 'butterfly_attach' (at offset 0x84e681) and 'at25_remove'
  WARNING: drivers/built-in.o - Section mismatch: reference to .init.text:spi_new_device from .text between 'butterfly_attach' (at offset 0x84e7e4) and 'at25_remove'

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:15 -07:00
Jiri Kosina 3899210ad9 [PATCH] ISDN: fix BChannel_bh() call from isar_bh()
isar_bh() bh handler calls another (compatible) bh handler - BChannel_bh()
- but passes struct BCState* instead of struct work_struct*, which seems
wrong.

Cc: Karsten Keil <kkeil@suse.de>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:15 -07:00
john stultz 1ff100d76f [PATCH] correct slow acpi_pm rating
On Bob's machine clocksource is selecting PIT over the ACPI PM timer,
because he has the PIIX4 bug.  That bug drops the ACPI PM timers rating
to the same as the PIT, so that's why you're getting the PIT.

Realistically, the PIT is much slower then even the triple read ACPI PM,
so the de-ranking code is probably dropping it too far.

So don't drop ACPI PM quite so low if we see the PIIX4 bug.

Signed-off-by: John Stultz <johnstul@us.ibm.com>
Cc: Bob Tracy <rct@gherkin.frus.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:15 -07:00
Daniel Drake d340d89087 [PATCH] generic_serial: fix decoding of baud rate
Commit d720bc4b8f partially removed a
private implementation of baud speed decoding.  However it doesn't seem
to be complete: after the speed is decoded, it is still being used as an
index to a local speed table (array overrun, no doubt).

This was found by Graham Murray who noticed it caused a 2.6.19 regression
with the SX driver: https://bugs.gentoo.org/170554

Signed-off-by: Daniel Drake <dsd@gentoo.org>
Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:15 -07:00
NeilBrown 5e55e2f5fc [PATCH] md: convert compile time warnings into runtime warnings
...  still not sure why we need this ....

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:15 -07:00
NeilBrown 041ae52e26 [PATCH] md: clear the congested_fn when stopping a raid5
If this mddev and queue got reused for another array that doesn't register a
congested_fn, this function would get called incorretly.

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:14 -07:00
NeilBrown 3d37890baa [PATCH] md: allow raid4 arrays to be reshaped
All that is missing the the function pointers in raid4_pers.

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 09:05:14 -07:00
Venki Pallipadi ec28297a56 [PATCH] Fix maxcpus=1 trigerring BUG() in cpufreq
Ingo reported it on lkml in the thread
  "2.6.21-rc5: maxcpus=1 crash in cpufreq: kernel BUG at drivers/cpufreq/cpufreq.c:82!"

This check added to remove_dev  is symmetric to one in add_dev and handles
callbacks for offline cpus cleanly.

Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-27 08:55:56 -07:00
Ingo Molnar 6d9658df07 KVM: always reload segment selectors
failed VM entry on VMX might still change %fs or %gs, thus make sure
that KVM always reloads the segment selectors. This is crutial on both
x86 and x86_64: x86 has __KERNEL_PDA in %fs on which things like
'current' depends and x86_64 has 0 there and needs MSR_GS_BASE to work.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
2007-03-27 17:55:48 +02:00
Avi Kivity 6af11b9e82 KVM: Prevent system selectors leaking into guest on real->protected mode transition on vmx
Intel virtualization extensions do not support virtualizing real mode.  So
kvm uses virtualized vm86 mode to run real mode code.  Unfortunately, this
virtualized vm86 mode does not support the so called "big real" mode, where
the segment selector and base do not agree with each other according to the
real mode rules (base == selector << 4).

To work around this, kvm checks whether a selector/base pair violates the
virtualized vm86 rules, and if so, forces it into conformance.  On a
transition back to protected mode, if we see that the guest did not touch
a forced segment, we restore it back to the original protected mode value.

This pile of hacks breaks down if the gdt has changed in real mode, as it
can cause a segment selector to point to a system descriptor instead of a
normal data segment.  In fact, this happens with the Windows bootloader
and the qemu acpi bios, where a protected mode memcpy routine issues an
innocent 'pop %es' and traps on an attempt to load a system descriptor.

"Fix" by checking if the to-be-restored selector points at a system segment,
and if so, coercing it into a normal data segment.  The long term solution,
of course, is to abandon vm86 mode and use emulation for big real mode.

Signed-off-by: Avi Kivity <avi@qumranet.com>
2007-03-27 17:54:38 +02:00
Thomas Viehweger 09d4895488 V4L/DVB (5472): Isl6421: don't reference freed memory
After freeing a block there should be no reference to this block.

Signed-off-by: Thomas Viehweger <Thomas.Viehweger@marconi.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-03-27 08:45:56 -03:00
Jean Delvare 21b48a70f7 V4L/DVB (5421): Fix suspend/resume in msp3400 and tuner
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-03-27 08:45:55 -03:00
Hans Verkuil 3284b4e077 V4L/DVB (5415): Msp_attach must return 0 if no msp3400 was found.
Returning -1 causes the probe to stop, but it should just continue
instead.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-03-27 08:45:55 -03:00
Mauro Carvalho Chehab a9aaec4e83 V4L/DVB (5408): Fix SECAM handling on saa7115
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-03-27 08:45:54 -03:00
Simon Arlott c278850206 V4L/DVB (5400): Core: fix several locking related problems
Fix several instances of dvb-core functions using mutex_lock_interruptible
and returning -ERESTARTSYS where the calling function will either never
retry or never check the return value.
These cause a race condition with dvb_dmxdev_filter_free and
dvb_dvr_release, both of which are filesystem release functions whose
return value is ignored and will never be retried.  When this happens it
becomes impossible to open dvr0 again (-EBUSY) since it has not been
released properly.

Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Acked-By: Johannes Stezenbach <js@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-03-27 08:45:54 -03:00
Trent Piepho b10fece583 V4L/DVB (5390): Radio: Fix error in Kbuild file
All the radio drivers need video_dev, but they were depending on
VIDEO_DEV!=n.  That meant that one could try to compile the driver into
the kernel when VIDEO_DEV=m, which will not work.  If video_dev is a
module, then the radio drivers must be modules too.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-03-27 08:45:53 -03:00
Vincent Penne 726cf56f24 V4L/DVB (5332): Ir_rc5_timer_end decoder lockup fix
ir_rc5_timer_end decoder lockup fix

Signed-off-by: Vincent Penne <ziggy@sashipa.com>
Signed-off-by: Hermann Pitton <hermann-pitton@arcor.de>
Signed-off-by: Hartmut Hackmann <hartmut.hackmann@t-online.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-03-27 08:45:53 -03:00
David S. Miller 37db9a348a [VIDEO] ffb: Fix two DAC handling bugs.
The determination of whether the DAC has inverted cursor logic is
broken, import the version checks the X.org driver uses to fix this.

Next, when we change the timing generator, borrow code from X.org that
does 10 NOP reads of the timing generator register afterwards to make
sure the video-enable transition occurs cleanly.

Finally, use macros for the DAC registers and fields in order to
provide documentation for the next person who reads this code.

Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-26 23:18:09 -07:00
David S. Miller b82f87f6d4 [DRM]: Delete sparc64 FFB driver code that never gets built.
The Kconfig bits were removed long ago, so we should kill off the
driver too.

Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-26 21:49:11 -07:00
Erez Zilber 3104a2175d IB/iser: Handle aborting a command after it is sent
The SCSI midlayer may abort a command that was already sent.  If the
initiator is still trying to send the command (or data-out PDUs for
that command), the QP may time out after the midlayer times
out. Therefore, when aborting the command, iSER may still have
references for the command's buffers.  When sending these PDUs, the
sends will complete with an error and their resources will be released
then.

Signed-off-by: Erez Zilber <erezz@voltaire.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-26 16:35:09 -07:00
Michael S. Tsirkin 0264d88531 IB/mthca: Fix thinko in init_mr_table()
Commit c20e20ab ("IB/mthca: Merge MR and FMR space on 64-bit systems")
swapped the number of MTTs and MPTs when initializing the MR table. As
a result, we get a kernel oops when the number of MTT segments
allocated exceeds 0x20000.

Noted by Troy Benjegerdes <troy@scl.ameslab.gov>, and reproduced by
Dotan Barak <dotanb@mellanox.co.il>.  This fixes
https://bugs.openfabrics.org/show_bug.cgi?id=490

Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-26 15:59:32 -07:00
Steve Wise ed6ee5178e RDMA/cxgb3: Fix resource leak in cxio_hal_init_ctrl_qp()
This was spotted by the Coverity checker (CID 1554).

Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-26 15:54:40 -07:00
Linus Torvalds 703071b5b9 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [SUNGEM]: Fix MAC address setting when interface is up.
  [IPV4] fib_trie: Document locking.
  [NET]: Correct accept(2) recovery after sock_attach_fd()
  [PPP]: Don't leak an sk_buff on interface destruction.
  [NET_SCHED]: Fix ingress locking
  [NET_SCHED]: cls_basic: fix NULL pointer dereference
  [DCCP]: make dccp_write_xmit_timer() static again
  [TG3]: Update version and reldate.
  [TG3]: Exit irq handler during chip reset.
  [TG3]: Eliminate the unused TG3_FLAG_SPLIT_MODE flag.
  [IPV6]: Fix routing round-robin locking.
  [DECNet] fib: Fix out of bound access of dn_fib_props[]
  [IPv4] fib: Fix out of bound access of fib_props[]
  [NET] AX.25 Kconfig and docs updates and fixes
  [NET]: Fix neighbour destructor handling.
  [NET]: Fix fib_rules compatibility breakage
  [SCTP]: Update SCTP Maintainers entry
  [NET]: remove unused header file: drivers/net/wan/lmc/lmc_media.h
2007-03-26 14:51:24 -07:00
Linus Torvalds 6288c33866 Merge branch 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6
* 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6:
  [S390] zcrypt: Fix ap_poll_requests counter in lost requests error path.
  [S390] zcrypt: Fix possible dead lock in AP bus module.
  [S390] cio: Device status validity.
  [S390] kprobes: Align probe address.
  [S390] Fix TCP/UDP pseudo header checksum computation.
  [S390] dasd: Work around gcc bug.
2007-03-26 14:45:56 -07:00
Ruben Vandeginste 09c72ec8ed [SUNGEM]: Fix MAC address setting when interface is up.
This patch implements set_mac_address for the sungem driver.  This
allows changing the mac address of the interface, even when the
interface is up.

Signed-off-by: Ruben Vandeginste <snowbender@gmail.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-26 14:43:49 -07:00
Linus Torvalds 8b66a454bf Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6:
  USB: fix usb-serial/ftdi build warning
  USB: fix usb-serial/generic build warning
  USB: another entry for the quirk list
  USB: remove duplicated device id in airprime driver
  USB: omap_udc: workaround dma_free_coherent() bogosity
  UHCI: Fix problem caused by lack of terminating QH
2007-03-26 14:34:11 -07:00
Linus Torvalds 55ab97569f Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6:
  PCI: Fix warning message in PCIE port driver
  PCI: Stop unhiding the SMBus on Toshiba laptops
  PCI: Fix up PCI power management doc
  pci: set pci=bfsort for PowerEdge R900
2007-03-26 14:33:50 -07:00
David Brownell 3b009c637f USB: fix usb-serial/ftdi build warning
Fix annoying build warning:

drivers/usb/serial/ftdi_sio.c:890: warning: enumeration value `FT232RL' not handled in switch

Also add logic to detect FT232R chips (version 6.00, usb 2.0 full speed),
so that case isn't completely useless.  (NOTE:  FT232RL and FT232RQ are
the same chip in different packages:  L is SSOP, Q is QFN.)

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:17:48 -07:00
David Brownell b46d60fc4b USB: fix usb-serial/generic build warning
Fix annoying build warning when CONFIG_USB_SERIAL_GENERIC is undefined.

  drivers/usb/serial/generic.c:24: warning: `generic_probe' declared `static' but never defined

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:17:48 -07:00
Oliver Neukum 8a61499bc7 USB: another entry for the quirk list
this scanner disconnects upon suspend.

Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:17:48 -07:00
Jon K Hellan 4928245163 USB: remove duplicated device id in airprime driver
Both airprime and option now want to handle vendor ID 0x1410,
device ID 0x1100. Airprime calls it 'ExpressCard34 Qualcomm 3G CDMA'.
Option calls it 'Novatel Merlin XS620/S640'. Patch attached to remove it
from airprime.

From: Jon K Hellan <jon.kare.hellan@uninett.no>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:17:48 -07:00
David Brownell 8a3c1f573c USB: omap_udc: workaround dma_free_coherent() bogosity
Various fixes to omap_udc, noted with some recent testing:

 - Cope with some SMP-induced braindamage in ARM's dma_{alloc,free}_coherent()
   implementation: alloc() can be called with IRQs blocked, but since late
   last year that's no longer true for free().  This resolves really NASTY
   problems with logspamming via WARN_ON(), indicating N-page leaks.

 - Be more correct in handling GET_STATUS request for RECIP_ENDPOINT ... the
   previous code only handled RECIP_INTERFACE, this version should be correct
   except for (sigh) bulk/interrupt endpoints.

 - Provide a better name for the function reporting whether the board has
   vbus sensing wired up.

GET_STATUS requests for endpoint status still acts strangely though, at least
given one flakey host doesn't always ack the first DATA packet, then the packet
that gets retransmitted doesn't have data!

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:17:48 -07:00
Alan Stern e009f1b202 UHCI: Fix problem caused by lack of terminating QH
This patch (as871) fixes a problem introduced by an earlier change.
It turns out that some systems really do need to have a terminating
skeleton QH present whenever FSBR is on.  I don't know any way to tell
which systems do need it and which don't; the easiest answer is to
have it there always.

This fixes the NumLock-hang bug reported by Jiri Slaby.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:17:48 -07:00
Prarit Bhargava bf5b4ba3d9 PCI: Fix warning message in PCIE port driver
PCIE error output should conform to vendor_id:device_id.

Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:13:08 -07:00
Jean Delvare 9208ee8286 PCI: Stop unhiding the SMBus on Toshiba laptops
It was found that the Toshiba laptops with hidden Intel SMBus have SMM
code handling the thermal management which accesses the SMBus. Thus it
is not safe to unhide it and let Linux access it. We have to leave the
SMBus hidden. SMM is a pain, really.

This fixes bugs #6315 and #6395, for good this time.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-03-26 14:13:07 -07:00
Suleiman Souhlal 513daadd15 ide: use correct IDE error recovery
IDE error recovery is using IDLE IMMEDIATE if the drive is busy or has DRQ set.
This violates the ATA spec (can only send IDLE IMMEDIATE when drive is not
busy) and really hoses up some drives (modern drives will not be able to
recover using this error handling).  The correct thing to do is issue a SRST
followed by a SET FEATURES command.  This is what Western Digital recommends
for error recovery and what Western Digital says Windows does.  It also does
not violate the ATA spec as far as I can tell.

Bart:
* port the patch over the current tree
* undo the recalibration code removal
* send SET FEATURES command after checking for good drive status
* don't check whether the current request is of REQ_TYPE_ATA_{CMD,TASK}
  type because we need to send SET FEATURES before handling any requests
* some pre-ATA4 drives require INITIALIZE DEVICE PARAMETERS command before
  other commands (except IDENTIFY) so send SET FEATURES only if there are
  no pending drive->special requests
* update comments and patch description
* any bugs introduced by this patch are mine and not Suleiman's :-)

Signed-off-by: Suleiman Souhlal <suleiman@google.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-03-26 23:03:20 +02:00
Albert Lee 362ebd83ad pdc202xx_new: Enable ATAPI DMA
[ bart: the ressurection of 2 years old patch which slipped thru the cracks
  (thanks to Sergei Shtylyov for finding it) ]

These is the patch to turn on pdc202xx_new for ATAPI DMA.  When testing, it
works fine without the (request_bufflen % 256) workaround as needed in libata.
ide-scsi filters out (pc->request_transfer % 1024) and use PIO, so the pdc202xx
ATAPI DMA problem is avoid.  Both ide-cd and ide-scsi won't hit the ATAPI DMA
problem on pdc202xx_new.

Signed-off-by: Albert Lee <albertcc@tw.ibm.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-03-26 23:03:19 +02:00
Patrick Ringl b43c5f3dbe ide: cosmetic adaption of drivers/ide/Kconfig concerning SATA
Since especially Serial ATA has it's own menu point now, I guess we can
change the description of the deprecated SATA driver as well, since the
new libATA subsystem is not configured through a SCSI low-level driver
anymore, but has it's own menu point.

From: Patrick Ringl <patrick_@freenet.de>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-03-26 23:03:19 +02:00
Bartlomiej Zolnierkiewicz 8799620400 ide: fix locking for manual DMA enable/disable ("hdparm -d")
Since hwif->ide_dma_check and hwif->ide_dma_on never queue any commands
(ide_config_drive_speed() sets transfer mode using polling and has no error
recovery) we are safe with setting hwgroup->busy for the time while DMA
setting for a drive is changed (so it won't race against I/O commands in fly).

I audited briefly all ->ide_dma_check/->ide_dma_on/->tuneproc/->speedproc
implementations and they all look OK wrt to this change.

This patch finally allowed me to close kernel bugzilla bug #8169
(once again thanks to Patrick Horn for reporting the issue & testing patches).

Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-03-26 23:03:19 +02:00
Bartlomiej Zolnierkiewicz f68d9320cd ide: revert "ide: fix drive side 80c cable check, take 2" for now
"ide: fix drive side 80c cable check, take 2" patch from Tejun Heo (commit
fab59375b9) fixed 80c bit test (bit13 of word93)
but we also need to fix master/slave IDENTIFY order (slave device should be
probed first in order to make it release PDIAG- signal) and we should also
check for pre-ATA3 slave devices (which may not release PDIAG- signal).

[ Unfortunately the fact that IDE driver doesn't reset devices itself helps
  only a bit as it seems that some BIOS-es reset ATA devices after programming
  the chipset, some BIOS-es can be set to not probe/configure selected devices,
  there may be no BIOS in case of add-on cards etc. ]

Since we are quite late in the release cycle and the required changes will
affect a lot of systems just revert the fix for now.

[ Please also see libata commit f31f0cc2f0. ]

Thanks goes out to Fernando Mitio Yamada for reporting the problem
and patiently testing patches.

Acked-by: Tejun Heo <htejun@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2007-03-26 23:03:18 +02:00
Ralph Wuerthner e675c0d2bf [S390] zcrypt: Fix ap_poll_requests counter in lost requests error path.
In the unlikely event that an AP device lost requests, don't forget to
update the ap_poll_requests counter too. Same must happen in case an AP
device is removed while there are still outstanding requests.

Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
2007-03-26 20:43:47 +02:00
Ralph Wuerthner c6a4826473 [S390] zcrypt: Fix possible dead lock in AP bus module.
If a AP device is unconfigured __ap_poll_all() will call
device_unregister() in software interrupt context which can cause
dead locks. To fix this the device will be only marked as unconfigured
and the device_unregister() call will be done later by either
ap_scan_bus() or ap_queue_message() in process context.

Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
2007-03-26 20:43:47 +02:00
Cornelia Huck 25c61a1fe8 [S390] cio: Device status validity.
Only accumulate device status field in irb if it is valid.

Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
2007-03-26 20:43:47 +02:00
Peter Oberparleiter 04439694ea [S390] dasd: Work around gcc bug.
gcc incorrectly removes initialization of register 0 in dasd diag
inline assembly. Use different register to work around this compiler
bug.

Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Peter Oberparleiter <peter.oberparleiter@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
2007-03-26 20:43:46 +02:00
G. Liakhovetski 165de5b7f2 [PPP]: Don't leak an sk_buff on interface destruction.
Signed-off-by: G. Liakhovetski <gl@dsa-ac.de>
Acked-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-25 19:04:09 -07:00
Michael Chan 20bd7dd4ca [TG3]: Update version and reldate.
Update version to 3.75.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-25 18:48:09 -07:00
Michael Chan d18edcb212 [TG3]: Exit irq handler during chip reset.
On most tg3 chips, the memory enable bit in the PCI command register
gets cleared during chip reset and must be restored before accessing
PCI registers using memory cycles.  The chip does not generate
interrupt during chip reset, but the irq handler can still be called
because of irq sharing or irqpoll.  Reading a register in the irq
handler can cause a master abort in this scenario and may result in a
crash on some architectures.

Use the TG3_FLAG_CHIP_RESETTING flag to tell the irq handler to exit
without touching any registers.  The checking of the flag is in the
"slow" path of the irq handler and will not affect normal performance.
The msi handler is not shared and therefore does not require checking
the flag.

Thanks to Bernhard Walle <bwalle@suse.de> for reporting the problem.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-25 18:48:08 -07:00
Michael Chan 1c46ae05d9 [TG3]: Eliminate the unused TG3_FLAG_SPLIT_MODE flag.
This flag to support multiple PCIX split completions was never used
because of hardware bugs.  This will make room for a new flag.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-25 18:48:06 -07:00
Alexey Kuznetsov ecbb416939 [NET]: Fix neighbour destructor handling.
->neigh_destructor() is killed (not used), replaced with
->neigh_cleanup(), which is called when neighbor entry goes to dead
state. At this point everything is still valid: neigh->dev,
neigh->parms etc.

The device should guarantee that dead neighbor entries (neigh->dead !=
0) do not get private part initialized, otherwise nobody will cleanup
it.

I think this is enough for ipoib which is the only user of this thing.
Initialization private part of neighbor entries happens in ipib
start_xmit routine, which is not reached when device is down.  But it
would be better to add explicit test for neigh->dead in any case.

Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-25 18:48:01 -07:00
Robert P. J. Day ea3d0d7708 [NET]: remove unused header file: drivers/net/wan/lmc/lmc_media.h
Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Cc: Krzysztof Halasa <khc@pm.waw.pl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-25 18:47:58 -07:00
Michael Krufky f5ae29e284 [PATCH] cx88-dvb: fix nxt200x rf input switching
After dvb tuner refactoring, the pllbuff has been altered such that the pll
address is now stored in buf[0].  Instead of sending buf to set_pll_input,
we should send buf+1.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: Ivan Andrewjeski <ivan@fiero-gt.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-24 16:49:22 -07:00
Ralf Baechle 8fb303c7f1 [MIPS] SB1250: Fix bugs/warnings by creative use of volatile.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-03-24 17:01:50 +00:00
Linus Torvalds cad6a84a39 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6:
  ieee1394: fix oops on "modprobe -r ohci1394" after network class_device conversion
2007-03-23 11:02:45 -07:00
Linus Torvalds 0ab602e5bc Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
  [netdrvr] ewrk3: correct card detection bug
  cxgb3 - fix white spaces in drivers/net/Kconfig
  myri10ge: update driver version to 1.3.0-1.226
  myri10ge: fix management of >4kB allocated pages
  myri10ge: update wcfifo and intr_coal_delay default values
  myri10ge: Serverworks HT2100 provides aligned PCIe completion
  mv643xx_eth: add mv643xx_eth_shutdown function
  SAA9730: Fix large pile of warnings
  Revert "ucc_geth: returns NETDEV_TX_BUSY when BD ring is full"
  cxgb3 - T3B2 pcie config space
  cxgb3 - Fix potential MAC hang
  cxgb3 - Auto-load FW if mismatch detected
  cxgb3 - fix ethtool cmd on multiple queues port
  Fix return code in pci-skeleton.c
  skge: use per-port phy locking
  skge: mask irqs when device down
  skge: deadlock on tx timeout
  [PATCH] airo: Fix an error path memory leak
  [PATCH] bcm43xx: MANUALWLAN fixes
2007-03-23 11:01:41 -07:00
Guido Guenther cee9e8c5cb [PATCH] rivafb: fix initial brightness
This is the rivafb equivalent of 238576e12f.
It fixes rivafb having a default backlight brightness of 0 (no picture at
all) on a PBook 6,1.

Signed-off-by: Guido Guenther <agx@sigxcpu.org>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Acked-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-23 11:01:22 -07:00
Danny Kukawka 6149dd5cfa [PATCH] add Fujitsu Siemens Tablet PC devices to 8250_pnp.c
Adds device ids of two Fujitsu Siemens Tablet PCs to pnp_dev_table

Signed-off-by: Danny Kukawka <dkukawka@suse.de>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-23 11:01:22 -07:00
Thomas Gleixner e585bef815 [PATCH] i386: add command line option "local_apic_timer_c2_ok"
It turned out that it is almost impossible to trust ACPI, BIOS & Co.
regarding the C states. This was the reason to switch the local apic
timer off in C2 state already. OTOH there are sane and well behaving
systems, which get punished by that decision.

Allow the user to confirm that the local apic timer is trustworthy in C2
state. This keeps the default behaviour on the safe side.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-23 10:21:02 -07:00
Linus Torvalds 296d93cd02 Revert "ACPI: Only use IPI on known broken machines (AMD, Dothan/BaniasPentium M)"
This reverts commit 25496caec1, which
broke bootup on at least Ingo's ThinkPad T60.  Need to figure out
exactly what is wrong before we can re-do the logic.

Requested-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Thomas Renninger <trenn@suse.de>
Cc: Len Brown <len.brown@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-23 08:03:47 -07:00
Stefan Richter 7a9eeb2fa1 ieee1394: fix oops on "modprobe -r ohci1394" after network class_device conversion
The networking subsystem has been converted from class_device to device
but ieee1394 hasn't.  This results in a 100% reproducible NULL pointer
dereference if the ohci1394 driver module is unloaded while the eth1394
module is still loaded.
http://lkml.org/lkml/2006/11/16/147
http://lkml.org/lkml/2007/3/14/4

This is a regression in 2.6.21-rc1.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Tested-by: Ismail Dönmez <ismail@pardus.org.tr>
2007-03-23 10:55:25 +01:00
Jeff Garzik 991b5557f7 [netdrvr] ewrk3: correct card detection bug
Arwin Vosselman pointed out:
> The ewrk3-driver doesn't function with 2.6.16-kernels (used 2.6.16.41 for
> my tests). Cards will never be detected due to this bug.
>
> drivers/net/ewrks3.c:
> Line 417 reads:
>
> if (nicsr == (CSR_TXD | CSR_RXD))
>
> that should be:
>
> if (nicsr != (CSR_TXD | CSR_RXD))
>
> Comparison with the same line in v2.4 shows why:
>
> 2.4:
> if (nicsr == (CSR_TXD | CSR_RXD)){
>
> blah, blah
> ==========
> 2.6:
> if (nicsr == (CSR_TXD | CSR_RXD))
>     return -ENXIO;
>
> blah, blah
> ==========
>
> blah,blah will not, but should, be executed in 2.6 with a card being present.
>
> The fix mentioned above solves this bug.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 02:03:29 -04:00
Jeff Garzik 604119a4b2 Merge branch 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into tmp 2007-03-23 01:51:20 -04:00
Divy Le Ray 194c1fbe43 cxgb3 - fix white spaces in drivers/net/Kconfig
Use tabs instead of white spaces for CHELSIO_T3 entry.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:35 -04:00
Brice Goglin 2ea34672f8 myri10ge: update driver version to 1.3.0-1.226
Driver version is now 1.3.0-1.226.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:35 -04:00
Brice Goglin b52a8b7f0a myri10ge: fix management of >4kB allocated pages
Fix management of allocated physical pages when the architecture
page size is not 4kB since the firmware cannot cross 4K boundary.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:35 -04:00
Brice Goglin f761fae1ae myri10ge: update wcfifo and intr_coal_delay default values
Update the default value of 2 module parameters:
* wcfifo disabled
* intr_coal_delay 75us

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:35 -04:00
Brice Goglin aafa70eb56 myri10ge: Serverworks HT2100 provides aligned PCIe completion
[PATCH 1/4] myri10ge: Serverworks HT2100 provides aligned PCIe completion

Use the regular firmware on Serverworks HT2100 PCIe ports since this
chipset provides aligned PCIe completion.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:34 -04:00
Dale Farnsworth d57ab6fdde mv643xx_eth: add mv643xx_eth_shutdown function
mv643xx_eth_shutdown is needed for kexec.

Signed-off-by: Dale Farnsworth <dale@farnsworth.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:34 -04:00
Ralf Baechle 69a43ac0cf SAA9730: Fix large pile of warnings
The SAA9730 driver doesn't quite grok what the difference between an ioport
and memory mapped I/O is.  It just happened to work on the one Linux
system the SAA9730 happens to spend it's misserable existence on.

drivers/net/saa9730.c: In function 'evm_saa9730_enable_lan_int':
drivers/net/saa9730.c:68: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:70: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:72: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'evm_saa9730_disable_lan_int':
drivers/net/saa9730.c:78: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:80: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'evm_saa9730_clear_lan_int':
drivers/net/saa9730.c:85: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'evm_saa9730_block_lan_int':
drivers/net/saa9730.c:91: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'evm_saa9730_unblock_lan_int':
drivers/net/saa9730.c:97: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'show_saa9730_regs':
drivers/net/saa9730.c:150: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_allocate_buffers':
drivers/net/saa9730.c:292: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:295: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:302: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:305: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:312: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_cam_load':
drivers/net/saa9730.c:329: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:332: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_mii_init':
drivers/net/saa9730.c:369: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:395: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:403: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:410: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:432: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_control_init':
drivers/net/saa9730.c:470: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:474: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:478: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:484: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:487: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:490: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:493: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_stop':
drivers/net/saa9730.c:505: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:508: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:510: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_dma_init':
drivers/net/saa9730.c:536: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_start':
drivers/net/saa9730.c:556: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:560: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:564: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:567: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_tx':
drivers/net/saa9730.c:590: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_rx':
drivers/net/saa9730.c:664: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:729: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_write':
drivers/net/saa9730.c:848: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c: In function 'lan_saa9730_set_multicast':
drivers/net/saa9730.c:943: warning: passing argument 2 of 'outl' makes integer from pointer without a cast
drivers/net/saa9730.c:949: warning: passing argument 2 of 'outl' makes integer from pointer without a cast

Fixed by using writel instead of outl.  42 warnings less.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:34 -04:00
Li Yang 6f6881b846 Revert "ucc_geth: returns NETDEV_TX_BUSY when BD ring is full"
This reverts commit 18babd3854.

Michael Barkowski points out that it's wrong, and I agree.  The
patch causes a problem rather than fixes one after another
patch "ucc_geth: Fix BD processing" was applied.  Before that
patch, current packet should be blocked.  However after the patch
current packet is ok and we only need to block next.

Reported-by: Michael Barkowski <michael.barkowski@freescale.com>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:34 -04:00
Divy Le Ray e4d08359ff cxgb3 - T3B2 pcie config space
T3B2 does not lose its pcie config space on reset.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:34 -04:00
Divy Le Ray fc90664e34 cxgb3 - Fix potential MAC hang
Under rare conditions, the MAC might hang while generating a pause frame.
This patch fine tunes the MAC settings to avoid the issue, allows for
periodic MAC state check, and triggers a recovery if hung.

Also fix one MAC statistics counter for the rev board T3B2.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:34 -04:00
Divy Le Ray 2e2839627a cxgb3 - Auto-load FW if mismatch detected
The driver attempts to upgrade the FW if the card has the wrong version.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:33 -04:00
Divy Le Ray 05b97b30b0 cxgb3 - fix ethtool cmd on multiple queues port
Limit ethtool -g/-G to the given port's queues.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:33 -04:00
Anton Blanchard 5c4851ccb6 Fix return code in pci-skeleton.c
We assign the return value of register_netdev to i, but return rc later
on. Fix it.

Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:33 -04:00
Stephen Hemminger 9cbe330f1f skge: use per-port phy locking
Rather than a workqueue and a per-board mutex to control PHY,
use a tasklet and spinlock. Tasklet is lower overhead and works
just as well for this.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:33 -04:00
Stephen Hemminger 4ebabfcb1d skge: mask irqs when device down
Wheen a port on the skge driver is not used, it should
mask off interrupts from theat port.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:33 -04:00
Stephen Hemminger e3a1b99fb6 skge: deadlock on tx timeout
The skge driver will deadlock if gets a transmit timeout
because the netif_tx_lock() is already held.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-23 01:48:33 -04:00
Linus Torvalds 37c70d0d09 Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
  ACPI: IA64: fix %ll build warnings
  ACPI: IA64: fix allnoconfig build
  ACPI: Only use IPI on known broken machines (AMD, Dothan/BaniasPentium M)
  ACPI: ibm-acpi: allow module to load when acpi notifiers can't be set (v2)
  ACPI: parse 2nd MADT by default
  ACPICA: revert "acpi_serialize" changes
  sony-laptop: MAINTAINERS fix entry, add L: and W:
  ACPI: resolve HP nx6125 S3 immediate wakeup regression
  ACPI: Add support to parse 2nd MADT
2007-03-22 19:43:02 -07:00
Adrian Bunk 47ebea8351 [PATCH] drivers/video/s3fb.c: fix a use-before-check
NULL checks should be before the first dereference.

Spotted by the Coverity checker.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Acked-by: Ondrej Zajicek <santiago@crfreenet.org>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-22 19:39:05 -07:00
Linus Torvalds fffda91e2e Merge branch 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6
* 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6:
  i2c/ds1374: Check workqueue creation status
  i2c-i801: Restore the device state before leaving
  i2c-amd8111: Missed cleanup
2007-03-22 19:34:44 -07:00
Linus Torvalds d6e8823e7b Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [NETFILTER]: nat: avoid rerouting packets if only XFRM policy key changed
  [NETFILTER]: nf_conntrack_netlink: add missing dependency on NF_NAT
  [NET]: fix up misplaced inlines.
  [SCTP]: Correctly reset ssthresh when restarting association
  [BRIDGE]: Fix fdb RCU race
  [NET]: Fix fib_rules dump race
  [XFRM]: ipsecv6 needs a space when printing audit record.
  [X25] x25_forward_call(): fix NULL dereferences
  [SCTP]: Reset some transport and association variables on restart
  [SCTP]: Increment error counters on user requested HBs.
  [SCTP]: Clean up stale data during association restart
  [IrDA]: Calling ppp_unregister_channel() from process context
  [IrDA]: irttp_dup spin_lock initialisation
  [IrDA]: Delay needed when uploading firmware chunks
2007-03-22 19:34:09 -07:00
Michael S. Tsirkin 77d8e1efea IB/ipoib: Fix thinko in packet length checks
The packet length checks in ipoib are broken: we add 4 bytes (IPoIB
encapsulation header) when sending a packet, not 20 bytes (hardware
address length) to each packet.  Therefore, if connected mode is
enabled so that the interface MTU is larger than the multicast MTU,
IPoIB may end up trying to send too-long multicast packets.  For
example, multicast is broken if a message of size 2048 bytes is sent
on an interface with UD MTU 2048, because 2048 is bigger than the real
limit of 2044 but the code tests against the wrong limit of 2060.

This patch fixes <https://bugs.openfabrics.org/show_bug.cgi?id=418>,
submitted by Scott Weitzenkamp <sweitzen@cisco.com>.

Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-22 14:40:16 -07:00
Michael S. Tsirkin d04d01b113 IPoIB: Fix use-after-free in path_rec_completion()
The connected mode code added the possibility that an neigh struct
gets freed in the list_for_each_entry() loop in path_rec_completion(),
which causes a use-after-free.  Fix this by changing to the _safe
variant of the list walking macro.

This was spotted by the Coverity checker (CID 1567).

Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-22 14:40:16 -07:00
Joachim Fenkes 73b9e9870f IB/ehca: Make scaling code work without CPU hotplug
eHCA scaling code must not depend on register_cpu_notifier() if
CONFIG_HOTPLUG_CPU is not set, so put all related code into #ifdefs.

Signed-off-by: Joachim Fenkes <fenkes@de.ibm.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-22 14:40:16 -07:00
Steve Wise d601347188 RDMA/cxgb3: Handle build_phys_page_list() failure in iwch_reregister_phys_mem()
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-22 14:40:16 -07:00
Bryan O'Sullivan fae8773b73 IB/ipath: Check return value of lookup_one_len
This fixes kernel.org bug 8003.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-22 14:40:15 -07:00
Sean Hefty e07832b662 IPoIB: Fix race in detaching from mcast group before attaching
There's a race between ipoib_mcast_leave() and ipoib_mcast_join_finish()
where we can try to detach from a multicast group before we've
attached to it.  Fix this by reordering the code in ipoib_mcast_leave
to free the multicast group first, which waits for the multicast
callback thread (which calls ipoib_mcast_join_finish()) to complete
before detaching from the group.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-22 14:32:09 -07:00
Michael S. Tsirkin 60a596dab7 IPoIB/cm: Fix reaping of stale connections
The sense of the time_after_eq() test in ipoib_cm_stale_task() is
reversed so that only non-stale connections are reaped.  Fix this by
changing to time_before_eq().

Noticed by Pradeep Satyanarayana <pradeep@us.ibm.com>.

Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2007-03-22 14:32:09 -07:00
Cyrill V. Gorcunov 0ca9493b4c i2c/ds1374: Check workqueue creation status
Check if workqueue creation failed.  Further usage of NULL pointed
workqueue is not good I guess ;)

Signed-off-by: Cyrill V. Gorcunov <gorcunov@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-03-22 19:49:01 +01:00