static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver agdmm_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi,
- std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver appa_55ii_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi,
- std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver arachnid_labs_re_load_pro_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver brymen_bm857_driver_info = {
if (sdi->status != SR_ST_ACTIVE)
return SR_ERR_DEV_CLOSED;
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver cem_dt_885x_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi,
- std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
/* Driver-specific API function wrappers */
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver colead_slm_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver flukedmm_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver gmc_mh_1x_2x_rs232_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
#define SCALE(ID, CHIPSET, VENDOR, MODEL, CONN, BAUDRATE, PACKETSIZE, \
if (sdi->status != SR_ST_ACTIVE)
return SR_ERR_DEV_CLOSED;
- return std_serial_dev_acquisition_stop(sdi,
- std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver korad_kaxxxxp_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi,
- std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver manson_hcs_3xxx_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
/* Driver-specific API function wrappers */
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver motech_lps_301_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver norma_dmm_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver pce_322a_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
#define DMM(ID, CHIPSET, VENDOR, MODEL, CONN, BAUDRATE, PACKETSIZE, TIMEOUT, \
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi,
- std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver teleinfo_driver_info = {
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
static struct sr_dev_driver tondaj_sl_814_driver_info = {
SR_PRIV int es51919_serial_acquisition_stop(struct sr_dev_inst *sdi)
{
- return std_serial_dev_acquisition_stop(sdi,
- std_serial_dev_close);
+ return std_serial_dev_acquisition_stop(sdi);
}
SR_PRIV int std_cleanup(const struct sr_dev_driver *di);
#ifdef HAVE_LIBSERIALPORT
SR_PRIV int std_serial_dev_open(struct sr_dev_inst *sdi);
-SR_PRIV int std_serial_dev_acquisition_stop(struct sr_dev_inst *sdi,
- dev_close_callback dev_close_fn);
+SR_PRIV int std_serial_dev_acquisition_stop(struct sr_dev_inst *sdi);
#endif
SR_PRIV int std_session_send_df_header(const struct sr_dev_inst *sdi);
SR_PRIV int std_session_send_df_end(const struct sr_dev_inst *sdi);
*
* @param sdi The device instance for which acquisition should stop.
* Must not be NULL.
- * @param cb_data Opaque 'cb_data' pointer. Must not be NULL.
- * @param dev_close_fn Function pointer to the driver's dev_close().
- * Must not be NULL.
*
* @retval SR_OK Success.
* @retval SR_ERR_ARG Invalid arguments.
* @retval SR_ERR_DEV_CLOSED Device is closed.
* @retval SR_ERR Other errors.
*/
-SR_PRIV int std_serial_dev_acquisition_stop(struct sr_dev_inst *sdi,
- dev_close_callback dev_close_fn)
+SR_PRIV int std_serial_dev_acquisition_stop(struct sr_dev_inst *sdi)
{
struct sr_serial_dev_inst *serial = sdi->conn;
const char *prefix = sdi->driver->name;
return ret;
}
- if ((ret = dev_close_fn(sdi)) < 0) {
+ if ((ret = sdi->driver->dev_close(sdi)) < 0) {
sr_err("%s: Failed to close device: %d.", prefix, ret);
return ret;
}