From owner-cvs-src@FreeBSD.ORG Fri May 16 10:32:52 2008 Return-Path: Delivered-To: cvs-src@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B185C1065676; Fri, 16 May 2008 10:32:52 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id A280D8FC25; Fri, 16 May 2008 10:32:52 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m4GAWq3G085152; Fri, 16 May 2008 10:32:52 GMT (envelope-from kib@repoman.freebsd.org) Received: (from kib@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m4GAWq26085151; Fri, 16 May 2008 10:32:52 GMT (envelope-from kib) Message-Id: <200805161032.m4GAWq26085151@repoman.freebsd.org> From: Konstantin Belousov Date: Fri, 16 May 2008 10:32:52 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: RELENG_6 Cc: Subject: cvs commit: src/sys/dev/fdc fdc.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 May 2008 10:32:52 -0000 kib 2008-05-16 10:32:52 UTC FreeBSD src repository Modified files: (Branch: RELENG_6) sys/dev/fdc fdc.c Log: MFC rev. 1.320: The wakeup() line from the rev. 1.319 is wrong and reintroduces a panic race on module unload. The wakeup() is internal to kproc_exit/kthread_exit. The correct fix is to fix the msleep() in detach to sleep on fdc->fdc_thread instead of &fdc->fdc_thread. MFC rev. 1.319: Wakeup the thread doing the fdc_detach() when the fdc worker thread exits [1]. Write access to the write-protected floppy shall call device_unbusy() to pair the device_busy() in the fd_access() [2]. PR: 116537 [1], 116539 [2] Revision Changes Path 1.307.2.5 +8 -2 src/sys/dev/fdc/fdc.c