Revision History:
  0.9.2 -
			* Removed debugging comments.
			* Added PPPoE support: use -t RFC1483 for standard operation (bridged ethernet), and
        use -t PPPoE to use the PPPoE encapsulation calculation instead.  This only
        affects how the queue determines what the "physical" size of the data is that
        you are sending so it can better estimate the bandwidth consumption.

  0.9.1 -
			* Fixed bug in queue reset (queue length variable was not reset to zero)

  0.9 -
      * Added extra logging to track ipq errors better

  0.8 -
      * Re-compiled with libipq.a from iptables package v1.2.8.  This seems to have
        fixed the queue-lockup & die problem that I had seen from time to time.
        Since I recompiled, I haven't seen any "queue reset" messages in the log
        and it has been 15 days with pretty heavy traffic, so I'm going to release
        it. 
  0.7 -
			* Added work-around for ipq-read errors.  When any IPQ error is encountered,
        the queue is internally restarted.  This has proven to prevent the occasional
        queue lock-up that I had been seeing.
      * Slightly modified ipt_rules to include a rule for network time protocol packets
        to be placed in the low-latency band.

  0.6 -
			* Added additional failure messages to queue startup sequence.

	0.5 -
			* Added specific debugging information for mainloop ipq_read() failure.

  0.4 -
			* Added additional debugging info via syslog.  This information helps
				to differentiate between the various reasons for getting "ipq died" messages
				in an effort to track down exactly where the errors are originating.

	0.3 -
			* Added additional debugging info via syslog.  Messages will appear in
				/var/log/messages on most systems.

	0.2 -
			* Added command line option capability and included binary in package distribution.
			  Program parameters are displayed upon initialization for confirmation.
				Run dsl_qos_queue -h for help on command line options.

	0.1	- Initial release

Please report any problems you have to me: dvsing@sonicspike.net.

* This has been tested on Redhat 7.3.
* You must be using iptables.

USE:

1. Compile the source: make
2. Run provided script to fwmark packets for priority: ipt_rules install
3. Verify rules set: iptables -t mangle -L

   Chain PREROUTING (policy ACCEPT)
   target     prot opt source               destination         
   QUEUE      all  --  anywhere             anywhere           
   
   Chain INPUT (policy ACCEPT)
   target     prot opt source               destination         
   
   Chain FORWARD (policy ACCEPT)
   target     prot opt source               destination         
   
   Chain OUTPUT (policy ACCEPT)
   target     prot opt source               destination         
   
   Chain POSTROUTING (policy ACCEPT)
   target     prot opt source               destination         
>  MYSHAPER-OUT  all  --  anywhere             anywhere           
   
   Chain MYSHAPER-OUT (1 references)
   target     prot opt source               destination         
>  MARK       tcp  --  anywhere             anywhere           tcp spts:0:1024 MARK set 0x17 
>  MARK       tcp  --  anywhere             anywhere           tcp dpts:0:1024 MARK set 0x17 
>  MARK       tcp  --  anywhere             anywhere           tcp dpt:ftp-data MARK set 0x1a 
>  MARK       tcp  --  anywhere             anywhere           tcp dpt:5190 MARK set 0x17 
>  MARK       icmp --  anywhere             anywhere           MARK set 0x14 
>  MARK       udp  --  anywhere             anywhere           MARK set 0x15 
>  MARK       tcp  --  anywhere             anywhere           tcp dpt:ssh MARK set 0x16 
>  MARK       tcp  --  anywhere             anywhere           tcp spt:ssh MARK set 0x16 
>  MARK       tcp  --  anywhere             anywhere           tcp dpt:telnet MARK set 0x16 
>  MARK       tcp  --  anywhere             anywhere           tcp spt:telnet MARK set 0x16 
>  MARK       ipv6-crypt--  anywhere             anywhere           MARK set 0x18 
>  MARK       tcp  --  anywhere             anywhere           tcp spt:http MARK set 0x19 
>  MARK       tcp  --  anywhere             anywhere           length 0:64 MARK set 0x15 
>  MARK       tcp  --  anywhere             anywhere           tcp spt:3389 MARK set 0x17 
>  MARK       all  --  anywhere             anywhere           MARK match 0x0 MARK set 0x1a 

4. Install user queue: dsl_qos_queue -d
5. Verify queue installed: iptables -t mangle -L

   ...
   
   Chain POSTROUTING (policy ACCEPT)
   target     prot opt source               destination         
   MYSHAPER-OUT  all  --  anywhere             anywhere           
>  QUEUE      all  --  anywhere             anywhere           
   
   ...

6. More verification that queue is installed: cat /proc/net/ip_queue

> Peer PID          : 20336
> Copy mode         : 2
> Copy range        : 2048
> Queue length      : 48
> Queue max. length : 1024

Any question ?

- adsl-qos list: http://jared.sonicspike.net/mailman/listinfo/adsl-qos
- author/maintainer: dvsing@sonicspike.net
