static GSList *scan(struct sr_dev_driver *di, GSList *options)
{
- struct drv_context *drvc;
- GSList *devices, *l;
+ GSList *l;
struct sr_config *src;
struct sr_dev_inst *sdi;
struct dev_context *devc;
int i, maxch;
- devices = NULL;
- drvc = di->context;
- drvc->instances = NULL;
-
/* Probe for /dev/beaglelogic */
if (!g_file_test(BEAGLELOGIC_DEV_NODE, G_FILE_TEST_EXISTS))
return NULL;
sdi->status = SR_ST_INACTIVE;
sdi->model = g_strdup("BeagleLogic");
sdi->version = g_strdup("1.0");
- sdi->driver = di;
/* Unless explicitly specified, keep max channels to 8 only */
maxch = 8;
channel_names[i]);
sdi->priv = devc;
- drvc->instances = g_slist_append(drvc->instances, sdi);
- devices = g_slist_append(devices, sdi);
- return devices;
+ return std_scan_complete(di, g_slist_append(NULL, sdi));
}
static int dev_open(struct sr_dev_inst *sdi)