sch_netem.c (f30ab418a1d3c5a8b83493e7d70d6876a74aa0ce) | sch_netem.c (b94c8afcba3ae6584653b98e315446ea83be6ea5) |
---|---|
1/* 2 * net/sched/sch_netem.c Network emulator 3 * 4 * This program is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU General Public License 6 * as published by the Free Software Foundation; either version 7 * 2 of the License. 8 * --- 317 unchanged lines hidden (view full) --- 326 327 d->size = n; 328 for (i = 0; i < n; i++) 329 d->table[i] = data[i]; 330 331 root_lock = qdisc_root_sleeping_lock(sch); 332 333 spin_lock_bh(root_lock); | 1/* 2 * net/sched/sch_netem.c Network emulator 3 * 4 * This program is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU General Public License 6 * as published by the Free Software Foundation; either version 7 * 2 of the License. 8 * --- 317 unchanged lines hidden (view full) --- 326 327 d->size = n; 328 for (i = 0; i < n; i++) 329 d->table[i] = data[i]; 330 331 root_lock = qdisc_root_sleeping_lock(sch); 332 333 spin_lock_bh(root_lock); |
334 d = xchg(&q->delay_dist, d); | 334 kfree(q->delay_dist); 335 q->delay_dist = d; |
335 spin_unlock_bh(root_lock); | 336 spin_unlock_bh(root_lock); |
336 337 kfree(d); | |
338 return 0; 339} 340 341static void get_correlation(struct Qdisc *sch, const struct nlattr *attr) 342{ 343 struct netem_sched_data *q = qdisc_priv(sch); 344 const struct tc_netem_corr *c = nla_data(attr); 345 --- 284 unchanged lines hidden --- | 337 return 0; 338} 339 340static void get_correlation(struct Qdisc *sch, const struct nlattr *attr) 341{ 342 struct netem_sched_data *q = qdisc_priv(sch); 343 const struct tc_netem_corr *c = nla_data(attr); 344 --- 284 unchanged lines hidden --- |