Commit 173e762
Revert "net: mirror skb frag ref/unref helpers"
This reverts commit a580ea9.
This revert is to resolve Dragos's report of page_pool leak here:
https://lore.kernel.org/lkml/20240424165646.1625690-2-dtatulea@nvidia.com/
The reverted patch interacts very badly with commit 2cc3aeb ("skbuff:
Fix a potential race while recycling page_pool packets"). The reverted
commit hopes that the pp_recycle + is_pp_page variables do not change
between the skb_frag_ref and skb_frag_unref operation. If such a change
occurs, the skb_frag_ref/unref will not operate on the same reference type.
In the case of Dragos's report, the grabbed ref was a pp ref, but the unref
was a page ref, because the pp_recycle setting on the skb was changed.
Attempting to fix this issue on the fly is risky. Lets revert and I hope
to reland this with better understanding and testing to ensure we don't
regress some edge case while streamlining skb reffing.
Fixes: a580ea9 ("net: mirror skb frag ref/unref helpers")
Reported-by: Dragos Tatulea <dtatulea@nvidia.com>
Signed-off-by: Mina Almasry <almasrymina@google.com>
Link: https://lore.kernel.org/r/20240502175423.2456544-1-almasrymina@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>1 parent 5bfadc5 commit 173e762
File tree
6 files changed
+51
-44
lines changed- drivers/net
- ethernet
- chelsio/inline_crypto/ch_ktls
- sun
- include/linux
- net
- core
- tls
6 files changed
+51
-44
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1659 | 1659 | | |
1660 | 1660 | | |
1661 | 1661 | | |
1662 | | - | |
| 1662 | + | |
1663 | 1663 | | |
1664 | 1664 | | |
1665 | 1665 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2000 | 2000 | | |
2001 | 2001 | | |
2002 | 2002 | | |
2003 | | - | |
| 2003 | + | |
2004 | 2004 | | |
2005 | 2005 | | |
2006 | 2006 | | |
| |||
2024 | 2024 | | |
2025 | 2025 | | |
2026 | 2026 | | |
2027 | | - | |
| 2027 | + | |
2028 | 2028 | | |
2029 | 2029 | | |
2030 | 2030 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
717 | 717 | | |
718 | 718 | | |
719 | 719 | | |
720 | | - | |
| 720 | + | |
721 | 721 | | |
722 | 722 | | |
723 | 723 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | 11 | | |
40 | 12 | | |
41 | 13 | | |
42 | 14 | | |
43 | | - | |
44 | 15 | | |
45 | | - | |
46 | | - | |
47 | | - | |
| 16 | + | |
48 | 17 | | |
49 | | - | |
| 18 | + | |
50 | 19 | | |
51 | | - | |
| 20 | + | |
52 | 21 | | |
53 | 22 | | |
54 | 23 | | |
| |||
60 | 29 | | |
61 | 30 | | |
62 | 31 | | |
63 | | - | |
| 32 | + | |
64 | 33 | | |
65 | 34 | | |
66 | 35 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
904 | 904 | | |
905 | 905 | | |
906 | 906 | | |
| 907 | + | |
| 908 | + | |
| 909 | + | |
| 910 | + | |
| 911 | + | |
907 | 912 | | |
908 | 913 | | |
909 | 914 | | |
| |||
1025 | 1030 | | |
1026 | 1031 | | |
1027 | 1032 | | |
| 1033 | + | |
| 1034 | + | |
| 1035 | + | |
| 1036 | + | |
| 1037 | + | |
| 1038 | + | |
| 1039 | + | |
| 1040 | + | |
| 1041 | + | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
| 1046 | + | |
| 1047 | + | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
| 1051 | + | |
| 1052 | + | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
| 1057 | + | |
| 1058 | + | |
| 1059 | + | |
| 1060 | + | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
1028 | 1064 | | |
1029 | 1065 | | |
1030 | 1066 | | |
| |||
4160 | 4196 | | |
4161 | 4197 | | |
4162 | 4198 | | |
4163 | | - | |
| 4199 | + | |
4164 | 4200 | | |
4165 | 4201 | | |
4166 | 4202 | | |
| |||
4810 | 4846 | | |
4811 | 4847 | | |
4812 | 4848 | | |
4813 | | - | |
| 4849 | + | |
4814 | 4850 | | |
4815 | 4851 | | |
4816 | 4852 | | |
| |||
5941 | 5977 | | |
5942 | 5978 | | |
5943 | 5979 | | |
5944 | | - | |
5945 | | - | |
| 5980 | + | |
| 5981 | + | |
| 5982 | + | |
| 5983 | + | |
5946 | 5984 | | |
5947 | 5985 | | |
5948 | 5986 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
278 | 278 | | |
279 | 279 | | |
280 | 280 | | |
281 | | - | |
| 281 | + | |
282 | 282 | | |
283 | 283 | | |
284 | 284 | | |
| |||
0 commit comments