Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
9p: ensure logical size fits allocated size
all buffers used to be msize big, but the size can now vary based on message type and arguments. Adjut p9_check_error() to check the logical size (request payload) fits within the allocated size (capacity) rather than msize. Note that for zc rpc, the capacity doesn't match the actual allowed size, we need to add 'inlen' on top... Except transports can adjust it slightly to fit hardware needs... So this doesn't really make sense. Transports normally all check this when the packet is being read, but might as well stay coherent. Also log allocated size in prepare req. Link: https://lkml.kernel.org/r/20221118135542.63400-2-asmadeus@codewreck.org Fixes: 60ece08 ("net/9p: allocate appropriate reduced message buffers") Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
- Loading branch information