Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
can: isotp: restore accidentally removed MSG_PEEK feature
stable inclusion from stable-v5.10.110 commit 90ec1b1538d4d5e9f0267ca16d30606b4701da50 bugzilla: https://gitee.com/openeuler/kernel/issues/I574AL Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=90ec1b1538d4d5e9f0267ca16d30606b4701da50 -------------------------------- [ Upstream commit e382fea ] In commit 42bf50a ("can: isotp: support MSG_TRUNC flag when reading from socket") a new check for recvmsg flags has been introduced that only checked for the flags that are handled in isotp_recvmsg() itself. This accidentally removed the MSG_PEEK feature flag which is processed later in the call chain in __skb_try_recv_from_queue(). Add MSG_PEEK to the set of valid flags to restore the feature. Fixes: 42bf50a ("can: isotp: support MSG_TRUNC flag when reading from socket") Link: linux-can/can-utils#347 (comment) Link: https://lore.kernel.org/all/[email protected] Reported-by: Derek Will <[email protected]> Suggested-by: Derek Will <[email protected]> Tested-by: Derek Will <[email protected]> Signed-off-by: Oliver Hartkopp <[email protected]> Signed-off-by: Marc Kleine-Budde <[email protected]> Signed-off-by: Sasha Levin <[email protected]> Signed-off-by: Yu Liao <[email protected]> Reviewed-by: Wei Li <[email protected]> Signed-off-by: Zheng Zengkai <[email protected]>
- Loading branch information