From: Bert Vermeulen Date: Sat, 4 Aug 2012 12:35:40 +0000 (+0200) Subject: sr: rename sr_hw_hwcap_get() to sr_devopt_get() X-Git-Tag: dsupstream~728 X-Git-Url: http://sigrok.org/gitweb/?p=libsigrok.git;a=commitdiff_plain;h=3cf91809a5aca7462f0fc9c3ca6fb9a7ebdf92d2 sr: rename sr_hw_hwcap_get() to sr_devopt_get() --- diff --git a/hwdriver.c b/hwdriver.c index 118e49a2..d01ffc35 100644 --- a/hwdriver.c +++ b/hwdriver.c @@ -264,17 +264,17 @@ SR_API const struct sr_hwcap_option *sr_drvopt_get(int hwopt) /** * Get information about a device option. * - * @param hwcap The capability to get. + * @param hwopt The option to get. * * @return A pointer to a struct with information about the parameter, or NULL * if the capability was not found. */ -SR_API const struct sr_hwcap_option *sr_hw_hwcap_get(int hwcap) +SR_API const struct sr_hwcap_option *sr_devopt_get(int hwopt) { int i; for (i = 0; sr_hwcap_options[i].hwcap; i++) { - if (sr_hwcap_options[i].hwcap == hwcap) + if (sr_hwcap_options[i].hwcap == hwopt) return &sr_hwcap_options[i]; } diff --git a/proto.h b/proto.h index 7ac3d09e..ea4bc591 100644 --- a/proto.h +++ b/proto.h @@ -71,7 +71,7 @@ SR_API int sr_info_get(struct sr_dev_driver *driver, int id, const void **data, const struct sr_dev_inst *sdi); SR_API gboolean sr_driver_hwcap_exists(struct sr_dev_driver *driver, int hwcap); SR_API const struct sr_hwcap_option *sr_drvopt_get(int hwopt); -SR_API const struct sr_hwcap_option *sr_hw_hwcap_get(int hwcap); +SR_API const struct sr_hwcap_option *sr_devopt_get(int hwcap); /*--- session.c -------------------------------------------------------------*/