Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=bd5a6ccc0e6d8eed3047b4af0e5c1e7168869cd8
Commit:     bd5a6ccc0e6d8eed3047b4af0e5c1e7168869cd8
Parent:     26bbf13ce1ca21ec69175bcc4b995cb8ffdf8593
Author:     Hoang-Nam Nguyen <[EMAIL PROTECTED]>
AuthorDate: Wed May 16 14:50:55 2007 +0200
Committer:  Roland Dreier <[EMAIL PROTECTED]>
CommitDate: Sat May 19 08:51:54 2007 -0700

    IB/ehca: Return proper error code if register_mr fails
    
    Set the return code of ehca_register_mr() to ENOMEM if the corresponding
    firmware call fails due to out of resources.  Some other error codes
    were explicitly mapped to EINVAL -- just remove those cases so they
    get mapped to the default case, which already returns EINVAL anyway.
    
    Signed-off-by: Hoang-Nam Nguyen <[EMAIL PROTECTED]>
    Signed-off-by: Roland Dreier <[EMAIL PROTECTED]>
---
 drivers/infiniband/hw/ehca/ehca_mrmw.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/drivers/infiniband/hw/ehca/ehca_mrmw.c 
b/drivers/infiniband/hw/ehca/ehca_mrmw.c
index 84c5bb4..add79bd 100644
--- a/drivers/infiniband/hw/ehca/ehca_mrmw.c
+++ b/drivers/infiniband/hw/ehca/ehca_mrmw.c
@@ -2050,13 +2050,10 @@ int ehca_mrmw_map_hrc_alloc(const u64 hipz_rc)
        switch (hipz_rc) {
        case H_SUCCESS:              /* successful completion */
                return 0;
-       case H_ADAPTER_PARM:         /* invalid adapter handle */
-       case H_RT_PARM:              /* invalid resource type */
        case H_NOT_ENOUGH_RESOURCES: /* insufficient resources */
-       case H_MLENGTH_PARM:         /* invalid memory length */
-       case H_MEM_ACCESS_PARM:      /* invalid access controls */
        case H_CONSTRAINED:          /* resource constraint */
-               return -EINVAL;
+       case H_NO_MEM:
+               return -ENOMEM;
        case H_BUSY:                 /* long busy */
                return -EBUSY;
        default:
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to