commit | bb60ed8b3d7e1babfa843ea4fd291528f1d79268 | [log] [tgz] |
---|---|---|
author | Eric Dumazet <[email protected]> | Fri Jun 21 13:09:55 2019 |
committer | Commit Bot <[email protected]> | Tue Jul 09 18:17:00 2019 |
tree | 3876015f456e684a218b2eac5e2b43852c7daf38 | |
parent | c1c7b3347f217eab8c557c213d2f809cb35033b9 [diff] |
FROMGIT: tcp: refine memory limit test in tcp_fragment() commit b6653b3629e5b88202be3c9abc44713973f5c4b4 upstream. tcp_fragment() might be called for skbs in the write queue. Memory limits might have been exceeded because tcp_sendmsg() only checks limits at full skb (64KB) boundaries. Therefore, we need to make sure tcp_fragment() wont punish applications that might have setup very low SO_SNDBUF values. Fixes: f070ef2ac667 ("tcp: tcp_fragment() should apply sane memory limits") Signed-off-by: Eric Dumazet <[email protected]> Reported-by: Christoph Paasch <[email protected]> Tested-by: Christoph Paasch <[email protected]> Signed-off-by: David S. Miller <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]> (cherry picked from commit 1bc13903773bc9418a8f898c462eef64b7fa1d52 git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.14.y) Signed-off-by: Robert Kolchmeyer <[email protected]> BUG=b:136039896 TEST=build and run Change-Id: Idea013a08b345bcb70873d3ba74842436b0c7a14 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/1681404 Reviewed-by: Sean Paul <[email protected]> Reviewed-by: Guenter Roeck <[email protected]> Commit-Queue: Guenter Roeck <[email protected]> Tested-by: Guenter Roeck <[email protected]>