From owner-cvs-src-old@FreeBSD.ORG Fri Jul 29 20:30:44 2011 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8A949106564A for ; Fri, 29 Jul 2011 20:30:44 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 5FB668FC20 for ; Fri, 29 Jul 2011 20:30:44 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.4/8.14.4) with ESMTP id p6TKUibX090802 for ; Fri, 29 Jul 2011 20:30:44 GMT (envelope-from mav@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.4/8.14.4/Submit) id p6TKUiE2090801 for cvs-src-old@freebsd.org; Fri, 29 Jul 2011 20:30:44 GMT (envelope-from mav@repoman.freebsd.org) Message-Id: <201107292030.p6TKUiE2090801@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to mav@repoman.freebsd.org using -f From: Alexander Motin Date: Fri, 29 Jul 2011 20:30:28 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/cam cam_periph.c X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Jul 2011 20:30:44 -0000 mav 2011-07-29 20:30:28 UTC FreeBSD src repository Modified files: sys/cam cam_periph.c Log: SVN rev 224496 on 2011-07-29 20:30:28Z by mav In some cases failed SATA disks may report their presence, but don't respond to any commands. I've found that because of multiple command retries, each of which cause 30s timeout, bus reset and another retry or requeue for many commands, it may take ages to eventually drop the failed device. The odd thing is that those retries continue even after XPT considered device as dead and invalidated it. This patch makes cam_periph_error() to block any command retries after periph was marked as invalid. With that patch all activity completes in 1-2 minutes, just after several timeouts, required to consider device death. This should make ZFS, gmirror, graid, etc. operation more robust. Reviewed by: mjacob@ on scsi@ Approved by: re (kib) Revision Changes Path 1.97 +19 -8 src/sys/cam/cam_periph.c