if_eql.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /*
  2. * Equalizer Load-balancer for serial network interfaces.
  3. *
  4. * (c) Copyright 1995 Simon "Guru Aleph-Null" Janes
  5. * NCM: Network and Communications Management, Inc.
  6. *
  7. *
  8. * This software may be used and distributed according to the terms
  9. * of the GNU General 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. #ifndef _LINUX_IF_EQL_H
  19. #define _LINUX_IF_EQL_H
  20. #include <linux/timer.h>
  21. #include <linux/spinlock.h>
  22. #include <uapi/linux/if_eql.h>
  23. typedef struct slave {
  24. struct list_head list;
  25. struct net_device *dev;
  26. long priority;
  27. long priority_bps;
  28. long priority_Bps;
  29. long bytes_queued;
  30. } slave_t;
  31. typedef struct slave_queue {
  32. spinlock_t lock;
  33. struct list_head all_slaves;
  34. int num_slaves;
  35. struct net_device *master_dev;
  36. } slave_queue_t;
  37. typedef struct equalizer {
  38. slave_queue_t queue;
  39. int min_slaves;
  40. int max_slaves;
  41. struct timer_list timer;
  42. } equalizer_t;
  43. #endif /* _LINUX_EQL_H */