Re: [B.A.T.M.A.N.] [RFC 12/23] batman-adv: add base throughput attribute

Andrew Lunn
2014-02-13T09:57:36Z

> I just checked what we do in the "improved GW bandwidth advertisement"
> introduced not so much time ago:
>
> - we store the bandwidth value in Mbps/10
> - we print it in the form XX.YMbps
> + but we allow the user to specify the unit when entering the value in
> the sysfs interface: "xxxMbps" or "yyyKbps".
>
> This way the user can pick the favourite unit, but of course the value
> is truncated (in the case of Kbps) to fit the internal representation.
>
> What do you think about this approach?

I think that is good.

Thanks
Andrew