From owner-p4-projects@FreeBSD.ORG Fri Aug 4 16:23:54 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 833B716A52F; Fri, 4 Aug 2006 16:23:54 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 468B416A51B for ; Fri, 4 Aug 2006 16:23:54 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6973943D53 for ; Fri, 4 Aug 2006 16:23:53 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k74GNrRB006203 for ; Fri, 4 Aug 2006 16:23:53 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k74GNrKD006200 for perforce@freebsd.org; Fri, 4 Aug 2006 16:23:53 GMT (envelope-from piso@freebsd.org) Date: Fri, 4 Aug 2006 16:23:53 GMT Message-Id: <200608041623.k74GNrKD006200@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 103178 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 04 Aug 2006 16:23:54 -0000 http://perforce.freebsd.org/chv.cgi?CH=103178 Change 103178 by piso@piso_newluxor on 2006/08/04 16:23:44 Avoid deadlock: during taskqueue_free() some of the predefined tasks could be executed, so watch out not to do it while holding a lock that one of these tasks could try to acquire. Affected files ... .. //depot/projects/soc2006/intr_filter/dev/bfe/if_bfe.c#7 edit Differences ... ==== //depot/projects/soc2006/intr_filter/dev/bfe/if_bfe.c#7 (text+ko) ==== @@ -475,8 +475,8 @@ device_delete_child(dev, sc->bfe_miibus); bfe_release_resources(sc); + BFE_UNLOCK(sc); taskqueue_free(sc->sc_tq); - BFE_UNLOCK(sc); mtx_destroy(&sc->bfe_mtx); return (0);