]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/center-3xx/api.c
sr_config_set(): Factor out SR_ERR_DEV_CLOSED check.
[libsigrok.git] / src / hardware / center-3xx / api.c
index 70a14699b90d520036101b8fe119bc1a35f86821..9e618777a8bcaae462bcb1e6482b0d7f9f4d6fc8 100644 (file)
@@ -14,8 +14,7 @@
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
 #include <config.h>
@@ -128,9 +127,6 @@ static int config_set(uint32_t key, GVariant *data, const struct sr_dev_inst *sd
 
        (void)cg;
 
-       if (sdi->status != SR_ST_ACTIVE)
-               return SR_ERR_DEV_CLOSED;
-
        devc = sdi->priv;
 
        return sr_sw_limits_config_set(&devc->sw_limits, key, data);
@@ -166,9 +162,6 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi, int idx)
        struct dev_context *devc;
        struct sr_serial_dev_inst *serial;
 
-       if (sdi->status != SR_ST_ACTIVE)
-               return SR_ERR_DEV_CLOSED;
-
        devc = sdi->priv;
 
        sr_sw_limits_acquisition_start(&devc->sw_limits);