From owner-freebsd-current@FreeBSD.ORG Wed Jan 5 21:02:37 2005 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CDAD816A4CE; Wed, 5 Jan 2005 21:02:37 +0000 (GMT) Received: from mailgate1b.savvis.net (mailgate1b.savvis.net [216.91.182.6]) by mx1.FreeBSD.org (Postfix) with ESMTP id 802EA43D3F; Wed, 5 Jan 2005 21:02:37 +0000 (GMT) (envelope-from Maksim.Yevmenkin@savvis.net) Received: from out001.email.savvis.net (out001.apptix.savvis.net [216.91.32.44])j05L0hoj011318; Wed, 5 Jan 2005 15:00:43 -0600 Received: from s228130hz1ew03.apptix-01.savvis.net ([10.146.4.28]) by out001.email.savvis.net with Microsoft SMTPSVC(6.0.3790.211); Wed, 5 Jan 2005 15:00:37 -0600 Received: from [10.254.186.111] ([66.35.239.94]) by s228130hz1ew03.apptix-01.savvis.net with Microsoft SMTPSVC(6.0.3790.211); Wed, 5 Jan 2005 15:00:23 -0600 Message-ID: <41DC5561.4090005@savvis.net> Date: Wed, 05 Jan 2005 13:00:17 -0800 From: Maksim Yevmenkin User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.2) Gecko/20040822 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Scott Long , Julian Elischer , Roman Kurakin References: <41DB08B9.6090801@savvis.net> <41DB1310.4060807@cronyx.ru> <41DB1700.7060708@savvis.net> <41DB1839.9080104@elischer.org> <41DC4FA2.8070609@savvis.net> <41DC5398.8020508@freebsd.org> In-Reply-To: <41DC5398.8020508@freebsd.org> Content-Type: multipart/mixed; boundary="------------070809080108090005000904" X-OriginalArrivalTime: 05 Jan 2005 21:00:23.0228 (UTC) FILETIME=[92BE57C0:01C4F369] X-ECS-MailScanner: No virus is found cc: current@freebsd.org Subject: Re: netgraph(4) initialization order X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2005 21:02:37 -0000 This is a multi-part message in MIME format. --------------070809080108090005000904 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Scott Long wrote: > Maksim Yevmenkin wrote: > >> Dear Hackers, >> >> any objections to the attached patch? >> > > Yes, as I stated in another email, I think that the core netgraph > module should be initialized before the SI_SUB_DRIVERS step. I > propose creating a new sysinit called SI_SUB_NETGRAPH with a value > of 0x30100000. That way it comes after SI_SUB_IF and before > SI_SUB_DRIVERS. This make fiddling with SI_ORDER_* unneccesary. how about new attached patch? thanks, max --------------070809080108090005000904 Content-Type: text/plain; name="netgraph.init.diff.txt" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="netgraph.init.diff.txt" --- sys/kernel.h.orig Wed Jan 5 12:55:03 2005 +++ sys/kernel.h Wed Jan 5 12:55:51 2005 @@ -132,6 +132,7 @@ SI_SUB_SOFTINTR = 0x2800001, /* start soft interrupt thread */ SI_SUB_DEVFS = 0x2F00000, /* devfs ready for devices */ SI_SUB_INIT_IF = 0x3000000, /* prep for net interfaces */ + SI_SUB_NETGRAPH = 0x3010000, /* Let Netgraph initialize */ SI_SUB_DRIVERS = 0x3100000, /* Let Drivers initialize */ SI_SUB_CONFIGURE = 0x3800000, /* Configure devices */ SI_SUB_VFS = 0x4000000, /* virtual filesystem*/ --- netgraph/ng_base.c.orig Wed Jan 5 12:04:36 2005 +++ netgraph/ng_base.c Wed Jan 5 12:56:51 2005 @@ -2991,7 +2991,7 @@ ngb_mod_event, (NULL) }; -DECLARE_MODULE(netgraph, netgraph_mod, SI_SUB_DRIVERS, SI_ORDER_MIDDLE); +DECLARE_MODULE(netgraph, netgraph_mod, SI_SUB_NETGRAPH, SI_ORDER_MIDDLE); SYSCTL_NODE(_net, OID_AUTO, graph, CTLFLAG_RW, 0, "netgraph Family"); SYSCTL_INT(_net_graph, OID_AUTO, abi_version, CTLFLAG_RD, 0, NG_ABI_VERSION,""); SYSCTL_INT(_net_graph, OID_AUTO, msg_version, CTLFLAG_RD, 0, NG_VERSION, ""); --------------070809080108090005000904--