Pull acpica into release branch
[pandora-kernel.git] / drivers / infiniband / core / uverbs_mem.c
index ed550f6..efe147d 100644 (file)
@@ -1,6 +1,7 @@
 /*
  * Copyright (c) 2005 Topspin Communications.  All rights reserved.
  * Copyright (c) 2005 Cisco Systems.  All rights reserved.
+ * Copyright (c) 2005 Mellanox Technologies. All rights reserved.
  *
  * This software is available to you under a choice of one of two
  * licenses.  You may choose to be licensed under the terms of the GNU
@@ -210,8 +211,10 @@ void ib_umem_release_on_close(struct ib_device *dev, struct ib_umem *umem)
         */
 
        work = kmalloc(sizeof *work, GFP_KERNEL);
-       if (!work)
+       if (!work) {
+               mmput(mm);
                return;
+       }
 
        INIT_WORK(&work->work, ib_umem_account, work);
        work->mm   = mm;