[ofa-general] [PATCH RFC] libibumad: give up cpu time slice if write() falied
Sean Hefty
sean.hefty at intel.com
Thu Jan 29 09:32:27 PST 2009
>Signed-off-by: Yevgeny Kliteynik <kliteyn at dev.mellanox.co.il>
>---
> libibumad/src/umad.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
>diff --git a/libibumad/src/umad.c b/libibumad/src/umad.c
>index 78b956d..a03a018 100644
>--- a/libibumad/src/umad.c
>+++ b/libibumad/src/umad.c
>@@ -814,6 +814,8 @@ umad_send(int fd, int agentid, void *umad, int length,
>
> DEBUG("write returned %d != sizeof umad %zu + length %d (%m)",
> n, umad_size(), length);
>+
>+ usleep(20000);
> if (!errno)
> errno = EIO;
> return -EIO;
I think this should be handled by the application, and not placed into the
lowest level library.
- Sean
More information about the general
mailing list