Add dsl-qos-queue to -ng and whiterussian, closes #690
authorFlorian Fainelli <florian@openwrt.org>
Fri, 18 Aug 2006 21:04:24 +0000 (21:04 +0000)
committerFlorian Fainelli <florian@openwrt.org>
Fri, 18 Aug 2006 21:04:24 +0000 (21:04 +0000)
SVN-Revision: 4602

openwrt/package/Config.in
openwrt/package/Makefile
openwrt/package/dsl-qos-queue/Config.in [new file with mode: 0644]
openwrt/package/dsl-qos-queue/Makefile [new file with mode: 0644]
openwrt/package/dsl-qos-queue/ipkg/dsl-qos-queue.control [new file with mode: 0644]
openwrt/package/dsl-qos-queue/patches/01-cross_compile.patch [new file with mode: 0644]

index 018adffa5d02b5d78447f3e330b80ac8d1d5fd72..b2f2138a65b932928518680829506ab5ffb56139 100644 (file)
@@ -36,6 +36,7 @@ source "package/cifsmount/Config.in"
 source "package/cups/Config.in"
 source "package/dhcp-forwarder/Config.in"
 source "package/dropbear/Config.in"
+source "package/dsl-qos-queue/Config.in"
 source "package/dsniff/Config.in"
 source "package/ebtables/Config.in"
 source "package/ez-ipupdate/Config.in"
index faad2031f825c018e3e26e3f3f93e2b15ed9ee63..15821ec740f4efe950002fcd5f292e73554cea06 100644 (file)
@@ -17,6 +17,7 @@ package-$(BR2_PACKAGE_CYRUS_SASL) += cyrus-sasl
 package-$(BR2_PACKAGE_DHCP_FORWARDER) += dhcp-forwarder
 package-$(BR2_PACKAGE_DNSMASQ) += dnsmasq
 package-$(BR2_PACKAGE_DROPBEAR) += dropbear
+package-$(BR2_PACKAGE_DSL_QOS_QUEUE) += dsl-qos-queue
 package-$(BR2_PACKAGE_DSNIFF) += dsniff
 package-$(BR2_PACKAGE_EBTABLES) += ebtables
 package-$(BR2_PACKAGE_EZIPUPDATE) += ez-ipupdate
