Re: [PATCH] net: wan: framer: Add missing static inline qualifiers

From: Andy Shevchenko
Date: Mon Mar 25 2024 - 09:54:19 EST


On Mon, Mar 25, 2024 at 09:25:05AM +0100, Herve Codina wrote:
> Compilation with CONFIG_GENERIC_FRAMER disabled lead to the following
> warnings:
> framer.h:184:16: warning: no previous prototype for function 'framer_get' [-Wmissing-prototypes]
> 184 | struct framer *framer_get(struct device *dev, const char *con_id)
> framer.h:184:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> 184 | struct framer *framer_get(struct device *dev, const char *con_id)
> framer.h:189:6: warning: no previous prototype for function 'framer_put' [-Wmissing-prototypes]
> 189 | void framer_put(struct device *dev, struct framer *framer)
> framer.h:189:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> 189 | void framer_put(struct device *dev, struct framer *framer)

Always try to minimize the warnings/backtraces/etc to the point. In this case
it's enough to have:

warning: no previous prototype for function 'framer_get' [-Wmissing-prototypes]
warning: no previous prototype for function 'framer_put' [-Wmissing-prototypes]

> Add missing 'static inline' qualifiers for these functions.

Code wise looks good,
Reviewed-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>

--
With Best Regards,
Andy Shevchenko