[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TC calling sequence timing



Hi all again,
Well I didn't have time to test the patch yet, I will do propably until next week, but
as I understand it is based on  polling  (while(qdisc_restart instead of if
(qdisc_restart...)) so it will add extra overhead to the system and worst response
times to other tasks, in way that cannot be excepted for any official linux kernel. Is
this right or I have misunderstood the program?
Thanks!
Panagiotis

kuznet@ms2.inr.ac.ru wrote:

> Hello!
>
> OK, I found those your mails.
>
> > tc qdisc add dev $DEV handle 1:0 root tbf rate 80Kbps buffer 3Kb limit 40Kb
> > DEV=atm0 or eth0 (it has been tested with both)
>
> In this case maximal timeout cannot be more than ~40msec.
> If it is greater, it is bug.
>
> EOI has nothing to do with this, it cannot decrease burstiness,
> burst size is controlled by and only by "burst" (=buffer).
>
> Alexey
>
> PS, try the following unofficial patch.
>
> diff -ur ../vger-000131/linux/include/net/pkt_sched.h linux/include/net/pkt_sched.h
> --- ../vger-000131/linux/include/net/pkt_sched.h        Sat May  1 16:28:20 1999
> +++ linux/include/net/pkt_sched.h       Mon Jan 31 22:29:12 2000
> @@ -387,7 +387,7 @@
>  void qdisc_run_queues(void);
>  int qdisc_restart(struct device *dev);
>
> -extern __inline__ void qdisc_wakeup(struct device *dev)
> +extern __inline__ void qdisc_wakeup_one(struct device *dev)
>  {
>         if (!dev->tbusy) {
>                 struct Qdisc *q = dev->qdisc;
> @@ -397,6 +397,23 @@
>                 }
>         }
>  }
> +
> +extern __inline__ void qdisc_wakeup(struct device *dev)
> +{
> +       if (!dev->tbusy) {
> +               struct Qdisc *q = dev->qdisc;
> +               int res;
> +
> +               while ((res = qdisc_restart(dev)) < 0 && !dev->tbusy)
> +                       /* NOTHING */;
> +
> +               if (res && q->h.forw == NULL) {
> +                       q->h.forw = qdisc_head.forw;
> +                       qdisc_head.forw = &q->h;
> +               }
> +       }
> +}
> +
>
>  extern __inline__ unsigned psched_mtu(struct device *dev)
>  {

--
-----------------------------------------------------
Panagiotis G.Stathopoulos
National Technical University of Athens
Telecommunications Laboratory
E-mail: pstath@telecom.ntua.gr
Tel: +30 1 772 1479     Fax: +30 1 772 2534
------------------------------------------------------