vf init issue with patch igb_uio: issue FLR during open and release of device file
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe. Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s) EAL: No free hugepages reported in hugepages-1048576kB EAL: Probing VFIO support... EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles ! EAL: PCI device 0000:00:03.0 on NUMA socket -1 EAL: Invalid NUMA socket, default to 0 EAL: probe driver: 8086:154c net_i40e_vf i40evf_init_vf(): init_adminq failed: -53 i40evf_dev_init(): Init vf failed EAL: Requested device 0000:00:03.0 cannot be used
commit b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530igb_uio: issue FLR during open and release of device file Set UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from vfio_pci kernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close. Bus master enable and disable are added in open and release respectively to take care of device DMA.
Best Regard,
Yang Qiming
Quoted 58 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>
Quoted 5 lines
Best Regard,
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
Shijith
Quoted 61 lines · Shijith Thotton
Quoted 60 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 2 lines
Shijith
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patch igb_uio: issue FLR during open and release of device file
Quoted 61 lines · Shijith Thotton
Quoted 60 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 2 lines
Shijith
Quoted 18 lines · Xuekun
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 8 lines · Shijith Thotton
Quoted 7 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k) 2- DPDK app run on host, so both PF and VF are in host. Linux driver for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and DPDK VF on guest, this works fine)
And I confirm the function igbuio_pci_open() added with below patch is causing it.
igbuio_pci_open() does:
pci_reset_function(dev);
pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 68 lines
Quoted 53 lines
Quoted 53 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 2 lines
Shijith
-----Original Message-----
From: dev <[email protected]> on behalf of Ferruh Yigit <[email protected]>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]>, "Thotton, Shijith" <[email protected]>, "Yang, Qiming" <[email protected]>, Gregory Etelson <[email protected]>
Cc: "[email protected]" <[email protected]>, "Tan, Jianfeng" <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patch igb_uio: issue FLR during open and release of device file
Quoted 33 lines · Xuekun
Quoted 11 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 11 lines
Quoted 10 lines · Shijith Thotton
Quoted 9 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k) 2- DPDK app run on host, so both PF and VF are in host. Linux driver for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and DPDK VF on guest, this works fine)
Quoted 79 lines
And I confirm the function
igbuio_pci_open()added with below patch is causing it.
igbuio_pci_open()does:pci_reset_function(dev); pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 70 lines
Quoted 57 lines
Quoted 57 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour fromvfio_pcikernel module code. With this
patch,
it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release
respectively
to take care of device DMA.Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due to this patch.
Could we revert this and leave it to individual PMDs to manage it?
Quoted 1 line
Quoted 1 line
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe and qede(Harish said) VF all meet initial failure. This issue only occurred when use 17.08 igb_uio, vfio-pci and 17.05 igb_uio all works well.
Considering this issue will block our vf driver develop and test work, could we revert this patch first and find another appropriate way?
Qiming
Quoted 140 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh <[email protected]>; Hu, Xuekun <[email protected]>; Thotton, Shijith <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device file-----Original Message-----
From: dev <[email protected]> on behalf of Ferruh Yigit <[email protected]>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]>, "Thotton, Shijith" <[email protected]>, "Yang, Qiming" <[email protected]>, Gregory Etelson <[email protected]>
Cc: "[email protected]" <[email protected]>, "Tan, Jianfeng" <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 33 lines · Xuekun
Quoted 11 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 11 lines
Quoted 10 lines · Shijith Thotton
Quoted 9 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k) 2- DPDK app run on host, so both PF and VF are in host. Linux driver for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and DPDK VF on guest, this works fine)
Quoted 79 lines
And I confirm the function
igbuio_pci_open()added with below patch is causing it.
igbuio_pci_open()does:pci_reset_function(dev); pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 70 lines
Quoted 57 lines
Quoted 57 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour fromvfio_pcikernel module code. With
this patch,
it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release
respectively
to take care of device DMA.Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due to this patch.
Could we revert this and leave it to individual PMDs to manage it?Quoted 1 line
Quoted 1 line
Hi
15/09/2017 10:04, Yang, Qiming:
Quoted 3 lines
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe and qede(Harish said) VF all meet initial failure.
This patch has been integrated in DPDK 17.08-rc2 (2 months ago). Why a so obvious issue is discovered only now?
Quoted 2 lines
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioall works well.
Considering this issue will block our vf driver develop and test work, could we revert this patch first and find another appropriate way?
We need to be sure the revert is the right solution because it will be backported to the stable 17.08 release.
Shijith suggests to "try removing pci_reset_function from igbuio_pci_open." Can we try this first?
Are we sure the bug is not in new firmwares?
Quoted 25 lines
-----Original Message-----
From: Thomas Monjalon [mailto:[email protected]]
Sent: Friday, September 15, 2017 4:43 PM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Gregory Etelson <[email protected]>; [email protected]
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHi
15/09/2017 10:04, Yang, Qiming:
Quoted 3 lines
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbeand qede(Harish said) VF all meet initial failure.
This patch has been integrated in DPDK 17.08-rc2 (2 months ago). Why a so obvious issue is discovered only now?
Quoted 1 line
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioallworks well.
Quoted 1 line
Considering this issue will block our vf driver develop and test work, could we
Quoted 8 lines
revert this patch first and find another appropriate way?
We need to be sure the revert is the right solution because it will be backported to the stable 17.08 release.
Shijith suggests to "try removing
pci_reset_functionfromigbuio_pci_open." Can we try this first?
Are we sure the bug is not in new firmwares?
I have tried to remove pci_reset_function, it works in my environment, but it doesn't work in someone's enviroment. And removing this function won't it changes the original purpose of his patch? So I'm not sure it is a good solution. This bug is not a firmware version related issue, we can reproduce stably with older firmware.
Qiming
Quoted 30 lines · Qiming
Quoted 30 lines
-----Original Message-----
From: Thomas Monjalon [mailto:[email protected]]
Sent: Friday, September 15, 2017 4:43 PM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Gregory Etelson <[email protected]>; [email protected]
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHi
15/09/2017 10:04, Yang, Qiming:
Quoted 3 lines
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbeand qede(Harish said) VF all meet initial failure.
This patch has been integrated in DPDK 17.08-rc2 (2 months ago). Why a so obvious issue is discovered only now?
Quoted 1 line
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioallworks well.
Quoted 1 line
Considering this issue will block our vf driver develop and test work, could we
revert this patch first and find another appropriate way?
We need to be sure the revert is the right solution because it will be backported to the stable 17.08 release.
Quoted 6 lines
Quoted 3 lines
Shijith suggests to "try removing
pci_reset_functionfromigbuio_pci_open." Can we try this first?
Are we sure the bug is not in new firmwares?I have tried to remove
pci_reset_function, it works in my environment, but it doesn't work in someone's enviroment. And removing this function won't it changes the original purpose of his patch? So I'm not sure it is a good solution.
Yes, removing that will be functionally almost same with revert.
Quoted 1 line
This bug is not a firmware version related issue, we can reproduce stably with older firmware.
I also think this is not related to the firmware.
But I don't see why works with one version of the Linux PF driver, but not other.
Quoted 3 lines
Qiming
Quoted 30 lines · Qiming
Quoted 30 lines
-----Original Message-----
From: Thomas Monjalon [mailto:[email protected]]
Sent: Friday, September 15, 2017 4:43 PM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Gregory Etelson <[email protected]>; [email protected]
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHi
15/09/2017 10:04, Yang, Qiming:
Quoted 3 lines
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbeand qede(Harish said) VF all meet initial failure.
This patch has been integrated in DPDK 17.08-rc2 (2 months ago). Why a so obvious issue is discovered only now?
Quoted 1 line
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioallworks well.
Quoted 1 line
Considering this issue will block our vf driver develop and test work, could we
revert this patch first and find another appropriate way?
We need to be sure the revert is the right solution because it will be backported to the stable 17.08 release.
Quoted 8 lines
Quoted 3 lines
Shijith suggests to "try removing
pci_reset_functionfromigbuio_pci_open." Can we try this first?
Are we sure the bug is not in new firmwares?I have tried to remove
pci_reset_function, it works in my environment, but it doesn't work in someone's enviroment. And removing this function won't it changes the original purpose of his patch? So I'm not sure it is a good solution. This bug is not a firmware version related issue, we can reproduce stably with older firmware.
There is a reset during release which was suggested as a fix by Gregory for an issue he faced with i40e VF[1]. Removing it can cause problems for him.
Hello Qiming,
Did you try to remove PCI reset at igbuio_pci_open ? Reverting the patch entirely will get us back to VF issues
Regards,
Gregory
Quoted 150 lines · Qiming
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe and qede(Harish said) VF all meet initial failure. This issue only occurred when use 17.08igb_uio, vfio-pci and 17.05igb_uioall works well.
Considering this issue will block our vf driver develop and test work, could we revert this patch first and find another appropriate way?Qiming
Quoted 140 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh <[email protected]>; Hu, Xuekun <[email protected]>; Thotton, Shijith <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device file-----Original Message-----
From: dev <[email protected]> on behalf of Ferruh Yigit <[email protected]>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]>, "Thotton, Shijith" <[email protected]>, "Yang, Qiming" <[email protected]>, Gregory Etelson <[email protected]>
Cc: "[email protected]" <[email protected]>, "Tan, Jianfeng" <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 33 lines · Xuekun
Quoted 11 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 11 lines
Quoted 10 lines · Shijith Thotton
Quoted 9 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k) 2- DPDK app run on host, so both PF and VF are in host. Linux driver for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and DPDK VF on guest, this works fine)
Quoted 79 lines
And I confirm the function
igbuio_pci_open()added with below patch is causing it.
igbuio_pci_open()does:pci_reset_function(dev); pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 70 lines
Quoted 57 lines
Quoted 57 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour fromvfio_pcikernel module code. With
this patch,
it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release
respectively
to take care of device DMA.Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due to this patch.
Could we revert this and leave it to individual PMDs to manage it?Quoted 1 line
Quoted 1 line
Yes, I have tried, and it works. But I think removing this function also makes the patch meaningless.
Qiming
From: Gregory Etelson [mailto:[email protected]]
Sent: Sunday, September 17, 2017 10:50 AM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patch igb_uio: issue FLR during open and release of device file
Hello Qiming,
Did you try to remove PCI reset at igbuio_pci_open ?
Reverting the patch entirely will get us back to VF issues
Regards,
Gregory
Quoted 299 lines · Qiming
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe and qede(Harish said) VF all meet initial failure.
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioall works well.Considering this issue will block our vf driver develop and test work, could we revert this patch first and find another appropriate way?
Qiming
Quoted 279 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh <[email protected]<mailto:[email protected]>>; Hu, Xuekun <[email protected]<mailto:[email protected]>>;
Thotton, Shijith <[email protected]<mailto:[email protected]>>; Yang, Qiming
<[email protected]<mailto:[email protected]>>; Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng <[email protected]<mailto:[email protected]>>Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
-----Original Message-----
From: dev <[email protected]<mailto:[email protected]>> on behalf of Ferruh Yigit
<[email protected]<mailto:[email protected]>>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]<mailto:[email protected]>>, "Thotton, Shijith"
<[email protected]<mailto:[email protected]>>, "Yang, Qiming" <[email protected]<mailto:[email protected]>>,
Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc "[email protected]<mailto:[email protected]>" <[email protected]<mailto:[email protected]>>, "Tan, Jianfeng" <[email protected]<mailto:[email protected]>>Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 74 lines · Xuekun
Quoted 17 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]<mailto:[email protected]>>; Yang,
Qiming <[email protected]<mailto:[email protected]>>; Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng <[email protected]<mailto:[email protected]>>Quoted 27 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLRduring open and release of device file
Quoted 19 lines · Shijith Thotton
Quoted 17 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver
for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and
DPDK VF on guest, this works fine)
And I confirm the function
igbuio_pci_open()added with below patch iscausing it.
igbuio_pci_open()does:Quoted 149 lines
pci_reset_function(dev);
pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 139 lines
Quoted 122 lines
Quoted 110 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using
unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084aAuthor: Shijith Thotton <[email protected]<mailto:[email protected]>>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour from
vfio_pcikernel module code. Withthis patch,
it is not mandatory to issue FLR by PMD's during init and close.
Bus master enable and disable are added in open and release
respectively
to take care of device DMA.
Quoted 9 lines
Best Regard,
Yang Qiming
Quoted 9 lines
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory
tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due to
this patch.
Could we revert this and leave it to individual PMDs to manage it?
Quoted 1 line
Quoted 1 line
Hi guys
May I suggest to revert the patch first, as it blocks existing functionalities. Then the original authors can add it back with a fix?
Regards,
Helin
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Yang, Qiming
Sent: Monday, September 18, 2017 10:21 AM
To: Gregory Etelson <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patch igb_uio: issue FLR during open and release of device file
Yes, I have tried, and it works. But I think removing this function also makes the patch meaningless.
Qiming
From: Gregory Etelson [mailto:[email protected]]
Sent: Sunday, September 17, 2017 10:50 AM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patch igb_uio: issue FLR during open and release of device file
Hello Qiming,
Did you try to remove PCI reset at igbuio_pci_open ?
Reverting the patch entirely will get us back to VF issues
Regards,
Gregory
Quoted 299 lines · Qiming
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe and qede(Harish said) VF all meet initial failure.
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioall works well.Considering this issue will block our vf driver develop and test work, could we revert this patch first and find another appropriate way?
Qiming
Quoted 279 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh <[email protected]<mailto:[email protected]>>; Hu, Xuekun <[email protected]<mailto:[email protected]>>;
Thotton, Shijith <[email protected]<mailto:[email protected]>>; Yang, Qiming
<[email protected]<mailto:[email protected]>>; Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng <[email protected]<mailto:[email protected]>>Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
-----Original Message-----
From: dev <[email protected]<mailto:[email protected]>> on behalf of Ferruh Yigit
<[email protected]<mailto:[email protected]>>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]<mailto:[email protected]>>, "Thotton, Shijith"
<[email protected]<mailto:[email protected]>>, "Yang, Qiming" <[email protected]<mailto:[email protected]>>,
Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc "[email protected]<mailto:[email protected]>" <[email protected]<mailto:[email protected]>>, "Tan, Jianfeng" <[email protected]<mailto:[email protected]>>Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 74 lines · Xuekun
Quoted 17 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]<mailto:[email protected]>>; Yang,
Qiming <[email protected]<mailto:[email protected]>>; Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng <[email protected]<mailto:[email protected]>>Quoted 27 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLRduring open and release of device file
Quoted 19 lines · Shijith Thotton
Quoted 17 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver
for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and
DPDK VF on guest, this works fine)
And I confirm the function
igbuio_pci_open()added with below patch iscausing it.
igbuio_pci_open()does:Quoted 149 lines
pci_reset_function(dev);
pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 139 lines
Quoted 122 lines
Quoted 110 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using
unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084aAuthor: Shijith Thotton <[email protected]<mailto:[email protected]>>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour from
vfio_pcikernel module code. Withthis patch,
it is not mandatory to issue FLR by PMD's during init and close.
Bus master enable and disable are added in open and release
respectively
to take care of device DMA.
Quoted 9 lines
Best Regard,
Yang Qiming
Quoted 9 lines
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory
tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due to
this patch.
Could we revert this and leave it to individual PMDs to manage it?
Quoted 1 line
Quoted 1 line
Sorry, Gregory and Shijith
I misunderstand your advice.
If we only remove PCI reset at igbuio_pci_open, not include igbuio_pci_release, I think it is a good solution. It reserve the functional of this patch and we have test on FVL 10G/40G/25G, all work fine.
Qiming
Quoted 391 lines
-----Original Message-----
From: Zhang, Helin
Sent: Monday, September 18, 2017 10:39 AM
To: Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>; [email protected]
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: RE: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHi guys
May I suggest to revert the patch first, as it blocks existing functionalities. Then the original authors can add it back with a fix?
Regards,
Helin-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Yang, Qiming
Sent: Monday, September 18, 2017 10:21 AM
To: Gregory Etelson <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileYes, I have tried, and it works. But I think removing this function also makes the patch meaningless.
Qiming
From: Gregory Etelson [mailto:[email protected]]
Sent: Sunday, September 17, 2017 10:50 AM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHello Qiming,
Did you try to remove PCI reset at
igbuio_pci_open?Reverting the patch entirely will get us back to VF issues
Regards,
Gregory
Quoted 5 lines · Qiming
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe
and qede(Harish said) VF all meet initial failure.
Quoted 1 line
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioallworks well.
Quoted 1 line
Considering this issue will block our vf driver develop and test work, could we
revert this patch first and find another appropriate way?
Quoted 13 lines
Qiming
Quoted 7 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh <[email protected]<mailto:[email protected]>>;
Hu, Xuekun <[email protected]<mailto:[email protected]>>;
Quoted 1 line
Quoted 1 line
Thotton, Shijith
<[email protected]<mailto:[email protected]>>; Yang, Qiming
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>; Gregory Etelson
<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 10 lines
Quoted 9 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 3 lines
Quoted 3 lines
-----Original Message-----
From: dev <[email protected]<mailto:[email protected]>> on
behalf of Ferruh Yigit
Quoted 5 lines
Quoted 5 lines
<[email protected]<mailto:[email protected]>>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]<mailto:[email protected]>>,
"Thotton, Shijith"
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>,
"Yang, Qiming" <[email protected]<mailto:[email protected]>>,
Quoted 3 lines
Quoted 3 lines
Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc "[email protected]<mailto:[email protected]>"<[email protected]<mailto:[email protected]>>, "Tan, Jianfeng" <[email protected]<mailto:[email protected]>>
Quoted 12 lines
Quoted 11 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 5 lines · Xuekun
Quoted 4 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>; Yang,
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Qiming <[email protected]<mailto:[email protected]>>;
Gregory Etelson <[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 126 lines
Quoted 125 lines
Quoted 125 lines
Quoted 27 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLRduring open and release of device file
Quoted 19 lines · Shijith Thotton
Quoted 17 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver
for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and
DPDK VF on guest, this works fine)
And I confirm the function
igbuio_pci_open()added with below patch iscausing it.
igbuio_pci_open()does:
pci_reset_function(dev);
pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 59 lines
Quoted 59 lines
Quoted 59 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using
unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084aAuthor: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>
Quoted 26 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour from
vfio_pcikernel module code. Withthis patch,
it is not mandatory to issue FLR by PMD's during init and close.
Bus master enable and disable are added in open and release
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
respectively
to take care of device DMA.
Signed-off-by Shijith Thotton<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Reviewed-by Jianfeng Tan<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Ferruh Yigit<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Gregory Etelson<[email protected]<mailto:[email protected]>>
Quoted 34 lines
Quoted 33 lines
Quoted 33 lines
Quoted 33 lines
Quoted 18 lines
Quoted 6 lines
Quoted 9 lines
Best Regard,
Yang Qiming
Quoted 9 lines
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory
tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 5 lines
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due
to
Quoted 9 lines
Quoted 5 lines
this patch.
Could we revert this and leave it to individual PMDs to manage it?
Quoted 1 line
Quoted 1 line
Quoted 6 lines · Qiming
Sorry, Gregory and Shijith
I misunderstand your advice.
If we only remove PCI reset atigbuio_pci_open, not includeigbuio_pci_release, I think it is a good solution. It reserve the functional of this patch and we have test on FVL 10G/40G/25G, all work fine.
Thanks Qiming. Glad to hear that removing pci_reset_function from igbuio_pci_open fixed the issue for Intel NICs.
Harish,
Please let us know the behavior with QEDE. Reverting won't be necessary if the fix works for all.
Thanks,
Shijith
Quoted 392 lines
Quoted 391 lines
-----Original Message-----
From: Zhang, Helin
Sent: Monday, September 18, 2017 10:39 AM
To: Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>; [email protected]
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: RE: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHi guys
May I suggest to revert the patch first, as it blocks existing functionalities. Then the original authors can add it back with a fix?
Regards,
Helin-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Yang, Qiming
Sent: Monday, September 18, 2017 10:21 AM
To: Gregory Etelson <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileYes, I have tried, and it works. But I think removing this function also makes the patch meaningless.
Qiming
From: Gregory Etelson [mailto:[email protected]]
Sent: Sunday, September 17, 2017 10:50 AM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHello Qiming,
Did you try to remove PCI reset at
igbuio_pci_open?Reverting the patch entirely will get us back to VF issues
Regards,
Gregory
Quoted 5 lines · Qiming
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe
and qede(Harish said) VF all meet initial failure.
Quoted 1 line
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioallworks well.
Quoted 1 line
Considering this issue will block our vf driver develop and test work, could we
revert this patch first and find another appropriate way?
Quoted 13 lines
Qiming
Quoted 7 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh <[email protected]<mailto:[email protected]>>;
Hu, Xuekun <[email protected]<mailto:[email protected]>>;
Quoted 1 line
Quoted 1 line
Thotton, Shijith
<[email protected]<mailto:[email protected]>>; Yang, Qiming
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>; Gregory Etelson
<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 10 lines
Quoted 9 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 3 lines
Quoted 3 lines
-----Original Message-----
From: dev <[email protected]<mailto:[email protected]>> on
behalf of Ferruh Yigit
Quoted 5 lines
Quoted 5 lines
<[email protected]<mailto:[email protected]>>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]<mailto:[email protected]>>,
"Thotton, Shijith"
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>,
"Yang, Qiming" <[email protected]<mailto:[email protected]>>,
Quoted 3 lines
Quoted 3 lines
Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc "[email protected]<mailto:[email protected]>"<[email protected]<mailto:[email protected]>>, "Tan, Jianfeng" <[email protected]<mailto:[email protected]>>
Quoted 12 lines
Quoted 11 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 5 lines · Xuekun
Quoted 4 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>; Yang,
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Qiming <[email protected]<mailto:[email protected]>>;
Gregory Etelson <[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 126 lines
Quoted 125 lines
Quoted 125 lines
Quoted 27 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLRduring open and release of device file
Quoted 19 lines · Shijith Thotton
Quoted 17 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver
for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and
DPDK VF on guest, this works fine)
And I confirm the function
igbuio_pci_open()added with below patch iscausing it.
igbuio_pci_open()does:
pci_reset_function(dev);
pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 59 lines
Quoted 59 lines
Quoted 59 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using
unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084aAuthor: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>
Quoted 26 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour from
vfio_pcikernel module code. Withthis patch,
it is not mandatory to issue FLR by PMD's during init and close.
Bus master enable and disable are added in open and release
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
respectively
to take care of device DMA.
Signed-off-by Shijith Thotton<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Reviewed-by Jianfeng Tan<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Ferruh Yigit<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Gregory Etelson<[email protected]<mailto:[email protected]>>
Quoted 34 lines
Quoted 33 lines
Quoted 33 lines
Quoted 33 lines
Quoted 18 lines
Quoted 6 lines
Quoted 9 lines
Best Regard,
Yang Qiming
Quoted 9 lines
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory
tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 5 lines
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due
to
Quoted 9 lines
Quoted 5 lines
this patch.
Could we revert this and leave it to individual PMDs to manage it?
Quoted 1 line
Quoted 1 line
Quoted 8 lines · Shijith Thotton
Quoted 6 lines · Qiming
Sorry, Gregory and Shijith
I misunderstand your advice.
If we only remove PCI reset atigbuio_pci_open, not includeigbuio_pci_release, I think it is a good solution. It reserve the functional of this patch and we have test on FVL 10G/40G/25G, all work fine.
Quoted 7 lines
Thanks Qiming. Glad to hear that removing
pci_reset_functionfromigbuio_pci_openfixed the issue for Intel NICs.Harish,
Please let us know the behavior with QEDE. Reverting won't be necessary if the fix works for all.
Hi Shijith,
Would you mind submitting the patch, so this becomes easier to discuss and test.
Thanks,
ferruh
Quoted 396 lines
Thanks,
ShijithQuoted 392 lines
Quoted 391 lines
-----Original Message-----
From: Zhang, Helin
Sent: Monday, September 18, 2017 10:39 AM
To: Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>; [email protected]
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: RE: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHi guys
May I suggest to revert the patch first, as it blocks existing functionalities. Then the original authors can add it back with a fix?
Regards,
Helin-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Yang, Qiming
Sent: Monday, September 18, 2017 10:21 AM
To: Gregory Etelson <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileYes, I have tried, and it works. But I think removing this function also makes the patch meaningless.
Qiming
From: Gregory Etelson [mailto:[email protected]]
Sent: Sunday, September 17, 2017 10:50 AM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith <[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileHello Qiming,
Did you try to remove PCI reset at
igbuio_pci_open?Reverting the patch entirely will get us back to VF issues
Regards,
Gregory
Quoted 5 lines · Qiming
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver, i40e, ixgbe
and qede(Harish said) VF all meet initial failure.
Quoted 1 line
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05igb_uioallworks well.
Quoted 1 line
Considering this issue will block our vf driver develop and test work, could we
revert this patch first and find another appropriate way?
Quoted 13 lines
Qiming
Quoted 7 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh <[email protected]<mailto:[email protected]>>;
Hu, Xuekun <[email protected]<mailto:[email protected]>>;
Quoted 1 line
Quoted 1 line
Thotton, Shijith
<[email protected]<mailto:[email protected]>>; Yang, Qiming
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>; Gregory Etelson
<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 10 lines
Quoted 9 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 3 lines
Quoted 3 lines
-----Original Message-----
From: dev <[email protected]<mailto:[email protected]>> on
behalf of Ferruh Yigit
Quoted 5 lines
Quoted 5 lines
<[email protected]<mailto:[email protected]>>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun" <[email protected]<mailto:[email protected]>>,
"Thotton, Shijith"
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>,
"Yang, Qiming" <[email protected]<mailto:[email protected]>>,
Quoted 3 lines
Quoted 3 lines
Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc "[email protected]<mailto:[email protected]>"<[email protected]<mailto:[email protected]>>, "Tan, Jianfeng" <[email protected]<mailto:[email protected]>>
Quoted 12 lines
Quoted 11 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLR during openand release of device file
Quoted 5 lines · Xuekun
Quoted 4 lines
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>; Yang,
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Qiming <[email protected]<mailto:[email protected]>>;
Gregory Etelson <[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 126 lines
Quoted 125 lines
Quoted 125 lines
Quoted 27 lines
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issue FLRduring open and release of device file
Quoted 19 lines · Shijith Thotton
Quoted 17 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as
below. If
revert your commit, all things work well. And this issue is not
only occur
in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver
for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and
DPDK VF on guest, this works fine)
And I confirm the function
igbuio_pci_open()added with below patch iscausing it.
igbuio_pci_open()does:
pci_reset_function(dev);
pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 59 lines
Quoted 59 lines
Quoted 59 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using
unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084aAuthor: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>
Quoted 26 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci
reset
function inside open and release to clear device state at start
and end.
Copied this behaviour from
vfio_pcikernel module code. Withthis patch,
it is not mandatory to issue FLR by PMD's during init and close.
Bus master enable and disable are added in open and release
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
respectively
to take care of device DMA.
Signed-off-by Shijith Thotton<[email protected]<mailto:shijith.thotton@caviumnetworks .com>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Reviewed-by Jianfeng Tan<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Ferruh Yigit<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Gregory Etelson<[email protected]<mailto:[email protected]>>
Quoted 34 lines
Quoted 33 lines
Quoted 33 lines
Quoted 33 lines
Quoted 18 lines
Quoted 6 lines
Quoted 9 lines
Best Regard,
Yang Qiming
Quoted 9 lines
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory
tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 5 lines
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF devices due
to
Quoted 9 lines
Quoted 5 lines
this patch.
Could we revert this and leave it to individual PMDs to manage it?
Quoted 1 line
Quoted 1 line
-----Original Message-----
From: "Thotton, Shijith" <[email protected]>
Date: Sunday, September 17, 2017 at 11:49 PM
To: "Yang, Qiming" <[email protected]>, Harish Patil <[email protected]>
Cc: "Zhang, Helin" <[email protected]>, Gregory Etelson <[email protected]>, "[email protected]" <[email protected]>, "[email protected]" <[email protected]>, "Tan, Jianfeng" <[email protected]>, "Thotton, Shijith" <[email protected]>, "Hu, Xuekun" <[email protected]>, "Yigit, Ferruh" <[email protected]>, "Li, Xiaoyun" <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patch igb_uio: issue FLR during open and release of device file
Quoted 14 lines · Qiming
Quoted 8 lines
Sorry, Gregory and Shijith
I misunderstand your advice.
If we only remove PCI reset atigbuio_pci_open, not includeigbuio_pci_release, I think it is a good solution.
It reserve the functional of this patch and we have test on FVL 10G/40G/25G, all work fine.Thanks Qiming. Glad to hear that removing
pci_reset_functionfromigbuio_pci_open
fixed the issue for Intel NICs.
Quoted 8 lines
Harish,
Please let us know the behavior with QEDE. Reverting won't be necessary if the
fix works for all.Thanks,
Shijith
[Harish] Shijith,
Removing pci_reset_function() from open() seems good enough. Thanks.
Quoted 430 lines
Quoted 430 lines
Quoted 7 lines
-----Original Message-----
From: Zhang, Helin
Sent: Monday, September 18, 2017 10:39 AM
To: Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>; [email protected]
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Thotton,Shijith
Quoted 2 lines
<[email protected]>; Hu, Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>; Patil, Harish
<[email protected]>; Li,
Quoted 2 lines
Xiaoyun <[email protected]>
Subject: RE: [dpdk-dev] vf init issue with patchigb_uio: issue FLRduring open
Quoted 5 lines
and release of device file
Hi guys
May I suggest to revert the patch first, as it blocks existing
functionalities.
Quoted 11 lines
Then the original authors can add it back with a fix?
Regards,
Helin-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Yang, Qiming
Sent: Monday, September 18, 2017 10:21 AM
To: Gregory Etelson <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith<[email protected]>; Hu,
Quoted 1 line
Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>;
Patil,
Quoted 2 lines
Harish <[email protected]>; Li, Xiaoyun <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLRduring open
Quoted 3 lines
and release of device file
Yes, I have tried, and it works. But I think removing this function
also makes the
Quoted 8 lines
patch meaningless.
Qiming
From: Gregory Etelson [mailto:[email protected]]
Sent: Sunday, September 17, 2017 10:50 AM
To: Yang, Qiming <[email protected]>
Cc: [email protected]; [email protected]; Tan, Jianfeng <[email protected]>; Thotton, Shijith<[email protected]>; Hu,
Quoted 1 line
Xuekun <[email protected]>; Yigit, Ferruh <[email protected]>;
Patil,
Quoted 2 lines
Harish <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLRduring open
Quoted 15 lines
and release of device file
Hello Qiming,
Did you try to remove PCI reset at
igbuio_pci_open?Reverting the patch entirely will get us back to VF issues
Regards,
Quoted 13 lines
Gregory
Quoted 5 lines · Qiming
Hi, Thomas
We meet a urgent issue because of Shijith's patch.
When use DPDK version 17.08, DPDK VF driver and kernel PF driver,
i40e, ixgbe
Quoted 3 lines
and qede(Harish said) VF all meet initial failure.
Quoted 1 line
This issue only occurred when use 17.08
igb_uio, vfio-pci and 17.05
igb_uioallQuoted 3 lines
works well.
Quoted 1 line
Considering this issue will block our vf driver develop and test
work, could we
Quoted 15 lines
revert this patch first and find another appropriate way?
Quoted 13 lines
Qiming
Quoted 7 lines
-----Original Message-----
From: Patil, Harish [mailto:[email protected]]
Sent: Thursday, September 14, 2017 3:45 AM
To: Yigit, Ferruh
<[email protected]<mailto:[email protected]>>;
Quoted 7 lines
Hu, Xuekun <[email protected]<mailto:[email protected]>>;
Quoted 1 line
Quoted 1 line
Thotton, Shijith
<[email protected]<mailto:[email protected]>>; Yang, Qiming
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>; Gregory
Etelson
Quoted 6 lines
<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issueFLR during open
Quoted 9 lines
Quoted 8 lines
Quoted 8 lines
and release of device file
Quoted 10 lines
Quoted 3 lines
Quoted 3 lines
-----Original Message-----
From: dev <[email protected]<mailto:[email protected]>> on
behalf of Ferruh Yigit
Quoted 5 lines
Quoted 5 lines
<[email protected]<mailto:[email protected]>>
Date: Wednesday, September 13, 2017 at 10:06 AM
To: "Hu, Xuekun"
<[email protected]<mailto:[email protected]>>,
Quoted 12 lines
"Thotton, Shijith"
Quoted 1 line
Quoted 1 line
<[email protected]<mailto:[email protected]>>,
"Yang, Qiming" <[email protected]<mailto:[email protected]>>,
Quoted 3 lines
Quoted 3 lines
Gregory Etelson <[email protected]<mailto:[email protected]>>
Cc "[email protected]<mailto:[email protected]>"<[email protected]<mailto:[email protected]>>, "Tan, Jianfeng" <[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio: issueFLR during open
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
and release of device file
Quoted 3 lines · Xuekun
Quoted 2 lines
I met the same issue too, only with i40e 2.1.26 PF kernel
driver.
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh
Yigit
Quoted 5 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks
Quoted 9 lines
.com>>; Yang,
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Qiming <[email protected]<mailto:[email protected]>>;
Gregory Etelson <[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Cc [email protected]<mailto:[email protected]>; Tan, Jianfeng<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Subject: Re: [dpdk-dev] vf init issue with patch
igb_uio:issue FLR
Quoted 17 lines
Quoted 16 lines
Quoted 16 lines
Quoted 16 lines
Quoted 16 lines
during open and release of device file
Quoted 9 lines · Shijith Thotton
Quoted 7 lines · Qiming
Hi, Shijith
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
VF init error will happen after apply your patch, error log
as
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
below. If
revert your commit, all things work well. And this issue is
not
Quoted 11 lines
Quoted 10 lines
Quoted 10 lines
Quoted 10 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
only occur
in i40 VF but also ixgbe.
Hi Qiming,
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux
driver
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
for PF and DPDK for VF. (When VF used in a VM, Linux PF on host
and
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
DPDK VF on guest, this works fine)
And I confirm the function
igbuio_pci_open()added with belowpatch is
Quoted 39 lines
Quoted 38 lines
Quoted 38 lines
Quoted 38 lines
causing it.
igbuio_pci_open()does:
pci_reset_function(dev);
pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 21 lines
Quoted 21 lines
Quoted 21 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no ->
using
Quoted 33 lines
Quoted 32 lines
Quoted 32 lines
Quoted 32 lines
Quoted 32 lines
Quoted 32 lines
Quoted 32 lines
unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
Quoted 4 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084aAuthor: Shijith Thotton
<[email protected]<mailto:shijith.thotton@caviumnetworks
Quoted 11 lines
.com>>
Quoted 9 lines
Quoted 9 lines
Quoted 9 lines
Quoted 9 lines
Quoted 9 lines
Quoted 9 lines
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call
pci
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
reset
function inside open and release to clear device state at
start
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
and end.
Copied this behaviour from
vfio_pcikernel module code. Withthis patch,
it is not mandatory to issue FLR by PMD's during init and
close.
Quoted 5 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Bus master enable and disable are added in open and release
Quoted 8 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
respectively
to take care of device DMA.
Signed-off-by Shijith Thotton<[email protected]<mailto:shijith.thotton@caviumnetworks
Quoted 34 lines
.com>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Reviewed-by Jianfeng Tan<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Ferruh Yigit<[email protected]<mailto:[email protected]>>
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Acked-by Gregory Etelson<[email protected]<mailto:[email protected]>>
Quoted 23 lines
Quoted 23 lines
Quoted 23 lines
Quoted 23 lines
Quoted 23 lines
Quoted 6 lines
Quoted 9 lines
Best Regard,
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think,
Gregory
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
tested it for Intel NICs. Adding more people to the loop for
help.
Quoted 9 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 2 lines
I will try to reproduce the issue.
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Shijith
[Harish] We are seeing similar issue with the bringup of qede VF
devices due
Quoted 12 lines
to
Quoted 9 lines
Quoted 5 lines
this patch.
Could we revert this and leave it to individual PMDs to manage it?
Quoted 1 line
Quoted 1 line
Quoted 36 lines
-----Original Message-----
From: Yigit, Ferruh
Sent: Thursday, September 14, 2017 1:06 AM
To: Hu, Xuekun <[email protected]>; Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 11 lines · Xuekun
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 9 lines
Quoted 8 lines · Shijith Thotton
Quoted 7 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
Quoted 8 lines
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and DPDK VF on guest, this works fine)And I confirm the function
igbuio_pci_open()added with below patch is causing it.
Hi, Shijith
Could you tell why this adding is necessary? And confirm why this function will cause the vf init issue. As Harish said, it seems not only reproduced in intel NICs.
Qiming
Quoted 74 lines
igbuio_pci_open()does:pci_reset_function(dev); pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 68 lines
Quoted 53 lines
Quoted 53 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 2 lines
Shijith
Quoted 41 lines · Qiming
Quoted 41 lines
-----Original Message-----
From: Yigit, Ferruh
Sent: Thursday, September 14, 2017 1:06 AM
To: Hu, Xuekun <[email protected]>; Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 11 lines · Xuekun
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 9 lines
Quoted 8 lines · Shijith Thotton
Quoted 7 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and DPDK VF on guest, this works fine)
Quoted 5 lines
Quoted 3 lines
And I confirm the function
igbuio_pci_open()added with below patch is causing it.Hi, Shijith
Could you tell why this adding is necessary? And confirm why this function will cause the vf init issue. As Harish said, it seems not only reproduced in intel NICs.
Reset was added in open to make the device ready for init. I'm not sure about the exact cause of this issue and was unable to reproduce the same with LiquidIO VFs.
Reset happens during open and if VFs are not ready by the time init happens in PMD, it can fail. Issue could be in firmware as we don't see it for all versions. If there are no other way to fix this, I think, it is best to remove reset during open as it breaks PMD from multiple vendors.
Please try removing igbuio_pci_open.
Thanks,
Shijith
Quoted 75 lines
Quoted 74 lines
igbuio_pci_open()does:pci_reset_function(dev); pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 68 lines
Quoted 53 lines
Quoted 53 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 2 lines
Shijith
Quoted 52 lines · Shijith Thotton
Quoted 41 lines · Qiming
Quoted 41 lines
-----Original Message-----
From: Yigit, Ferruh
Sent: Thursday, September 14, 2017 1:06 AM
To: Hu, Xuekun <[email protected]>; Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 11 lines · Xuekun
I met the same issue too, only with i40e 2.1.26 PF kernel driver.
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ferruh Yigit
Sent: Wednesday, September 13, 2017 7:04 PM
To: Shijith Thotton <[email protected]>; Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>
Subject: Re: [dpdk-dev] vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 9 lines
Quoted 8 lines · Shijith Thotton
Quoted 7 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Hi Qiming,
I can reproduce the issue for the case:
1- i40e 2.1.26 PF kernel driver (NOT reproduced with 1.6.27-k)
2- DPDK app run on host, so both PF and VF are in host. Linux driver for PF and DPDK for VF. (When VF used in a VM, Linux PF on host and DPDK VF on guest, this works fine)Quoted 5 lines
Quoted 3 lines
And I confirm the function
igbuio_pci_open()added with below patch is causing it.Hi, Shijith
Could you tell why this adding is necessary? And confirm why this function will cause the vf init issue. As Harish said, it seems not only reproduced in intel NICs.Reset was added in open to make the device ready for init. I'm not sure about the exact cause of this issue and was unable to reproduce the same with LiquidIO VFs.
Quoted 6 lines
Reset happens during open and if VFs are not ready by the time init happens in PMD, it can fail. Issue could be in firmware as we don't see it for all versions. If there are no other way to fix this, I think, it is best to remove reset during open as it breaks PMD from multiple vendors.
Please try removing
igbuio_pci_open.
Sorry. Please try removing pci_reset_function from igbuio_pci_open.
Thanks,
Shijith
Quoted 75 lines
Quoted 75 lines
Quoted 74 lines
igbuio_pci_open()does:pci_reset_function(dev); pci_set_master(dev);Don't know yet root cause of the error, will dig more.
Quoted 68 lines
Quoted 53 lines
Quoted 53 lines
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Best Regard,
Quoted 9 lines
Quoted 3 lines
Yang Qiming
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
I will try to reproduce the issue.
Quoted 2 lines
Shijith
Quoted 75 lines
-----Original Message-----
From: Shijith Thotton [mailto:[email protected]]
Sent: Wednesday, September 13, 2017 6:49 PM
To: Yang, Qiming <[email protected]>; Gregory Etelson <[email protected]>
Cc: [email protected]; Tan, Jianfeng <[email protected]>; Yigit, Ferruh <[email protected]>
Subject: Re: vf init issue with patchigb_uio: issue FLR during open and release of device fileQuoted 58 lines · Qiming
Hi, Shijith
VF init error will happen after apply your patch, error log as below. If revert your commit, all things work well. And this issue is not only occur in i40 VF but also ixgbe.
Could you help to check it soon?
[root@localhost app]# ./testpmd -c 7 -n 4 -- -i
EAL: Detected 10 lcore(s)
EAL: No free hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using unreliable clock cycles !
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: Invalid NUMA socket, default to 0
EAL: probe driver: 8086:154c
net_i40e_vf
i40evf_init_vf():init_adminqfailed: -53
i40evf_dev_init(): Init vf failedEAL: Requested device 0000:00:03.0 cannot be used
commit
b58eedfc7dd57eef6d12e2c654a52c834f36084a
Author: Shijith Thotton <[email protected]>
Date: Fri Jul 7 16:43:51 2017 +0530
igb_uio: issue FLR during open and release of device fileSet UIO info device file operations open and release. Call pci reset function inside open and release to clear device state at start and end. Copied this behaviour from
vfio_pcikernel module code. With this patch, it is not mandatory to issue FLR by PMD's during init and close.Bus master enable and disable are added in open and release respectively to take care of device DMA.
Signed-off-by Shijith Thotton <[email protected]>Reviewed-by Jianfeng Tan <[email protected]>Acked-by Ferruh Yigit <[email protected]>Acked-by Gregory Etelson <[email protected]>Quoted 5 lines
Best Regard,
Yang Qiming
Quoted 6 lines
Hi Yang Qiming,
We didn't face this issue while preparing patch. I think, Gregory tested it for Intel NICs. Adding more people to the loop for help.
Shijith
Thanks a lot, Shijith
Qiming
PATCH 1/1 igb_uio: remove PCI reset during uio device open
In reply to Yang, QimingIssuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed. Bus master enable is kept as part of open since we disable it in uio device release.
--- lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
lib/librte_eal/linuxapp/igb_uio/igb_uio.c +1 -3
@@ -179,9 +179,7 @@ struct rte_uio_pci_dev {struct rte_uio_pci_dev *udev = info->priv;struct pci_dev *dev = udev->pdev; -pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */ +/* enable bus mastering on the device */ pci_set_master (dev);return 0 ;
Signature · 1 line
1.8.3.1
Re: [PATCH] igb_uio: remove PCI reset during uio device open
Quoted 9 lines · Shijith Thotton
Issuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed. Bus master enable is kept as part of open since we disable it in uio device release.
Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device file")Signed-off-by Shijith Thotton <[email protected]>
I can't re-produce the issue described by Qiming with this patch.
Hi Qiming,
Can you also please confirm the patch?
Thanks,
ferruh
Re: [PATCH] igb_uio: remove PCI reset during uio device open
In reply to Shijith ThottonQuoted 28 lines · Shijith Thotton
Issuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed. Bus master enable is kept as part of open since we disable it in uio device release.
Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release ofdevice file")
Cc: [email protected]Signed-off-by Shijith Thotton <[email protected]>---
lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 4 +---1 file changed, 1 insertion(+), 3 deletions(-)lib/librte_eal/linuxapp/igb_uio/igb_uio.c +0
-0@@ -179,9 +179,7 @@ struct rte_uio_pci_dev { struct rte_uio_pci_dev *udev = info->priv; struct pci_dev *dev = udev->pdev;lib/librte_eal/linuxapp/igb_uio/igb_uio.c +0
-3-pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */
lib/librte_eal/linuxapp/igb_uio/igb_uio.c +1
-0+/* enable bus mastering on the device */
Quoted 3 lines
pci_set_master(dev);
return 0;
Hi, we had the same issue, Chas applied and tested this patch on top of 17.08 and our QA department confirms that it fixes the problem.
Signature · 2 lines
Kind regards, Luca Boccassi
Re: [PATCH] igb_uio: remove PCI reset during uio device open
In reply to Shijith ThottonQuoted 41 lines
-----Original Message-----
From: Shijith Thotton [mailto:[email protected]]
Sent: Tuesday, September 19, 2017 6:24 PM
To: [email protected]
Cc: Yigit, Ferruh <[email protected]>; Thomas Monjalon <[email protected]>; Yang, Qiming <[email protected]>; Patil, Harish <[email protected]>; Zhang, Helin <[email protected]>; Gregory Etelson <[email protected]>; Tan, Jianfeng <[email protected]>; Hu, Xuekun <[email protected]>; Li, Xiaoyun <[email protected]>; Thotton, Shijith <[email protected]>; [email protected]
Subject: [PATCH]igb_uio: remove PCI reset during uio device openIssuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed.
Bus master enable is kept as part of open since we disable it in uio device release.Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device file")Signed-off-by Shijith Thotton <[email protected]>--- lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)lib/librte_eal/linuxapp/igb_uio/igb_uio.c +1
-4@@ -179,9 +179,7 @@ struct rte_uio_pci_dev {struct rte_uio_pci_dev *udev = info->priv;struct pci_dev *dev = udev->pdev; -pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */ +/* enable bus mastering on the device */ pci_set_master (dev);return 0 ; --
Quoted 1 line
1.8.3.1
Hi, applied and tested this patch with 17.08 DPDK VF and 2.1.26 kernel PF and it fixes the problem on 10G/25G/40G.
Re: [PATCH] igb_uio: remove PCI reset during uio device open
In reply to Shijith ThottonHi, Shijith
Only removing the PCI reset in uio device open function is not enough.
We faced an issue like:
1. Here is a FVL NIC, generate VF on one port, and then pass-through the VF by vfio-pci to VM:
For example:
echo 1 > /sys/bus/pci/devices/0000\:07\:00.1/sriov_numvfs
modprobe vfio-pci
echo "8086 154c" > /sys/bus/pci/drivers/vfio-pci/new_id
echo 0000:07:0a.0 > /sys/bus/pci/devices/0000\:07\:0a.0/driver/unbind
echo 0000:07:0a.0 > /sys/bus/pci/drivers/vfio-pci/bind
2. Start VM (by QEMU) in the VM, and in VM, bind the passthrough VF to igb_uio driver 3.Check the MSIX status of that VF, you can see the MSIX is enabled both in guest and host. For example:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSI
Capabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00
[root@dpdk2]# lspci -vv -s 07:0a.0 | grep MSI
Capabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 004. start dpdk example (e.g. testpmd)
5. quit the dpdk example
6. Check the MSIX status of that VF, you can see the MSIX is enabled in Guest, but disabled on host
Such like:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSI
Capabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00
[root@dpdk2 dpdk.org]# lspci -vv -s 07:0a.0 | grep MSI
Capabilities: [70] MSI-X: Enable- Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00
7. if restart dpdk application again, DPDK in VM cannot get any interrupts on that VF.
After investigate, I found current Qemu cannot support pci_reset_function well if the MSI-X is enabled on that VF.. Because when we use pci_reset_function to reset VF in in VM, the Qemu captures the control register reading/writing.
In pci_reset_function, it first reads the PCI configure and set FLR reset, and then writes PCI configure as restoration. But not all the writing are successful to Host.
If we look into the vfio-pci driver, you will find that, for different PCI CAP ID, the read/write functions are different. For PCI MSI-X, it cannot be write to host VF. I think that is because vfio already provides ioctl ops to deal with MSI-X cap.
So I think it is a common issue, not only for intel NICs.
There may be same ways to fix that:
1. fix Qemu to capture the FLR writing, and sync the Qemu's status on MSIX.
2. revert the patch in DPDK which introduced "pci_reset_function".
3. move the pci_reset_function from open/release func to igb_uio probe/remove func.
4. move the enable/disable MSIX from probe/remove to open/release func.
Any opinions?
Thanks
Jingjing
Quoted 43 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Shijith Thotton
Sent: Tuesday, September 19, 2017 6:24 PM
To: [email protected]
Cc: Yigit, Ferruh <[email protected]>; Thomas Monjalon <[email protected]>; Yang, Qiming <[email protected]>; Patil, Harish <[email protected]>; Zhang, Helin <[email protected]>; Gregory Etelson <[email protected]>; Tan, Jianfeng <[email protected]>; Hu, Xuekun <[email protected]>; Li, Xiaoyun <[email protected]>; Thotton, Shijith <[email protected]>; [email protected]
Subject: [dpdk-dev] [PATCH]igb_uio: remove PCI reset during uio device openIssuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed. Bus master enable is kept as part of open since we disable it in uio device release.
Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device file")Signed-off-by Shijith Thotton <[email protected]>--- lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)lib/librte_eal/linuxapp/igb_uio/igb_uio.c +1
-4@@ -179,9 +179,7 @@ struct rte_uio_pci_dev {struct rte_uio_pci_dev *udev = info->priv;struct pci_dev *dev = udev->pdev; -pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */ +/* enable bus mastering on the device */ pci_set_master (dev);return 0 ; --1.8.3.1
Re: [PATCH] igb_uio: remove PCI reset during uio device open
Quoted 49 lines · Jingjing
Hi, Shijith
Only removing the PCI reset in uio device open function is not enough.
We faced an issue like:
1. Here is a FVL NIC, generate VF on one port, and then pass-through the VF by vfio-pci to VM:
For example:
echo 1 > /sys/bus/pci/devices/0000\:07\:00.1/sriov_numvfs
modprobe vfio-pci
echo "8086 154c" >/sys/bus/pci/drivers/vfio-pci/new_id
echo 0000:07:0a.0 > /sys/bus/pci/devices/0000\:07\:0a.0/driver/unbind
echo 0000:07:0a.0 >/sys/bus/pci/drivers/vfio-pci/bind2. Start VM (by QEMU) in the VM, and in VM, bind the passthrough VF to
igb_uiodriver 3.Check the MSIX status of that VF, you can see the MSIX is enabled both in guest and host. For example:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSI
Capabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00[root@dpdk2]# lspci -vv -s 07:0a.0 | grep MSI Capabilities: [70] MSI-X: Enable+ Count=5 Masked- Capabilities: [a0] Express (v2) Endpoint, MSI 004. start dpdk example (e.g. testpmd)
5. quit the dpdk example
6. Check the MSIX status of that VF, you can see the MSIX is enabled in Guest, but disabled on hostSuch like:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSI
Capabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00[root@dpdk2 dpdk.org]# lspci -vv -s 07:0a.0 | grep MSI
Capabilities: [70] MSI-X: Enable- Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 007. if restart dpdk application again, DPDK in VM cannot get any interrupts on that VF.
After investigate, I found current Qemu cannot support
pci_reset_functionwell if the MSI-X is enabled on that VF.. Because when we usepci_reset_functionto reset VF in in VM, the Qemu captures the control register reading/writing.In
pci_reset_function, it first reads the PCI configure and set FLR reset, and then writes PCI configure as restoration. But not all the writing are successful to Host.
If we look into the vfio-pci driver, you will find that, for different PCI CAP ID, the read/write functions are different. For PCI MSI-X, it cannot be write to host VF. I think that is because vfio already provides ioctl ops to deal with MSI-X cap.So I think it is a common issue, not only for intel NICs.
Quoted 9 lines
There may be same ways to fix that:
1. fix Qemu to capture the FLR writing, and sync the Qemu's status on MSIX.
2. revert the patch in DPDK which introduced "pci_reset_function".
3. move thepci_reset_functionfrom open/release func toigb_uioprobe/remove func.
4. move the enable/disable MSIX from probe/remove to open/release func.Any opinions?
Hi Jingjing,
Thanks for finding the root cause. I'm in for reverting the patch (as there are chances of issues in future), even though option 4 can fix the issue for both side. If there are no expert opinion on this, please proceed with the best option.
Shijith
Quoted 44 lines
Quoted 43 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Shijith Thotton
Sent: Tuesday, September 19, 2017 6:24 PM
To: [email protected]
Cc: Yigit, Ferruh <[email protected]>; Thomas Monjalon <[email protected]>; Yang, Qiming <[email protected]>; Patil, Harish <[email protected]>; Zhang, Helin <[email protected]>; Gregory Etelson <[email protected]>; Tan, Jianfeng <[email protected]>; Hu, Xuekun <[email protected]>; Li, Xiaoyun <[email protected]>; Thotton, Shijith <[email protected]>; [email protected]
Subject: [dpdk-dev] [PATCH]igb_uio: remove PCI reset during uio device openIssuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed. Bus master enable is kept as part of open since we disable it in uio device release.
Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device file")Signed-off-by Shijith Thotton <[email protected]>--- lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)lib/librte_eal/linuxapp/igb_uio/igb_uio.c +1
-4@@ -179,9 +179,7 @@ struct rte_uio_pci_dev {struct rte_uio_pci_dev *udev = info->priv;struct pci_dev *dev = udev->pdev; -pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */ +/* enable bus mastering on the device */ pci_set_master (dev);return 0 ; --1.8.3.1
Re: [PATCH] igb_uio: remove PCI reset during uio device open
Hello,
Can we hold with revert until proper solution will be introduced ?
Regards,
Gregory
Quoted 132 lines · On Monday, 2 October 2017 21:24:19 IDT Shijith Thotton wrote:
Quoted 64 lines · Jingjing
Hi, Shijith
Only removing the PCI reset in uio device open function is not enough.
We faced an issue like:
1. Here is a FVL NIC, generate VF on one port, and then pass-through the VF by vfio-pci to VM: For example:
echo 1 > /sys/bus/pci/devices/0000\:07\:00.1/sriov_numvfs modprobe vfio-pci
echo "8086 154c" >/sys/bus/pci/drivers/vfio-pci/new_id
echo 0000:07:0a.0 > /sys/bus/pci/devices/0000\:07\:0a.0/driver/unbind echo 0000:07:0a.0 >/sys/bus/pci/drivers/vfio-pci/bind2. Start VM (by QEMU) in the VM, and in VM, bind the passthrough VF to
igb_uiodriver 3.Check the MSIX status of that VF, you can see the MSIX is enabled both in guest and host. For example:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSICapabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00[root@dpdk2]# lspci -vv -s 07:0a.0 | grep MSICapabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 004. start dpdk example (e.g. testpmd)
5. quit the dpdk example
6. Check the MSIX status of that VF, you can see the MSIX is enabled in Guest, but disabled on hostSuch like:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSICapabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00[root@dpdk2 dpdk.org]# lspci -vv -s 07:0a.0 | grep MSI
Capabilities: [70] MSI-X: Enable- Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00
7. if restart dpdk application again, DPDK in VM cannot get any interrupts on that VF.
After investigate, I found current Qemu cannot support
pci_reset_functionwell if the MSI-X is enabled on that VF.. Because when we usepci_reset_functionto reset VF in in VM, the Qemu captures the control register reading/writing.In
pci_reset_function, it first reads the PCI configure and set FLR reset, and then writes PCI configure as restoration. But not all the writing are successful to Host. If we look into the vfio-pci driver, you will find that, for different PCI CAP ID, the read/write functions are different. For PCI MSI-X, it cannot be write to host VF. I think that is because vfio already provides ioctl ops to deal with MSI-X cap.So I think it is a common issue, not only for intel NICs.
There may be same ways to fix that:
Quoted 8 lines
1. fix Qemu to capture the FLR writing, and sync the Qemu's status on MSIX.
2. revert the patch in DPDK which introduced "pci_reset_function".
3. move thepci_reset_functionfrom open/release func toigb_uioprobe/remove func. 4. move the enable/disable MSIX from probe/remove to open/release func.Any opinions?
Hi Jingjing,
Thanks for finding the root cause. I'm in for reverting the patch (as there are chances of issues in future), even though option 4 can fix the issue for both side. If there are no expert opinion on this, please proceed with the best option.
Shijith
Quoted 49 lines
Quoted 49 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Shijith Thotton
Sent: Tuesday, September 19, 2017 6:24 PM
To: [email protected]
Cc: Yigit, Ferruh <[email protected]>; Thomas Monjalon <[email protected]>; Yang, Qiming <[email protected]>; Patil, Harish <[email protected]>; Zhang, Helin <[email protected]>; Gregory Etelson <[email protected]>; Tan, Jianfeng <[email protected]>; Hu, Xuekun <[email protected]>; Li, Xiaoyun <[email protected]>; Thotton, Shijith <[email protected]>; [email protected]
Subject: [dpdk-dev] [PATCH]igb_uio: remove PCI reset during uio device openIssuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed. Bus master enable is kept as part of open since we disable it in uio device release.
Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release ofdevice file") Cc: [email protected]
Signed-off-by Shijith Thotton <[email protected]>---
lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)lib/librte_eal/linuxapp/igb_uio/igb_uio.c +1
-3@@ -179,9 +179,7 @@ struct rte_uio_pci_dev {struct rte_uio_pci_dev *udev = info->priv;struct pci_dev *dev = udev->pdev; -pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */ +/* enable bus mastering on the device */ pci_set_master (dev);return 0;
--
1.8.3.1
Re: [PATCH] igb_uio: remove PCI reset during uio device open
Quoted 134 lines · Gregory Etelson
Hello,
Can we hold with revert until proper solution will be introduced ?
Regards,
GregoryQuoted 126 lines · On Monday, 2 October 2017 21:24:19 IDT Shijith Thotton wrote:
Quoted 64 lines · Jingjing
Hi, Shijith
Only removing the PCI reset in uio device open function is not enough.
We faced an issue like:
1. Here is a FVL NIC, generate VF on one port, and then pass-through the VF by vfio-pci to VM: For example:
echo 1 > /sys/bus/pci/devices/0000\:07\:00.1/sriov_numvfs modprobe vfio-pci
echo "8086 154c" >/sys/bus/pci/drivers/vfio-pci/new_id
echo 0000:07:0a.0 > /sys/bus/pci/devices/0000\:07\:0a.0/driver/unbind echo 0000:07:0a.0 >/sys/bus/pci/drivers/vfio-pci/bind2. Start VM (by QEMU) in the VM, and in VM, bind the passthrough VF to
igb_uiodriver 3.Check the MSIX status of that VF, you can see the MSIX is enabled both in guest and host. For example:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSICapabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00[root@dpdk2]# lspci -vv -s 07:0a.0 | grep MSICapabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 004. start dpdk example (e.g. testpmd)
5. quit the dpdk example
6. Check the MSIX status of that VF, you can see the MSIX is enabled in Guest, but disabled on hostSuch like:
root@ubuntu-4:~ # lspci -vv -s 00:04.0 | grep MSICapabilities: [70] MSI-X: Enable+ Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00[root@dpdk2 dpdk.org]# lspci -vv -s 07:0a.0 | grep MSI
Capabilities: [70] MSI-X: Enable- Count=5 Masked-
Capabilities: [a0] Express (v2) Endpoint, MSI 00
7. if restart dpdk application again, DPDK in VM cannot get any interrupts on that VF.
After investigate, I found current Qemu cannot support
pci_reset_functionwell if the MSI-X is enabled on that VF.. Because when we usepci_reset_functionto reset VF in in VM, the Qemu captures the control register reading/writing.In
pci_reset_function, it first reads the PCI configure and set FLR reset, and then writes PCI configure as restoration. But not all the writing are successful to Host. If we look into the vfio-pci driver, you will find that, for different PCI CAP ID, the read/write functions are different. For PCI MSI-X, it cannot be write to host VF. I think that is because vfio already provides ioctl ops to deal with MSI-X cap.So I think it is a common issue, not only for intel NICs.
There may be same ways to fix that:
Quoted 8 lines
1. fix Qemu to capture the FLR writing, and sync the Qemu's status on MSIX.
2. revert the patch in DPDK which introduced "pci_reset_function".
3. move thepci_reset_functionfrom open/release func toigb_uioprobe/remove func. 4. move the enable/disable MSIX from probe/remove to open/release func.Any opinions?
Hi Jingjing,
Thanks for finding the root cause. I'm in for reverting the patch (as there are chances of issues in future), even though option 4 can fix the issue for both side. If there are no expert opinion on this, please proceed with the best option.
Shijith
Quoted 43 lines
Quoted 43 lines
-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Shijith Thotton
Sent: Tuesday, September 19, 2017 6:24 PM
To: [email protected]
Cc: Yigit, Ferruh <[email protected]>; Thomas Monjalon <[email protected]>; Yang, Qiming <[email protected]>; Patil, Harish <[email protected]>; Zhang, Helin <[email protected]>; Gregory Etelson <[email protected]>; Tan, Jianfeng <[email protected]>; Hu, Xuekun <[email protected]>; Li, Xiaoyun <[email protected]>; Thotton, Shijith <[email protected]>; [email protected]
Subject: [dpdk-dev] [PATCH]igb_uio: remove PCI reset during uio device openIssuing reset during uio device open caused PMD init failure for some NIC VFs (i40, ixgbe, qede) in host. So this initial reset is removed. Bus master enable is kept as part of open since we disable it in uio device release.
Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release ofdevice file") Cc: [email protected]
Signed-off-by Shijith Thotton <[email protected]>---
lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)lib/librte_eal/linuxapp/igb_uio/igb_uio.c +1
-3@@ -179,9 +179,7 @@ struct rte_uio_pci_dev {struct rte_uio_pci_dev *udev = info->priv;struct pci_dev *dev = udev->pdev; -pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */ +/* enable bus mastering on the device */
Quoted 8 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
lib/librte_eal/linuxapp/igb_uio/igb_uio.c +0
-0pci_set_master (dev);return 0;
--
1.8.3.1
Jingjing's patch[1] supersedes this patch, updating it in patchwork.
1. http://dpdk.org/dev/patchwork/patch/30022/
Shijith
PATCH 1/1 igb_uio: revert open and release operations
In reply to Yang, QimingSome VF drivers cannot work with igb_uio because of the reset done in these functions.
First bug report:
http://dpdk.org/ml/archives/dev/2017-September/075236.html
A partial reset was tried:
http://dpdk.org/patch/28940
Second bug report after a partial revert trial:
http://dpdk.org/ml/archives/dev/2017-September/076998.html
The patch author agreed to revert his patch:
http://dpdk.org/ml/archives/dev/2017-October/077158.html
There are also some patches available to fix issues with i40e:
http://dpdk.org/patch/30021 http://dpdk.org/patch/30022
This patch takes the simple option of reverting the initial patch and gives more time to properly improve igb_uio and PMDs.
--- lib/librte_eal/linuxapp/igb_uio/igb_uio.c | 33 ------------------------------- 1 file changed, 33 deletions(-)
lib/librte_eal/linuxapp/igb_uio/igb_uio.c +0 -33
@@ -220,37 +220,6 @@ igbuio_pci_irqhandler(int irq, struct uio_info *info)return IRQ_HANDLED ; } -/** -* This gets called while opening uio device file. -*/ -static int -igbuio_pci_open (struct uio_info *info,struct inode *inode) -{ -struct rte_uio_pci_dev *udev = info->priv; -struct pci_dev *dev = udev->pdev; - -pci_reset_function (dev); - -/* set bus master, which was cleared by the reset function */ -pci_set_master (dev); - -return 0 ; -} - -static int -igbuio_pci_release (struct uio_info *info,struct inode *inode) -{ -struct rte_uio_pci_dev *udev = info->priv; -struct pci_dev *dev = udev->pdev; - -/* stop the device from further DMA */ -pci_clear_master (dev); - -pci_reset_function (dev); - -return 0 ; -} -/* Remap pci resources described by bar #pci_bar in uio resource n. */ static int igbuio_pci_setup_iomem(struct pci_dev *dev, struct uio_info *info,
@@ -492,8 +461,6 @@ igbuio_pci_probe(struct pci_dev *dev, const struct pci_device_id *id) udev->info.version ="0.1" ; udev->info.handler = igbuio_pci_irqhandler; udev->info.irqcontrol = igbuio_pci_irqcontrol; - udev->info.open = igbuio_pci_open; - udev->info.release = igbuio_pci_release; udev->info.priv = udev; udev->pdev = dev;
Signature · 1 line
2.14.1
Re: [PATCH] igb_uio: revert open and release operations
Quoted 19 lines · Thomas Monjalon
Some VF drivers cannot work with
igb_uiobecause of the reset done in these functions.First bug report:
http://dpdk.org/ml/archives/dev/2017-September/075236.htmlA partial reset was tried:
http://dpdk.org/patch/28940Second bug report after a partial revert trial:
http://dpdk.org/ml/archives/dev/2017-September/076998.htmlThe patch author agreed to revert his patch:
http://dpdk.org/ml/archives/dev/2017-October/077158.htmlThere are also some patches available to fix issues with i40e:
http://dpdk.org/patch/30021 http://dpdk.org/patch/30022
Quoted 8 lines
This patch takes the simple option of reverting the initial patch and gives more time to properly improve
igb_uioand PMDs.Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device file")Reported-by Qiming Yang <[email protected]>Reported-by Jingjing Wu <[email protected]>Signed-off-by Thomas Monjalon <[email protected]>
Hi Thomas,
I put already some comment into other fix patch [1].
Mainly taking into account of current time for release, this patch make sense, but I suggest giving a chance to the fix mentioned above.
Because the original patch is for safer igb_uio, and fixing a few times reported issue.
Since this is rc1, we have time for testing, and many parties will be doing tests. Lets get the fix for rc1, and if we find any issue revert the patch?
Thanks,
ferruh
Re: [PATCH] igb_uio: revert open and release operations
13/10/2017 23:05, Ferruh Yigit:
Quoted 36 lines · Thomas Monjalon
Quoted 19 lines
Some VF drivers cannot work with
igb_uiobecause of the reset done in these functions.First bug report:
http://dpdk.org/ml/archives/dev/2017-September/075236.htmlA partial reset was tried:
http://dpdk.org/patch/28940Second bug report after a partial revert trial:
http://dpdk.org/ml/archives/dev/2017-September/076998.htmlThe patch author agreed to revert his patch:
http://dpdk.org/ml/archives/dev/2017-October/077158.htmlThere are also some patches available to fix issues with i40e:
http://dpdk.org/patch/30021 http://dpdk.org/patch/30022Quoted 8 lines
This patch takes the simple option of reverting the initial patch and gives more time to properly improve
igb_uioand PMDs.Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device file")Reported-by Qiming Yang <[email protected]>Reported-by Jingjing Wu <[email protected]>Signed-off-by Thomas Monjalon <[email protected]>Hi Thomas,
I put already some comment into other fix patch [1].
Mainly taking into account of current time for release, this patch make sense, but I suggest giving a chance to the fix mentioned above.
Quoted 6 lines
Because the original patch is for safer
igb_uio, and fixing a few times reported issue.Since this is rc1, we have time for testing, and many parties will be doing tests. Lets get the fix for rc1, and if we find any issue revert the patch?
OK, please check it works for every VF drivers.
There was an issue reported with bnxt.
Re: [PATCH] igb_uio: revert open and release operations
13/10/2017 23:11, Thomas Monjalon:
Quoted 40 lines
13/10/2017 23:05, Ferruh Yigit:
Quoted 39 lines · Thomas Monjalon
Quoted 19 lines
Some VF drivers cannot work with
igb_uiobecause of the reset done in these functions.First bug report:
http://dpdk.org/ml/archives/dev/2017-September/075236.htmlA partial reset was tried:
http://dpdk.org/patch/28940Second bug report after a partial revert trial:
http://dpdk.org/ml/archives/dev/2017-September/076998.htmlThe patch author agreed to revert his patch:
http://dpdk.org/ml/archives/dev/2017-October/077158.htmlThere are also some patches available to fix issues with i40e:
http://dpdk.org/patch/30021 http://dpdk.org/patch/30022Quoted 8 lines
This patch takes the simple option of reverting the initial patch and gives more time to properly improve
igb_uioand PMDs.Fixes b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device file")Reported-by Qiming Yang <[email protected]>Reported-by Jingjing Wu <[email protected]>Signed-off-by Thomas Monjalon <[email protected]>Hi Thomas,
I put already some comment into other fix patch [1].
Mainly taking into account of current time for release, this patch make sense, but I suggest giving a chance to the fix mentioned above.
Because the original patch is for safer
igb_uio, and fixing a few times reported issue.
Quoted 6 lines
Quoted 3 lines
Since this is rc1, we have time for testing, and many parties will be doing tests. Lets get the fix for rc1, and if we find any issue revert the patch?
OK, please check it works for every VF drivers.
There was an issue reported with bnxt.
Sorry, it was qede.