From owner-svn-src-all@FreeBSD.ORG Thu Jul 15 14:43:13 2010 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 2E9E31065672; Thu, 15 Jul 2010 14:43:13 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1EF578FC08; Thu, 15 Jul 2010 14:43:13 +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 o6FEhDuY015985; Thu, 15 Jul 2010 14:43:13 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o6FEhDFs015983; Thu, 15 Jul 2010 14:43:13 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <201007151443.o6FEhDFs015983@svn.freebsd.org> From: Luigi Rizzo Date: Thu, 15 Jul 2010 14:43:13 +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: r210123 - head/sys/netinet/ipfw 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: Thu, 15 Jul 2010 14:43:13 -0000 Author: luigi Date: Thu Jul 15 14:43:12 2010 New Revision: 210123 URL: http://svn.freebsd.org/changeset/base/210123 Log: remove some conditional #ifdefs (no-op on FreeBSD); run the timer routine on cpu 0. Modified: head/sys/netinet/ipfw/ip_fw_dynamic.c Modified: head/sys/netinet/ipfw/ip_fw_dynamic.c ============================================================================== --- head/sys/netinet/ipfw/ip_fw_dynamic.c Thu Jul 15 14:41:59 2010 (r210122) +++ head/sys/netinet/ipfw/ip_fw_dynamic.c Thu Jul 15 14:43:12 2010 (r210123) @@ -894,10 +894,7 @@ struct mbuf * ipfw_send_pkt(struct mbuf *replyto, struct ipfw_flow_id *id, u_int32_t seq, u_int32_t ack, int flags) { -#ifndef __FreeBSD__ - return NULL; -#else - struct mbuf *m; + struct mbuf *m = NULL; /* stupid compiler */ int len, dir; struct ip *h = NULL; /* stupid compiler */ #ifdef INET6 @@ -1033,7 +1030,6 @@ ipfw_send_pkt(struct mbuf *replyto, stru } return (m); -#endif /* __FreeBSD__ */ } /* @@ -1131,8 +1127,8 @@ ipfw_tick(void * vnetx) } #endif done: - callout_reset(&V_ipfw_timeout, V_dyn_keepalive_period * hz, - ipfw_tick, vnetx); + callout_reset_on(&V_ipfw_timeout, V_dyn_keepalive_period * hz, + ipfw_tick, vnetx, 0); CURVNET_RESTORE(); } @@ -1173,7 +1169,7 @@ ipfw_dyn_init(void) V_dyn_max = 4096; /* max # of dynamic rules */ callout_init(&V_ipfw_timeout, CALLOUT_MPSAFE); - callout_reset(&V_ipfw_timeout, hz, ipfw_tick, curvnet); + callout_reset_on(&V_ipfw_timeout, hz, ipfw_tick, curvnet, 0); } void