Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
sch_htb.c File Reference
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/types.h>
#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/errno.h>
#include <linux/skbuff.h>
#include <linux/list.h>
#include <linux/compiler.h>
#include <linux/rbtree.h>
#include <linux/workqueue.h>
#include <linux/slab.h>
#include <net/netlink.h>
#include <net/pkt_sched.h>

Go to the source code of this file.

Data Structures

struct  htb_class
 
struct  htb_sched
 

Macros

#define HTB_VER   0x30011 /* major must be matched with number suplied by TC as version */
 
#define HTB_WARN_TOOMANYEVENTS   0x1
 
#define HTB_DIRECT   ((struct htb_class *)-1L)
 

Enumerations

enum  htb_cmode { HTB_CANT_SEND, HTB_MAY_BORROW, HTB_CAN_SEND }
 

Functions

 module_param (htb_hysteresis, int, 0640)
 
 MODULE_PARM_DESC (htb_hysteresis,"Hysteresis mode, less CPU load, less accurate")
 

Macro Definition Documentation

#define HTB_DIRECT   ((struct htb_class *)-1L)

htb_classify - classify a packet into class

It returns NULL if the packet should be dropped or -1 if the packet should be passed directly thru. In all other cases leaf class is returned. We allow direct class selection by classid in priority. The we examine filters in qdisc and in inner nodes (if higher filter points to the inner node). If we end up with classid MAJOR:0 we enqueue the skb into special internal fifo (direct). These packets then go directly thru. If we still have no valid leaf we try to use MAJOR:default leaf. It still unsuccessful then finish and return direct queue.

Definition at line 189 of file sch_htb.c.

#define HTB_VER   0x30011 /* major must be matched with number suplied by TC as version */

Definition at line 57 of file sch_htb.c.

#define HTB_WARN_TOOMANYEVENTS   0x1

Definition at line 160 of file sch_htb.c.

Enumeration Type Documentation

enum htb_cmode
Enumerator:
HTB_CANT_SEND 
HTB_MAY_BORROW 
HTB_CAN_SEND 

Definition at line 68 of file sch_htb.c.

Function Documentation

module_param ( htb_hysteresis  ,
int  ,
0640   
)
MODULE_PARM_DESC ( htb_hysteresis  ,
"Hysteresis  mode,
less CPU  load,
less accurate"   
)