From owner-freebsd-current Thu Oct 8 15:24:08 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id PAA04020 for freebsd-current-outgoing; Thu, 8 Oct 1998 15:24:08 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from alpha.xerox.com (omega.Xerox.COM [13.1.64.95]) by hub.freebsd.org (8.8.8/8.8.8) with SMTP id PAA03960 for ; Thu, 8 Oct 1998 15:23:37 -0700 (PDT) (envelope-from fenner@parc.xerox.com) Received: from crevenia.parc.xerox.com ([13.2.116.11]) by alpha.xerox.com with SMTP id <435711(2)>; Thu, 8 Oct 1998 15:23:23 PDT Received: from localhost by crevenia.parc.xerox.com with SMTP id <177476>; Thu, 8 Oct 1998 15:21:24 -0700 To: Eivind Eklund cc: Brian Somers , Kris Kennaway , current@FreeBSD.ORG Subject: Re: Improper sharing of modem bandwidth In-reply-to: Your message of "Thu, 08 Oct 98 12:14:41 PDT." <19981008211441.00286@follo.net> Date: Thu, 8 Oct 1998 15:21:21 PDT From: Bill Fenner Message-Id: <98Oct8.152124pdt.177476@crevenia.parc.xerox.com> Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message <19981008211441.00286@follo.net> Eivind wrote: >#2 is probably the best (from the view of which possibilities it >gives), but I also suspect it is what would give most work (unless bpf >already can be used this way; then it would just be a question of >making PPP use it.) [Jumping straight in where I know none of the context...] i = bpf_filter(program, (u_char *)m, ip->ip_len, 0) is all you need to do to run BPF program "program" on the packet in mbuf m. The BPF program can return the packet's priority (i.e. by looking at TCP ports or IP TOS or whatever) and then you could order the packets in the queue by their priority. Bill To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message