std: Improve prototypes of some functions.
This commit is contained in:
parent
0f523f2b45
commit
769561cbe9
|
@ -366,11 +366,11 @@ static int config_list(uint32_t key, GVariant **data,
|
|||
case SR_CONF_DEVICE_OPTIONS:
|
||||
if (!cg) {
|
||||
if (model)
|
||||
*data = std_gvar_array_u32((const uint32_t *)model->devopts, model->num_devopts);
|
||||
*data = std_gvar_array_u32(*model->devopts, model->num_devopts);
|
||||
else
|
||||
*data = std_gvar_array_u32(ARRAY_AND_SIZE(drvopts));
|
||||
} else if (cg_type == CG_ANALOG) {
|
||||
*data = std_gvar_array_u32((const uint32_t *)model->devopts_cg_analog, model->num_devopts_cg_analog);
|
||||
*data = std_gvar_array_u32(*model->devopts_cg_analog, model->num_devopts_cg_analog);
|
||||
} else {
|
||||
*data = std_gvar_array_u32(NULL, 0);
|
||||
}
|
||||
|
|
|
@ -978,9 +978,9 @@ SR_PRIV GVariant *std_gvar_min_max_step_thresholds(const double dmin, const doub
|
|||
SR_PRIV GVariant *std_gvar_tuple_u64(uint64_t low, uint64_t high);
|
||||
SR_PRIV GVariant *std_gvar_tuple_double(double low, double high);
|
||||
|
||||
SR_PRIV GVariant *std_gvar_array_i32(const int32_t *a, unsigned int n);
|
||||
SR_PRIV GVariant *std_gvar_array_u32(const uint32_t *a, unsigned int n);
|
||||
SR_PRIV GVariant *std_gvar_array_u64(const uint64_t *a, unsigned int n);
|
||||
SR_PRIV GVariant *std_gvar_array_i32(const int32_t a[], unsigned int n);
|
||||
SR_PRIV GVariant *std_gvar_array_u32(const uint32_t a[], unsigned int n);
|
||||
SR_PRIV GVariant *std_gvar_array_u64(const uint64_t a[], unsigned int n);
|
||||
SR_PRIV GVariant *std_gvar_array_str(const char *a[], unsigned int n);
|
||||
|
||||
SR_PRIV GVariant *std_gvar_thresholds(const double a[][2], unsigned int n);
|
||||
|
|
|
@ -749,19 +749,19 @@ SR_PRIV GVariant *std_gvar_tuple_double(double low, double high)
|
|||
return g_variant_new_tuple(range, 2);
|
||||
}
|
||||
|
||||
SR_PRIV GVariant *std_gvar_array_i32(const int32_t *a, unsigned int n)
|
||||
SR_PRIV GVariant *std_gvar_array_i32(const int32_t a[], unsigned int n)
|
||||
{
|
||||
return g_variant_new_fixed_array(G_VARIANT_TYPE_INT32,
|
||||
a, n, sizeof(int32_t));
|
||||
}
|
||||
|
||||
SR_PRIV GVariant *std_gvar_array_u32(const uint32_t *a, unsigned int n)
|
||||
SR_PRIV GVariant *std_gvar_array_u32(const uint32_t a[], unsigned int n)
|
||||
{
|
||||
return g_variant_new_fixed_array(G_VARIANT_TYPE_UINT32,
|
||||
a, n, sizeof(uint32_t));
|
||||
}
|
||||
|
||||
SR_PRIV GVariant *std_gvar_array_u64(const uint64_t *a, unsigned int n)
|
||||
SR_PRIV GVariant *std_gvar_array_u64(const uint64_t a[], unsigned int n)
|
||||
{
|
||||
return g_variant_new_fixed_array(G_VARIANT_TYPE_UINT64,
|
||||
a, n, sizeof(uint64_t));
|
||||
|
|
Loading…
Reference in New Issue