Skip to content
Commit e37e2ff3 authored by Andy Lutomirski's avatar Andy Lutomirski Committed by David S. Miller
Browse files

virtio-net: Fix DMA-from-the-stack in virtnet_set_mac_address()



With CONFIG_VMAP_STACK=y, virtnet_set_mac_address() can be passed a
pointer to the stack and it will OOPS.  Copy the address to the heap
to prevent the crash.

Cc: Michael S. Tsirkin <mst@redhat.com>
Cc: Jason Wang <jasowang@redhat.com>
Cc: Laura Abbott <labbott@redhat.com>
Reported-by: default avatar <zbyszek@in.waw.pl>
Signed-off-by: default avatarAndy Lutomirski <luto@kernel.org>
Acked-by: default avatarJason Wang <jasowang@redhat.com>
Acked-by: default avatarMichael S. Tsirkin <mst@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent dcb17d22
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment