kni: fix crash on userspace VA for segmented packets
authorFerruh Yigit <ferruh.yigit@intel.com>
Tue, 22 Jun 2021 12:29:56 +0000 (13:29 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Thu, 24 Jun 2021 08:04:25 +0000 (10:04 +0200)
commit9b83a7ed2ac160aca64eed4d45102aadf26bc053
tree8e936e18019d143624752d26531c755c39354433
parent0db3d5551abe94bb8a7030c1b90496b290ddb7f4
kni: fix crash on userspace VA for segmented packets

When IOVA=VA, address translation for segmented packets is wrong, it
assumes the address in the mbuf->next is physical address, not VA
address.

Fixing the address translation to work both PA & VA mode.

Fixes: e73831dc6c26 ("kni: support userspace VA")
Cc: stable@dpdk.org
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
kernel/linux/kni/kni_net.c