Skip to content

Commit

Permalink
drivers: counter: Fix compilation warning due to deprecated typedef
Browse files Browse the repository at this point in the history
Counter test compiles with warnings even though
deprecated typedef is not used. It is enough that
it is used in another function which is also
deprecated. Removed __deprecated keyword from
typedef, keeping it only for the function.

Signed-off-by: Krzysztof Chruscinski <[email protected]>
  • Loading branch information
nordic-krch committed Nov 29, 2018
1 parent b2fb3cd commit c78e4a1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions include/counter.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,6 @@ struct counter_alarm_cfg {
*/
typedef void (*counter_wrap_callback_t)(struct device *dev, void *user_data);

__deprecated typedef void (*counter_callback_t)(struct device *dev,
void *user_data);

/** @brief Structure with generic counter features.
*
* @param max_wrap Maximal (default) wrap value on which counter is reset
Expand Down Expand Up @@ -377,6 +374,10 @@ static inline u32_t _impl_counter_get_max_relative_alarm(struct device *dev)
return api->get_max_relative_alarm(dev);
}

/* Deprecated counter callback. */
typedef void (*counter_callback_t)(struct device *dev,
void *user_data);

/**
* @brief Deprecated function.
*/
Expand Down

0 comments on commit c78e4a1

Please sign in to comment.