Commit Graph

73254 Commits (b82d9fdd848abfbe7263a4ecd9bbb55e575100a6)

Author SHA1 Message Date
Anton Altaparmakov ebab89909e NTFS: Fix read regression.
The regression was caused by:
        commit[a32ea1e1f9] Fix read/truncate race

This causes ntfs_readpage() to be called for a zero i_size inode, which
failed when the file was compressed and non-resident.

Thanks a lot to Mike Galbraith for reporting the issue and tracking down
the commit that caused the regression.

Looking into it I found three bugs which the patch fixes.

Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
Tested-by:  Mike Galbraith <efault@gmx.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-03 12:27:21 -07:00
Robert Jennings 3c887e8a1a [SCSI] ibmvscsi: Prevent IO during partner login
By setting the request_limit in send_srp_login to 1 we allowed login
requests to be sent to the server adapter.  If this was not an initial
login, but was a login after a disconnect with the server, other I/O
requests could attempt to be processed before the login occured.  These
I/O requests would fail, sometimes resulting in filesystems getting
marked read-only.

To address this we can set the request_limit to 0 while doing the login
and add an exception where login requests, along with task management
events, are always passed to the server.

There is a case where the request_limit had already reached 0 would result
in all events being sent rather than returning SCSI_MLQUEUE_HOST_BUSY; this
has also been fixed by this patch.

Signed-off-by: Robert Jennings <rcj@linux.vnet.ibm.com>
Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2007-11-03 12:10:36 -05:00
James Smart 7e2b19fbc7 [SCSI] lpfc : Correct queue tag handling
This patch corrects the lpfc tag handling issue identified by Hannes Reinecke
http://marc.info/?l=linux-scsi@m=119270235628850&w=2

The basis for this patch originated from Hajime Kai. Thank You Hajime.

Signed-off-by: hajime-kai@soft.fujitsu.com
Signed-off-by: James Smart <James.Smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2007-11-03 12:09:29 -05:00
James Bottomley c4e1608ef4 [SCSI] Update MAINTAINER email address and trees
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2007-11-03 08:40:30 -05:00
Tejun Heo 5270222f96 libata: don't configure downstream links faster than the upstream link
There's nothing to be gained by configuring downstream links faster
than the upstream link and such configurations cause problems on
certain PMPs.  Limit downstream link speed by the upstream link speed.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:47:27 -04:00
Tejun Heo db64bcf387 libata: request PHY speed configuration on SControl access failure
In sata_set_spd_needed(), if SControl read failed, it returned 0 and
skipped PHY speed configuration.  However, if SControl access fails,
it's far more logical to request PHY speed configuration.  Reverse the
logic.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:47:27 -04:00
Tejun Heo dfcc173d71 libata: consider errors not associated with commands for speed down
libata EH used to ignore errors not associated with commands when
determining whether speed down is necessary or not.  This leads to the
following problems.

* Errors not associated with commands can occur indefinitely without
  libata EH taking corrective actions.

* Upstream link errors don't trigger speed down when PMP is attached
  to it and commands issued to downstream device trigger errors on the
  upstream link.

This patch makes ata_eh_link_autopsy() consider errors not associated
with command for speed down.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:47:26 -04:00
Tejun Heo 08cf69d005 libata: more robust reset failure handling
Reset failure is a critical error.  It results in disabling the link
requiring user intervention to re-enable it.  Make reset failure
handling more robust such that libata EH doesn't give up too early.

* Temporary glitches during hardreset may lead to classification
  failure when there's no softreset available.  Retry instead of
  giving up.

* Initial softreset or follow up softreset may fail classification.
  Move classification error handling block out of followup softreset
  block such that both cases are handled and retry instead of giving
  up.  Also, on the last try, give ATA class a blind shot.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:54 -04:00
Tejun Heo 416dc9ed20 libata: cosmetic clean up / reorganization of ata_eh_reset()
Clean up and reorganize ata_eh_reset() to ease further changes.

* Cache ARRAY_SIZE(ata_eh_reset_timeouts) in @max_tries.
* Cache link->flags in @lflags.
* Move failure handling block to the end of the function and unnest
  both success and failure handling blocks.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:54 -04:00
Tejun Heo cd955463bb libata: fix timing computation in ata_eh_reset()
As jiffies changes asynchronously, it needs to be cached if unchanging
timestamp is needed.  The code in ata_eh_reset() intended to do that
with @now but never actually did it.  Fix it.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:54 -04:00
Tony Battersby f8d8e5799b libata: increase 128 KB / cmd limit for ATAPI tape drives
Commands sent to ATAPI tape drives via the SCSI generic (sg) driver are
limited in the amount of data that they can transfer by the max_sectors
value.  The max_sectors value is currently calculated according to the
command set for disk drives, which doesn't apply to tape drives.  The
default max_sectors value of 256 limits ATAPI tape drive commands to
128 KB.  This patch against 2.6.24-rc1 increases the max_sectors value
for tape drives to 65535, which permits tape drive commands to transfer
just under 32 MB.

