net: mvpp2: refill RX buffers before XDP or skb use
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 07dd0a7aae7f72af7cec18909581c2bb570edddc · < 02e1b5c4d3b4c658b72c145427cded1bba613fc1| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net: mvpp2: refill RX buffers before XDP or skb use
The RX error path returns the current descriptor buffer to the hardware BM pool. That is only valid while the driver still owns the buffer.
mvpp2_rx_refill() can fail after the current buffer has been handed to XDP or attached to an skb. In those cases mvpp2_run_xdp() may have recycled, redirected, or queued the page for XDP_TX, and an skb free also retires the data buffer. Returning such a buffer to BM lets hardware DMA into memory that is no longer owned by the RX ring.
Refill the BM pool before handing the current buffer to XDP or to the skb. If the allocation fails there, drop the packet and return the still-owned current buffer to BM, preserving the pool depth. Once the refill succeeds, later local drops retire/free the current buffer instead of returning it to BM.
From the CVE record · Linux
The Linux kernel mvpp2 RX driver can return a buffer to the hardware pool after handing it to XDP or an skb if buffer refill fails. Hardware may then DMA into memory the RX ring no longer owns. The input does not specify how an attacker could trigger this or whether access or user interaction is required.
Engineers running Linux kernels with the mvpp2 driver should check their kernel versions; affected versions are not specified.