>-----Original Message----- >From: Aravindhan Dhanasekaran [mailto:adha...@ncsu.edu] >Sent: Wednesday, October 15, 2014 8:15 PM >To: Zoltán Lajos Kis; openflow-discuss@lists.stanford.edu >Subject: Re: [openflow-discuss] Using queues in OpenFlow soft switch 13 > >On 10/12/2014 03:05 PM, Zoltán Lajos Kis wrote: >> Can you try changing the order of the queue and output actions, and also >using a simple apply instruction? >> Like this: >> sudo dpctl unix:/tmp/s1 flow-mod cmd=add,table=3 meta=0x6,in_port=2 >> apply:queue1,output=1 > >Actually, it works either way (queue, port and vice versa). > >It seems that my actual issue was due to the way ofss applies the ceil rate on >classes. The functions to setup qdiscs and classes seems to be scaling up the >ceil (and rate too) by 1000 of the given value. > >For example, in the function below, both rate and ceil are scaled up. >https://github.com/CPqD/ofsoftswitch13/blob/master/lib/netdev.c#L243 >static int >netdev_setup_root_class(const struct netdev *netdev, uint16_t class_id, > uint16_t rate) >{ > char command[1024]; > int actual_rate; > > /* we need to translate from .1% to kbps */ > actual_rate = rate*netdev->speed; > > snprintf(command, sizeof(command), COMMAND_ADD_CLASS, netdev- >>name, > TC_QDISC,0,TC_QDISC, class_id, actual_rate, netdev->speed*1000); > if (system(command) != 0) { > VLOG_ERR(LOG_MODULE, "Problem configuring root class %d for device >%s", > class_id, netdev->name); > return -1; > } > > return 0; >} > >The above function is called from netdev_setup_slicing() where the rate is >passed as 1000. >https://github.com/CPqD/ofsoftswitch13/blob/master/lib/netdev.c#L491 >... > error = netdev_setup_root_class(netdev, TC_ROOT_CLASS,1000); ... > >Can you please explain the comment on 0.1% to kbps?
In OpenFlow the rate field of the ofp_queue_prop_*_rate structures is defined as "the rate in 1/10 of a percent". I suppose the same semantics are used in the queue manipulation extensions. So 1000 means the maximum. BR, Zoltan > >Thanks, >/Aravind _______________________________________________ openflow-discuss mailing list openflow-discuss@lists.stanford.edu https://mailman.stanford.edu/mailman/listinfo/openflow-discuss