27 Jul, 2008
1 commit
-
This patch frees the luntbl dma area in sym_hcb_free if allocated.
Since the luntbl is part of a larger dma coherent area not freeing the
luntbl kept a 64k dma coherent area previous allocated through
dma_alloc_coherent allocated. This prevented a DLPAR remove IO
operation from completing successfully.Signed-off-by: Mike Anderson
Cc: Matthew Wilcox
Signed-off-by: James Bottomley
12 Jul, 2008
1 commit
-
The sym53c8xx driver, for some reason, seems to mostly re-implement
linux/list.h with added bogosity. The main one is it's implementation
of sym_que_entry which spits warnings with recent gcc's on some
64 bits architectures.Signed-off-by: Benjamin Herrenschmidt
Signed-off-by: James Bottomley
29 Apr, 2008
1 commit
-
drivers/scsi/aic7xxx/aic7770_osm.c:53:58: warning: Using plain integer as NULL pointer
drivers/scsi/aic7xxx/aic7xxx_osm_pci.c:355:47: warning: Using plain integer as NULL pointer
drivers/scsi/aic7xxx/aic7xxx_osm_pci.c:372:55: warning: Using plain integer as NULL pointer
drivers/scsi/aha152x.c:997:28: warning: Using plain integer as NULL pointer
drivers/scsi/aha152x.c:1003:28: warning: Using plain integer as NULL pointer
drivers/scsi/aha152x.c:1165:46: warning: Using plain integer as NULL pointer
drivers/scsi/fdomain.c:1446:40: warning: Using plain integer as NULL pointer
drivers/scsi/sym53c8xx_2/sym_hipd.c:1650:51: warning: Using plain integer as NULL pointer
drivers/scsi/sym53c8xx_2/sym_hipd.c:3171:42: warning: Using plain integer as NULL pointer
drivers/scsi/sym53c8xx_2/sym_hipd.c:5732:52: warning: Using plain integer as NULL pointer
drivers/scsi/ncr53c8xx.c:8189:31: warning: Using plain integer as NULL pointer
drivers/scsi/ncr53c8xx.c:8225:34: warning: Using plain integer as NULL pointer
drivers/scsi/dpt_i2o.c:156:32: warning: Using plain integer as NULL pointer
drivers/scsi/ultrastor.c:954:42: warning: Using plain integer as NULL pointer
drivers/scsi/ultrastor.c:1104:18: warning: Using plain integer as NULL pointerSigned-off-by: Harvey Harrison
Signed-off-by: Linus Torvalds
08 Feb, 2008
1 commit
-
This patch fixes the calculation of the data transfer residual for the
case of a command that is supposed to transfer an odd number of bytes on
a wide bus but transfers nothing instead.Signed-off-by: Tony Battersby
Cc: Matthew Wilcox
Signed-off-by: James Bottomley
31 Jan, 2008
2 commits
-
With the sg table code, every SCSI driver is now either chain capable
or broken (or has sg_tablesize set so chaining is never activated), so
there's no need to have a check in the host template.Also tidy up the code by moving the scatterlist size defines into the
SCSI includes and permit the last entry of the scatterlist pools not
to be a power of two.
Signed-off-by: James Bottomley -
On a big powerpc box I got the following oops with 2.6.24-git2:
sym0: rev 0x1 at pci 0000:d0:01.0 irq 215
sym0: No NVRAM, ID 7, Fast-80, LVD, parity checking
sym0: SCSI BUS has been reset.
scsi0 : sym-2.2.3
target0:0:8: FAST-40 WIDE SCSI 80.0 MB/s ST (25 ns, offset 31)
scsi 0:0:8:0: Direct-Access IBM ST318305LC C509 PQ: 0
ANSI: 3
target0:0:8: tagged command queuing enabled, command queue depth 16.
target0:0:8: Beginning Domain Validation
target0:0:8: asynchronous
target0:0:8: wide asynchronous
target0:0:8: FAST-80 WIDE SCSI 160.0 MB/s DT (12.5 ns, offset 31)
target0:0:8: FAST-80 WIDE SCSI 160.0 MB/s DT (12.5 ns, offset 31)
Unable to handle kernel paging request for data at address 0x00000000
Faulting instruction address: 0xc000000000038460
cpu 0x25: Vector: 300 (Data Access) at [c00000000f567840]
pc: c000000000038460: .memcpy+0x60/0x280
lr: d000000000050280: .sym_set_cam_result_error+0xfc/0x1e0 [sym53c8xx]
sp: c00000000f567ac0
msr: 8000000000009032
dar: 0
dsisr: 42000000
current = 0xc000006d1e0af0a0
paca = 0xc0000000004afc00
pid = 0, comm = swapper
enter ? for help
[link register ] d000000000050280
.sym_set_cam_result_error+0xfc/0x1e0 [sym53c8xx]
[c00000000f567ac0] c00000000f567b80 (unreliable)
[c00000000f567b80] d0000000000552b8 .sym_complete_error+0x12c/0x1bc [sym53c8xx]
[c00000000f567c20] d0000000000561a4 .sym_int_sir+0xaa4/0x1718 [sym53c8xx]
[c00000000f567d00] d000000000057e8c .sym_interrupt+0x4e4/0x6ec [sym53c8xx]
[c00000000f567dc0] d00000000004fdf4 .sym53c8xx_intr+0x6c/0xdc [sym53c8xx]
[c00000000f567e50] c0000000000a83e0 .handle_IRQ_event+0x7c/0xec
[c00000000f567ef0] c0000000000aa344 .handle_fasteoi_irq+0x130/0x1f0
[c00000000f567f90] c00000000002a538 .call_handle_irq+0x1c/0x2c
[c000004d5e0b3a90] c00000000000c320 .do_IRQ+0x108/0x1d0
[c000004d5e0b3b20] c000000000004790 hardware_interrupt_entry+0x18/0x1cThe memset() in sym_set_cam_result_error() would appear to be trashing
the scsi_cmnd struct instead of clearing sense_buffer.Signed-off-by: Nathan Lynch
Signed-off-by: James Bottomley
24 Jan, 2008
2 commits
-
This replaces sizeof sense_buffer with SCSI_SENSE_BUFFERSIZE in
several LLDs. It's a preparation for the future changes to remove
sense_buffer array in scsi_cmnd structure.Signed-off-by: FUJITA Tomonori
Signed-off-by: James Bottomley -
This patch fixes two bugs pointed by James Bottomley:
1. the if (!sym_data->io_reset). That variable is only ever filled
by a stack based completion. If we find it non empty it means
this code has been entered twice and we have a severe problem,
so that should just become a BUG_ON(sym_data->io_reset).
2. sym_data->io_reset should be set to NULL before the routine is
exited otherwise the PCI recovery code could end up completing
what will be a bogus pointer into the stack.Big thanks to James Bottomley for help with the patch.
Signed-off-by: Krzysztof Helt
Signed-off-by: James Bottomley
12 Jan, 2008
1 commit
-
Fix section mismatch warning:
WARNING: vmlinux.o(.text+0x1ff3a2): Section mismatch: reference to .exit.text:sym2_remove (between 'sym2_io_error_detected' and 'sym_xpt_done')
Signed-off-by: Randy Dunlap
Signed-off-by: James Bottomley
19 Dec, 2007
2 commits
-
The patch described by the following excerpt from ChangeLog-2.6.24-rc1
eventually causes a "irq X: nobody cared" error after a while:commit 99c9e0a1d6cfe1ba1169a7a81435ee85bc00e4a1
Author: Matthew Wilcox
Date: Fri Oct 5 15:55:12 2007 -0400[SCSI] sym53c8xx: Make interrupt handler capable of returning IRQ_NONE
After this happens, the kernel disables the IRQ, causing the SCSI card
to stop working until the next reboot. The problem is caused by the
interrupt handler returning IRQ_NONE instead of IRQ_HANDLED after
handling an interrupt-on-the-fly (INTF) condition. The following patch
fixes the problem.Signed-off-by: Tony Battersby
Acked-by: Matthew Wilcox
Signed-off-by: James Bottomley -
The following commit changed the pointer passed to request_irq(), but
failed to change the pointer passed to free_irq():commit 99c9e0a1d6cfe1ba1169a7a81435ee85bc00e4a1
Author: Matthew Wilcox
Date: Fri Oct 5 15:55:12 2007 -0400[SCSI] sym53c8xx: Make interrupt handler capable of returning IRQ_NONE
...
The result is that free_irq() doesn't actually take any action. This
patch fixes it.Signed-off-by: Tony Battersby
Acked-by: Christoph Hellwig
Signed-off-by: James Bottomley
24 Oct, 2007
18 commits
-
* master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (39 commits)
[SCSI] qla2xxx: Update version number to 8.02.00-k5.
[SCSI] qla2xxx: Correct display of ISP serial-number.
[SCSI] qla2xxx: Correct residual-count handling discrepancies during UNDERRUN handling.
[SCSI] qla2xxx: Make driver (mostly) legacy I/O port free.
[SCSI] qla2xxx: Fix issue where final flash-segment updates were falling into the slow-path write handler.
[SCSI] qla2xxx: Handle unaligned sector writes during NVRAM/VPD updates.
[SCSI] qla2xxx: Defer explicit interrupt-polling processing to init-time scenarios.
[SCSI] qla2xxx: Resync with latest HBA SSID specification -- 2.2u.
[SCSI] sym53c8xx: Remove sym_xpt_async_sent_bdr
[SCSI] sym53c8xx: Remove pci_dev pointer from sym_shcb
[SCSI] sym53c8xx: Make interrupt handler capable of returning IRQ_NONE
[SCSI] sym53c8xx: Get rid of IRQ_FMT and IRQ_PRM
[SCSI] sym53c8xx: Use scmd_printk where appropriate
[SCSI] sym53c8xx: Simplify DAC DMA handling
[SCSI] sym53c8xx: Remove tag_ctrl module parameter
[SCSI] sym53c8xx: Remove io_ws, mmio_ws and ram_ws elements
[SCSI] sym53c8xx: Remove ->device_id
[SCSI] sym53c8xx: Use pdev->revision
[SCSI] sym53c8xx: PCI Error Recovery support
[SCSI] sym53c8xx: Stop overriding scsi_done
... -
This function just printed a message to the user; move the print to its
only caller, and turn it into an starget_printk.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
This structure is accessed by the device; the fewer Linux things in it,
the better. Using the pci_dev pointer from the hostdata requires a lot
of changes:- Pass Scsi_Host to a lot of routines which currently take a sym_hcb.
- Set the Scsi_Host as the pci drvdata (instead of the sym_hcb)Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Make sym_interrupt return an irqreturn_t instead of void, and take a
Scsi_Host instead of a sym_hcb. Pass the Scsi_Host to the interrupt
handler instead of the sym_hcb. Rename the host_data to sym_data.
Keep a pci_dev pointer in the sym_data. Rename the Scsi_Host from
instance to shost.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
These macros aren't needed any more. They used to be used for SPARC.
Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
If we have a scsi_cmnd, it gives the user more information than the
sym_name, and maybe the target.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
By introducing the use_dac(), set_dac() and DMA_DAC_MASK macros, we can
eliminate a lot of ifdefs from the code. We now rely on the compiler to
optimise away a few things that we'd formerly relied on the preprocessor
to do. This makes sym_setup_bus_dma_mask() small enough to inline into
its only caller.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
With sysfs making these options tunable at runtime, there's no
justification for keeping this horrendously complex specification
string around.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
These struct elements record info that is never needed
Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Following the same path as ->revision_id, remove ->device_id
Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Auke missed the sym2 driver in his initial sweep.
Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
This patch adds the PCI error recovery callbacks to the Symbios SCSI device
driver. It includes support for First Failure Data Capture.Signed-off-by: Linas Vepstas
Assorted changes to initial patches, including returning IRQ_NONE from the
interrupt handler if the device is offline and re-using the eh_done completion
in the scsi error handler.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Instead of telling the reset routine that the command completed from
sym_eh_done, do it from sym_xpt_done. The 'to_do' element of the ucmd
is redundant -- it serves only to tell whether eh_done is valid or not,
and we can tell this by checking to see if it's NULL.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Interrupts can't be re-entered, so it's sufficient to call spin_lock, not
spin_lock_irqsave().Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
The midlayer won't scan the host ID, so we don't need to check.
This is the only caller of sym_xpt_done2, so remove that too.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Before all commands used sg, data_mapping and data_mapped were used to
distinguish whether the command had used map_single or map_sg. Now all
commands are sg, so we can delete data_mapping, data_mapped and the
wrapper functions __unmap_scsi_data, __map_scsi_sg_data, unmap_scsi_data
and map_scsi_sg_data.Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Don't cache a private copy of the interrupt number
Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley -
Prevent DMA transfers from crossing the 16MB limit for early 53c896 chips.
Signed-off-by: Matthew Wilcox
Signed-off-by: James Bottomley
20 Oct, 2007
1 commit
-
From: Jean Delvare
Signed-off-by: Jean Delvare
Signed-off-by: Adrian Bunk
16 Oct, 2007
1 commit
-
This option is true if a low-level driver can support sg
chaining. This will be removed eventually when all the drivers are
converted to support sg chaining. q->max_phys_segments is set to
SCSI_MAX_SG_SEGMENTS if false.Signed-off-by: FUJITA Tomonori
Signed-off-by: Jens Axboe
25 Jul, 2007
1 commit
-
Apropos this thread
http://marc.theaimsgroup.com/?l=linux-scsi&m=115591706804045&w=2
which led to this patch
http://www.kernel.org/git/?p=linux/kernel/git/jejb/scsi-rc-fixes-2.6.git;a=commit;h=b2b3c121076961333977f485f0d54c22121df920
We also need to fix sym53c8xx only to bind to the PCI ID if it is of
device class PCI_CLASS_STORAGE_SCSI (otherwise it will be the cpqarray
RAID device).Signed-off-by: Chip Coldwell
Cc: Matthew Wilcox
Signed-off-by: Andrew Morton
Signed-off-by: James Bottomley
15 Jul, 2007
1 commit
-
- remove the unnecessary map_single path.
- convert to use the new accessors for the sg lists and the
parameters.Jens Axboe did the for_each_sg cleanup.
Signed-off-by: FUJITA Tomonori
Cc: Matthew Wilcox
Signed-off-by: James Bottomley
18 Feb, 2007
1 commit
-
Fix the various misspellings of "agressive", as well as a couple
other things on the same lines while we're there.Signed-off-by: Robert P. J. Day
Signed-off-by: Adrian Bunk
14 Dec, 2006
1 commit
-
All kcalloc() calls of the form "kcalloc(1,...)" are converted to the
equivalent kzalloc() calls, and a few kcalloc() calls with the incorrect
ordering of the first two arguments are fixed.Signed-off-by: Robert P. J. Day
Cc: Jeff Garzik
Cc: Alan Cox
Cc: Dominik Brodowski
Cc: Adam Belay
Cc: James Bottomley
Cc: Greg KH
Cc: Mark Fasheh
Cc: Trond Myklebust
Cc: Neil Brown
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
05 Oct, 2006
1 commit
-
Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
of passing regs around manually through all ~1800 interrupt handlers in the
Linux kernel.The regs pointer is used in few places, but it potentially costs both stack
space and code to pass it around. On the FRV arch, removing the regs parameter
from all the genirq function results in a 20% speed up of the IRQ exit path
(ie: from leaving timer_interrupt() to leaving do_IRQ()).Where appropriate, an arch may override the generic storage facility and do
something different with the variable. On FRV, for instance, the address is
maintained in GR28 at all times inside the kernel as part of general exception
handling.Having looked over the code, it appears that the parameter may be handed down
through up to twenty or so layers of functions. Consider a USB character
device attached to a USB hub, attached to a USB controller that posts its
interrupts through a cascaded auxiliary interrupt controller. A character
device driver may want to pass regs to the sysrq handler through the input
layer which adds another few layers of parameter passing.I've build this code with allyesconfig for x86_64 and i386. I've runtested the
main part of the code on FRV and i386, though I can't test most of the drivers.
I've also done partial conversion for powerpc and MIPS - these at least compile
with minimal configurations.This will affect all archs. Mostly the changes should be relatively easy.
Take do_IRQ(), store the regs pointer at the beginning, saving the old one:struct pt_regs *old_regs = set_irq_regs(regs);
And put the old one back at the end:
set_irq_regs(old_regs);
Don't pass regs through to generic_handle_irq() or __do_IRQ().
In timer_interrupt(), this sort of change will be necessary:
- update_process_times(user_mode(regs));
- profile_tick(CPU_PROFILING, regs);
+ update_process_times(user_mode(get_irq_regs()));
+ profile_tick(CPU_PROFILING);I'd like to move update_process_times()'s use of get_irq_regs() into itself,
except that i386, alone of the archs, uses something other than user_mode().Some notes on the interrupt handling in the drivers:
(*) input_dev() is now gone entirely. The regs pointer is no longer stored in
the input_dev struct.(*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does
something different depending on whether it's been supplied with a regs
pointer or not.(*) Various IRQ handler function pointers have been moved to type
irq_handler_t.Signed-Off-By: David Howells
(cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
29 Jul, 2006
1 commit
-
The follow patch fixes a problem for Matt Taggart.
The Compaq system he had (dl380?) has a SmartArray device that exposes
the 53c1510 device in both RAID and "normal" modes. The difference
is in RAID mode, the smart array driver (IIRC) should claim the
device instead of sym2 driver. Patch below prevents sym2 from
claiming the device when the RAID "daughter board" is attached.Signed-off-by: Grant Grundler
Signed-off-by: James Bottomley
03 Jul, 2006
1 commit
-
Signed-off-by: Thomas Gleixner
Cc: Ingo Molnar
Cc: "David S. Miller"
Cc: Benjamin Herrenschmidt
Cc: James Bottomley
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
01 Jul, 2006
1 commit
-
Signed-off-by: Jörn Engel
Signed-off-by: Adrian Bunk
22 Jun, 2006
1 commit
-
* master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (85 commits)
[SCSI] 53c700: remove reliance on deprecated cmnd fields
[SCSI] hptiop: don't use cmnd->bufflen
[SCSI] hptiop: HighPoint RocketRAID 3xxx controller driver
[SCSI] aacraid: small misc. cleanups
[SCSI] aacraid: Update supported product information
[SCSI] aacraid: Fix return code interpretation
[SCSI] scsi_transport_sas: fix panic in sas_free_rphy
[SCSI] remove RQ_SCSI_* flags
[SCSI] remove scsi_request infrastructure
[SCSI] mptfusion: change driver revision to 3.03.10
[SCSI] mptfc: abort of board reset leaves port dead requiring reboot
[SCSI] mptfc: fix fibre channel infinite request/response loop
[SCSI] mptfc: set fibre channel fw target missing timers to one second
[SCSI] mptfusion: move fc event/reset handling to mptfc
[SCSI] spi transport: don't allow dt to be set on SE or HVD buses
[SCSI] aic7xxx: expose the bus setting to sysfs
[SCSI] scsi: remove Documentation/scsi/cpqfc.txt
[SCSI] drivers/scsi: Use ARRAY_SIZE macro
[SCSI] Remove last page_address from dc395x.c
[SCSI] hptiop: HighPoint RocketRAID 3xxx controller driver
...Fixed up conflicts in drivers/message/fusion/mptbase.c manually (due to
the sparc interrupt cleanups)