]> sigrok.org Git - libsigrok.git/blobdiff - hardware/agilent-dmm/api.c
Remove non-error hw_info_get() messages.
[libsigrok.git] / hardware / agilent-dmm / api.c
index fcd51d54130ffeedb7dc5908fd77a981e441db95..167d4cc83cdb44d89cd547eb7ea7ae6a01f11897 100644 (file)
@@ -41,11 +41,6 @@ static const int hwcaps[] = {
        0,
 };
 
-static const char *probe_names[] = {
-       "Probe",
-       NULL,
-};
-
 extern const struct agdmm_job agdmm_jobs_u123x[];
 extern const struct agdmm_recv agdmm_recvs_u123x[];
 extern const struct agdmm_job agdmm_jobs_u125x[];
@@ -94,7 +89,7 @@ static int clear_instances(void)
        return SR_OK;
 }
 
-static int hw_init(void)
+static int hw_init(struct sr_context *sr_ctx)
 {
        struct drv_context *drvc;
 
@@ -103,6 +98,7 @@ static int hw_init(void)
                return SR_ERR_MALLOC;
        }
 
+       drvc->sr_ctx = sr_ctx;
        di->priv = drvc;
 
        return SR_OK;
@@ -254,7 +250,6 @@ static int hw_cleanup(void)
 static int hw_info_get(int info_id, const void **data,
        const struct sr_dev_inst *sdi)
 {
-
        (void)sdi;
 
        switch (info_id) {
@@ -264,12 +259,6 @@ static int hw_info_get(int info_id, const void **data,
        case SR_DI_HWCAPS:
                *data = hwcaps;
                break;
-       case SR_DI_NUM_PROBES:
-               *data = GINT_TO_POINTER(1);
-               break;
-       case SR_DI_PROBE_NAMES:
-               *data = probe_names;
-               break;
        default:
                return SR_ERR_ARG;
        }