Skip to content
This repository was archived by the owner on Jun 1, 2026. It is now read-only.

net: add pskb_may_pull_reason() helper#7

Open
xyzhao2018 wants to merge 1 commit into
projectceladon:user/JeevakaPrabu/v6.1_a13from
xyzhao2018:add-net-patch-for-compile
Open

net: add pskb_may_pull_reason() helper#7
xyzhao2018 wants to merge 1 commit into
projectceladon:user/JeevakaPrabu/v6.1_a13from
xyzhao2018:add-net-patch-for-compile

Conversation

@xyzhao2018

Copy link
Copy Markdown

[ Upstream commit 1fb2d41 ]

pskb_may_pull() can fail for two different reasons.

Provide pskb_may_pull_reason() helper to distinguish between these reasons.

It returns:

SKB_NOT_DROPPED_YET : Success
SKB_DROP_REASON_PKT_TOO_SMALL : packet too small
SKB_DROP_REASON_NOMEM : skb->head could not be resized

Reviewed-by: David Ahern dsahern@kernel.org

Stable-dep-of: 8bd67ebb50c0 ("net: bridge: xmit: make sure we have at least eth header len bytes")

[ Upstream commit 1fb2d41 ]

pskb_may_pull() can fail for two different reasons.

Provide pskb_may_pull_reason() helper to distinguish
between these reasons.

It returns:

SKB_NOT_DROPPED_YET           : Success
SKB_DROP_REASON_PKT_TOO_SMALL : packet too small
SKB_DROP_REASON_NOMEM         : skb->head could not be resized

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Stable-dep-of: 8bd67ebb50c0 ("net: bridge: xmit: make sure we have at least eth header len bytes")
Signed-off-by: Sasha Levin <sashal@kernel.org>
@sysopenci sysopenci added Pending Developer Approval Pending Developer Approval Pending PR Review Pending PR Review Engineering Build Not Started Engineering Build Not Started labels Aug 13, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Engineering Build Not Started Engineering Build Not Started Pending Developer Approval Pending Developer Approval Pending PR Review Pending PR Review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants