From owner-cvs-all Mon Jan 24 17:37:13 2000 Delivered-To: cvs-all@freebsd.org Received: from awfulhak.org (dynamic-4.max4-du-ws.dialnetwork.pavilion.co.uk [212.74.9.132]) by hub.freebsd.org (Postfix) with ESMTP id B7D1514CF1; Mon, 24 Jan 2000 17:36:58 -0800 (PST) (envelope-from brian@Awfulhak.org) Received: from hak.lan.Awfulhak.org (root@hak.lan.Awfulhak.org [172.16.0.12]) by awfulhak.org (8.9.3/8.9.3) with ESMTP id BAA68244; Tue, 25 Jan 2000 01:36:25 GMT (envelope-from brian@lan.awfulhak.org) Received: from hak.lan.Awfulhak.org (brian@localhost.lan.Awfulhak.org [127.0.0.1]) by hak.lan.Awfulhak.org (8.9.3/8.9.3) with ESMTP id BAA36929; Tue, 25 Jan 2000 01:36:27 GMT (envelope-from brian@hak.lan.Awfulhak.org) Message-Id: <200001250136.BAA36929@hak.lan.Awfulhak.org> X-Mailer: exmh version 2.1.0 09/18/1999 To: Garrett Wollman Cc: Brian Somers , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org, brian@hak.lan.Awfulhak.org Subject: Re: cvs commit: src/sys/conf files src/sys/modules/if_tun Makefile src/sys/net intrq.c intrq.h if_tun.c src/sys/netatalk ddp_input.c src/sys/netatm atm_subr.c src/sys/netinet ip_input.c src/sys/netinet6 ip6_input.c src/sys/netipx ipx_input.c ... In-Reply-To: Message from Garrett Wollman of "Mon, 24 Jan 2000 20:23:24 EST." <200001250123.UAA01185@khavrinen.lcs.mit.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Tue, 25 Jan 2000 01:36:26 +0000 From: Brian Somers Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk > < said: > > > That's what the *intrq_present variables are for. The file that's > > #ifdef'd in with (for example) IPX will say > > ``const int ipxintrq_present = 1;'' whereas intrq.c says > > ``const int ipxintrq_present;''. > > I'd really rather see this implemented as a functional interface (say, > *_queue_input). Do you mean to `hide' the *_present variables ? If so, I agree that something like the following would be better - it's a bit more protective against rogue modules: intrq.h: extern int ipx_enqueue(struct mbuf *); ..... intrq.c: int ipx_enqueue(struct mbuf *m) { if (ipxintrq_present) { IF_ENQUEUE(&ipxintrq, m); return 0; } m_freem(m); return EAFNOSUPPORT; } ..... > -GAWollman > > -- > Garrett A. Wollman | O Siem / We are all family / O Siem / We're all the same > wollman@lcs.mit.edu | O Siem / The fires of freedom > Opinions not those of| Dance in the burning flame > MIT, LCS, CRS, or NSA| - Susan Aglukark and Chad Irschick -- Brian Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message