mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-12 16:19:53 +00:00
pktgen: correct uninitialized queue_map
This fix a bug reported by backyes. Right the first time pktgen's using queue_map that's not been initialized by set_cur_queue_map(pkt_dev); Signed-off-by: Junchang Wang <junchangwang@gmail.com> Signed-off-by: Backyes <backyes@mail.ustc.edu.cn> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
18543a643f
commit
eb589063ed
@ -2612,8 +2612,8 @@ static struct sk_buff *fill_packet_ipv4(struct net_device *odev,
|
|||||||
/* Update any of the values, used when we're incrementing various
|
/* Update any of the values, used when we're incrementing various
|
||||||
* fields.
|
* fields.
|
||||||
*/
|
*/
|
||||||
queue_map = pkt_dev->cur_queue_map;
|
|
||||||
mod_cur_headers(pkt_dev);
|
mod_cur_headers(pkt_dev);
|
||||||
|
queue_map = pkt_dev->cur_queue_map;
|
||||||
|
|
||||||
datalen = (odev->hard_header_len + 16) & ~0xf;
|
datalen = (odev->hard_header_len + 16) & ~0xf;
|
||||||
|
|
||||||
@ -2976,8 +2976,8 @@ static struct sk_buff *fill_packet_ipv6(struct net_device *odev,
|
|||||||
/* Update any of the values, used when we're incrementing various
|
/* Update any of the values, used when we're incrementing various
|
||||||
* fields.
|
* fields.
|
||||||
*/
|
*/
|
||||||
queue_map = pkt_dev->cur_queue_map;
|
|
||||||
mod_cur_headers(pkt_dev);
|
mod_cur_headers(pkt_dev);
|
||||||
|
queue_map = pkt_dev->cur_queue_map;
|
||||||
|
|
||||||
skb = __netdev_alloc_skb(odev,
|
skb = __netdev_alloc_skb(odev,
|
||||||
pkt_dev->cur_pkt_size + 64
|
pkt_dev->cur_pkt_size + 64
|
||||||
|
Loading…
x
Reference in New Issue
Block a user