diff options
author | Mi Jinlong <mijinlong@cn.fujitsu.com> | 2011-08-28 18:18:56 +0800 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2011-09-16 10:31:01 -0400 |
commit | 58e7b33a58d0cd07c9294d5161553b204c75662d (patch) | |
tree | 270c778b51d482789aa9b9b982bfa796c1c34992 /kernel | |
parent | 038c01598e728cda5b2996c4bf883e8485b2fe50 (diff) | |
download | blackbird-op-linux-58e7b33a58d0cd07c9294d5161553b204c75662d.tar.gz blackbird-op-linux-58e7b33a58d0cd07c9294d5161553b204c75662d.zip |
nfsd41: try to check reply size before operation
For checking the size of reply before calling a operation,
we need try to get maxsize of the operation's reply.
v3: using new method as Bruce said,
"we could handle operations in two different ways:
- For operations that actually change something (write, rename,
open, close, ...), do it the way we're doing it now: be
very careful to estimate the size of the response before even
processing the operation.
- For operations that don't change anything (read, getattr, ...)
just go ahead and do the operation. If you realize after the
fact that the response is too large, then return the error at
that point.
So we'd add another flag to op_flags: say, OP_MODIFIES_SOMETHING. And for
operations with OP_MODIFIES_SOMETHING set, we'd do the first thing. For
operations without it set, we'd do the second."
Signed-off-by: Mi Jinlong <mijinlong@cn.fujitsu.com>
[bfields@redhat.com: crash, don't attempt to handle, undefined op_rsize_bop]
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions