From owner-p4-projects@FreeBSD.ORG Tue Aug 29 12:58:13 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 62A1A16A4E2; Tue, 29 Aug 2006 12:58:13 +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 0FC2F16A4E0 for ; Tue, 29 Aug 2006 12:58:13 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B963843D58 for ; Tue, 29 Aug 2006 12:58:11 +0000 (GMT) (envelope-from hselasky@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 k7TCwBkr096430 for ; Tue, 29 Aug 2006 12:58:11 GMT (envelope-from hselasky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k7TCwBmM096427 for perforce@freebsd.org; Tue, 29 Aug 2006 12:58:11 GMT (envelope-from hselasky@FreeBSD.org) Date: Tue, 29 Aug 2006 12:58:11 GMT Message-Id: <200608291258.k7TCwBmM096427@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky To: Perforce Change Reviews Cc: Subject: PERFORCE change 105259 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: Tue, 29 Aug 2006 12:58:13 -0000 http://perforce.freebsd.org/chv.cgi?CH=105259 Change 105259 by hselasky@hselasky_mini_itx on 2006/08/29 12:57:15 Try to make "usbd_config_td_queue_command()" smarter by calling "command_func" before "p_config_copy". Affected files ... .. //depot/projects/usb/src/sys/dev/usb/usb_subr.c#14 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/usb_subr.c#14 (text+ko) ==== @@ -2561,6 +2561,15 @@ } } + /* first call to command function + * (do this before calling the + * config copy function, so that + * the immediate part of the command + * function gets a chance to change + * the config before it is copied) + */ + (command_func)(ctd->p_softc, NULL, command_ref); + USBD_IF_DEQUEUE(&(ctd->cmd_free), m); if (m == NULL) { @@ -2586,11 +2595,6 @@ ctd->flag_config_td_sleep = 0; wakeup(&(ctd->wakeup_config_td)); } - - /* first call to command function */ - - (command_func)(ctd->p_softc, NULL, command_ref); - return; }