RE: [RFT][PATCH v2 0/9] Update vfio_pin/unpin_pages API

Xu, Terrence posted 9 patches 3 years, 9 months ago
Only 0 patches received!
RE: [RFT][PATCH v2 0/9] Update vfio_pin/unpin_pages API
Posted by Xu, Terrence 3 years, 9 months ago
> -----Original Message-----
> From: intel-gvt-dev <intel-gvt-dev-bounces@lists.freedesktop.org> On Behalf Of
> On Thu, Jul 07, 2022 at 06:08:45AM +0000, Tian, Kevin wrote:
> 
> > > Request for testing: I only did build for s390 and i915 code, so
> > > it'd be nice to have people who have environment to run sanity accordingly.
> > >
> >
> > +Terrence who is testing it for i915 now...
> 
> Hi Terrence, would it be possible for you to pull v3 to test on?
> https://github.com/nicolinc/iommufd/commits/dev/vfio_pin_pages-v3
> 
> They are basically same but there's a new DIV_ROUND_UP change, which
> shouldn't result in any functional difference, IMHO. If
> v3 passes, I can simply add your Tested-by when I respin it.

Hi Nicolin, I already completed KVMGT key feature testing based on your v3 repo, VM booted up successfully and run smoothly, but there is a call trace during each time VM booting up, as the attachment.

[ 4379.881770] ------------[ cut here ]------------
[ 4379.881776] WARNING: CPU: 1 PID: 4042 at drivers/vfio/vfio_iommu_type1.c:1167 vfio_remove_dma+0xb3/0xc0 [vfio_iommu_type1]
[ 4379.881818] Modules linked in: binfmt_misc nfnetlink bridge stp llc rfcomm cmac algif_hash algif_skcipher af_alg bnep snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic ledtrig_audio snd_hda_intel snd_intel_dspcfg snd_hda_codec snd_hda_core snd_hwdep snd_pcm intel_rapl_msr intel_rapl_common x86_pkg_temp_thermal intel_powerclamp coretemp snd_seq_midi snd_seq_midi_event snd_rawmidi kvm_intel btusb snd_seq btrtl rapl btbcm btintel snd_seq_device intel_cstate input_leds snd_timer bluetooth serio_raw mei_me ecdh_generic mxm_wmi ecc snd soundcore mei mac_hid acpi_pad sch_fq_codel kvmgt mdev vfio_iommu_type1 vfio kvm irqbypass parport_pc ppdev lp parport nfsd auth_rpcgss nfs_acl lockd grace sunrpc ip_tables x_tables autofs4 btrfs blake2b_generic zstd_compress raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor raid6_pq libcrc32c raid1 raid0 multipath linear dm_mirror dm_region_hash dm_log i915 i2c_algo_bit cec rc_core drm_buddy ttm drm_display_helper
[ 4379.882092]  drm_kms_helper crct10dif_pclmul syscopyarea sysfillrect crc32_pclmul sysimgblt ghash_clmulni_intel fb_sys_fops aesni_intel crypto_simd e1000e cryptd i2c_i801 psmouse ptp drm i2c_smbus ahci pps_core libahci hid_generic wmi video usbhid hid
[ 4379.882173] CPU: 1 PID: 4042 Comm: qemu-system-x86 Tainted: G        W         5.19.0-rc1-next-20220606+ #1
[ 4379.882187] Hardware name: Supermicro C7Z370-CG-IW/C7Z370-CG-IW, BIOS 1.1 02/08/2018
[ 4379.882194] RIP: 0010:vfio_remove_dma+0xb3/0xc0 [vfio_iommu_type1]
[ 4379.882218] Code: d5 48 89 df e8 ee 28 67 d5 41 83 44 24 78 01 5b 41 5c 5d c3 e8 8e 57 3f d5 eb b3 be 03 00 00 00 48 89 d7 e8 df 11 94 d5 eb a4 <0f> 0b e9 65 ff ff ff 66 0f 1f 44 00 00 0f 1f 44 00 00 55 48 89 e5
[ 4379.882230] RSP: 0018:ffffad03835a7bc8 EFLAGS: 00010282
[ 4379.882242] RAX: ffff8df213fa0380 RBX: ffff8df1d2d28060 RCX: 00000000802a0009
[ 4379.882251] RDX: 0000000000000000 RSI: ffff8df1d2d28060 RDI: ffff8df2c2ce1180
[ 4379.882259] RBP: ffffad03835a7bd8 R08: ffff8df1d2d28300 R09: 00000000802a0009
[ 4379.882267] R10: ffff8df213d1dc00 R11: fffffffffffffffe R12: ffff8df2c2ce1180
[ 4379.882275] R13: ffff8df1c87cf900 R14: ffff8df2c2ce11a0 R15: ffff8df1c71a9900
[ 4379.882284] FS:  0000000000000000(0000) GS:ffff8df91aa40000(0000) knlGS:0000000000000000
[ 4379.882294] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 4379.882302] CR2: 00007fbf5c950290 CR3: 00000002b5886003 CR4: 00000000003726e0
[ 4379.882311] Call Trace:
[ 4379.882316]  <TASK>
[ 4379.882325]  vfio_iommu_unmap_unpin_all+0x20/0x40 [vfio_iommu_type1]
[ 4379.882348]  vfio_iommu_type1_detach_group+0x123/0x560 [vfio_iommu_type1]
[ 4379.882369]  ? security_file_free+0x54/0x60
[ 4379.882388]  __vfio_group_unset_container+0x4c/0x1b0 [vfio]
[ 4379.882415]  vfio_group_fops_release+0x52/0x80 [vfio]
[ 4379.882438]  __fput+0x99/0x260
[ 4379.882451]  ____fput+0xe/0x10
[ 4379.882460]  task_work_run+0x6c/0xa0
[ 4379.882475]  do_exit+0x355/0xb70
[ 4379.882492]  do_group_exit+0x35/0xa0
[ 4379.882506]  get_signal+0x946/0x950
[ 4379.882519]  arch_do_signal_or_restart+0x37/0x770
[ 4379.882536]  ? do_futex+0x118/0x1a0
[ 4379.882554]  exit_to_user_mode_prepare+0x9b/0x180
[ 4379.882569]  syscall_exit_to_user_mode+0x29/0x40
[ 4379.882582]  do_syscall_64+0x46/0x80
[ 4379.882597]  entry_SYSCALL_64_after_hwframe+0x46/0xb0
[ 4379.882610] RIP: 0033:0x7f9ffcb97376
[ 4379.882621] Code: Unable to access opcode bytes at RIP 0x7f9ffcb9734c.
[ 4379.882627] RSP: 002b:00007f9ff9d275b0 EFLAGS: 00000282 ORIG_RAX: 00000000000000ca
[ 4379.882639] RAX: fffffffffffffe00 RBX: 0000000000000000 RCX: 00007f9ffcb97376
[ 4379.882647] RDX: 0000000000000000 RSI: 0000000000000080 RDI: 00005567e17a8f2c
[ 4379.882655] RBP: 00005567e17a8f00 R08: 0000000000000000 R09: 0000000000000004
[ 4379.882662] R10: 0000000000000000 R11: 0000000000000282 R12: 00005567e17a8f24
[ 4379.882669] R13: 00005567df8f5200 R14: 00007f9ff9d275f0 R15: 00005567e17a8f2c
[ 4379.882686]  </TASK>
[ 4379.882692] ---[ end trace 0000000000000000 ]---
[ 4423.824057] device tap1 left promiscuous mode
[ 4423.824085] sw0: port 3(tap1) entered disabled state
Re: [RFT][PATCH v2 0/9] Update vfio_pin/unpin_pages API
Posted by Nicolin Chen 3 years, 9 months ago
On Fri, Jul 08, 2022 at 07:24:30AM +0000, Xu, Terrence wrote:
> External email: Use caution opening links or attachments
> 
> 
> > -----Original Message-----
> > From: intel-gvt-dev <intel-gvt-dev-bounces@lists.freedesktop.org> On Behalf Of
> > On Thu, Jul 07, 2022 at 06:08:45AM +0000, Tian, Kevin wrote:
> >
> > > > Request for testing: I only did build for s390 and i915 code, so
> > > > it'd be nice to have people who have environment to run sanity accordingly.
> > > >
> > >
> > > +Terrence who is testing it for i915 now...
> >
> > Hi Terrence, would it be possible for you to pull v3 to test on?
> > https://github.com/nicolinc/iommufd/commits/dev/vfio_pin_pages-v3
> >
> > They are basically same but there's a new DIV_ROUND_UP change, which
> > shouldn't result in any functional difference, IMHO. If
> > v3 passes, I can simply add your Tested-by when I respin it.
> 
> Hi Nicolin, I already completed KVMGT key feature testing based on
> your v3 repo, VM booted up successfully and run smoothly, but there
> is a call trace during each time VM booting up, as the attachment.

Nice! Thank you for the testing. I will add your Tested-by in v3.