Commit 1396d31
net: ena: fix packet's addresses for rx_offset feature
This patch fixes two lines in which the rx_offset received by the device
wasn't taken into account:
- prefetch function:
In our driver the copied data would reside in
rx_info->page + rx_headroom + rx_offset
so the prefetch function is changed accordingly.
- setting page_offset to zero for descriptors > 1:
for every descriptor but the first, the rx_offset is zero. Hence
the page_offset value should be set to rx_headroom.
The previous implementation changed the value of rx_info after
the descriptor was added to the SKB (essentially providing wrong
page offset).
Fixes: 68f236d ("net: ena: add support for the rx offset feature")
Signed-off-by: Shay Agroskin <shayagr@amazon.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>1 parent 09323b3 commit 1396d31
1 file changed
Lines changed: 11 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
908 | 908 | | |
909 | 909 | | |
910 | 910 | | |
| 911 | + | |
911 | 912 | | |
912 | 913 | | |
913 | 914 | | |
914 | 915 | | |
| 916 | + | |
| 917 | + | |
| 918 | + | |
915 | 919 | | |
916 | 920 | | |
917 | 921 | | |
| |||
941 | 945 | | |
942 | 946 | | |
943 | 947 | | |
944 | | - | |
945 | 948 | | |
946 | | - | |
947 | | - | |
| 949 | + | |
| 950 | + | |
948 | 951 | | |
949 | 952 | | |
950 | 953 | | |
| |||
1356 | 1359 | | |
1357 | 1360 | | |
1358 | 1361 | | |
1359 | | - | |
| 1362 | + | |
| 1363 | + | |
1360 | 1364 | | |
1361 | 1365 | | |
1362 | 1366 | | |
| |||
1397 | 1401 | | |
1398 | 1402 | | |
1399 | 1403 | | |
1400 | | - | |
1401 | | - | |
1402 | 1404 | | |
1403 | 1405 | | |
1404 | 1406 | | |
| |||
1517 | 1519 | | |
1518 | 1520 | | |
1519 | 1521 | | |
1520 | | - | |
1521 | | - | |
| 1522 | + | |
1522 | 1523 | | |
1523 | 1524 | | |
1524 | 1525 | | |
| |||
1585 | 1586 | | |
1586 | 1587 | | |
1587 | 1588 | | |
| 1589 | + | |
1588 | 1590 | | |
1589 | | - | |
| 1591 | + | |
1590 | 1592 | | |
1591 | 1593 | | |
1592 | 1594 | | |
| |||
0 commit comments