drivers: Trim unused config_get() calls

None of the driver config_get/set/list calls are required.
This commit is contained in:
Bert Vermeulen 2013-01-25 16:05:48 +01:00
parent ddd9b41f5a
commit 6a4710fac2
12 changed files with 0 additions and 169 deletions

View File

@ -173,14 +173,6 @@ static int sanity_check_all_drivers(void)
sr_err("No dev_close in driver %d ('%s').", i, d);
errors++;
}
if (!drivers[i]->config_get) {
sr_err("No config_get in driver %d ('%s').", i, d);
errors++;
}
if (!drivers[i]->config_set) {
sr_err("No config_set in driver %d ('%s').", i, d);
errors++;
}
if (!drivers[i]->dev_acquisition_start) {
sr_err("No dev_acquisition_start in driver %d ('%s').",
i, d);

View File

@ -247,18 +247,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -381,7 +369,6 @@ SR_PRIV struct sr_dev_driver agdmm_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -191,18 +191,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -325,7 +313,6 @@ SR_PRIV struct sr_dev_driver colead_slm_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -281,18 +281,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -421,7 +409,6 @@ SR_PRIV struct sr_dev_driver flukedmm_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -422,24 +422,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
uint64_t tmp;
(void)sdi;
switch (id) {
/* TODO remove this */
case SR_CONF_SAMPLERATE:
*data = &tmp;
break;
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -925,7 +907,6 @@ SR_PRIV struct sr_dev_driver hantek_dso_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -213,18 +213,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -491,7 +479,6 @@ SR_PRIV struct sr_dev_driver lascar_el_usb_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -265,20 +265,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
/* TODO */
(void)data;
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
int ret;
@ -348,7 +334,6 @@ SR_PRIV struct sr_dev_driver nexus_osciprime_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -324,18 +324,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -520,7 +508,6 @@ SR_PRIV struct sr_dev_driver rigol_ds1xx2_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -373,18 +373,6 @@ static int hw_cleanup(int dmm)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -533,7 +521,6 @@ SR_PRIV struct sr_dev_driver ID##_driver_info = { \
.scan = hw_scan_##ID_UPPER, \
.dev_list = hw_dev_list_##ID_UPPER, \
.dev_clear = clear_instances_##ID_UPPER, \
.config_get = config_get, \
.config_set = config_set, \
.config_list = config_list, \
.dev_open = hw_dev_open, \

View File

@ -195,18 +195,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -318,7 +306,6 @@ SR_PRIV struct sr_dev_driver tondaj_sl_814_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -186,27 +186,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
sr_spew("Backend requested info_id %d.", id);
switch (id) {
case SR_CONF_SAMPLERATE:
/* TODO: Get rid of this. */
*data = NULL;
sr_spew("%s: Returning current samplerate.", __func__);
return SR_ERR_ARG;
break;
default:
return SR_ERR_ARG;
break;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -321,7 +300,6 @@ SR_PRIV struct sr_dev_driver uni_t_ut61d_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,
@ -340,7 +318,6 @@ SR_PRIV struct sr_dev_driver voltcraft_vc820_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,

View File

@ -244,18 +244,6 @@ static int hw_cleanup(void)
return SR_OK;
}
static int config_get(int id, const void **data, const struct sr_dev_inst *sdi)
{
(void)sdi;
switch (id) {
default:
return SR_ERR_ARG;
}
return SR_OK;
}
static int config_set(int id, const void *value, const struct sr_dev_inst *sdi)
{
struct dev_context *devc;
@ -477,7 +465,6 @@ SR_PRIV struct sr_dev_driver victor_dmm_driver_info = {
.scan = hw_scan,
.dev_list = hw_dev_list,
.dev_clear = clear_instances,
.config_get = config_get,
.config_set = config_set,
.config_list = config_list,
.dev_open = hw_dev_open,