libibumad: update umad_recv man page.
PATCH v2 1/1 libibumad: update umad_recv man page.
Document the umad_recv length parameter better.
Changes since V1:
add comments from Hal
--- man/umad_recv.3 | 18 +++++++++++++++++- 1 files changed, 17 insertions(+), 1 deletions(-)
man/umad_recv.3 +17 -1
@@ -27,10 +27,26 @@ A negative makes the function block until a packet is received. A .I timeout_ms\fR parameter of zero indicates a non blocking read. + +.B Note +.I length +is a pointer to the length of the +.B data +portion of the umad buffer. This means that +.I umad +should point to a buffer at least umad_size() + +.I *length +bytes long. + +.B Note also +that +.I *length\fR +must be >= 256 bytes. + .SH "RETURN VALUE" .B umad_recv() returns non negative receiving agentid on success, and a negative value on error as follows: - -EINVAL invalid port handle or agentid + -EINVAL invalid port handle or agentid or *length is less than the minimum -EIO receive operation failed -EWOULDBLOCK non blocking read can't be fulfilled .SH "SEE ALSO"
Signature · 6 lines
1.7.1 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 24 lines · Ira Weiny
Document the
umad_recvlength parameter better.Changes since V1:
add comments from HalSigned-off-by Ira Weiny <[email protected]>--- man/umad_recv.3 | 18 +++++++++++++++++- 1 files changed, 17 insertions(+), 1 deletions(-)man/umad_recv.3 +5
-0@@ -27,10 +27,26 @@ A negative makes the function block until a packet is received. A .I timeout_ms\fR parameter of zero indicates a non blocking read. + +.B Note +.I length +is a pointer to the length of the +.B data
man/umad_recv.3 A negative · line 44
Quoted 10 lines
man/umad_recv.3 +10
-0+portion of the umad buffer. This means that +.I umad +should point to a buffer at least umad_size() + +.I *length +bytes long. + +.B Note also +that +.I *length\fR +must be >= 256 bytes.
This seems somewhat redundant to me as just above it says "should point to a bugger that's at least umad_size() + *length bytes long.
Also, if this remains, should "must be" be "should be" ?
man/umad_recv.3 A negative · line 49
Quoted 6 lines
man/umad_recv.3 +2
-1+ .SH "RETURN VALUE" .B umad_recv() returns non negative receiving agentid on success, and a negative value on error as follows: - -EINVAL invalid port handle or agentid + -EINVAL invalid port handle or agentid or *length is less than the minimum
Rather than just minimum, minimum support length might be clearer.
-- Hal
man/umad_recv.3 A negative · line 52
Quoted 3 lines
man/umad_recv.3 +0
-0-EIO receive operation failed -EWOULDBLOCK non blocking read can't be fulfilled .SH "SEE ALSO"
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 4FF72FB0.6020202-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org
Quoted 39 lines · On Fri, 06 Jul 2012 14:34:24 -0400 Hal Rosenstock…
Quoted 24 lines · Ira Weiny
Document the
umad_recvlength parameter better.Changes since V1:
add comments from HalSigned-off-by Ira Weiny <[email protected]>--- man/umad_recv.3 | 18 +++++++++++++++++- 1 files changed, 17 insertions(+), 1 deletions(-)man/umad_recv.3 +5
-0@@ -27,10 +27,26 @@ A negative makes the function block until a packet is received. A .I timeout_ms\fR parameter of zero indicates a non blocking read. + +.B Note +.I length +is a pointer to the length of the +.B dataman/umad_recv.3 A negative · line 44
Quoted 10 lines
man/umad_recv.3 +10
-0+portion of the umad buffer. This means that +.I umad +should point to a buffer at least umad_size() + +.I *length +bytes long. + +.B Note also +that +.I *length\fR +must be >= 256 bytes.This seems somewhat redundant to me as just above it says "should point to a bugger that's at least
umad_size()+ *length bytes long.
Quoted 1 line
Also, if this remains, should "must be" be "should be" ?
I _guess_ it _could_ be less than 256. However the specification states:
"C13-3: The data payload (as used in Chapter 9: Transport Layer on page 233) for all MADs shall be exactly 256 bytes."
Furthermore, the kernel checks to ensure that *length is > the first (or only) packet in the MAD transaction. While some Class/Attributes may allow for less "valid" data I'm not sure the kernel distinguishes that. Therefore, I think it is safer to just specify it. Don't you think?
Ira
Quoted 16 lines
man/umad_recv.3 A negative · line 49
Quoted 7 lines
man/umad_recv.3 +2
-1+ .SH "RETURN VALUE" .B umad_recv() returns non negative receiving agentid on success, and a negative value on error as follows: - -EINVAL invalid port handle or agentid + -EINVAL invalid port handle or agentid or *length is less than the minimumRather than just minimum, minimum support length might be clearer.
-- Hal
Quoted 3 lines
man/umad_recv.3 +0
-0-EIO receive operation failed -EWOULDBLOCK non blocking read can't be fulfilled .SH "SEE ALSO"
Signature · 9 lines
Ira Weiny Member of Technical Staff Lawrence Livermore National Lab 925-423-8008 [email protected] -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20120706122408.2540ea8dd74f94dcadd3fce1-i2BcT+NCU+M@public.gmane.org
Quoted 42 lines · Ira Weiny
Quoted 39 lines · On Fri, 06 Jul 2012 14:34:24 -0400 Hal Rosenstock…
Quoted 24 lines · Ira Weiny
Document the
umad_recvlength parameter better.Changes since V1:
add comments from HalSigned-off-by Ira Weiny <[email protected]>--- man/umad_recv.3 | 18 +++++++++++++++++- 1 files changed, 17 insertions(+), 1 deletions(-)man/umad_recv.3 +5
-0@@ -27,10 +27,26 @@ A negative makes the function block until a packet is received. A .I timeout_ms\fR parameter of zero indicates a non blocking read. + +.B Note +.I length +is a pointer to the length of the +.B dataman/umad_recv.3 A negative · line 44
Quoted 10 lines
man/umad_recv.3 +10
-0+portion of the umad buffer. This means that +.I umad +should point to a buffer at least umad_size() + +.I *length +bytes long. + +.B Note also +that +.I *length\fR +must be >= 256 bytes.This seems somewhat redundant to me as just above it says "should point to a bugger that's at least
umad_size()+ *length bytes long.
Quoted 3 lines
Quoted 1 line
Also, if this remains, should "must be" be "should be" ?
I _guess_ it _could_ be less than 256.
My only point here is that if it's less than 256 + header, then the error is returned (and nothing useful can be done). To me, that makes it a should rather than a must but just make the two lines consistent. Roland does have this as a must in user_mad.txt kernel doc:
"The buffer passed to read() must be at least one struct ib_user_mad + 256 bytes."
-- Hal
Quoted 26 lines
However the specification states:
"C13-3: The data payload (as used in Chapter 9: Transport Layer on page 233) for all MADs shall be exactly 256 bytes."
Furthermore, the kernel checks to ensure that *length is > the first (or only) packet in the MAD transaction. While some Class/Attributes may allow for less "valid" data I'm not sure the kernel distinguishes that. Therefore, I think it is safer to just specify it. Don't you think?
Ira
Quoted 16 lines
man/umad_recv.3 A negative · line 49
Quoted 7 lines
man/umad_recv.3 +2
-1+ .SH "RETURN VALUE" .B umad_recv() returns non negative receiving agentid on success, and a negative value on error as follows: - -EINVAL invalid port handle or agentid + -EINVAL invalid port handle or agentid or *length is less than the minimumRather than just minimum, minimum support length might be clearer.
-- Hal
Quoted 3 lines
man/umad_recv.3 +0
-0-EIO receive operation failed -EWOULDBLOCK non blocking read can't be fulfilled .SH "SEE ALSO"
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 4FF73D63.9010704-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org
Quoted 16 lines · On Fri, 06 Jul 2012 15:32:51 -0400 Hal Rosenstock…
Quoted 15 lines · Ira Weiny
Quoted 12 lines · On Fri, 06 Jul 2012 14:34:24 -0400 Hal Rosenstock…
Quoted 11 lines · Ira Weiny
Document the
umad_recvlength parameter better.Changes since V1:
add comments from HalSigned-off-by Ira Weiny <[email protected]>--- man/umad_recv.3 | 18 +++++++++++++++++- 1 files changed, 17 insertions(+), 1 deletions(-)
Quoted 16 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
man/umad_recv.3 +0
-0@@ -27,10 +27,26 @@ A negative makes the function block until a packet is received. A .I timeout_ms\fR parameter of zero indicates a non blocking read.Quoted 8 lines
Quoted 8 lines
man/umad_recv.3 A negative · line 37
Quoted 8 lines
man/umad_recv.3 +8
-0+ +.B Note +.I length +is a pointer to the length of the +.B data +portion of the umad buffer. This means that +.I umad +should point to a buffer at least umad_size() +
^^^^^^
mustOh, You mean must here?
Ira
Quoted 55 lines
Quoted 11 lines
Quoted 11 lines
man/umad_recv.3 A negative · line 44
Quoted 7 lines
man/umad_recv.3 +7
-0+.I *length +bytes long. + +.B Note also +that +.I *length\fR +must be >= 256 bytes.This seems somewhat redundant to me as just above it says "should point to a bugger that's at least
umad_size()+ *length bytes long.Quoted 3 lines
Quoted 1 line
Also, if this remains, should "must be" be "should be" ?
I _guess_ it _could_ be less than 256.
My only point here is that if it's less than 256 + header, then the error is returned (and nothing useful can be done). To me, that makes it a should rather than a must but just make the two lines consistent. Roland does have this as a must in user_mad.txt kernel doc:
"The buffer passed toread()must be at least one structib_user_mad+ 256 bytes."-- Hal
Quoted 26 lines
However the specification states:
"C13-3: The data payload (as used in Chapter 9: Transport Layer on page 233) for all MADs shall be exactly 256 bytes."
Furthermore, the kernel checks to ensure that *length is > the first (or only) packet in the MAD transaction. While some Class/Attributes may allow for less "valid" data I'm not sure the kernel distinguishes that. Therefore, I think it is safer to just specify it. Don't you think?
Ira
Quoted 16 lines
man/umad_recv.3 A negative · line 49
Quoted 7 lines
man/umad_recv.3 +2
-1+ .SH "RETURN VALUE" .B umad_recv() returns non negative receiving agentid on success, and a negative value on error as follows: - -EINVAL invalid port handle or agentid + -EINVAL invalid port handle or agentid or *length is less than the minimumRather than just minimum, minimum support length might be clearer.
-- Hal
Quoted 3 lines
man/umad_recv.3 +0
-0-EIO receive operation failed -EWOULDBLOCK non blocking read can't be fulfilled .SH "SEE ALSO"--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 9 lines
Ira Weiny Member of Technical Staff Lawrence Livermore National Lab 925-423-8008 [email protected] -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20120706123804.d3d836b998988a2cc5be0ca5-i2BcT+NCU+M@public.gmane.org
Quoted 38 lines · Ira Weiny
Quoted 16 lines · On Fri, 06 Jul 2012 15:32:51 -0400 Hal Rosenstock…
Quoted 15 lines · Ira Weiny
Quoted 12 lines · On Fri, 06 Jul 2012 14:34:24 -0400 Hal Rosenstock…
Quoted 11 lines · Ira Weiny
Document the
umad_recvlength parameter better.Changes since V1:
add comments from HalSigned-off-by Ira Weiny <[email protected]>--- man/umad_recv.3 | 18 +++++++++++++++++- 1 files changed, 17 insertions(+), 1 deletions(-)Quoted 16 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
man/umad_recv.3 +0
-0@@ -27,10 +27,26 @@ A negative makes the function block until a packet is received. A .I timeout_ms\fR parameter of zero indicates a non blocking read.Quoted 8 lines
Quoted 8 lines
man/umad_recv.3 A negative · line 37
Quoted 8 lines
man/umad_recv.3 +8
-0+ +.B Note +.I length +is a pointer to the length of the +.B data +portion of the umad buffer. This means that +.I umad +should point to a buffer at least umad_size() +^^^^^^ must
Quoted 1 line
Oh, You mean must here?
Yes, if that's the direction you choose (must rather than should).
-- Hal
Quoted 60 lines
Ira
Quoted 55 lines
Quoted 11 lines
Quoted 11 lines
man/umad_recv.3 A negative · line 44
Quoted 7 lines
man/umad_recv.3 +7
-0+.I *length +bytes long. + +.B Note also +that +.I *length\fR +must be >= 256 bytes.This seems somewhat redundant to me as just above it says "should point to a bugger that's at least
umad_size()+ *length bytes long.Quoted 3 lines
Quoted 1 line
Also, if this remains, should "must be" be "should be" ?
I _guess_ it _could_ be less than 256.
My only point here is that if it's less than 256 + header, then the error is returned (and nothing useful can be done). To me, that makes it a should rather than a must but just make the two lines consistent. Roland does have this as a must in user_mad.txt kernel doc:
"The buffer passed toread()must be at least one structib_user_mad+ 256 bytes."-- Hal
Quoted 26 lines
However the specification states:
"C13-3: The data payload (as used in Chapter 9: Transport Layer on page 233) for all MADs shall be exactly 256 bytes."
Furthermore, the kernel checks to ensure that *length is > the first (or only) packet in the MAD transaction. While some Class/Attributes may allow for less "valid" data I'm not sure the kernel distinguishes that. Therefore, I think it is safer to just specify it. Don't you think?
Ira
Quoted 16 lines
man/umad_recv.3 A negative · line 49
Quoted 7 lines
man/umad_recv.3 +2
-1+ .SH "RETURN VALUE" .B umad_recv() returns non negative receiving agentid on success, and a negative value on error as follows: - -EINVAL invalid port handle or agentid + -EINVAL invalid port handle or agentid or *length is less than the minimumRather than just minimum, minimum support length might be clearer.
-- Hal
Quoted 3 lines
man/umad_recv.3 +0
-0-EIO receive operation failed -EWOULDBLOCK non blocking read can't be fulfilled .SH "SEE ALSO"--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html