Skip to content

Conversation

@wangchen61698
Copy link
Contributor

Note: Please adhere to Contributing Guidelines.

Summary

When SOL_SOCKET options (e.g., SO_BINDTODEVICE via ping -I) hit ICMP sockets, icmp_{get,set}sockopt logged “Unrecognized ICMP option: 17” before fallback. Handle SOL_SOCKET explicitly by returning -ENOPROTOOPT so psock_* routes to the socket-level handler. Removes noisy logs without changing behavior (invalid devices still return -ENODEV).

Impact

icmp log

Testing

Please verify this PR together with another PR
apache/nuttx-apps#3263

After patch
image

Before patch

image

When SOL_SOCKET options (e.g., SO_BINDTODEVICE via ping -I) hit ICMP sockets, icmp_{get,set}sockopt logged “Unrecognized ICMP option: 17” before fallback. Handle SOL_SOCKET explicitly by returning -ENOPROTOOPT so psock_* routes to the socket-level handler. Removes noisy logs without changing behavior (invalid devices still return -ENODEV).

Signed-off-by: wangchen <wangchen41@xiaomi.com>
@github-actions github-actions bot added Area: Networking Effects networking subsystem Size: S The size of the change in this PR is small labels Dec 24, 2025
linguini1
linguini1 previously approved these changes Dec 24, 2025
@github-actions github-actions bot added Area: Documentation Improvements or additions to documentation Size: M The size of the change in this PR is medium labels Dec 25, 2025
@github-actions github-actions bot removed the Area: Documentation Improvements or additions to documentation label Dec 25, 2025
@xiaoxiang781216 xiaoxiang781216 merged commit c825404 into apache:master Dec 25, 2025
97 of 117 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: Networking Effects networking subsystem Size: M The size of the change in this PR is medium Size: S The size of the change in this PR is small

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants