root/include/linux/if_eql.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 /*
   2  * Equalizer Load-balancer for serial network interfaces.
   3  *
   4  * (c) Copyright 1995 Simon "Guru Aleph-Null" Janes
   5  * NCM: Network and Communications Mangement, Inc.
   6  *
   7  *
   8  *      This software may be used and distributed according to the terms
   9  *      of the GNU Public License, incorporated herein by reference.
  10  * 
  11  * The author may be reached as simon@ncm.com, or C/O
  12  *    NCM
  13  *    Attn: Simon Janes
  14  *    6803 Whittier Ave
  15  *    McLean VA 22101
  16  *    Phone: 1-703-847-0040 ext 103
  17  */
  18 
  19 #ifndef _LINUX_IF_EQL_H
  20 #define _LINUX_IF_EQL_H
  21 
  22 #include <linux/timer.h>
  23 
  24 #define EQL_DEFAULT_SLAVE_PRIORITY 28800
  25 #define EQL_DEFAULT_MAX_SLAVES     4
  26 #define EQL_DEFAULT_MTU            576
  27 #define EQL_DEFAULT_RESCHED_IVAL   100
  28 
  29 #define EQL_ENSLAVE     (SIOCDEVPRIVATE)
  30 #define EQL_EMANCIPATE  (SIOCDEVPRIVATE + 1)
  31 
  32 #define EQL_GETSLAVECFG (SIOCDEVPRIVATE + 2)
  33 #define EQL_SETSLAVECFG (SIOCDEVPRIVATE + 3)
  34 
  35 #define EQL_GETMASTRCFG (SIOCDEVPRIVATE + 4)
  36 #define EQL_SETMASTRCFG (SIOCDEVPRIVATE + 5)
  37 
  38 typedef struct slave {
  39   struct device *dev;
  40   long priority;
  41   long priority_bps;
  42   long priority_Bps;
  43   long bytes_queued;
  44   struct slave *next;
  45 } slave_t;
  46 
  47 typedef struct slave_queue {
  48   slave_t *head;
  49   slave_t *best_slave;
  50   int num_slaves;
  51   struct device *master_dev;
  52   char lock;
  53 } slave_queue_t;
  54 
  55 typedef struct equalizer {
  56   slave_queue_t *queue;
  57   int min_slaves;
  58   int max_slaves;
  59   struct enet_statistics *stats;
  60   struct timer_list timer;
  61   char timer_on;
  62 } equalizer_t;  
  63 
  64 typedef struct master_config {
  65   char master_name[16];
  66   int max_slaves;
  67   int min_slaves;
  68 } master_config_t;
  69 
  70 typedef struct slave_config {
  71   char slave_name[16];
  72   long priority;
  73 } slave_config_t;
  74 
  75 typedef struct slaving_request {
  76   char slave_name[16];
  77   long priority;
  78 } slaving_request_t;
  79 
  80 
  81 #endif /* _LINUX_EQL_H */

/* [previous][next][first][last][top][bottom][index][help] */