From owner-freebsd-bugs@FreeBSD.ORG Tue Jun 21 12:50:19 2005 Return-Path: X-Original-To: freebsd-bugs@hub.freebsd.org Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EA1C816A41C for ; Tue, 21 Jun 2005 12:50:19 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id AFD8743D49 for ; Tue, 21 Jun 2005 12:50:19 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j5LCoJUP044789 for ; Tue, 21 Jun 2005 12:50:19 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j5LCoJDC044788; Tue, 21 Jun 2005 12:50:19 GMT (envelope-from gnats) Resent-Date: Tue, 21 Jun 2005 12:50:19 GMT Resent-Message-Id: <200506211250.j5LCoJDC044788@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Steven Hartland Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 099A816A41C; Tue, 21 Jun 2005 12:49:42 +0000 (GMT) (envelope-from root@r2d2.multiplay.co.uk) Received: from r2d2.multiplay.co.uk (host7.iclon.multiplay.co.uk [212.135.219.182]) by mx1.FreeBSD.org (Postfix) with ESMTP id 93A5F43D1D; Tue, 21 Jun 2005 12:49:41 +0000 (GMT) (envelope-from root@r2d2.multiplay.co.uk) Received: from r2d2.multiplay.co.uk (localhost [127.0.0.1]) by r2d2.multiplay.co.uk (8.13.3/8.13.3) with ESMTP id j5LDomZ5000650; Tue, 21 Jun 2005 13:50:48 GMT (envelope-from root@r2d2.multiplay.co.uk) Received: (from root@localhost) by r2d2.multiplay.co.uk (8.13.3/8.13.3/Submit) id j5LDomF4000649; Tue, 21 Jun 2005 13:50:48 GMT (envelope-from root) Message-Id: <200506211350.j5LDomF4000649@r2d2.multiplay.co.uk> Date: Tue, 21 Jun 2005 13:50:48 GMT From: Steven Hartland To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: freebsd-stable-list Subject: kern/82482: hptmv ( Highpoint RocketRaid 1820a ) corrupts fs on shutdown -p X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Steven Hartland List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Jun 2005 12:50:20 -0000 >Number: 82482 >Category: kern >Synopsis: hptmv ( Highpoint RocketRaid 1820a ) corrupts fs on shutdown -p >Confidential: no >Severity: serious >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Jun 21 12:50:18 GMT 2005 >Closed-Date: >Last-Modified: >Originator: Steven Hartland >Release: FreeBSD 5.4-RELEASE-p2 i386 >Organization: Multiplay >Environment: System: FreeBSD r2d2.multiplay.co.uk 5.4-RELEASE-p2 FreeBSD 5.4-RELEASE-p2 #5: Tue Jun 21 13:29:02 UTC 2005 root@r2d2.multiplay.co.uk:/.usr/i386/src/sys/i386/compile/MPUK_SMP_200HZ i386 >Description: When shutting down with power off e.g. shutdown -p now a machine with a Highpoint RocketRaid 1820a ( more than likely the 1820 as well ) corrupts the FS bad enough to force recorvery in single user mode. The problem occurs because the disk flush is async and no time is given for this to happen. >How-To-Repeat: Shutdown a box with a hptmv based controller with power off. >Fix: Apply the following patch which adds a 5 second delay after calling flush. Note: the fix is only relavent for i386 as there is no source for amd64, which is also affected. I've informed Highpoint of the issue but as yet no updated driver has been released. --- entry.c.orig Tue Jun 21 13:23:05 2005 +++ entry.c Tue Jun 21 13:27:38 2005 @@ -2157,6 +2157,10 @@ return (EINVAL); - EVENTHANDLER_DEREGISTER(shutdown_final, pAdapter->eh); FlushAdapter(pAdapter); + + /* give the flush some time to happen */ + DELAY( 1000 * 1000 * 5 ); + + EVENTHANDLER_DEREGISTER(shutdown_final, pAdapter->eh); return 0; >Release-Note: >Audit-Trail: >Unformatted: