kernel backtrace when receiving large UDP packages
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
linux (Ubuntu) |
Invalid
|
Medium
|
Unassigned | ||
Artful |
Fix Released
|
Medium
|
Unassigned |
Bug Description
== SRU Justification ==
Artful is missing commit a90bcb86ae70, which was sent
to upstream stable. Since upstream 4.13 is EOL, Artful never got it.
Because Artful does not have this commit when receiving large UDP packages
with a small MTU there are backtraces, examples posted in the bug.
Commit a90bcb86ae70 is in mainline as ov v4.14-rc2 and is only needed in
Artful.
== Fix ==
a90bcb86ae70 ("iov_iter: fix page_copy_sane for compound pages")
== Regression Potential ==
Low. This commit fixes a current regression in Artful. It was also
cc'd to stable, so it has had additional upstream review.
== Test Case ==
A test kernel was built with this patch and tested by the original bug reporter.
The bug reporter states the test kernel resolved the bug.
kernel 4.13.0-41-generic is missing commit a90bcb86ae70:
Author: Petar Penkov <email address hidden>
Date: Tue Aug 29 11:20:32 2017 -0700
iov_iter: fix page_copy_sane for compound pages
Issue is that if the data crosses a page boundary inside a compound
page, this check will incorrectly trigger a WARN_ON.
To fix this, compute the order using the head of the compound page and
adjust the offset to be relative to that head.
Fixes: 72e809ed81ed ("iov_iter: sanity checks for copy to/from page
primitives")
Signed-off-by: Petar Penkov <email address hidden>
CC: Al Viro <email address hidden>
CC: Eric Dumazet <email address hidden>
Signed-off-by: Al Viro <email address hidden>
Commit 72e809ed81ed is in kernel 4.13.0-41-generic.
As a result, when receiving large UDP packages with a small MTU we get backtraces like:
[ 361.260969] ------------[ cut here ]------------
[ 361.260974] WARNING: CPU: 4 PID: 2541 at /build/
[ 361.260975] Modules linked in: cmdlinepart sfc(OE) hwmon_vid crc32_generic mii rpcsec_gss_krb5 auth_rpcgss nfsv4 nfs lockd grace fscache 8021q garp mrp stp llc intel_rapl x86_pkg_
[ 361.261002] CPU: 4 PID: 2541 Comm: udp_recv Tainted: G OE 4.13.0-39-generic #44~16.04.1-Ubuntu
[ 361.261003] Hardware name: Dell Inc. PowerEdge R220/05Y15N, BIOS 1.4.0 10/23/2014
[ 361.261004] task: ffff91630b2bae80 task.stack: ffffbb19c2bfc000
[ 361.261005] RIP: 0010:copy_
[ 361.261006] RSP: 0018:ffffbb19c2
[ 361.261007] RAX: 0000000000001000 RBX: 00000000000000df RCX: 0017ffffc0000000
[ 361.261008] RDX: 00000000000000df RSI: 0000000000000f8e RDI: fffff666895279c0
[ 361.261009] RBP: ffffbb19c2bffca0 R08: 000000000000106d R09: 0000000000001024
[ 361.261009] R10: 0000000000000000 R11: ffff91630ccc9b00 R12: ffff91630d27a300
[ 361.261010] R13: ffffbb19c2bffde0 R14: 00000000000000df R15: 0000000000000175
[ 361.261011] FS: 00007fb8e764970
[ 361.261012] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 361.261013] CR2: 000014588da85624 CR3: 000000024bad2002 CR4: 00000000001606e0
[ 361.261013] Call Trace:
[ 361.261017] ? proto_init_
[ 361.261019] skb_copy_
[ 361.261022] udp_recvmsg+
[ 361.261024] inet_recvmsg+
[ 361.261026] sock_recvmsg+
[ 361.261028] sock_read_
[ 361.261030] new_sync_
[ 361.261032] __vfs_read+
[ 361.261033] vfs_read+0x93/0x130
[ 361.261034] SyS_read+0x55/0xc0
[ 361.261037] entry_SYSCALL_
[ 361.261038] RIP: 0033:0x7fb8e7160260
[ 361.261039] RSP: 002b:00007ffed9
[ 361.261040] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fb8e7160260
[ 361.261041] RDX: 000000000000ffe3 RSI: 00005622ad02f0a0 RDI: 0000000000000003
[ 361.261041] RBP: 00007ffed9dd9e70 R08: 0000000000000000 R09: 0000000000000011
[ 361.261042] R10: 0000000000000000 R11: 0000000000000246 R12: 00005622ace2e800
[ 361.261043] R13: 00007ffed9dd9f50 R14: 0000000000000000 R15: 0000000000000000
[ 361.261044] Code: de 4c 89 e7 e8 be fa ff ff 41 83 af a0 12 00 00 01 48 83 c4 18 5b 41 5c 41 5d 41 5e 41 5f 5d c3 8b 4f 6c 48 d3 e0 e9 9d fe ff ff <0f> ff 48 83 c4 18 31 c0 5b 41 5c 41 5d 41 5e 41 5f 5d c3 49 83
[ 361.261064] ---[ end trace c0b23bf37be9874d ]---
This is a request to pull in commit a90bcb86ae70.
# lsb_release -rd
Description: Ubuntu 17.10
Release: 17.10
# uname -a
Linux c6320f 4.13.0-41-generic #46-Ubuntu SMP Wed May 2 13:38:30 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
# cat /proc/version_
Ubuntu 4.13.0-
affects: | linux-meta (Ubuntu) → linux (Ubuntu) |
Changed in linux (Ubuntu): | |
importance: | Undecided → Medium |
Changed in linux (Ubuntu Artful): | |
importance: | Undecided → Medium |
status: | New → In Progress |
Changed in linux (Ubuntu): | |
status: | Confirmed → Invalid |
Changed in linux (Ubuntu Artful): | |
assignee: | nobody → Joseph Salisbury (jsalisbury) |
Changed in linux (Ubuntu Artful): | |
status: | In Progress → Fix Committed |
This change was made by a bot.