diff --git a/openwrt/package/dsl-qos-queue/Config.in b/openwrt/package/dsl-qos-queue/Config.in
new file mode 100644 (file)
index 0000000..7df4686
--- /dev/null
@@ -0,0 +1,13 @@
+config BR2_PACKAGE_DSL_QOS_QUEUE
+       tristate "dsl-qos-queue - ADSL/ATM Bandwith management"
+       default m if CONFIG_DEVEL
+       select BR2_PACKAGE_KMOD_IPT_QUEUE
+       help
+         This program implements a user space QUEUE processor which controls outbound traffic
+         over a DSL modem using a pseudo- token-bucket-filter style queue with starvation protection.
+
+         Main feature of this outbound rate limiter is it's ability to rate limit based on the calculated
+         raw bandwidth used rather than just the IP bandwidth used. This provides a MUCH more accurate way
+         to prevent packet queueing in the network device (in this case, ADSL modem).
+
+         http://www.sonicspike.net/software/
diff --git a/openwrt/package/dsl-qos-queue/Makefile b/openwrt/package/dsl-qos-queue/Makefile
new file mode 100644 (file)
index 0000000..1f2ba1f
--- /dev/null
@@ -0,0 +1,43 @@
+# $Id: $
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=dsl_qos_queue
+PKG_VERSION:=0.9.3
+PKG_RELEASE:=1
+PKG_MD5SUM:=ccbe8d28c3508c67f669fe98532533be
+
+PKG_SOURCE_URL:=http://www.sonicspike.net/software/download/
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_CAT:=zcat
+
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
+
+include $(TOPDIR)/package/rules.mk
+
+$(eval $(call PKG_template,DSL_QOS_QUEUE,dsl-qos-queue,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+
+$(PKG_BUILD_DIR)/.configured:
+       touch $@
+
+$(PKG_BUILD_DIR)/.built:
+       $(MAKE) -C $(PKG_BUILD_DIR) \
+               CC=$(TARGET_CC) \
+               $(TARGET_CONFIGURE_OPTS) \
+               CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
+               LDFLAGS="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
+               install_prefix="$(PKG_INSTALL_DIR)" \
+               all
+       touch $@
+
+$(IPKG_DSL_QOS_QUEUE):
+       install -d -m0755 $(IDIR_DSL_QOS_QUEUE)/usr/sbin
+       install -m0755 $(PKG_BUILD_DIR)/$(PKG_NAME) $(IDIR_DSL_QOS_QUEUE)/usr/sbin/
+       install -m0755 $(PKG_BUILD_DIR)/dsl_qos_train $(IDIR_DSL_QOS_QUEUE)/usr/sbin
+       install -m0755 $(PKG_BUILD_DIR)/ipt_rules $(IDIR_DSL_QOS_QUEUE)/usr/sbin
+       $(RSTRIP) $(IDIR_DSL_QOS_QUEUE)
+       $(IPKG_BUILD) $(IDIR_DSL_QOS_QUEUE) $(PACKAGE_DIR)
+
+mostlyclean:
+       make -C $(PKG_BUILD_DIR) clean
+       rm $(PKG_BUILD_DIR)/.built
diff --git a/openwrt/package/dsl-qos-queue/ipkg/dsl-qos-queue.control b/openwrt/package/dsl-qos-queue/ipkg/dsl-qos-queue.control
new file mode 100644 (file)
index 0000000..4aefd01
--- /dev/null
@@ -0,0 +1,4 @@
+Package: dsl-qos-queue
+Priority: optional
+Section: net
+Description: ADSL/ATM Bandwith management
diff --git a/openwrt/package/dsl-qos-queue/patches/01-cross_compile.patch b/openwrt/package/dsl-qos-queue/patches/01-cross_compile.patch
new file mode 100644 (file)
index 0000000..b124b27
--- /dev/null
@@ -0,0 +1,42 @@
+diff -urN dsl_qos_queue/dsl_qos_queue.c dsl_qos_queue.new/dsl_qos_queue.c
+--- dsl_qos_queue/dsl_qos_queue.c      2006-03-28 20:48:18.000000000 +0200
++++ dsl_qos_queue.new/dsl_qos_queue.c  2006-08-18 22:14:12.000000000 +0200
+@@ -552,12 +552,12 @@
+   
+   syslog(LOG_INFO, "setup()");
+   
+-  rval=system("modprobe ip_queue");
++/*  rval=system("modprobe ip_queue");
+   if (WEXITSTATUS(rval)!=0)
+   {
+     printf("Unable to install ip_queue module.\n");
+     exit(1);
+-  }
++  }*/
+   
+   for (i=0;i<MAX_QDEV;i++) if (_qdev[i]) hook_iptables(_qdev[i]);
+diff -urN dsl_qos_queue/makefile dsl_qos_queue.new/makefile
+--- dsl_qos_queue/makefile     2004-12-15 03:10:45.000000000 +0100
++++ dsl_qos_queue.new/makefile 2006-08-18 22:20:48.000000000 +0200
+@@ -4,14 +4,14 @@
+ all: dsl_qos_queue dsl_qos_train
+ clean:
+       rm *.o
+-dsl_qos_queue: dsl_qos_queue.o daemon.o $(LIBIPQ)
+-      $(CC) -o dsl_qos_queue dsl_qos_queue.o daemon.o -lipq
++dsl_qos_queue: dsl_qos_queue.o daemon.o
++      $(CC) $(CFLAGS) $(LDFLAGS) -o dsl_qos_queue dsl_qos_queue.o daemon.o -lipq
+ dsl_qos_queue.o: dsl_qos_queue.c
+-      $(CC) -c dsl_qos_queue.c
++      $(CC) $(CFLAGS) -c dsl_qos_queue.c
+ daemon.o: daemon.c
+-      $(CC) -c daemon.c
++      $(CC) $(CFLAGS) -c daemon.c
+ dsl_qos_train: dsl_qos_train.o
+-      $(CC) -o dsl_qos_train dsl_qos_train.o
++      $(CC) $(CFLAGS) -o dsl_qos_train dsl_qos_train.o
+ dsl_qos_train.o: dsl_qos_train.c
+-      $(CC) -c dsl_qos_train.c
++      $(CC) $(CFLAGS) -c dsl_qos_train.c