Skip to content
Snippets Groups Projects
Commit 77cf3a68 authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Gerd Hoffmann
Browse files

drm/virtio: Use struct_size() helper in kmalloc()


Make use of the struct_size() helper instead of an open-coded version
in order to avoid any potential type mistakes.

This code was detected with the help of Coccinelle and, audited and
fixed manually.

Signed-off-by: default avatarGustavo A. R. Silva <gustavoars@kernel.org>
Link: http://patchwork.freedesktop.org/patch/msgid/20200617215707.GA16785@embeddedor


Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
parent 66c8ef90
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment