Xen/gntdev: don't needlessly use kvcalloc()
authorJan Beulich <jbeulich@suse.com>
Wed, 10 Mar 2021 10:46:13 +0000 (11:46 +0100)
committerBoris Ostrovsky <boris.ostrovsky@oracle.com>
Wed, 10 Mar 2021 22:39:29 +0000 (16:39 -0600)
commitf1d20d8643e54dcde242fd2c8748063ed75702a8
treed30db68e7e948fcdeeae5f0fb503654c2d504a81
parentbce21a2b48ede7cbcab92db18bc956daf1d5c246
Xen/gntdev: don't needlessly use kvcalloc()

Requesting zeroed memory when all of it will be overwritten subsequently
by all ones is a waste of processing bandwidth. In fact, rather than
recording zeroed ->grants[], fill that array too with more appropriate
"invalid" indicators.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
Link: https://lore.kernel.org/r/9a726be2-4893-8ffe-0ef1-b70dd1c229b1@suse.com
Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
drivers/xen/gntdev.c