[Codel] [Bloat] better tc support for bittorrent/diffserv

Eric Dumazet eric.dumazet at gmail.com
Mon May 14 14:31:47 EDT 2012


On Mon, 2012-05-14 at 20:24 +0200, Juliusz Chroboczek wrote:
> > There is an API to set ECN on UDP packets.
> >
> > setsockopt() IP_TOS, with val = 2
> 
> Interesting, I didn't realise that.  Is it also possible to read the ECN
> bits?


Yep

man 7 ip

     IP_RECVTOS (since Linux 2.2)
       If enabled the IP_TOS ancillary message is passed with incoming packets.
      It contains a byte which specifies the Type of Service/Precedence field
      of the packet header.  Expects a boolean integer flag.






More information about the Codel mailing list