From owner-svn-src-all@FreeBSD.ORG Sun Feb 6 01:00:40 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5FF39106564A; Sun, 6 Feb 2011 01:00:40 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4D3AD8FC08; Sun, 6 Feb 2011 01:00:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p1610es6047342; Sun, 6 Feb 2011 01:00:40 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p1610ekh047340; Sun, 6 Feb 2011 01:00:40 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201102060100.p1610ekh047340@svn.freebsd.org> From: Ed Maste Date: Sun, 6 Feb 2011 01:00:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r218361 - stable/7/sys/dev/aac X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Feb 2011 01:00:40 -0000 Author: emaste Date: Sun Feb 6 01:00:40 2011 New Revision: 218361 URL: http://svn.freebsd.org/changeset/base/218361 Log: MFC r218207: Revert part of r173264. Both aac_ioctl_sendfib and aac_ioctl_send_raw_srb make use of the aac_ioctl_event callback, if acc_alloc_command fails. This can end up in an infinite loop in the while loop in aac_release_command. Modified: stable/7/sys/dev/aac/aac.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/dev/aac/aac.c ============================================================================== --- stable/7/sys/dev/aac/aac.c Sat Feb 5 23:32:17 2011 (r218360) +++ stable/7/sys/dev/aac/aac.c Sun Feb 6 01:00:40 2011 (r218361) @@ -1411,11 +1411,7 @@ aac_release_command(struct aac_command * aac_enqueue_free(cm); - /* - * Dequeue all events so that there's no risk of events getting - * stranded. - */ - while ((event = TAILQ_FIRST(&sc->aac_ev_cmfree)) != NULL) { + if ((event = TAILQ_FIRST(&sc->aac_ev_cmfree)) != NULL) { TAILQ_REMOVE(&sc->aac_ev_cmfree, event, ev_links); event->ev_callback(sc, event, event->ev_arg); }