> WARN_ON is used where the function has no way to signal errors to the
> caller.

There isn't really much point in that - failing allocations are already
*very* noisy. Please respin with that removed (and then I guess you can
fix the Fixes: too)

You didn't actually do that in this patch though :-)

johannes

> +     bool filled;
>       int ret;
>  
>       /* if the user specified a customised value for this interface, then
> @@ -102,7 +103,17 @@ static u32 batadv_v_elp_get_throughput(struct 
> batadv_hardif_neigh_node *neigh)
>               if (!real_netdev)
>                       goto default_throughput;
>  
> -             ret = cfg80211_get_station(real_netdev, neigh->addr, &sinfo);
> +             sinfo = kzalloc(sizeof(*sinfo), GFP_KERNEL);
> +             if (!sinfo)
> +                     goto default_throughput;
> +
> +             ret = cfg80211_get_station(real_netdev, neigh->addr, sinfo);
> +
> +             /* just save these here instead of having complex free logic 
> below */
> +             throughput = sinfo.expected_throughput / 100;
> +             filled = !!(sinfo.filled & 
> BIT(NL80211_STA_INFO_EXPECTED_THROUGHPUT));

It's bool so you don't need the !!(...) :-)

johannes

Reply via email to