Skip to content

Commit

Permalink
Auto merge of #3197 - zonyitoo:master, r=JohnTitor
Browse files Browse the repository at this point in the history
linux_like: IPPROTO_MPTCP are supported in all linux_like platforms

`IPPROTO_MPTCP` is supported on Android.

Android: https://android.googlesource.com/platform/external/kernel-headers/+/refs/heads/master/original/uapi/linux/in.h#85
  • Loading branch information
bors committed Apr 23, 2023
2 parents fc51b8b + b5fff1d commit 86593ce
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions libc-test/build.rs
Expand Up @@ -1795,6 +1795,8 @@ fn test_android(target: &str) {
| "MADV_POPULATE_READ"
| "MADV_POPULATE_WRITE" => true,

// kernel 5.6 minimum required
"IPPROTO_MPTCP" => true,

_ => false,
}
Expand Down
2 changes: 0 additions & 2 deletions src/unix/linux_like/linux/mod.rs
Expand Up @@ -1933,8 +1933,6 @@ pub const CLONE_PIDFD: ::c_int = 0x1000;
// netinet/in.h
// NOTE: These are in addition to the constants defined in src/unix/mod.rs

/// Multipath TCP
pub const IPPROTO_MPTCP: ::c_int = 262;
#[deprecated(
since = "0.2.80",
note = "This value was increased in the newer kernel \
Expand Down
2 changes: 2 additions & 0 deletions src/unix/linux_like/mod.rs
Expand Up @@ -916,6 +916,8 @@ pub const IPPROTO_UDPLITE: ::c_int = 136;
pub const IPPROTO_RAW: ::c_int = 255;
pub const IPPROTO_BEETPH: ::c_int = 94;
pub const IPPROTO_MPLS: ::c_int = 137;
/// Multipath TCP
pub const IPPROTO_MPTCP: ::c_int = 262;

pub const MCAST_EXCLUDE: ::c_int = 0;
pub const MCAST_INCLUDE: ::c_int = 1;
Expand Down

0 comments on commit 86593ce

Please sign in to comment.