Remove non-error hw_info_get() messages.
Currently hw_info_get() can receive requests for entries (info_id) that the specific driver doesn't support. That is (right now) a valid use-case and not an error (might change later, though). Thus, for now, don't output messages for such requests at all (certainly not as sr_err() where they show up in e.g. sigrok-cli output per default).
This commit is contained in:
parent
a978eda2c9
commit
4ebd48b352
|
@ -250,7 +250,6 @@ static int hw_cleanup(void)
|
|||
static int hw_info_get(int info_id, const void **data,
|
||||
const struct sr_dev_inst *sdi)
|
||||
{
|
||||
|
||||
(void)sdi;
|
||||
|
||||
switch (info_id) {
|
||||
|
|
|
@ -163,7 +163,6 @@ static int hw_info_get(int info_id, const void **data,
|
|||
*data = &devc->supp_rates;
|
||||
break;
|
||||
default:
|
||||
sr_err("Invalid info_id: %d.", info_id);
|
||||
return SR_ERR_ARG;
|
||||
}
|
||||
|
||||
|
|
|
@ -194,7 +194,6 @@ static int hw_cleanup(void)
|
|||
static int hw_info_get(int info_id, const void **data,
|
||||
const struct sr_dev_inst *sdi)
|
||||
{
|
||||
|
||||
(void)sdi;
|
||||
|
||||
switch (info_id) {
|
||||
|
|
|
@ -284,7 +284,6 @@ static int hw_cleanup(void)
|
|||
static int hw_info_get(int info_id, const void **data,
|
||||
const struct sr_dev_inst *sdi)
|
||||
{
|
||||
|
||||
(void)sdi;
|
||||
|
||||
switch (info_id) {
|
||||
|
|
|
@ -216,7 +216,6 @@ static int hw_cleanup(void)
|
|||
static int hw_info_get(int info_id, const void **data,
|
||||
const struct sr_dev_inst *sdi)
|
||||
{
|
||||
|
||||
(void)sdi;
|
||||
|
||||
switch (info_id) {
|
||||
|
@ -227,7 +226,6 @@ static int hw_info_get(int info_id, const void **data,
|
|||
*data = hwcaps;
|
||||
break;
|
||||
default:
|
||||
sr_err("Unknown info_id: %d.", info_id);
|
||||
return SR_ERR_ARG;
|
||||
}
|
||||
|
||||
|
|
|
@ -268,14 +268,12 @@ static int hw_cleanup(void)
|
|||
static int hw_info_get(int info_id, const void **data,
|
||||
const struct sr_dev_inst *sdi)
|
||||
{
|
||||
|
||||
/* TODO */
|
||||
(void)data;
|
||||
(void)sdi;
|
||||
|
||||
switch (info_id) {
|
||||
default:
|
||||
sr_err("Unknown info_id: %d.", info_id);
|
||||
return SR_ERR_ARG;
|
||||
}
|
||||
|
||||
|
|
|
@ -347,7 +347,6 @@ static int hw_info_get(int info_id, const void **data,
|
|||
*data = coupling;
|
||||
break;
|
||||
default:
|
||||
sr_err("Unknown info_id: %d.", info_id);
|
||||
return SR_ERR_ARG;
|
||||
}
|
||||
|
||||
|
|
|
@ -208,7 +208,6 @@ static int hw_info_get(int info_id, const void **data,
|
|||
*data = hwcaps;
|
||||
break;
|
||||
default:
|
||||
sr_err("Unknown info_id: %d.", info_id);
|
||||
return SR_ERR_ARG;
|
||||
}
|
||||
|
||||
|
|
|
@ -186,7 +186,6 @@ static int hw_info_get(int info_id, const void **data,
|
|||
return SR_ERR_ARG;
|
||||
break;
|
||||
default:
|
||||
sr_err("%s: Unknown info_id %d.", __func__, info_id);
|
||||
return SR_ERR_ARG;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -254,7 +254,6 @@ static int hw_info_get(int info_id, const void **data,
|
|||
*data = hwcaps;
|
||||
break;
|
||||
default:
|
||||
sr_err("Unknown info_id: %d.", info_id);
|
||||
return SR_ERR_ARG;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue