Dummynet AQM v0.1- CoDel and FQ-CoDel for FreeBSD's ipfw/dummynet

Don Lewis truckman at FreeBSD.org
Sun Mar 6 20:40:44 UTC 2016


On 26 Feb, Rasool Al-Saadi wrote:
> Dear all,
> 
> I would like to announce that we (myself and Grenville Armitage)
> released Dummynet AQM v0.1, which is an independent implementation of
> CoDel and FQ-CoDel for FreeBSD's ipfw/dummynet framework, based on the
> IETF  CoDel [1] and FQ-CoDel [2] Internet-Drafts. We prepared patches
> for FreeBSD11-CURRENT-r295345  and FreeBSD 10.x-RELEASE (10.0, 10.1,
> 10.2), and a technical report  of our implementation.
> 
> Patches and documentation can be found in:
> http://caia.swin.edu.au/freebsd/aqm

The FreeBSD 10 patch applies cleanly to FreeBSD 10.3-PRERELEASE, but the
build fails on i386:

/usr/src/sbin/ipfw/dummynet.c:166:5: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
                                ep->par[0],
                                ^~~~~~~~~~
/usr/src/sbin/ipfw/dummynet.c:167:5: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
                                ep->par[1] );
                                ^~~~~~~~~~
/usr/src/sbin/ipfw/dummynet.c:177:5: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
                                ep->par[0],
                                ^~~~~~~~~~
/usr/src/sbin/ipfw/dummynet.c:178:5: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
                                ep->par[1],
                                ^~~~~~~~~~
/usr/src/sbin/ipfw/dummynet.c:179:5: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
                                ep->par[3],
                                ^~~~~~~~~~
/usr/src/sbin/ipfw/dummynet.c:180:5: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
                                ep->par[4],
                                ^~~~~~~~~~
/usr/src/sbin/ipfw/dummynet.c:181:5: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
                                ep->par[5]
                                ^~~~~~~~~~


The proper fix for this on FreeBSD is to cast these values to intmax_t
and use the %jd printf format.



More information about the freebsd-net mailing list