Tested with a SuperMicro PDSME motherboard, AHCI, and a Sony SDX-570V
SATA tape drive.

Note that some of the chipset drivers also set their own max_sectors
value, which may override the value set in libata-core.  I don't have
any of these chipsets to test, so I didn't go messing with them.  Also,
ATAPI devices other than tape drives may benefit from similar changes,
but I have only tape drives and disk drives to test.

Signed-off-by: Tony Battersby <tonyb@cybernetics.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:54 -04:00
Mikael Pettersson 03116d67e0 sata_promise: fix endianess bug in ASIC PRD bug workaround
The original workaround for the Promise ASIC PRD bug
contained an endianess bug which I failed to detect:
the adjustment of the last PRD entry's length field
applied host arithmetic to little-endian data, which
is incorrect on big-endian machines.

We have the length available in host-endian format, so
do the adjustment on host-endian data and then convert
and store it in the PRD entry's little-endian data field.

Thanks to an anonymous reviewer for detecting this bug.

Signed-off-by: Mikael Pettersson <mikpe@it.uu.se>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:54 -04:00
Stephen Hemminger 48166fd9b0 libata: fix docbook
Fix docbook format in the comments.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:53 -04:00
Adrian Bunk a2d6ed149c make ata_scsi_lpm_get() static
ata_scsi_lpm_get() can become static.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:29 -04:00
Stephen Rothwell 1992a5ede1 libata: suppress two warnings
drivers/ata/libata-core.c:768: warning: 'ata_lpm_enable' defined but not used
drivers/ata/libata-core.c:784: warning: 'ata_lpm_disable' defined but not used

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:29 -04:00
ashish kalra aa91c72566 ata/sata_fsl: Remove ata_scsi_suspend/resume callbacks
Signed-off-by: ashish kalra <ashish.kalra@freescale.com>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:29 -04:00
ashish kalra 1f0e4175ae ata/sata_fsl: Remove sending LOG EXT command in sata_fsl_softreset()
Signed-off-by: ashish kalra <ashish.kalra@freescale.com>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:29 -04:00
ashish kalra e7eac96e8f ata/sata_fsl: Move MPC8315DS link speed limit workaround to specific ifdef
Signed-off-by: ashish kalra <ashish.kalra@freescale.com>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:28 -04:00
Li Yang 520d3a1a8c ata/sata_fsl: cleanup style problem
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:28 -04:00
Jeff Garzik 066ce4db07 ata/sata_fsl: remove unneeded sata_fsl_hardreset()
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:28 -04:00
Jeff Garzik 25ce945a8e ata/sata_fsl: remove unneeded on-stack copy of FIS
Remove unneeded on-stack copy of FIS
in sata_fsl_cache_taskfile_from_d2h_fis().

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:28 -04:00
Jeff Garzik 2a52e8d4ea ata/sata_fsl: cleanup needless casts to/from void __iomem *
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:28 -04:00
Jeff Garzik 9465d53248 ata/sata_fsl: Remove unnecessary SCR cases
SCRs in the driver map to the standard values found in include/linux/ata.h,
so no need for individual scr_read/scr_write case statements duplicating
the natural value.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:28 -04:00
Li Yang a2962dd096 ata/sata_fsl: Kill ata_sg_is_last()
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:27 -04:00
Li Yang 79b3edc97e ata/sata_fsl: save irq in private data for irq unmapping
Powerpc uses virtual irq which has to be unmapped.

Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:27 -04:00
Li Yang 27c96eaaba ata/sata_fsl: Remove deprecated hooks
Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:27 -04:00
Li Yang 1bf617b712 ata/sata_fsl: Update for ata_link introduction
Update the driver to use the newly added ata_link structure.

Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-11-03 08:46:27 -04:00
Ralf Baechle 74521c28e5 Use i8253.c lock for PC speaker on MIPS, too.
The Jazz machines have to use the PIT timer for dyntick and highresolution
kernels.  This may break because currently just like i386 used to do MIPS
uses two separate spinlocks in the actual PIT code and the PC speaker
code.  So switch to do it the same that x86 currently does PIT locking.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-02 19:39:18 -07:00
Linus Torvalds a89b7717a8 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: linux-input mailing list moved to vger.kernel.org
  Input: inport, logibm - use KERN_INFO when reporting missing mouse
  Input: appletouch - idle reset logic broke older Fountains
  Input: hp_sdc.c - fix section mismatch
  Input: appletouch - add Johannes Berg as maintainer
  Input: Add Euro and Dollar key codes
  Input: xpad - add more USB IDs
