summaryrefslogtreecommitdiff
path: root/accel-pppd/shaper/shaper.h
diff options
context:
space:
mode:
authorKozlov Dmitry <xeb@mail.ru>2012-05-15 23:49:48 +0400
committerKozlov Dmitry <xeb@mail.ru>2012-05-15 23:49:48 +0400
commitd669038e70d2e3690423792e63b8179e44a7a340 (patch)
tree18dfc9e4ddcc9d11f0ff0b8cb9a82e4bb795af52 /accel-pppd/shaper/shaper.h
parent6efad618371915bf0b402f26117a02ad53aaeb20 (diff)
downloadaccel-ppp-xebd-d669038e70d2e3690423792e63b8179e44a7a340.tar.gz
accel-ppp-xebd-d669038e70d2e3690423792e63b8179e44a7a340.zip
shaper: implemented leaf qdisc attachment
Diffstat (limited to 'accel-pppd/shaper/shaper.h')
-rw-r--r--accel-pppd/shaper/shaper.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/accel-pppd/shaper/shaper.h b/accel-pppd/shaper/shaper.h
index bd2a718..41e6e43 100644
--- a/accel-pppd/shaper/shaper.h
+++ b/accel-pppd/shaper/shaper.h
@@ -5,6 +5,24 @@
#define LIM_TBF 1
#define LIM_HTB 2
+#define LEAF_QDISC_SFQ 1
+
+struct rtnl_handle;
+struct nlmsghdr;
+
+struct qdisc_opt
+{
+ char *kind;
+ int handle;
+ int parent;
+ double latency;
+ int rate;
+ int buffer;
+ int quantum;
+ int defcls;
+ int (*qdisc)(struct qdisc_opt *opt, struct nlmsghdr *n);
+};
+
extern int conf_up_limiter;
extern int conf_down_limiter;
@@ -16,9 +34,18 @@ extern int conf_quantum;
extern int conf_r2q;
extern int conf_cburst;
extern int conf_ifb_ifindex;
+extern int conf_leaf_qdisc;
+extern int conf_lq_arg1;
+extern int conf_lq_arg2;
+extern int conf_lq_arg3;
int install_limiter(struct ppp_t *ppp, int down_speed, int down_burst, int up_speed, int up_burst);
int remove_limiter(struct ppp_t *ppp);
+int install_leaf_qdisc(struct rtnl_handle *rth, int ifindex, int parent, int handle);
int init_ifb(const char *);
+void leaf_qdisc_parse(const char *);
+
+int tc_qdisc_modify(struct rtnl_handle *rth, int ifindex, int cmd, unsigned flags, struct qdisc_opt *opt);
+
#endif