X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fcem-dt-885x%2Fapi.c;h=8a9a6e1e0461f29428428978d197c089614960b8;hb=a078d3ec527c0a8180f59086e62a8905ae79aa65;hp=a30b5b778d9e9be015fe17d1b7955cb30041063b;hpb=e742b88f9aef970f8d6755858c930a47f79782fa;p=libsigrok.git
diff --git a/src/hardware/cem-dt-885x/api.c b/src/hardware/cem-dt-885x/api.c
index a30b5b77..8a9a6e1e 100644
--- a/src/hardware/cem-dt-885x/api.c
+++ b/src/hardware/cem-dt-885x/api.c
@@ -17,6 +17,7 @@
* along with this program. If not, see .
*/
+#include
#include
#include "protocol.h"
@@ -102,7 +103,7 @@ static GSList *scan(struct sr_dev_driver *di, GSList *options)
return NULL;
devices = NULL;
- drvc = di->priv;
+ drvc = di->context;
start = g_get_monotonic_time();
while (g_get_monotonic_time() - start < MAX_SCAN_TIME_US) {
if (serial_read_nonblocking(serial, &c, 1) == 1 && c == 0xa5) {
@@ -137,7 +138,7 @@ static GSList *scan(struct sr_dev_driver *di, GSList *options)
static GSList *dev_list(const struct sr_dev_driver *di)
{
- return ((struct drv_context *)(di->priv))->instances;
+ return ((struct drv_context *)(di->context))->instances;
}
static int dev_open(struct sr_dev_inst *sdi)
@@ -431,5 +432,5 @@ SR_PRIV struct sr_dev_driver cem_dt_885x_driver_info = {
.dev_close = std_serial_dev_close,
.dev_acquisition_start = dev_acquisition_start,
.dev_acquisition_stop = dev_acquisition_stop,
- .priv = NULL,
+ .context = NULL,
};