2007-11-02 19:37:41 -07:00
Linus Torvalds 29dd5a7733 Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: (25 commits)
  [MIPS] Jazz: disable PIT; cleanup R4030 clockevent
  [MIPS] Bigsur supports highmem.
  [MIPS] mtx-1: Enable -Werror.
  [MIPS] mtx-1: Remove unused mtx1_sys_btn.
  [MIPS] Pb1200: Enable -Werror.
  [MIPS] Fix and cleanup the MIPS part of the (ab)use of CLOCK_TICK_RATE.
  [MIPS] SNI: register a02r clockevent; don't use PIT timer
  [MIPS] i8253.h: Remove all i8259 related definitions.
  [MIPS] i8253: Cleanup.
  [MIPS] Cobalt: Fix IRQ comment; the Cobalt kernel uses CP0 counter now.
  [MIPS] Pb1200: Fix warning.
  [MIPS] Pb1200: Fix warning.
  [MIPS] IP27: Fix build error.
  [MIPS] Excite: Fix build error.
  [MIPS] Sibyte: Split and move clock code.
  [MIPS] Sibyte: Fixes for oneshot timer mode.
  [MIPS] Sibyte: Remove blank line.
  [MIPS] Swarm: Fix build failure
  [MIPS] time: Code cleanups
  [MIPS] time: Remove now unused local_timer_interrupt.
  ...
2007-11-02 19:37:26 -07:00
Linus Torvalds 71527bf833 Merge git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog
* git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog:
  [WATCHDOG] iTCO_wdt.c ICH8 pci-device-id's
  [WATCHDOG] iTCO_wdt.c init & exit fixes
  [WATCHDOG] iTCO_wdt.c pci_device_id table clean-up
  [WATCHDOG] spin_lock_init() fixes
  [WATCHDOG] Unlock in iTCO_wdt_start when reboot is disabled
  [WATCHDOG] Add necessary braces to if (...) \n #if... cases
  [WATCHDOG] trivial fix two returns in void functions
2007-11-02 19:36:26 -07:00
Wim Van Sebroeck acf603513e [WATCHDOG] iTCO_wdt.c ICH8 pci-device-id's
Add the pci-device-id's for the ICH8M and the ICH8M-E chipsets.

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2007-11-02 22:25:43 +00:00
Wim Van Sebroeck 08113e39df [WATCHDOG] iTCO_wdt.c init & exit fixes
Mark init and exit procedures as __devinit & _-devexit.

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2007-11-02 22:25:35 +00:00
Wim Van Sebroeck c87b639a2a [WATCHDOG] iTCO_wdt.c pci_device_id table clean-up
Make the pci_device_id table more readable.

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
2007-11-02 22:25:21 +00:00
Alexey Dobriyan c7dfd0cca3 [WATCHDOG] spin_lock_init() fixes
Some watchdog drivers initialize global spinlocks in module's init function
which is tolerable, but some do it in PCI probe function.  So, switch to
static initialization to fix theoretical bugs and, more importantly, stop
giving people bad examples.

Signed-off-by: Alexey Dobriyan <adobriyan@sw.ru>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2007-11-02 19:09:07 +00:00
Thomas Bogendoerfer 3be51f70e1 [MIPS] Jazz: disable PIT; cleanup R4030 clockevent
Fix ISA irq acknowledge.
Make r4030 clockevent code look like other mips clockevent code.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:49 +00:00
Ralf Baechle 651194f820 [MIPS] Bigsur supports highmem.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:49 +00:00
Ralf Baechle 9603a23d3b [MIPS] mtx-1: Enable -Werror.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:49 +00:00
Ralf Baechle e7c9d6b927 [MIPS] mtx-1: Remove unused mtx1_sys_btn.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:49 +00:00
Ralf Baechle ae11e3214b [MIPS] Pb1200: Enable -Werror.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:48 +00:00
Ralf Baechle 72fc19ff51 [MIPS] Fix and cleanup the MIPS part of the (ab)use of CLOCK_TICK_RATE.
This is the clock rate of the i8253 PIT.  A MIPS system may not have
a PIT by the symbol is used all over the kernel including some APIs.
So keeping it defined to the number for the PIT is the only sane thing
for now.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:48 +00:00
Thomas Bogendoerfer c9294022af [MIPS] SNI: register a02r clockevent; don't use PIT timer
Register A20R clockevent.
Remove PIT timer setup because it doesn't work

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:48 +00:00
Ralf Baechle f6a8cc31aa [MIPS] i8253.h: Remove all i8259 related definitions.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:48 +00:00
Ralf Baechle dd3db6eb0e [MIPS] i8253: Cleanup.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:48 +00:00
Yoichi Yuasa 9aa4cc11b2 [MIPS] Cobalt: Fix IRQ comment; the Cobalt kernel uses CP0 counter now.
Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:48 +00:00
Ralf Baechle db0c19e1a6 [MIPS] Pb1200: Fix warning.
arch/mips/au1000/pb1200/irqmap.c:101: warning: ignoring return value of 'request_irq', declared with attribute warn_unused_result

And while at it a few coding style cleanups.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:48 +00:00
Ralf Baechle f5cd9f14e2 [MIPS] Pb1200: Fix warning.
arch/mips/au1000/pb1200/board_setup.c:71: warning: unused variable 'pin_func'

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:47 +00:00
Ralf Baechle c8925297e8 [MIPS] IP27: Fix build error.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:47 +00:00
Ralf Baechle 07f6169cff [MIPS] Excite: Fix build error.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:47 +00:00
Ralf Baechle 217dd11e9d [MIPS] Sibyte: Split and move clock code.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-11-02 16:13:47 +00:00