Lines Matching refs:slave
142 static void eql_kill_one_slave(slave_queue_t *queue, slave_t *slave);
152 slave_t *slave = list_entry(this, slave_t, list); in eql_timer() local
154 if ((slave->dev->flags & IFF_UP) == IFF_UP) { in eql_timer()
155 slave->bytes_queued -= slave->priority_Bps; in eql_timer()
156 if (slave->bytes_queued < 0) in eql_timer()
157 slave->bytes_queued = 0; in eql_timer()
159 eql_kill_one_slave(&eql->queue, slave); in eql_timer()
223 static void eql_kill_one_slave(slave_queue_t *queue, slave_t *slave) in eql_kill_one_slave() argument
225 list_del(&slave->list); in eql_kill_one_slave()
227 slave->dev->flags &= ~IFF_SLAVE; in eql_kill_one_slave()
228 netdev_put(slave->dev, &slave->dev_tracker); in eql_kill_one_slave()
229 kfree(slave); in eql_kill_one_slave()
313 slave_t *slave = list_entry(this, slave_t, list); in __eql_schedule_slaves() local
319 bytes_queued = slave->bytes_queued; in __eql_schedule_slaves()
320 priority_Bps = slave->priority_Bps; in __eql_schedule_slaves()
321 if ((slave->dev->flags & IFF_UP) == IFF_UP) { in __eql_schedule_slaves()
327 best_slave = slave; in __eql_schedule_slaves()
331 eql_kill_one_slave(queue, slave); in __eql_schedule_slaves()
340 slave_t *slave; in eql_slave_xmit() local
344 slave = __eql_schedule_slaves(&eql->queue); in eql_slave_xmit()
345 if (slave) { in eql_slave_xmit()
346 struct net_device *slave_dev = slave->dev; in eql_slave_xmit()
350 slave->bytes_queued += skb->len; in eql_slave_xmit()
374 slave_t *slave = list_entry(this, slave_t, list); in __eql_find_slave_dev() local
376 if (slave->dev == dev) in __eql_find_slave_dev()
377 return slave; in __eql_find_slave_dev()
393 static int __eql_insert_slave(slave_queue_t *queue, slave_t *slave) in __eql_insert_slave() argument
398 duplicate_slave = __eql_find_slave_dev(queue, slave->dev); in __eql_insert_slave()
402 netdev_hold(slave->dev, &slave->dev_tracker, GFP_ATOMIC); in __eql_insert_slave()
403 list_add(&slave->list, &queue->all_slaves); in __eql_insert_slave()
405 slave->dev->flags |= IFF_SLAVE; in __eql_insert_slave()
471 slave_t *slave = __eql_find_slave_dev(&eql->queue, slave_dev); in eql_emancipate() local
472 if (slave) { in eql_emancipate()
473 eql_kill_one_slave(&eql->queue, slave); in eql_emancipate()
485 slave_t *slave; in eql_g_slave_cfg() local
501 slave = __eql_find_slave_dev(&eql->queue, slave_dev); in eql_g_slave_cfg()
502 if (slave) { in eql_g_slave_cfg()
503 sc.priority = slave->priority; in eql_g_slave_cfg()
517 slave_t *slave; in eql_s_slave_cfg() local
535 slave = __eql_find_slave_dev(&eql->queue, slave_dev); in eql_s_slave_cfg()
536 if (slave) { in eql_s_slave_cfg()
537 slave->priority = sc.priority; in eql_s_slave_cfg()
538 slave->priority_bps = sc.priority; in eql_s_slave_cfg()
539 slave->priority_Bps = sc.priority / 8; in eql_s_slave_cfg()