All of lore.kernel.org
 help / color / mirror / Atom feed
From: "lartc@manchotnetworks.net" <lartc@manchotnetworks.net>
To: lartc@vger.kernel.org
Subject: Re:  [LARTC] was tcng error; now found bug in tcc]
Date: Thu, 27 Nov 2003 18:16:34 +0000	[thread overview]
Message-ID: <marc-lartc-106995767813203@msgid-missing> (raw)

hi all,

after slicing and dicing, i found that i had cut and pasted bad syntax,
so i have solved the problem posted in my first message.

that said, i have found an issue in 9h and 9i of tcng running on a
bi-processor with redhat-8 up2date with 2.4.20 kernel.

here's a small tcng cfg:


#define DEVICE eth0
#define UPLINK 512 

dev DEVICE {
    egress {
        htb () {
            class (rate UPLINK kbps) {
            }
        }
    }
}

[root]# cat tc.bug | tcc
tc qdisc add dev eth0 handle 1:0 root dsmark indices 1 default_index 0
tc qdisc add dev eth0 handle 2:0 parent 1:0 htb
tc class add dev eth0 parent 2:0 classid 2:1 htb rate 64000bps
------------------------------------------------------^^^^^^^^

notice that the UPLINK of 512 kbps (arguably 524288 bps) has been
incorrectly calculated as 64000 bps

similarly, the following:

#define DEVICE eth0
#define UPLINK 64 

dev DEVICE {
    egress {
        htb () {
            class (rate UPLINK kBps) {
            }
        }
    }
}

[root]# cat tc.bug | tcc
tc qdisc add dev eth0 handle 1:0 root dsmark indices 1 default_index 0
tc qdisc add dev eth0 handle 2:0 parent 1:0 htb
tc class add dev eth0 parent 2:0 classid 2:1 htb rate 64000bps
------------------------------------------------------^^^^^^^^

if i express the UPLINK in kilobytes/s, then the rate has been
incorrectly multiplied by 1000 instead equaling 64 * 8 * 1024 = 524288


have i missed something, or indeed there is a problem??

many thanks

charles

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

             reply	other threads:[~2003-11-27 18:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-11-27 18:16 lartc [this message]
2003-11-28  7:45 ` [LARTC] was tcng error; now found bug in tcc lartc

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=marc-lartc-106995767813203@msgid-missing \
    --to=lartc@manchotnetworks.net \
    --cc=lartc@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.