]> sigrok.org Git - libsigrok.git/commitdiff
sr: remove obsolete sr_dev_inst_get() call
authorBert Vermeulen <redacted>
Tue, 24 Jul 2012 13:42:51 +0000 (15:42 +0200)
committerBert Vermeulen <redacted>
Fri, 3 Aug 2012 09:29:00 +0000 (11:29 +0200)
hwdriver.c
libsigrok-internal.h

index ff9cc5f8dc58bce17f96cdff2b4a3bdd12b62fab..d1181a2f59dc3c1c8e98c0d769543a03ba6b9232 100644 (file)
@@ -232,21 +232,6 @@ SR_PRIV struct sr_dev_inst *sr_dev_inst_new(int index, int status,
        return sdi;
 }
 
-SR_PRIV struct sr_dev_inst *sr_dev_inst_get(GSList *dev_insts, int dev_index)
-{
-       struct sr_dev_inst *sdi;
-       GSList *l;
-
-       for (l = dev_insts; l; l = l->next) {
-               sdi = (struct sr_dev_inst *)(l->data);
-               if (sdi->index == dev_index)
-                       return sdi;
-       }
-       sr_warn("could not find device index %d instance", dev_index);
-
-       return NULL;
-}
-
 SR_PRIV void sr_dev_inst_free(struct sr_dev_inst *sdi)
 {
        g_free(sdi->priv);
index 6874e4efdb2f3bdf20917cc11c7f7212b8d655b7..1d93d9e5baa76d414a8397b52e5a309dbde9b813 100644 (file)
@@ -89,7 +89,6 @@ SR_PRIV int sr_session_send(const struct sr_dev_inst *sdi,
 /* Generic device instances */
 SR_PRIV struct sr_dev_inst *sr_dev_inst_new(int index, int status,
                const char *vendor, const char *model, const char *version);
-SR_PRIV struct sr_dev_inst *sr_dev_inst_get(GSList *dev_insts, int dev_index);
 SR_PRIV void sr_dev_inst_free(struct sr_dev_inst *sdi);
 SR_PRIV struct sr_probe *sr_probe_new(int index, int type,
                gboolean enabled, const char *name);
@@ -121,15 +120,4 @@ SR_PRIV int ezusb_upload_firmware(libusb_device *dev, int configuration,
                                  const char *filename);
 #endif
 
-/*--- hardware/common/misc.c ------------------------------------------------*/
-
-#ifdef HAVE_LIBUSB_1_0
-SR_PRIV int opendev2(int dev_index, struct sr_dev_inst **sdi,
-                    libusb_device *dev, struct libusb_device_descriptor *des,
-                    int *skip, uint16_t vid, uint16_t pid, int interface);
-SR_PRIV int opendev3(struct sr_dev_inst **sdi, libusb_device *dev,
-                    struct libusb_device_descriptor *des,
-                    uint16_t vid, uint16_t pid, int interface);
-#endif
-
 #endif