Skip to content
Snippets Groups Projects
Commit 48c41661 authored by Hauke Petersen's avatar Hauke Petersen
Browse files

net/ng_netdev: changed semantics of get function

parent 2d064614
No related branches found
No related tags found
No related merge requests found
......@@ -115,17 +115,17 @@ typedef struct {
* @param[in] dev network device descriptor
* @param[in] opt option type
* @param[out] value pointer to store the option's value in
* @param[in,out] value_len the length of @p value. Must be initialized to
* the available space in @p value on call.
* @param[in] max_len maximal amount of byte that fit into @p value
*
* @return 0 on success
* @return number of bytes written to @p value
* @return -ENODEV if @p dev is invalid
* @return -ENOTSUP if @p opt is not supported
* @return -EOVERFLOW if available space in @p value given in
* @p value_len is too small to store the option value
* @p max_len is too small to store the option value
* @return -ECANCELED if internal driver error occurred
*/
int (*get)(ng_netdev_t *dev, ng_netconf_opt_t opt,
void *value, size_t *value_len);
void *value, size_t max_len);
/**
* @brief Set an option value for a given network device
......@@ -135,10 +135,11 @@ typedef struct {
* @param[in] value value to set
* @param[in] value_len the length of @p value
*
* @return 0 on success
* @return number of bytes used from @p value
* @return -ENODEV if @p dev is invalid
* @return -ENOTSUP if @p opt is not supported
* @return -EINVAL if @p value is invalid
* @return -ECANCELED if internal driver error occurred
*/
int (*set)(ng_netdev_t *dev, ng_netconf_opt_t opt,
void *value, size_t value_len);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment