driver-proxy.h 626 B

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef BFG_DRIVER_PROXY_H
  2. #define BFG_DRIVER_PROXY_H
  3. #include <uthash.h>
  4. #include "miner.h"
  5. #ifdef USE_LIBEVENT
  6. struct stratumsrv_conn_userlist;
  7. #endif
  8. extern struct device_drv proxy_drv;
  9. struct proxy_client {
  10. char *username;
  11. struct cgpu_info *cgpu;
  12. struct work *work;
  13. struct timeval tv_hashes_done;
  14. float desired_share_pdiff;
  15. #ifdef USE_LIBEVENT
  16. struct stratumsrv_conn_userlist *stratumsrv_connlist;
  17. #endif
  18. UT_hash_handle hh;
  19. };
  20. extern struct proxy_client *proxy_find_or_create_client(const char *user);
  21. #ifdef USE_LIBEVENT
  22. extern void stratumsrv_client_changed_diff(struct proxy_client *);
  23. #endif
  24. #endif