With the memory registration restrictions of the eHCA coupled with our
applications which require large memory registrations, we've found that
we can quickly trigger a case where ibv_reg_mr() will return -EINVAL,
when it should be returning -ENOMEM. If we were able to differentiate
this type of error from the default -EINVAL, we would be able to handle
this in userspace by flushing cached entries and retrying the memory
registration.
I've attached a patch to start the process, if there are other paths
back to userspace that can return ENOMEM on a resource limitation we
should also add that.
thanks,
Kyle
--
Kyle Schochenmaier
[EMAIL PROTECTED]
Research Assistant, Dr. Brett Bode
AmesLab - US Dept.Energy
Scalable Computing Laboratory
--- infiniband/ofed_1_2/drivers/infiniband/hw/ehca/ehca_mrmw.c 2007-05-09 12:32:04.000000000 -0500
+++ ofed_1_2/ofed_1_2/drivers/infiniband/hw/ehca/ehca_mrmw.c 2007-05-09 12:59:37.000000000 -0500
@@ -2047,13 +2047,16 @@ int ehca_mrmw_map_hrc_alloc(const u64 hi
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_BUSY: /* long busy */
return -EBUSY;
+ case H_CONSTRAINED: /* resource constraint */
+ case H_NOT_ENOUGH_RESOURCES: /* insufficient resources */
+ return -ENOMEM;
+ case H_NO_MEM:
+ return -ENOMEM;
default:
return -EINVAL;
}
_______________________________________________
general mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general
To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general