Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[linux-drm-fsl-dcu.git] / drivers / infiniband / hw / ehca / ehca_pd.c
index 2c3cdc6f7b39ef5982876bf5dfae77108d374888..79d0591a80431eb487fad97590f1ecfa83f531b1 100644 (file)
@@ -50,14 +50,13 @@ struct ib_pd *ehca_alloc_pd(struct ib_device *device,
 {
        struct ehca_pd *pd;
 
-       pd = kmem_cache_alloc(pd_cache, SLAB_KERNEL);
+       pd = kmem_cache_zalloc(pd_cache, GFP_KERNEL);
        if (!pd) {
                ehca_err(device, "device=%p context=%p out of memory",
                         device, context);
                return ERR_PTR(-ENOMEM);
        }
 
-       memset(pd, 0, sizeof(struct ehca_pd));
        pd->ownpid = current->tgid;
 
        /*