xdp: Remove WARN() from __xdp_reg_mem_model()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 8d5d88527587516bd58ff0f3810f07c38e65e2be · < 7e9f79428372c6eab92271390851be34ab26bfb4| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
xdp: Remove WARN() from __xdp_reg_mem_model()
syzkaller reports a warning in __xdp_reg_mem_model().
The warning occurs only if __mem_id_init_hash_table() returns an error. It returns the error in two cases:
1. memory allocation fails; 2. rhashtable_init() fails when some fields of rhashtable_params struct are not initialized properly.
The second case cannot happen since there is a static const rhashtable_params struct with valid fields. So, warning is only triggered when there is a problem with memory allocation.
Thus, there is no sense in using WARN() to handle this error and it can be safely removed.
WARNING: CPU: 0 PID: 5065 at net/core/xdp.c:299 __xdp_reg_mem_model+0x2d9/0x650 net/core/xdp.c:299
From the CVE record · Linux
The Linux kernel's XDP memory-model registration emits a warning if memory allocation fails. The warning was observed through a local BPF test-run syscall; the input does not establish whether authentication or user interaction is required.
Engineers running the Linux kernel should check their versions against the vendor advisory; the affected version range is not specified.