Show
Ignore:
Timestamp:
06/08/09 18:29:43 (3 years ago)
Author:
Neutron Soutmun <neo.neutron@…>
Children:
5987af1b79b0c1fbd4aa9d30a53ec6879853ece3
Parents:
03dc5e370ef4fbf66e34cbe5bc5b878ed764149c
git-committer:
Neutron Soutmun <neo.neutron@…> (06/08/09 18:29:43)
Message:

Implement IFB to replace the IMQ

  • IFB (Intermediate Functional Block) is more clearly work in the SMP.
  • Implement IFB on config, bandwidth task and support scripts.
  • IMQ is now deprecated. (not support).
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/rh-config.h

    raace70f r2f0141c  
    2020#define XMLSERVICE_URL  "/rahunas_service/xmlrpc_service.php" 
    2121 
     22#define MAX_IFB_IFACE   64 
     23 
    2224#define CONFIG_FILE RAHUNAS_CONF_DIR "rahunas.conf" 
    2325#define DEFAULT_PID RAHUNAS_RUN_DIR "rahunasd.pid" 
    2426#define DB_NAME "rahunas" 
     27 
     28struct interfaces { 
     29  char dev_internal[32]; 
     30  char dev_ifb[32]; 
     31  int  hit; 
     32  int  init; 
     33}; 
    2534 
    2635struct rahunas_main_config { 
     
    4049  char *dev_external; 
    4150  char *dev_internal; 
     51  struct interfaces *iface; 
    4252  char *vlan; 
    4353  char *vlan_raw_dev_external; 
     
    91101}; 
    92102 
     103extern GList *interfaces_list; 
     104 
    93105int get_config(const char *cfg_file, union rahunas_config *config); 
    94106int get_value(const char *cfg_file, const char *key, void **data, size_t *len); 
     
    98110enum lcfg_status rahunas_visitor(const char *key, void *data, size_t size,  
    99111                                 void *user_data); 
     112 
     113GList *append_interface (GList *inf,  
     114                         const char *inf_name); 
     115GList *remove_interface (GList *inf, 
     116                         const char *inf_name); 
     117struct interfaces *get_interface (GList *inf, 
     118                                  const char *inf_name); 
     119int    ifb_interface_reserve (void); 
     120void    ifb_interface_release (int ifno); 
    100121#endif // __RH_CONFIG_H