OpenSolaris

Printable Version Enter a New Search
Bug ID 6731337
Synopsis sata drivers try to process SYNCH commands in their interrupt handler, deadlocks ensue
State 10-Fix Delivered (Fix available in build)
Category:Subcategory driver:ahci
Keywords ahci | disk_transport | fmd | rtiq_regression | sata
Responsible Engineer Ying Tian
Reported Against snv_94
Duplicate Of
Introduced In solaris_nevada
Commit to Fix snv_100
Fixed In snv_100
Release Fixed solaris_nevada(snv_100) , solaris_10u8(s10u8_01) (Bug ID:2172941)
Related Bugs 6261241 , 6418168 , 6648729 , 6681317 , 6728187
Submit Date 30-July-2008
Last Update Date 16-July-2009
Description
My home server (Intel SS4200) started hanging once I generated an FMA topology for it that included the disk devices.  That caused the fmd disk_transport module to start generating SMART and other SCSI transactions that are emulated by the sata framework.

sata_txlt_rw_completion, and similar, invoked as a result of interrupt processing, can cause sd to submit more commands in the same thread.  Those commands, if intended to be processed synchronously, will end up in the hba's start routine which tends to cv_wait for interrupt processing to finish.  That won't happen since the in-progress interrupt will never be completed.  The machine hangs.

ffffff0001ecbc80 fffffffffbc287b0                0   0 104 ffffff00c57548b0
  PC: resume_from_intr+0xb4    THREAD: thread_create_intr()
  stack pointer for thread ffffff0001ecbc80: ffffff0001ecb3b0
  [ ffffff0001ecb3b0 resume_from_intr+0xb4() ]
    swtch+0x9f()
    cv_timedwait+0xcf()
    ahci`ahci_do_sync_start+0x116()
    ahci`ahci_tran_start+0x178()
    sata`sata_ext_smart_selftest_read_log+0x111()
    sata`sata_build_lsense_page_10+0x264()
    sata`sata_txlt_log_sense+0x17b()
    sata`sata_scsi_start+0x19d()
    scsi`scsi_transport+0xe6()
    sd`sd_start_cmds+0x2f4()
    sd`sd_return_command+0x11d()
    sd`sdintr+0x521()
    sata`sata_txlt_rw_completion+0x214()
    ahci`ahci_intr_set_device_bits+0x2d0()
    ahci`ahci_port_intr+0x152()
    ahci`ahci_intr+0x71()
    av_dispatch_autovect+0x78()
    dispatch_hardint+0x2f()
    switch_sp_and_call+0x13()
Work Around
N/A
Comments
N/A