From cffdc3e63b132795bfcaab91864c1c6b124e87fa Mon Sep 17 00:00:00 2001 From: Martin Ling Date: Mon, 2 Nov 2015 01:03:07 +0000 Subject: [PATCH] Make SR_CONF_{SCAN,DEVICE}_OPTIONS into internal constants. These are no longer needed in the public API as we have new wrapper functions. They are still used internally by drivers. --- include/libsigrok/libsigrok.h | 6 ------ src/hwdriver.c | 4 ---- src/libsigrok-internal.h | 6 ++++++ 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/include/libsigrok/libsigrok.h b/include/libsigrok/libsigrok.h index de3136b9..22d9be45 100644 --- a/include/libsigrok/libsigrok.h +++ b/include/libsigrok/libsigrok.h @@ -982,12 +982,6 @@ enum sr_configkey { /*--- Special stuff -------------------------------------------------*/ - /** Scan options supported by the driver. */ - SR_CONF_SCAN_OPTIONS = 40000, - - /** Device options for a particular device. */ - SR_CONF_DEVICE_OPTIONS, - /** Session filename. */ SR_CONF_SESSIONFILE, diff --git a/src/hwdriver.c b/src/hwdriver.c index 5a4b1b01..0aa7eb8c 100644 --- a/src/hwdriver.c +++ b/src/hwdriver.c @@ -173,10 +173,6 @@ static struct sr_key_info sr_key_info_config[] = { "Over-temperature protection active", NULL}, /* Special stuff */ - {SR_CONF_SCAN_OPTIONS, SR_T_STRING, "scan_options", - "Scan options", NULL}, - {SR_CONF_DEVICE_OPTIONS, SR_T_STRING, "device_options", - "Device options", NULL}, {SR_CONF_SESSIONFILE, SR_T_STRING, "sessionfile", "Session file", NULL}, {SR_CONF_CAPTUREFILE, SR_T_STRING, "capturefile", diff --git a/src/libsigrok-internal.h b/src/libsigrok-internal.h index 12b556ae..cc87e1ed 100644 --- a/src/libsigrok-internal.h +++ b/src/libsigrok-internal.h @@ -675,6 +675,12 @@ SR_PRIV int sr_log(int loglevel, const char *format, ...) G_GNUC_PRINTF(2, 3); /*--- device.c --------------------------------------------------------------*/ +/** Scan options supported by a driver. */ +#define SR_CONF_SCAN_OPTIONS 0x7FFF0000 + +/** Device options for a particular device. */ +#define SR_CONF_DEVICE_OPTIONS 0x7FFF0001 + /** Values for the changes argument of sr_dev_driver.config_channel_set. */ enum { /** The enabled state of the channel has been changed. */