From owner-svn-src-head@FreeBSD.ORG Tue Jan 26 05:14:50 2010 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D19F1106566B; Tue, 26 Jan 2010 05:14:50 +0000 (UTC) (envelope-from rrs@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C25EE8FC16; Tue, 26 Jan 2010 05:14:50 +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 o0Q5EoxT087690; Tue, 26 Jan 2010 05:14:50 GMT (envelope-from rrs@svn.freebsd.org) Received: (from rrs@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o0Q5EoVg087688; Tue, 26 Jan 2010 05:14:50 GMT (envelope-from rrs@svn.freebsd.org) Message-Id: <201001260514.o0Q5EoVg087688@svn.freebsd.org> From: Randall Stewart Date: Tue, 26 Jan 2010 05:14:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r203010 - head/sys/mips/rmi/dev/xlr X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Jan 2010 05:14:50 -0000 Author: rrs Date: Tue Jan 26 05:14:50 2010 New Revision: 203010 URL: http://svn.freebsd.org/changeset/base/203010 Log: 1) Make sure static is init'd to 0 2) In one place make sure we call the backup startup routine (from the timer). Modified: head/sys/mips/rmi/dev/xlr/rge.c Modified: head/sys/mips/rmi/dev/xlr/rge.c ============================================================================== --- head/sys/mips/rmi/dev/xlr/rge.c Tue Jan 26 05:11:48 2010 (r203009) +++ head/sys/mips/rmi/dev/xlr/rge.c Tue Jan 26 05:14:50 2010 (r203010) @@ -1686,7 +1686,7 @@ mac_frin_replenish(void *args /* ignored #endif } -static volatile uint32_t g_tx_frm_tx_ok; +static volatile uint32_t g_tx_frm_tx_ok=0; static void rge_tx_bkp_func(void *arg, int npending) @@ -1835,6 +1835,8 @@ xlr_tx_q_wakeup(void *addr) } } } + if (atomic_cmpset_int(&g_tx_frm_tx_ok, 0, 1)) + rge_tx_bkp_func(NULL, 0); callout_reset(&xlr_tx_stop_bkp, 5 * hz, xlr_tx_q_wakeup, NULL); }