siglent-sds: Drop obsolete SR_ST_ACTIVE checks.

These are now done in the wrapper functions.
This commit is contained in:
Uwe Hermann 2018-02-17 17:47:28 +01:00
parent e5896840f6
commit 8856f173df
1 changed files with 0 additions and 13 deletions

View File

@ -371,8 +371,6 @@ static int dev_open(struct sr_dev_inst *sdi)
return SR_ERR; return SR_ERR;
} }
sdi->status = SR_ST_ACTIVE;
return SR_OK; return SR_OK;
} }
@ -535,9 +533,6 @@ static int config_set(uint32_t key, GVariant *data,
devc = sdi->priv; devc = sdi->priv;
if (sdi->status != SR_ST_ACTIVE)
return SR_ERR_DEV_CLOSED;
/* If a channel group is specified, it must be a valid one. */ /* If a channel group is specified, it must be a valid one. */
if (cg && !g_slist_find(sdi->channel_groups, cg)) { if (cg && !g_slist_find(sdi->channel_groups, cg)) {
sr_err("Invalid channel group specified."); sr_err("Invalid channel group specified.");
@ -870,9 +865,6 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi)
gboolean some_digital; gboolean some_digital;
GSList *l, *d; GSList *l, *d;
if (sdi->status != SR_ST_ACTIVE)
return SR_ERR_DEV_CLOSED;
scpi = sdi->conn; scpi = sdi->conn;
devc = sdi->priv; devc = sdi->priv;
@ -980,11 +972,6 @@ static int dev_acquisition_stop(struct sr_dev_inst *sdi)
devc = sdi->priv; devc = sdi->priv;
if (sdi->status != SR_ST_ACTIVE) {
sr_err("Device inactive, can't stop acquisition.");
return SR_ERR;
}
std_session_send_df_end(sdi); std_session_send_df_end(sdi);
g_slist_free(devc->enabled_channels); g_slist_free(devc->enabled_channels);