1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-02-05 03:24:26 +00:00

Use macro expansion to generate extern device_drv prototypes.

This commit is contained in:
ckolivas 2013-09-28 11:45:58 +10:00
parent 8875197466
commit 2903028e6b
2 changed files with 5 additions and 24 deletions

View File

@ -248,6 +248,11 @@ enum drv_driver {
};
#undef DRIVER_ADD_COMMAND
/* Use DRIVER_PARSE_COMMANDS to generate extern device_drv prototypes */
#define DRIVER_ADD_COMMAND(X) extern struct device_drv X##_drv;
DRIVER_PARSE_COMMANDS;
#undef DRIVER_ADD_COMMAND
enum alive {
LIFE_WELL,
LIFE_SICK,

View File

@ -406,30 +406,6 @@ static struct usb_find_devices find_dev[] = {
{ DRV_LAST, NULL, 0, 0, 0, NULL, NULL, 0, 0, 0, 0, NULL }
};
#ifdef USE_BFLSC
extern struct device_drv bflsc_drv;
#endif
#ifdef USE_BITFORCE
extern struct device_drv bitforce_drv;
#endif
#ifdef USE_BITFURY
extern struct device_drv bitfury_drv;
#endif
#ifdef USE_MODMINER
extern struct device_drv modminer_drv;
#endif
#ifdef USE_ICARUS
extern struct device_drv icarus_drv;
#endif
#ifdef USE_AVALON
extern struct device_drv avalon_drv;
#endif
#define STRBUFLEN 256
static const char *BLANK = "";
static const char *space = " ";