]> git.baikalelectronics.ru Git - kernel.git/commit
xen/gntdev: reduce copy batch size to 16
authorDavid Vrabel <david.vrabel@citrix.com>
Mon, 9 May 2016 09:59:48 +0000 (10:59 +0100)
committerDavid Vrabel <david.vrabel@citrix.com>
Tue, 24 May 2016 11:58:17 +0000 (12:58 +0100)
commitd2f64f4582bd10d095bf4d53464109ce4858f10f
tree16cc6a9a504a130ffe9e3ab4926e19db7db38e68
parent19bb207b00f33eb3427e546aac26ffe548e0c406
xen/gntdev: reduce copy batch size to 16

IOCTL_GNTDEV_GRANT_COPY batches copy operations to reduce the number
of hypercalls.  The stack is used to avoid a memory allocation in a
hot path. However, a batch size of 24 requires more than 1024 bytes of
stack which in some configurations causes a compiler warning.

    xen/gntdev.c: In function ‘gntdev_ioctl_grant_copy’:
    xen/gntdev.c:949:1: warning: the frame size of 1248 bytes is
    larger than 1024 bytes [-Wframe-larger-than=]

This is a harmless warning as there is still plenty of stack spare,
but people keep trying to "fix" it.  Reduce the batch size to 16 to
reduce stack usage to less than 1024 bytes.  This should have minimal
impact on performance.

Signed-off-by: David Vrabel <david.vrabel@citrix.com>
drivers/xen/gntdev.c