diff options
author | Cong Wang <[email protected]> | 2022-12-17 14:17:07 -0800 |
---|---|---|
committer | David S. Miller <[email protected]> | 2022-12-19 09:43:18 +0000 |
commit | 9cd3fd2054c3b3055163accbf2f31a4426f10317 (patch) | |
tree | 6fe1afa00c4329bc39273b4a4a833d4cb603cd5c /tools/perf/scripts/python/Perf-Trace-Util/Context.c | |
parent | 89529367293c975c3580f49f38568f44848d5683 (diff) |
net_sched: reject TCF_EM_SIMPLE case for complex ematch module
When TCF_EM_SIMPLE was introduced, it is supposed to be convenient
for ematch implementation:
https://lore.kernel.org/all/[email protected]/
"You don't have to, providing a 32bit data chunk without TCF_EM_SIMPLE
set will simply result in allocating & copy. It's an optimization,
nothing more."
So if an ematch module provides ops->datalen that means it wants a
complex data structure (saved in its em->data) instead of a simple u32
value. We should simply reject such a combination, otherwise this u32
could be misinterpreted as a pointer.
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Reported-and-tested-by: [email protected]
Reported-by: Jun Nie <[email protected]>
Cc: Jamal Hadi Salim <[email protected]>
Cc: Paolo Abeni <[email protected]>
Signed-off-by: Cong Wang <[email protected]>
Acked-by: Paolo Abeni <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/Perf-Trace-Util/Context.c')
0 files changed, 0 insertions, 0 deletions