Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Oct 2019 16:34:24 +0300
From:      Andriy Gapon <avg@FreeBSD.org>
To:        Luigi Rizzo <rizzo@iet.unipi.it>
Cc:        freebsd-net <freebsd-net@freebsd.org>
Subject:   Re: dummynet: bandwidth is limited to 2 Gbit/s ?
Message-ID:  <379cc8b6-7275-9b48-df36-547eb1470e84@FreeBSD.org>
In-Reply-To: <CA%2BhQ2%2BjXxwkVMMoLMMdXU5RVqsMxfbQfNazVKTp9rB9i6z%2BJ3A@mail.gmail.com>
References:  <a1c0ac18-1290-a109-1c46-c8d6047cd8c1@FreeBSD.org> <CA%2BhQ2%2BjXxwkVMMoLMMdXU5RVqsMxfbQfNazVKTp9rB9i6z%2BJ3A@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 25/09/2019 17:09, Luigi Rizzo wrote:
> As others have commented changing the ABI is a no-go.
> However the command structure can be extended:
> - define a new type, say DN_LINK64, and a new struct dn_link64 with a
> 64-bit bw field;
> - modify the kernel to accept the new type in addition to DN_LINK to
> set link speed,
>   and reply with DN_LINK64 for links whose bandwidth cannot be
> represented on 31 bits
>   (these must come from a userland that understands the new format, so
> it is reasonable
>   to reply to queries with those)
> - modify the ipfw libraries to, likewise, understand DN_LINK64 on
> queries, and issue
>   DN_LINK64 when bw requests do not fit on 31 bits (on failure).
> 
> An alternate, hack-ish approach would be to encode high speeds with
> coarse granularity,
> say speed 0x7fnnnnnn with n = 0.. 0xffffe representing speed in
> Mbits/s (so that would give
> you up to 16 Pbit/s) and reserve 0x7fffffff for the pre-existing
> "2Gbit/s - 1" to avoid breaking
> former userland that may pick that value.

Luigi, and everyone who commented,

thank you very much for your suggestions.
(Un)fortunately, my work decided to use a workaround rather than extending
dummynet, so I won't be working on that.  Sorry.

I am cross-referencing this thread with an oldish bug for the same issue, just
in case: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=194453

-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?379cc8b6-7275-9b48-df36-547eb1470e84>