| Date | Thu, 28 Feb 2013 11:08:51 +0000 | From | "Jan Beulich" <> | Subject | Re: [Xen-devel] [PATCH RFC 10/12] xen-blkback: make the queue of free requests per backend |
| |
>>> On 28.02.13 at 11:28, Roger Pau Monne <roger.pau@citrix.com> wrote: > @@ -122,6 +125,19 @@ static struct xen_blkif *xen_blkif_alloc(domid_t domid) > spin_lock_init(&blkif->free_pages_lock); > INIT_LIST_HEAD(&blkif->free_pages); > blkif->free_pages_num = 0; > + blkif->pending_reqs = kzalloc(sizeof(blkif->pending_reqs[0]) * > + xen_blkif_reqs, GFP_KERNEL);
kcalloc() is preferred in cases like this, I believe.
Jan
|